/*
Theme Name: Tanaka Kobetsu
Theme URI: https://tanakakobetsu.com/
Author: Tanaka Kobetsu Project
Description: WordPress draft theme for Tanaka Kobetsu Shido Kyoshitsu.
Version: 0.1.2
Requires at least: 6.0
Tested up to: 6.6
Requires PHP: 8.1
Text Domain: tanaka-kobetsu
*/

:root {
  --ink: #17211d;
  --muted: #66736d;
  --paper: #fbfaf6;
  --surface: #ffffff;
  --line: #dedbd0;
  --green: #102a4c;
  --green-2: #e3eaf3;
  --brick: #9b3f2c;
  --gold: #c59c45;
  --navy: #102a4c;
  --shadow: 0 18px 45px rgba(23, 33, 29, 0.12);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Yu Gothic", "YuGothic", "Noto Sans JP", sans-serif;
  line-height: 1.75;
}

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

a {
  color: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(251, 250, 246, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}

.header-inner,
.section-inner,
.footer-inner,
.page-shell {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-weight: 800;
}

.brand-name {
  display: block;
  font-size: 18px;
  font-weight: 800;
  line-height: 1.2;
}

.brand-sub {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.2;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 14px;
  font-weight: 700;
}

.site-nav a {
  white-space: nowrap;
  text-decoration: none;
}

.nav-cta,
.button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--brick);
  color: #fff;
  font-weight: 800;
  padding: 10px 18px;
  text-decoration: none;
  white-space: nowrap;
}

.hero {
  position: relative;
  min-height: calc(100vh - 72px);
  isolation: isolate;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero::before {
  position: absolute;
  inset: 0;
  z-index: -2;
  background: url("assets/images/hero-study-room.png") center / cover no-repeat;
  content: "";
}

.hero::after {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, rgba(251, 250, 246, 0.96) 0%, rgba(251, 250, 246, 0.86) 42%, rgba(251, 250, 246, 0.2) 78%);
  content: "";
}

.hero-content {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
  padding: 88px 0 118px;
}

.eyebrow {
  color: var(--brick);
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0;
}

.hero h1 {
  max-width: 720px;
  margin: 14px 0 20px;
  font-size: clamp(40px, 6vw, 74px);
  line-height: 1.08;
  letter-spacing: 0;
}

.hero-copy {
  max-width: 640px;
  margin: 0 0 28px;
  color: #33413b;
  font-size: 18px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 38px;
}

.button.secondary {
  background: var(--green);
}

.button.ghost {
  border: 1px solid var(--green);
  background: rgba(255, 255, 255, 0.7);
  color: var(--green);
}

.hero-stats {
  display: grid;
  max-width: 760px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--line);
  box-shadow: var(--shadow);
}

.hero-stats div {
  background: rgba(255, 255, 255, 0.86);
  padding: 18px;
}

.hero-stats strong {
  display: block;
  color: var(--green);
  font-size: 22px;
  line-height: 1.25;
}

.hero-stats span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.section {
  padding: 80px 0;
}

.section.alt {
  background: #fff;
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 30px;
}

.section-head h2,
.page-title h1 {
  margin: 0;
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1.15;
  letter-spacing: 0;
}

.section-head p {
  max-width: 520px;
  margin: 0;
  color: var(--muted);
}

.cards,
.class-list,
.results-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.card,
.class-list article,
.results-board div,
.access-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 24px;
  box-shadow: 0 8px 24px rgba(23, 33, 29, 0.06);
}

.card span,
.class-list span,
.results-board span {
  display: inline-flex;
  margin-bottom: 14px;
  border-radius: 999px;
  background: var(--green-2);
  color: var(--green);
  font-size: 12px;
  font-weight: 900;
  padding: 3px 10px;
}

.card h3,
.class-list h2,
.results-board h2 {
  margin: 0 0 10px;
  font-size: 21px;
  line-height: 1.35;
}

