:root {
  --accent: #6c63ff;
  --accent-strong: #4f46e5;
  --text: #12131a;
  --muted: #5d6475;
  --line: rgba(18, 19, 26, 0.1);
  --surface: #ffffff;
  --surface-tint: #f5f7ff;
  --surface-deep: #111827;
  --surface-soft: #f7f8fc;
  --shadow: 0 18px 60px rgba(17, 24, 39, 0.08);
  --shadow-soft: 0 12px 36px rgba(17, 24, 39, 0.06);
  --radius: 24px;
  --radius-md: 18px;
  --container: min(1180px, calc(100vw - 32px));
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at top right, rgba(108, 99, 255, 0.12), transparent 24%),
    linear-gradient(180deg, #f8faff 0%, #ffffff 30%, #ffffff 100%);
  font-family: "Inter", "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic", "Meiryo", sans-serif;
  line-height: 1.8;
  letter-spacing: 0.01em;
}

body.admin-bar .site-header {
  top: 32px;
}

a {
  color: inherit;
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--accent-strong);
}

img {
  max-width: 100%;
  display: block;
}

input,
button,
textarea,
select {
  font: inherit;
}

button,
input[type="submit"] {
  cursor: pointer;
}

.container {
  width: var(--container);
  margin-inline: auto;
}

.site-shell {
  min-height: 100vh;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(20px);
  background: rgba(255, 255, 255, 0.88);
  border-bottom: 1px solid rgba(18, 19, 26, 0.06);
}

.header-inner {
  min-height: 88px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.site-branding {
  display: flex;
  align-items: center;
  gap: 16px;
}

.site-logo-wrap img {
  max-height: 56px;
  width: auto;
}

.site-title {
  margin: 0;
  font-size: 1.2rem;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.site-title a {
  text-decoration: none;
}

.site-description {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.main-navigation {
  display: flex;
  align-items: center;
  gap: 24px;
}

.main-navigation ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  gap: 20px;
  align-items: center;
}

.main-navigation a {
  text-decoration: none;
  font-weight: 700;
}

.header-actions {
  width: min(280px, 34vw);
}

.search-form {
  display: flex;
  gap: 10px;
  align-items: stretch;
}

.search-form label {
  flex: 1;
}

.search-field,
.footer-signup input,
.comment-form input,
.comment-form textarea {
  width: 100%;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.94);
  padding: 14px 16px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.comment-form textarea {
  min-height: 180px;
  border-radius: 20px;
}

.search-field:focus,
.footer-signup input:focus,
.comment-form input:focus,
.comment-form textarea:focus {
  outline: none;
  border-color: rgba(108, 99, 255, 0.4);
  box-shadow: 0 0 0 4px rgba(108, 99, 255, 0.08);
}

.search-submit,
.button-primary,
.button-secondary,
.footer-signup button,
.comment-form input[type="submit"] {
  border: 0;
  border-radius: 999px;
  padding: 14px 18px;
  font-weight: 700;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  white-space: nowrap;
}

.search-submit,
.button-primary,
.footer-signup button,
.comment-form input[type="submit"] {
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  color: white;
  box-shadow: 0 10px 30px rgba(79, 70, 229, 0.22);
}

.button-secondary {
  background: rgba(255, 255, 255, 0.78);
  color: var(--text);
  border: 1px solid var(--line);
}

.search-submit:hover,
.button-primary:hover,
.button-secondary:hover,
.footer-signup button:hover,
.comment-form input[type="submit"]:hover {
  transform: translateY(-1px);
}

.sidebar-column .search-form {
  flex-direction: column;
}

.sidebar-column .search-field,
.sidebar-column .search-submit {
  border-radius: 0;
}

.sidebar-column .search-submit {
  width: 100%;
  box-shadow: none;
}

.menu-toggle,
.back-to-top {
  display: none;
  border: 0;
  background: rgba(255, 255, 255, 0.92);
  border-radius: 999px;
  box-shadow: var(--shadow-soft);
}

.menu-toggle {
  width: 52px;
  height: 52px;
  align-items: center;
  justify-content: center;
  padding: 0;
  flex-direction: column;
  gap: 5px;
}

.menu-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--text);
  border-radius: 999px;
}

.reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  transform-origin: left center;
  transform: scaleX(0);
  background: linear-gradient(90deg, var(--accent), #9b8cff);
  z-index: 99;
}

.page-section {
  padding: 64px 0;
}

.stack-gap {
  display: grid;
  gap: 28px;
}

.narrow-stack {
  max-width: 860px;
}

.hero-wrap {
  padding-top: 42px;
}

.hero-card,
.card {
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(18, 19, 26, 0.06);
  box-shadow: var(--shadow);
  border-radius: var(--radius);
}

.hero-card {
  display: grid;
  grid-template-columns: 1.35fr 0.85fr;
  gap: 32px;
  padding: 44px;
  background:
    radial-gradient(circle at 0% 0%, rgba(108, 99, 255, 0.1), transparent 34%),
    linear-gradient(160deg, #ffffff 0%, var(--surface-tint) 100%);
}

.hero-copy h1,
.section-heading h1,
.section-heading h2,
.single-header h1,
.page-header h1,
.error-card h1 {
  line-height: 1.1;
  letter-spacing: -0.04em;
  margin: 0;
}

.hero-copy h1 {
  font-size: clamp(2.5rem, 5vw, 4.4rem);
  max-width: 11ch;
}

.hero-text,
.section-heading p,
.single-header .post-meta,
.entry-footer-card,
.footer-intro p,
.widget,
.prose,
.sidebar-card p {
  color: var(--muted);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 16px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.74rem;
  color: var(--accent-strong);
  font-weight: 800;
}

.hero-actions,
.post-nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
}

.hero-aside {
  display: grid;
  gap: 16px;
  align-content: start;
}

.hero-stat,
.hero-note,
.sidebar-card,
.widget,
.comments-area,
.entry-footer-card,
.page-article,
.error-card {
  padding: 24px;
}

.hero-stat {
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(108, 99, 255, 0.12);
  border-radius: var(--radius-md);
}

.hero-stat span {
  display: block;
  font-size: 2rem;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 8px;
}

.hero-note strong {
  display: block;
  margin-bottom: 10px;
  color: var(--text);
}

.hero-note p,
.error-card p {
  margin-bottom: 0;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
}

.section-heading.compact {
  align-items: start;
  justify-content: start;
  flex-direction: column;
}

.text-link {
  font-weight: 700;
  text-decoration: none;
}

.feature-story {
  display: grid;
  grid-template-columns: 1.12fr 0.88fr;
  overflow: hidden;
}

.feature-media,
.post-media {
  display: block;
  background: linear-gradient(135deg, rgba(108, 99, 255, 0.18), rgba(108, 99, 255, 0.05));
}

.feature-media img,
.single-thumbnail img,
.post-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.feature-content {
  padding: 34px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.feature-content h3,
.post-card .entry-title {
  font-size: clamp(1.3rem, 2vw, 2.15rem);
  line-height: 1.25;
  letter-spacing: -0.03em;
  margin: 12px 0;
}

.post-card .entry-title {
  font-size: 1.28rem;
}

.post-card .entry-title a,
.feature-content h3 a,
.footer-widget a,
.widget a,
.sidebar-card a {
  text-decoration: none;
}

.post-grid {
  display: grid;
  gap: 24px;
}

.post-grid.three-col {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.post-grid.two-col {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.post-card {
  overflow: hidden;
  transform: translateY(12px);
  opacity: 0;
  transition: transform 0.45s ease, opacity 0.45s ease, box-shadow 0.2s ease;
}

.post-card:hover {
  box-shadow: 0 20px 48px rgba(17, 24, 39, 0.1);
}

.post-card.is-revealed {
  transform: translateY(0);
  opacity: 1;
}

.post-card-body {
  padding: 24px;
}

.post-media {
  aspect-ratio: 1.45 / 1;
}

.image-fallback {
  aspect-ratio: 1.45 / 1;
  display: grid;
  place-items: center;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent-strong);
}

.post-chip,
.topic-cloud li a,
.tag-list a {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 8px 12px;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--accent-strong);
  background: rgba(108, 99, 255, 0.08);
  text-decoration: none;
}

.post-meta,
.entry-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  font-size: 0.92rem;
  color: var(--muted);
}

.meta-separator {
  color: rgba(18, 19, 26, 0.3);
}

.topic-cloud ul,
.footer-widget ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.sidebar-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 12px;
}

.sidebar-list li,
.footer-widget li,
.topic-cloud li {
  margin: 0;
}

.sidebar-list a,
.footer-widget li a {
  font-weight: 600;
}

.topic-cloud li a {
  gap: 8px;
}

.topic-cloud .count,
.sidebar-list .count,
.footer-widget .count {
  opacity: 0.75;
}

.single-layout {
  display: grid;
  gap: 28px;
  grid-template-columns: minmax(0, 1fr) 320px;
  align-items: start;
}

.single-header,
.page-header {
  margin-bottom: 24px;
}

.single-header h1,
.page-header h1 {
  font-size: clamp(2.1rem, 4vw, 3.8rem);
}

.single-thumbnail {
  margin: 24px 0;
  overflow: hidden;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.prose {
  font-size: 1.05rem;
  line-height: 2;
}

.prose > *:first-child {
  margin-top: 0;
}

.prose > *:last-child {
  margin-bottom: 0;
}

.prose h2,
.prose h3,
.prose h4 {
  color: var(--text);
  line-height: 1.3;
  letter-spacing: -0.03em;
  margin-top: 1.8em;
  margin-bottom: 0.7em;
}

.prose p,
.prose ul,
.prose ol {
  margin-top: 0;
  margin-bottom: 1.2em;
}

.prose blockquote {
  margin: 32px 0;
  padding: 20px 24px;
  border-left: 4px solid var(--accent);
  background: rgba(108, 99, 255, 0.06);
  border-radius: 0 18px 18px 0;
}

.prose code,
.prose pre {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

.prose pre {
  overflow: auto;
  padding: 18px;
  background: #111827;
  color: #f9fafb;
  border-radius: 20px;
}

.entry-footer-card {
  margin-top: 24px;
  display: grid;
  gap: 18px;
}

.tag-list {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.sidebar-column {
  display: grid;
  gap: 18px;
  position: sticky;
  top: 110px;
}

.widget,
.sidebar-card,
.comments-area,
.entry-footer-card,
.page-article,
.error-card,
.footer-widget,
.footer-intro {
  box-shadow: var(--shadow-soft);
}

.widget-title,
.comments-title,
.comment-reply-title,
.footer-intro h2,
.sidebar-card h2 {
  margin-top: 0;
  margin-bottom: 12px;
  line-height: 1.3;
  letter-spacing: -0.03em;
  color: var(--text);
}

.widget-title,
.sidebar-card h2,
.footer-intro h2 {
  font-size: 1.15rem;
}

.comments-area {
  margin-top: 24px;
}

.comment-list {
  list-style: none;
  padding: 0;
  margin: 0 0 24px;
}

.comment-list li {
  padding: 18px 0;
  border-top: 1px solid var(--line);
}

.comment-list li:first-child {
  border-top: 0;
}

.footer-grid {
  padding: 72px 0 26px;
  display: grid;
  gap: 28px;
  grid-template-columns: 1.15fr 0.85fr;
}

.footer-intro,
.footer-widget {
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(18, 19, 26, 0.06);
  border-radius: var(--radius);
  padding: 24px;
}

.footer-signup {
  margin-top: 20px;
  display: flex;
  gap: 12px;
}

.footer-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 32px;
  color: var(--muted);
  font-size: 0.95rem;
}

.error-card,
.empty-state {
  text-align: center;
}

.empty-state {
  padding: 28px;
}

.navigation.pagination,
.posts-navigation,
.post-navigation,
.comment-navigation {
  display: flex;
  justify-content: center;
  margin-top: 20px;
}

.nav-links {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.page-numbers,
.nav-links a,
.nav-links span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  padding: 10px 14px;
  border-radius: 999px;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid var(--line);
}

.current {
  background: rgba(108, 99, 255, 0.12);
  color: var(--accent-strong);
  border-color: rgba(108, 99, 255, 0.16);
}

.back-to-top {
  position: fixed;
  right: 18px;
  bottom: 18px;
  width: 48px;
  height: 48px;
  z-index: 50;
  opacity: 0;
  transform: translateY(8px);
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  display: grid;
  place-items: center;
}

.back-to-top.is-visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.screen-reader-text {
  position: absolute;
  clip: rect(1px, 1px, 1px, 1px);
  padding: 0;
  border: 0;
  height: 1px;
  width: 1px;
  overflow: hidden;
}

@media (max-width: 1024px) {
  body.admin-bar .site-header {
    top: 46px;
  }

  .hero-card,
  .feature-story,
  .footer-grid,
  .single-layout,
  .post-grid.three-col,
  .post-grid.two-col {
    grid-template-columns: 1fr;
  }

  .main-navigation {
    position: fixed;
    inset: 88px 16px auto;
    border-radius: 24px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: var(--shadow);
    border: 1px solid var(--line);
    display: none;
    flex-direction: column;
    align-items: stretch;
  }

  .main-navigation ul,
  .main-navigation .menu {
    flex-direction: column;
    align-items: stretch;
  }

  .main-navigation.is-open {
    display: flex;
  }

  .header-actions {
    width: 100%;
  }

  .menu-toggle {
    display: inline-flex;
  }

  .sidebar-column {
    position: static;
  }
}

@media (max-width: 700px) {
  body.admin-bar .site-header {
    top: 0;
  }

  .header-inner {
    min-height: 78px;
  }

  .hero-card,
  .feature-content,
  .post-card-body,
  .page-article,
  .sidebar-card,
  .widget,
  .footer-intro,
  .footer-widget,
  .comments-area,
  .entry-footer-card,
  .error-card,
  .empty-state {
    padding: 20px;
  }

  .hero-copy h1,
  .single-header h1,
  .page-header h1,
  .section-heading h1,
  .section-heading h2 {
    font-size: clamp(2rem, 9vw, 2.8rem);
  }

  .search-form,
  .hero-actions,
  .footer-signup,
  .footer-meta,
  .post-nav-links {
    flex-direction: column;
    align-items: stretch;
  }
}


:focus-visible {
  outline: 3px solid rgba(108, 99, 255, 0.34);
  outline-offset: 3px;
}

body {
  word-break: normal;
  overflow-wrap: anywhere;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -48px;
  z-index: 120;
  padding: 12px 16px;
  border-radius: 999px;
  background: #111827;
  color: #fff;
  text-decoration: none;
  transition: top 0.2s ease;
}

.skip-link:focus {
  top: 16px;
}

.header-actions .search-form {
  background: rgba(248, 250, 255, 0.9);
  border: 1px solid rgba(18, 19, 26, 0.06);
  border-radius: 999px;
  padding: 6px;
}

.header-actions .search-field,
.header-actions .search-submit {
  border-radius: 999px;
}

.header-actions .search-field {
  border-color: transparent;
  background: transparent;
  padding-block: 12px;
}

.sidebar-column .widget,
.sidebar-column .sidebar-card {
  background: rgba(255, 255, 255, 0.92);
}

.sidebar-column .widget > *:last-child,
.sidebar-column .sidebar-card > *:last-child,
.single-article > *:last-child {
  margin-bottom: 0;
}

.sidebar-column .widget ul:not(.children),
.sidebar-column .widget ol,
.footer-widget ul,
.footer-widget ol {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.sidebar-column .widget li,
.footer-widget li {
  padding: 10px 0;
  border-top: 1px solid var(--line);
}

.sidebar-column .widget li:first-child,
.footer-widget li:first-child {
  border-top: 0;
  padding-top: 0;
}

.sidebar-column .widget li:last-child,
.footer-widget li:last-child {
  padding-bottom: 0;
}

.breadcrumbs {
  padding: 14px 20px;
  border-radius: 18px;
  box-shadow: var(--shadow-soft);
}

.breadcrumbs ol {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
  font-size: 0.94rem;
  color: var(--muted);
}

.breadcrumbs li {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.breadcrumbs li + li::before {
  content: '/';
  color: rgba(18, 19, 26, 0.28);
  margin-right: 2px;
}

.breadcrumbs a {
  text-decoration: none;
}

.layout-full {
  grid-column: 1 / -1;
}

.single-article {
  display: grid;
  gap: 24px;
}

.single-header .post-meta {
  margin-top: 12px;
}

.single-content.card,
.page-article {
  padding: 34px;
}

.single-content > * {
  max-width: 100%;
}

.single-content img {
  border-radius: 18px;
}

.single-content table {
  width: 100%;
  border-collapse: collapse;
  display: block;
  overflow-x: auto;
}

.single-content th,
.single-content td {
  border: 1px solid var(--line);
  padding: 12px 14px;
  text-align: left;
}

.single-content th {
  background: rgba(108, 99, 255, 0.06);
}

.content-outline {
  padding: 22px 24px;
}

.content-outline.is-empty {
  display: none;
}

.content-outline-title {
  margin: 0 0 14px;
  font-size: 1.04rem;
  line-height: 1.3;
}

.content-outline-list,
.content-outline-list ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.content-outline-list {
  display: grid;
  gap: 10px;
}

.content-outline-list ul {
  display: grid;
  gap: 8px;
  margin-top: 8px;
  padding-left: 18px;
  border-left: 1px solid rgba(18, 19, 26, 0.08);
}

.content-outline a {
  text-decoration: none;
  color: var(--muted);
  font-weight: 600;
}

.content-outline a:hover,
.content-outline a.is-active {
  color: var(--accent-strong);
}

.author-box {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 20px;
  align-items: start;
  padding: 24px;
}

.author-avatar img {
  width: 96px;
  height: 96px;
  border-radius: 999px;
}

.author-content h2 {
  margin: 0 0 10px;
  font-size: 1.35rem;
  line-height: 1.25;
}

.author-content h2 a {
  text-decoration: none;
}

.related-posts {
  margin-top: 6px;
}

.related-grid .post-card .entry-title {
  font-size: 1.14rem;
}

.nav-card-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.nav-card {
  display: block;
}

.nav-card a {
  display: block;
  min-height: 100%;
  padding: 16px 18px;
  border-radius: 18px;
  background: rgba(248, 250, 255, 0.92);
  border: 1px solid rgba(18, 19, 26, 0.06);
  text-decoration: none;
  color: var(--text);
  font-weight: 700;
}

.nav-card a:hover {
  background: rgba(108, 99, 255, 0.08);
}

.quick-links-card li {
  color: var(--muted);
}

.section-heading.compact p,
.section-heading.compact h1,
.section-heading.compact h2 {
  max-width: 18ch;
}

.empty-state .search-form,
.error-card .search-form {
  max-width: 560px;
  margin: 18px auto 0;
}

.footer-signup input {
  border-radius: 18px;
}

.footer-signup button {
  min-width: 132px;
}

.comment-form .form-submit {
  margin-bottom: 0;
}

@media (max-width: 1024px) {
  .nav-card-links {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 700px) {
  .breadcrumbs,
  .single-content.card,
  .page-article,
  .content-outline,
  .author-box {
    padding: 20px;
  }

  .author-box {
    grid-template-columns: 1fr;
  }

  .header-actions .search-form {
    border-radius: 24px;
  }

  .section-heading.compact p,
  .section-heading.compact h1,
  .section-heading.compact h2 {
    max-width: none;
  }
}

/* Search widget rounded corners fix */
.widget_search .wp-block-search,
.widget_block.widget_search .wp-block-search {
  margin: 0;
}

.widget_search .wp-block-search__inside-wrapper,
.widget_block.widget_search .wp-block-search__inside-wrapper {
  display: flex;
  align-items: center;
  gap: 0;
  border: 1px solid var(--line);
  border-radius: 999px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.96);
}

.widget_search .wp-block-search__input,
.widget_block.widget_search .wp-block-search__input {
  flex: 1;
  min-width: 0;
  border: 0;
  background: transparent;
  padding: 12px 16px;
  outline: none;
}

.widget_search .wp-block-search__button,
.widget_block.widget_search .wp-block-search__button {
  margin: 0;
  border: 0;
  border-radius: 0;
  padding: 12px 18px;
  white-space: nowrap;
}

.widget.card.widget_search,
.widget.card.widget_block.widget_search {
  border-radius: var(--radius);
  overflow: hidden;
}