.card p,
.class-list p,
.results-board p {
  margin: 0;
  color: var(--muted);
}

.news-section {
  background: #fff;
}

.news-list {
  display: grid;
  gap: 14px;
}

.news-item,
.news-empty {
  display: grid;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 8px 24px rgba(23, 33, 29, 0.06);
  gap: 8px;
  grid-template-columns: 110px 1fr;
  padding: 20px 24px;
}

.news-item time {
  color: var(--brick);
  font-size: 13px;
  font-weight: 900;
  line-height: 1.4;
}

.news-item h3 {
  margin: 0;
  font-size: 20px;
  line-height: 1.35;
}

.news-item h3 a {
  text-decoration: none;
}

.news-item p {
  grid-column: 2;
  margin: 0;
  color: var(--muted);
}

.news-empty {
  display: block;
}

.news-empty p {
  margin: 0;
  color: var(--muted);
}

.result-index {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.result-index > div {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 24px;
  box-shadow: 0 8px 24px rgba(23, 33, 29, 0.06);
}

.result-index h2 {
  margin: 0 0 16px;
  color: var(--green);
  font-size: 24px;
  line-height: 1.3;
}

.result-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.result-category {
  scroll-margin-top: 96px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 28px;
  box-shadow: 0 8px 24px rgba(23, 33, 29, 0.06);
}

.result-category-head {
  margin-bottom: 22px;
}

.result-category-head span {
  display: inline-flex;
  margin-bottom: 12px;
  border-radius: 999px;
  background: var(--green-2);
  color: var(--green);
  font-size: 12px;
  font-weight: 900;
  padding: 3px 10px;
}

.result-category-head h2 {
  margin: 0;
  font-size: clamp(26px, 4vw, 38px);
  line-height: 1.18;
}

.result-category-head p {
  max-width: 760px;
  margin: 10px 0 0;
  color: var(--muted);
}

.result-year-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.result-year-grid.single {
  grid-template-columns: minmax(0, 1fr);
}

.result-year-grid article {
  border-top: 4px solid var(--gold);
  border-radius: var(--radius);
  background: #fbfaf6;
  padding: 20px;
}

.result-year-grid article:nth-child(2) {
  border-top-color: var(--brick);
}

.result-year-grid article:nth-child(3) {
  border-top-color: var(--green);
}

.result-year-grid h3 {
  margin: 0 0 14px;
  color: var(--green);
  font-size: 19px;
  line-height: 1.35;
}

.guidance-schools .result-year-grid {
  grid-template-columns: 1.3fr 0.85fr 0.85fr;
}

.guidance-schools .result-year-grid article {
  border-top: 0;
}

.school-prefecture + .school-prefecture {
  margin-top: 18px;
}

.school-prefecture h4 {
  display: inline-flex;
  margin: 0 0 6px;
  border-radius: 999px;
  background: var(--green-2);
  color: var(--green);
  font-size: 13px;
  line-height: 1.3;
  padding: 4px 10px;
}

.school-run {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 2;
}

.class-list article {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.class-list .class-note {
  margin-top: auto;
  border-top: 1px solid var(--line);
  color: var(--brick);
  font-size: 13px;
  font-weight: 800;
  padding-top: 12px;
}

.info-strip {
  display: grid;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--line);
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.info-strip div {
  background: #fff;
  padding: 20px;
}

.info-strip strong,
.info-strip span {
  display: block;
}

.info-strip strong {
  color: var(--green);
  font-size: 13px;
}

.info-strip span {
  margin-top: 4px;
  font-weight: 800;
}

.class-summary {
  display: grid;
  align-items: center;
  border-radius: var(--radius);
  background: var(--green);
  color: #fff;
  gap: 24px;
  grid-template-columns: 1fr auto;
  padding: 30px;
}

.class-summary h2,
.class-summary p {
  margin: 0;
}

.class-summary p {
  margin-top: 8px;
  color: rgba(255, 255, 255, 0.78);
}

.pdf-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.class-summary .button,
.class-summary .button.ghost,
.class-summary .button.secondary {
  border-color: transparent;
  background: var(--gold);
  color: var(--ink);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.2);
}

.split {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 40px;
  align-items: center;
}

.quote-panel,
.cta-band,
.note-band,
.feature-panel {
  border-radius: var(--radius);
  background: var(--green);
  color: #fff;
  padding: 34px;
}

.quote-panel p {
  margin: 0;
  font-size: 24px;
  font-weight: 800;
  line-height: 1.6;
}

.quote-panel span {
  display: block;
  margin-top: 18px;
  color: rgba(255, 255, 255, 0.74);
}

.timeline {
  display: grid;
  gap: 16px;
}

.timeline div {
  border-left: 4px solid var(--gold);
  padding-left: 18px;
}

.timeline strong {
  display: block;
  font-size: 20px;
}

.timeline span {
  color: var(--muted);
}

.cta-band {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-top: 28px;
}

.cta-band h2,
.note-band h2,
.feature-panel h2 {
  margin: 0 0 8px;
}

.cta-band p,
.note-band p,
.feature-panel p {
  margin: 0;
}

.page-title {
  padding: 62px 0 34px;
  background: #fff;
  border-bottom: 1px solid var(--line);
}

.page-title p {
  max-width: 700px;
  margin: 14px 0 0;
  color: var(--muted);
}

.page-shell {
  padding: 54px 0 90px;
}

.page-content > * + * {
  margin-top: 34px;
}

.page-lead {
  max-width: 850px;
  font-size: 19px;
}

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

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

.content-grid > div {
  border-top: 3px solid var(--green);
  background: #fff;
  padding: 24px;
}

.precheck-bubbles {
  align-items: start;
}

.precheck-bubbles > div {
  position: relative;
  overflow: visible;
  border: 5px solid rgba(197, 156, 69, 0.58);
  border-radius: 36px;
  background: #fff7d9;
  box-shadow: 0 14px 30px rgba(23, 33, 29, 0.09);
  padding: 28px;
  text-align: center;
}

.precheck-bubbles > div:nth-child(2) {
  border-color: rgba(16, 42, 76, 0.36);
  background: #eaf2fb;
}

.precheck-bubbles > div::after {
  position: absolute;
  bottom: -14px;
  left: 42px;
  width: 26px;
  height: 26px;
  border-right: 5px solid rgba(197, 156, 69, 0.58);
  border-bottom: 5px solid rgba(197, 156, 69, 0.58);
  background: #fff7d9;
  content: "";
  transform: rotate(45deg);
}

.precheck-bubbles > div:nth-child(2)::after {
  border-color: rgba(16, 42, 76, 0.36);
  background: #eaf2fb;
}

.precheck-bubbles h2 {
  display: inline-flex;
  margin: 0 0 16px;
  border-radius: 999px;
  background: #fff;
  color: var(--green);
  font-size: 20px;
  line-height: 1.3;
  padding: 6px 14px;
}

.precheck-bubbles .check-list {
  text-align: center;
}

.feature-panel {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

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

.check-list li {
  border-bottom: 1px solid rgba(255, 255, 255, 0.22);
  padding-bottom: 12px;
}

.check-list.light li {
  border-bottom-color: var(--line);
  color: var(--muted);
}

.contact-layout {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 24px;
}

.contact-hero {
  display: grid;
  align-items: stretch;
  border-radius: var(--radius);
  background: var(--green);
  color: #fff;
  gap: 28px;
  grid-template-columns: 1.15fr 0.85fr;
  padding: 34px;
}

.contact-hero span,
.contact-hero aside strong {
  display: inline-flex;
  margin-bottom: 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: var(--gold);
  font-size: 13px;
  font-weight: 900;
  padding: 4px 12px;
}

.contact-hero h2 {
  margin: 0 0 12px;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.18;
}

.contact-hero p {
  max-width: 680px;
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
}

.contact-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.line-button {
  background: #06c755;
  color: #fff;
}

.contact-hero .button.ghost {
  border-color: rgba(255, 255, 255, 0.34);
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.contact-hero aside {
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.08);
  padding: 24px;
}

.contact-list li {
  color: #fff;
}

.contact-bubbles > div {
  border-top: 0;
  border-radius: 28px;
  box-shadow: 0 12px 28px rgba(23, 33, 29, 0.08);
}

.contact-bubbles > div:first-child {
  border: 3px solid rgba(197, 156, 69, 0.44);
  background: #fff7d9;
}

.contact-bubbles > div:nth-child(2) {
  border: 3px solid rgba(155, 63, 44, 0.26);
  background: #fff0ea;
}

.contact-bubbles h2 {
  margin: 0 0 16px;
  color: var(--green);
  font-size: 23px;
}

.contact-layout.detailed {
  align-items: stretch;
}

.contact-photo {
  overflow: hidden;
  min-height: 280px;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 8px 24px rgba(23, 33, 29, 0.06);
}

.contact-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.map-placeholder {
  display: grid;
  min-height: 220px;
  place-items: center;
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  background: #f1efe7;
  color: var(--muted);
  font-weight: 800;
}

.map-placeholder div {
  display: grid;
  justify-items: center;
  gap: 8px;
  text-align: center;
}

.map-placeholder strong {
  color: var(--green);
  font-size: 22px;
}

.map-placeholder span {
  font-weight: 700;
}

.map-placeholder a {
  color: var(--brick);
  font-weight: 900;
}

.contact-note {
  background: var(--brick);
}

.site-footer {
  background: var(--ink);
  color: #fff;
  padding: 42px 0;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 24px;
}

.footer-inner p {
  margin: 0;
  color: rgba(255, 255, 255, 0.68);
}

@media (max-width: 900px) {
  .header-inner {
    align-items: flex-start;
    flex-direction: column;
    padding: 16px 0;
  }

  .site-nav {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 4px;
  }

  .hero {
    min-height: auto;
  }

  .hero::after {
    background: linear-gradient(180deg, rgba(251, 250, 246, 0.96) 0%, rgba(251, 250, 246, 0.9) 62%, rgba(251, 250, 246, 0.55) 100%);
  }

  .hero-content {
    padding: 58px 0 72px;
  }

  .hero-stats,
  .cards,
  .class-list,
  .results-board,
  .result-index,
  .result-year-grid,
  .info-strip,
  .class-summary,
  .split,
  .content-grid.two,
  .feature-panel,
  .contact-hero,
  .contact-layout {
    grid-template-columns: 1fr;
  }

  .section-head,
  .cta-band,
  .news-item,
  .pdf-links,
  .contact-actions,
  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .pdf-links {
    justify-content: flex-start;
  }

  .news-item {
    grid-template-columns: 1fr;
  }

  .news-item p {
    grid-column: 1;
  }
}

@media (max-width: 560px) {
  .header-inner,
  .section-inner,
  .footer-inner,
  .page-shell,
  .hero-content {
    width: min(100% - 28px, 1120px);
  }

  .site-nav {
    gap: 8px;
    font-size: 12px;
  }

  .brand-name {
    font-size: 17px;
  }

  .brand-sub {
    font-size: 11px;
  }

  .nav-cta {
    min-width: max-content;
    padding: 8px 12px;
  }

  .hero h1 {
    font-size: 34px;
    line-height: 1.14;
  }

  .hero-copy,
  .page-lead {
    font-size: 16px;
  }

  .hero-stats strong {
    font-size: 19px;
  }

  .section {
    padding: 56px 0;
  }

  .quote-panel,
  .cta-band,
  .note-band,
  .feature-panel {
    padding: 24px;
  }
}
