:root {
  --ink: #18202a;
  --muted: #667085;
  --line: #d9e2e7;
  --paper: #ffffff;
  --soft: #f4f8f7;
  --brand: #0b6b57;
  --brand-dark: #084d40;
  --accent: #d9a441;
  --accent-soft: #fff3cf;
  --danger: #b42318;
  --shadow: 0 18px 45px rgba(24, 32, 42, 0.12);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: "Yu Gothic", "Hiragino Kaku Gothic ProN", "Noto Sans JP", system-ui, sans-serif;
  line-height: 1.7;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
}

button,
input,
textarea {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

.header-inner,
.footer-inner,
.section-inner {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 96px;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  letter-spacing: 0;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  color: var(--paper);
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
  border: 2px solid var(--accent);
  border-radius: 50%;
  font-size: 16px;
}

.brand-text {
  font-size: 20px;
}

.nav {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav a,
.lang-toggle,
.menu-button {
  min-height: 40px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  padding: 8px 12px;
}

.nav a:hover,
.lang-toggle:hover,
.menu-button:hover {
  border-color: var(--line);
  background: var(--soft);
}

.lang-toggle {
  border-color: var(--brand);
  color: var(--brand-dark);
  font-weight: 700;
}

.floating-lang-toggle {
  position: fixed;
  top: 14px;
  right: 14px;
  z-index: 60;
  background: var(--paper);
}

.signup-page-body .site-header .nav {
  display: flex;
  position: static;
  background: transparent;
  border: 0;
  padding: 0;
}

.signup-page-body .site-header .lang-toggle {
  background: var(--paper);
}

.menu-button {
  display: none;
  width: 44px;
  padding: 8px;
  font-size: 22px;
}

.hero {
  position: relative;
  min-height: min(620px, calc(100vh - 72px));
  isolation: isolate;
  display: grid;
  align-items: center;
  overflow: hidden;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, rgba(10, 23, 31, 0.78), rgba(10, 23, 31, 0.34), rgba(10, 23, 31, 0.18));
}

.hero-image {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-content {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  color: var(--paper);
  padding: 56px 0 88px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--accent-soft);
  font-weight: 700;
}

.eyebrow.dark {
  color: var(--brand-dark);
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 720px;
  margin-bottom: 20px;
  font-size: clamp(38px, 6vw, 72px);
  line-height: 1.12;
}

h2 {
  margin-bottom: 18px;
  font-size: clamp(27px, 3.4vw, 42px);
  line-height: 1.25;
}

h3 {
  margin-bottom: 10px;
  font-size: 20px;
  line-height: 1.35;
}

.lead {
  max-width: 720px;
  color: #ecf3f1;
  font-size: 20px;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  border: 1px solid var(--brand);
  border-radius: var(--radius);
  background: var(--brand);
  color: var(--paper);
  font-weight: 800;
  padding: 10px 18px;
  text-align: center;
}

.button.secondary {
  border-color: var(--accent);
  background: var(--accent);
  color: #211805;
}

.button.ghost {
  border-color: var(--line);
  background: var(--paper);
  color: var(--brand-dark);
}

.fixed-cta .button.ghost {
  border-color: var(--brand);
  background: var(--brand);
  color: var(--paper);
}

.button:disabled {
  border-color: var(--brand);
  background: var(--brand);
  color: var(--paper);
  opacity: 0.55;
}


.button,
button,
.menu-button,
.admin-nav-link,
.video-item,
.answer-option,
.btn-premium-toggle,
.btn-signup,
.pop-btn-primary,
.pop-btn-secondary {
  transition: transform 80ms ease, filter 80ms ease, box-shadow 80ms ease, background-color 80ms ease, border-color 80ms ease;
  -webkit-tap-highlight-color: transparent;
}

.button:not(.disabled):not(:disabled),
button:not(:disabled),
.menu-button:not(:disabled),
.admin-nav-link,
.video-item:not(:disabled),
.answer-option,
.btn-premium-toggle:not(:disabled),
.btn-signup:not(:disabled),
.pop-btn-primary:not(:disabled),
.pop-btn-secondary:not(:disabled) {
  cursor: pointer;
}

.button:not(.disabled):not(:disabled):active,
button:not(:disabled):active,
.menu-button:not(:disabled):active,
.admin-nav-link:active,
.video-item:not(:disabled):active,
.answer-option:active,
.btn-premium-toggle:not(:disabled):active,
.btn-signup:not(:disabled):active,
.pop-btn-primary:not(:disabled):active,
.pop-btn-secondary:not(:disabled):active {
  transform: translateY(2px) scale(0.98);
  filter: brightness(0.92);
  box-shadow: inset 0 2px 8px rgba(14, 42, 52, 0.22);
}

.button:focus-visible,
button:focus-visible,
.menu-button:focus-visible,
.admin-nav-link:focus-visible,
.video-item:focus-visible,
.answer-option:focus-within,
.btn-premium-toggle:focus-visible,
.btn-signup:focus-visible,
.pop-btn-primary:focus-visible,
.pop-btn-secondary:focus-visible {
  outline: 3px solid rgba(45, 156, 121, 0.35);
  outline-offset: 2px;
}

.answer-option:has(input:checked) {
  border-color: var(--brand);
  background: #eaf8f3;
  box-shadow: inset 0 0 0 1px rgba(45, 156, 121, 0.18);
}
.section {
  padding: 76px 0;
}

.section.soft {
  background: var(--soft);
}

.grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}

.card,
.price-card,
.form-panel,
.login-panel,
.faq-item,
.voice-card,
.admin-note {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: 0 10px 28px rgba(24, 32, 42, 0.06);
}

.card,
.price-card,
.voice-card,
.admin-note {
  padding: 24px;
}

.card.disabled {
  color: var(--muted);
  background: #f2f4f5;
}

.muted {
  color: var(--muted);
}

.site-footer {
  border-top: 1px solid var(--line);
  background: #101820;
  color: var(--paper);
  padding: 48px 0;
  overflow: visible;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  color: #d7e0df;
  font-size: 14px;
}

.lp-hero {
  position: relative;
  height: min(520px, 66vh);
  min-height: 360px;
  overflow: hidden;
}

.lp-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(12, 25, 32, 0.2), rgba(12, 25, 32, 0.62));
}

.lp-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.lp-hero-text {
  position: absolute;
  left: max(16px, calc((100% - 1120px) / 2));
  right: 16px;
  bottom: 54px;
  z-index: 2;
  color: var(--paper);
}

.lp-shell {
  display: grid;
  grid-template-columns: 230px minmax(0, 1fr);
  gap: 44px;
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 56px 0 116px;
}

.toc {
  position: sticky;
  top: 128px;
  align-self: start;
  max-height: calc(100vh - 150px);
  overflow-y: auto;
  border-left: 3px solid var(--brand);
  padding-left: 16px;
  padding-bottom: 14px;
  scrollbar-width: thin;
}

.toc a {
  display: block;
  color: var(--muted);
  padding: 7px 0;
}

.toc a:hover {
  color: var(--brand-dark);
}

.mobile-tabs {
  display: none;
}

.lp-section {
  scroll-margin-top: 92px;
  padding: 42px 0;
  border-bottom: 1px solid var(--line);
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.price-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.price {
  color: var(--brand-dark);
  font-size: 28px;
  font-weight: 900;
}

.price-list {
  list-style: none;
  margin: 16px 0 0;
  padding: 0;
}

.price-list li {
  border-top: 1px solid var(--line);
  padding: 9px 0;
}

.material-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 24px;
}

.link-card-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 24px;
}

.link-card {
  display: block;
  border-width: 2px;
  transition: border-color 0.15s, transform 0.15s;
}

.link-card:hover {
  border-color: var(--brand);
  transform: translateY(-2px);
}

.full-lp-section {
  overflow: hidden;
}

.fulltext-panel {
  width: 100%;
}

.fulltext-panel section,
.fulltext-panel .page,
.fulltext-panel .final {
  max-width: 760px;
  margin-right: auto;
  margin-left: auto;
}

#flow .fulltext-panel .page {
  text-align: center;
}

.fulltext-panel .tag {
  display: inline-block;
  border: 1px solid var(--accent);
  border-radius: 999px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  padding: 4px 14px;
}

.fulltext-panel .divider {
  width: 48px;
  height: 4px;
  border-radius: 999px;
  background: var(--accent);
  margin: 24px 0 32px;
}

#flow .fulltext-panel .divider {
  margin-right: auto;
  margin-left: auto;
}

.fulltext-panel .divider.wide {
  width: 100%;
  height: 1px;
  background: var(--line);
}

.fulltext-panel .accent {
  color: var(--accent);
}

.fulltext-panel .lead,
.fulltext-panel .body-text,
.fulltext-panel .step p {
  color: #3b4652;
}

.fulltext-panel .step-number {
  display: block;
  width: auto;
  height: auto;
  border: 0;
  border-radius: 0;
  color: var(--accent);
  background: transparent;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.18em;
  line-height: 1.4;
  text-transform: uppercase;
  margin-bottom: 10px;
  place-items: initial;
}

.fulltext-panel .scroll-hint {
  display: none !important;
}

.fulltext-panel .arrow {
  display: none !important;
}

.fulltext-panel .highlight-box {
  text-align: center;
}

.fulltext-panel .final {
  max-width: none;
  border-radius: var(--radius);
  background: #101820;
  overflow: hidden;
  text-align: center;
}

.fulltext-panel .final,
.fulltext-panel .final h1,
.fulltext-panel .final h2,
.fulltext-panel .final h3,
.fulltext-panel .final p,
.fulltext-panel .final strong {
  color: #f7fbff;
}

.fulltext-panel .final p,
.fulltext-panel .final [style*="color:#fff"],
.fulltext-panel .final [style*="color: #fff"] {
  color: #f7fbff !important;
}

.fulltext-panel .final [style*="color:#9AA3B5"],
.fulltext-panel .final [style*="color: #9AA3B5"],
.fulltext-panel .final p:not([style*="FFE600"]) {
  color: #d8e1ea !important;
}

.fulltext-panel .final .accent {
  color: var(--accent) !important;
}

.fulltext-panel .final [style*="FFE600"] {
  display: block;
  width: 100%;
  text-align: center !important;
  color: #fff34a !important;
}

.fulltext-panel .final [style*="background: #E94560"],
.fulltext-panel .final [style*="background:#E94560"] {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center !important;
}

.lp-lang-pt {
  display: none;
}

html[lang="pt-BR"] .lp-lang-ja {
  display: none;
}

html[lang="pt-BR"] .lp-lang-pt {
  display: block;
}

.material-number {
  display: block;
  color: var(--accent);
  font-size: 38px;
  font-weight: 900;
  line-height: 1;
  margin-bottom: 14px;
}

.history-section {
  background: linear-gradient(180deg, #ffffff, #f7faf9);
}

.history-body {
  max-width: 760px;
}

.history-body p {
  color: #3b4652;
  font-size: 17px;
  line-height: 2;
}

.highlight {
  border-left: 4px solid var(--accent);
  border-radius: 0 var(--radius) var(--radius) 0;
  background: #fff8ec;
  padding: 18px 20px;
  margin: 28px 0;
}

.highlight p {
  margin: 0;
  color: #332715;
  font-weight: 700;
}

.history-closing {
  margin-top: 30px;
  color: var(--brand-dark) !important;
  font-size: 21px !important;
  font-weight: 900;
}

.fixed-cta {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 25;
  overflow: hidden;
  border-top: 2px solid #c78116;
  background: linear-gradient(90deg, #fff4cc 0%, #f3c24e 42%, #fff0b8 100%);
  box-shadow: 0 -12px 30px rgba(99, 56, 6, 0.2);
  backdrop-filter: blur(12px);
}

.fixed-cta::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 0%, rgba(255,255,255,0.65) 45%, transparent 62%);
  transform: translateX(-120%);
  animation: campaignShine 3.2s ease-in-out infinite;
  pointer-events: none;
}

.fixed-cta-inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  min-height: 86px;
  gap: 16px;
}

.fixed-cta p {
  margin: 0;
  color: #2b1803;
  font-size: 24px;
  font-weight: 900;
  letter-spacing: 0;
  text-shadow: 0 1px 0 rgba(255,255,255,0.65);
}

.fixed-cta .button {
  min-width: 180px;
  background: #0b6b57;
  color: #fff;
  border-color: #084d40;
  box-shadow: 0 8px 0 #084d40, 0 12px 22px rgba(8, 77, 64, 0.22);
  transform: translateY(-2px);
}

.fixed-cta .button:hover {
  background: #084d40;
  transform: translateY(-4px);
}

@keyframes campaignShine {
  0%, 52% { transform: translateX(-120%); }
  100% { transform: translateX(120%); }
}
.fixed-cta + .site-footer {
  padding-bottom: 140px;
}

.form-page {
  min-height: calc(100vh - 72px);
  background: var(--soft);
  padding: 68px 0;
}

.login-panel,
.form-panel {
  width: min(560px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px;
}

.field {
  display: grid;
  gap: 6px;
  margin-bottom: 16px;
}

.field label {
  font-weight: 700;
}

.field input,
.field textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  padding: 11px 12px;
}

.field textarea {
  min-height: 140px;
  resize: vertical;
}

.checkbox {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 6px 0 20px;
}

.login-links {
  display: grid;
  gap: 8px;
  margin-top: 22px;
  color: var(--brand-dark);
}

.faq-list {
  display: grid;
  gap: 12px;
}

.faq-item {
  overflow: hidden;
}

.faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  border: 0;
  background: var(--paper);
  cursor: pointer;
  padding: 18px 20px;
  text-align: left;
  font-weight: 800;
}

.faq-answer {
  display: none;
  padding: 0 20px 20px;
  color: var(--muted);
}

.faq-item.open .faq-answer {
  display: block;
}

.success-message {
  display: none;
  margin-top: 18px;
  border: 1px solid #8ec8b6;
  border-radius: var(--radius);
  background: #eaf8f3;
  color: var(--brand-dark);
  padding: 12px 14px;
  font-weight: 700;
}

.success-message.visible {
  display: block;
}

@media (max-width: 820px) {
  .header-inner {
    min-height: 72px;
  }

  .brand-logo {
    width: 178px;
    height: 58px;
  }

  .menu-button {
    display: inline-grid;
    place-items: center;
  }

  .nav {
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    border-bottom: 1px solid var(--line);
    background: var(--paper);
    padding: 12px 16px 18px;
  }

  .nav.open {
    display: flex;
  }

  .nav a,
  .lang-toggle {
    text-align: left;
  }

  .signup-page-body .site-header .header-inner {
    align-items: center;
  }

  .signup-page-body .site-header .nav {
    display: flex;
    position: static;
    width: auto;
    flex-direction: row;
    align-items: center;
  }

  .signup-page-body .site-header .lang-toggle {
    min-width: 52px;
    text-align: center;
  }

  .hero {
    min-height: 560px;
  }

  .hero::after {
    background: linear-gradient(180deg, rgba(10, 23, 31, 0.44), rgba(10, 23, 31, 0.82));
  }

  h1 {
    font-size: 42px;
  }

  .lead {
    font-size: 18px;
  }

  .grid,
  .steps,
  .price-grid,
  .material-grid,
  .link-card-grid {
    grid-template-columns: 1fr;
  }

  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .lp-shell {
    display: block;
    padding-top: 26px;
  }

  .toc {
    display: none;
  }

  .mobile-tabs {
    position: sticky;
    top: 64px;
    z-index: 20;
    display: flex;
    gap: 8px;
    overflow-x: auto;
    border-bottom: 1px solid var(--line);
    background: var(--paper);
    padding: 10px 16px;
  }

  .mobile-tabs a {
    flex: 0 0 auto;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 7px 12px;
    font-weight: 700;
  }

  .fixed-cta-inner {
    align-items: stretch;
    flex-direction: column;
    padding: 14px 0;
    min-height: 132px;
  }

  .fixed-cta p {
    text-align: center;
    font-size: 18px;
    line-height: 1.45;
  }

  .fixed-cta .actions {
    margin: 0;
  }
  .fixed-cta + .site-footer {
    padding-bottom: 196px;
  }

  .button {
    width: 100%;
  }
}


.brand-logo {
  display: block;
  width: 292px;
  height: 96px;
  object-fit: contain;
}

.site-footer .brand-logo {
  filter: brightness(1.1);
  width: 180px;
  height: auto;
  object-fit: unset;
  background: transparent;
}

/* Banner full-image display override */
.hero {
  background: #101820;
}

.hero-image {
  object-fit: contain;
  object-position: center;
}

.lp-hero {
  background: #101820;
}

.lp-hero img {
  object-fit: contain;
  object-position: center;
}

/* Hero images use prepared wide banners */
.hero-image {
  object-fit: cover;
  object-position: center;
}

.lp-hero img {
  object-fit: cover;
  object-position: center;
}

/* Phase 2 signup, auth, and modal styles */
.signup-shell { width: min(1480px, calc(100% - 32px)); margin: 0 auto; }
.steps-indicator { display: flex; align-items: center; justify-content: center; gap: 0; margin-bottom: 32px; }
.step { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.diagnosis-step { color: inherit; text-decoration: none; }
.diagnosis-step .step-number { border-color: #e0a937; background: #fff7e4; color: #633806; }
.diagnosis-step .step-label { color: #633806; font-weight: 800; }
.diagnosis-step:hover .step-number { border-color: var(--brand); background: #fff1cc; }
.step-number { display: grid; place-items: center; width: 36px; height: 36px; border: 2px solid var(--line); border-radius: 50%; font-weight: 800; color: var(--muted); }
.step.active .step-number { border-color: var(--brand); background: var(--brand); color: var(--paper); }
.step.done .step-number { border-color: var(--brand); color: var(--brand); }
.step-label { font-size: 12px; color: var(--muted); }
.step.active .step-label { color: var(--brand-dark); font-weight: 700; }
.step-line { flex: 1; height: 2px; background: var(--line); margin: 0 8px 20px; }
.plan-card { display: flex; align-items: center; justify-content: space-between; gap: 14px; border: 2px solid var(--line); border-radius: var(--radius); padding: 16px 20px; cursor: pointer; margin-bottom: 10px; background: var(--paper); transition: border-color 0.15s, background 0.15s; }
.plan-card:hover { border-color: var(--brand); }
.plan-card.selected { border-color: var(--brand); background: #eaf8f3; }
.plan-card.popular { border-color: var(--accent); }
.badge { font-size: 11px; font-weight: 800; background: var(--accent); color: #211805; padding: 2px 8px; border-radius: 20px; }
.plan-group { border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; margin-bottom: 16px; background: var(--soft); }
.wide-panel { width: 100%; }
.inline-field { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; }
#stripe-payment-element { min-height: 160px; border: 1px dashed var(--line); border-radius: var(--radius); padding: 16px; background: var(--paper); }
.textbook-choice-notice { margin: 16px 0; padding: 12px 14px; border: 1px solid #e4c27d; border-radius: var(--radius); background: #fff8e8; color: #633806; font-size: 13px; line-height: 1.7; }
.textbook-payment-box { border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; margin: 0 0 16px; background: var(--soft); }
.textbook-payment-title { margin: 0 0 10px; font-weight: 800; color: var(--ink); }
.textbook-payment-title-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.textbook-detail { margin: 0; max-width: 460px; color: var(--muted); font-size: 12px; line-height: 1.8; }
.textbook-payment-option { display: flex; align-items: center; gap: 8px; margin: 8px 0; font-size: 14px; }
.estimate-box { border: 1px solid #c9dce8; border-radius: 8px; padding: 20px; margin-bottom: 18px; background: var(--paper); box-shadow: 0 14px 34px rgba(24, 32, 42, 0.14); }
.estimate-box h3 { margin: 0 0 8px; font-size: 18px; }
.estimate-plan { margin: 0 0 12px; }
.estimate-table { display: grid; gap: 8px; }
.estimate-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; border-top: 1px solid var(--line); padding-top: 8px; font-size: 14px; }
.estimate-heading { margin-top: 8px; border-top: 2px solid var(--brand); color: var(--brand-dark); font-weight: 800; }
.estimate-row:last-child strong { color: var(--brand-dark); font-size: 16px; }
.estimate-selected { background: #eef7ff; border: 1px solid #9bd0ff; border-radius: 6px; padding: 10px 12px; color: #075985; }
.estimate-selected strong { color: #0369a1; }
.estimate-total-row { background: #f8fafc; border-top: 2px solid var(--brand); border-radius: 6px; padding: 12px; font-weight: 800; }
.estimate-note { margin: 12px 0 0; color: #7a3d00; font-size: 12px; line-height: 1.7; }
.trial-notice { margin-top: 16px; }
.modal { position: fixed; inset: 0; z-index: 100; background: rgba(24, 32, 42, 0.55); display: grid; place-items: center; padding: 16px; }
.modal[hidden] { display: none; }
.modal-inner { background: var(--paper); border-radius: var(--radius); padding: 32px; width: min(440px, 100%); box-shadow: var(--shadow); }
.signup-step { display: none; }
.signup-step.active { display: block; }
.success-message.error-message { border-color: #f3b3ae; background: #fff0ee; color: var(--danger); }
@media (max-width: 820px) {
  .signup-shell { width: min(100% - 24px, 1480px); }
  .plan-card { align-items: flex-start; flex-direction: column; }
  .plan-grid-2,
  .plan-grid-3,
  .premium-grid {
    grid-template-columns: 1fr;
  }
  .inline-field { grid-template-columns: 1fr; }
}

/* Phase 3 e-learning pages */
.course-layout {
  display: grid;
  grid-template-columns: 248px minmax(0, 1fr);
  min-height: calc(100vh - 112px);
  background: var(--soft);
}

.course-sidebar {
  position: sticky;
  top: 112px;
  align-self: start;
  min-height: calc(100vh - 112px);
  border-right: 1px solid var(--line);
  background: var(--paper);
  padding: 22px 16px;
}

.sidebar-link {
  display: block;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  margin-bottom: 10px;
  padding: 10px 12px;
  font-weight: 700;
}

.sidebar-link.season-link {
  border-color: var(--season-color);
  color: var(--brand-dark);
}

.sidebar-link.active,
.sidebar-link:hover {
  background: #eaf8f3;
}

.sidebar-link.locked {
  color: var(--muted);
  background: #f2f4f5;
}

.course-main {
  padding: 34px;
}

.course-panel,
.test-card {
  width: min(1100px, 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: 0 10px 28px rgba(24, 32, 42, 0.06);
  padding: 28px;
}

.course-top-panel {
  overflow-wrap: anywhere;
}

.welcome-title {
  max-width: 100%;
  font-size: clamp(34px, 4.6vw, 58px);
  line-height: 1.16;
}

.welcome-title span {
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.course-header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.course-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin: 22px 0;
}

.stat-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--soft);
  padding: 16px;
}

.stat-card span {
  display: block;
  color: var(--muted);
  font-size: 13px;
}

.stat-card strong {
  display: block;
  margin-top: 4px;
  font-size: 24px;
}

.medal-section {
  margin: 28px 0;
}

.medal-section h2 {
  margin-bottom: 12px;
}

.medal-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.lesson-medal {
  width: 54px;
  height: 62px;
  object-fit: contain;
  flex: 0 0 auto;
}

.lesson-medal.fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 54px;
  border: 2px solid var(--accent);
  border-radius: 50%;
  background: #f8e4a9;
  color: #3d2b00;
  font-weight: 900;
}

.lesson-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.lesson-card {
  display: block;
  min-height: 190px;
  border: 2px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  padding: 18px;
}

.lesson-card-wide {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  min-height: 104px;
}

.lesson-card-wide h3,
.lesson-card-wide p {
  margin-bottom: 0;
}

.lesson-card-wide .progress-bar {
  grid-column: 2 / -1;
  width: 100%;
}

.lesson-card.done {
  border-color: var(--brand);
  background: #eaf8f3;
}

.lesson-card.milestone {
  border-color: var(--accent);
}

.lesson-card.locked {
  pointer-events: none;
  color: var(--muted);
  background: #f2f4f5;
}

.lesson-number {
  display: inline-block;
  margin-bottom: 10px;
  color: var(--brand-dark);
  font-weight: 900;
}

.lesson-card-wide .lesson-number {
  margin-bottom: 0;
  font-size: 22px;
}

.progress-bar {
  height: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: #dfe7e6;
  margin: 12px 0;
}

.progress-bar span {
  display: block;
  height: 100%;
  background: var(--brand);
}

.test-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.test-meta p {
  margin: 0;
}

.test-timer {
  color: var(--muted);
  font-weight: 700;
}

.test-timer strong {
  color: var(--danger);
  font-size: 18px;
}

.video-frame {
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  background: #101820;
  overflow: hidden;
  margin: 18px 0;
}

.video-frame iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

.video-list,
.answer-list,
.result-list {
  display: grid;
  gap: 10px;
  margin: 18px 0;
}

.video-item,
.answer-option,
.result-item,
.mypage-row {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  padding: 12px 14px;
  text-align: left;
}

.answer-option {
  display: block;
  cursor: pointer;
}

.result-item.correct {
  border-color: #8ec8b6;
  background: #eaf8f3;
}

.result-item.wrong {
  border-color: #f3b3ae;
  background: #fff0ee;
}

.button.disabled {
  pointer-events: none;
  border-color: var(--line);
  background: #dfe3e5;
  color: var(--muted);
}

.mypage-row {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr) 64px;
  align-items: center;
  gap: 14px;
}

@media (max-width: 820px) {
  .course-layout {
    display: block;
  }

  .course-sidebar {
    position: static;
    display: flex;
    gap: 8px;
    min-height: 0;
    overflow-x: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding: 12px;
  }

  .sidebar-link {
    flex: 0 0 auto;
    margin-bottom: 0;
  }

  .course-main {
    padding: 18px 12px;
  }

  .course-panel,
  .test-card {
    padding: 20px;
  }

  .course-stats,
  .mypage-row {
    grid-template-columns: 1fr;
  }

  .course-header-actions {
    flex-direction: column;
    align-items: stretch;
  }
}

/* Phase 4 admin pages */
.admin-layout {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  min-height: calc(100vh - 112px);
  background: var(--soft);
}

.admin-sidebar {
  position: sticky;
  top: 112px;
  align-self: start;
  min-height: calc(100vh - 112px);
  border-right: 1px solid var(--line);
  background: var(--paper);
  padding: 18px 14px;
}

.admin-nav-link {
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  padding: 10px 12px;
  color: var(--ink);
  font-weight: 700;
}

.admin-nav-link:hover,
.admin-nav-link.active {
  border-color: var(--line);
  background: #eaf8f3;
  color: var(--brand-dark);
}

.admin-main {
  padding: 30px;
}

.admin-panel {
  width: min(1180px, 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: 0 10px 28px rgba(24, 32, 42, 0.06);
  padding: 28px;
}

.admin-header {
  gap: 18px;
}

.admin-name {
  margin-left: auto;
  color: var(--muted);
  font-weight: 700;
}

.admin-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin: 22px 0;
}

.admin-table-wrap {
  width: 100%;
  overflow-x: auto;
  margin: 14px 0 24px;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--paper);
}

.admin-table th,
.admin-table td {
  border-bottom: 1px solid var(--line);
  padding: 10px 12px;
  text-align: left;
  vertical-align: top;
}

.admin-table th {
  color: var(--muted);
  font-size: 13px;
}

.admin-filters,
.admin-tabs,
.admin-form-grid,
.admin-form-row {
  display: grid;
  gap: 10px;
  margin: 12px 0;
}

.admin-filters {
  grid-template-columns: 1fr 180px 180px;
}

.admin-tabs {
  grid-template-columns: repeat(auto-fit, minmax(120px, max-content));
}

.admin-form-grid {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.admin-form-row {
  grid-template-columns: minmax(160px, 240px) minmax(0, 1fr);
}

.admin-panel input,
.admin-panel select,
.admin-panel textarea,
.admin-note input,
.admin-note select,
.admin-note textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 10px 12px;
}

.admin-panel textarea,
.admin-note textarea {
  min-height: 110px;
  resize: vertical;
}

.button.danger {
  border-color: var(--danger);
  background: var(--danger);
  color: var(--paper);
}

#planChart,
#salesChart,
#activeChart {
  max-height: 260px;
}

@media (max-width: 900px) {
  .admin-layout {
    display: block;
  }

  .admin-sidebar {
    position: static;
    display: flex;
    gap: 8px;
    min-height: 0;
    overflow-x: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding: 12px;
  }

  .admin-nav-link {
    flex: 0 0 auto;
  }

  .admin-main {
    padding: 16px 12px;
  }

  .admin-panel {
    padding: 20px;
  }

  .admin-stats,
  .admin-filters,
  .admin-form-row {
    grid-template-columns: 1fr;
  }
}

.lesson-accuracy-row {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr) 64px;
  align-items: center;
  gap: 14px;
  margin: 10px 0;
}

@media (max-width: 820px) {
  .lesson-accuracy-row {
    grid-template-columns: 1fr;
  }
}

/* Japanese LP full banner ratio fix */
.lp-hero {
  height: auto;
  min-height: 0;
  aspect-ratio: 1727 / 910;
  background: #101820;
}

.lp-hero img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
}

/* Japanese LP banner fixed band resize */
.lp-hero {
  height: min(520px, 66vh);
  min-height: 360px;
  aspect-ratio: auto;
}

.lp-hero img {
  width: 100%;
  height: 100%;
  object-fit: fill;
  object-position: center;
}

/* Japanese LP banner current image preview */
.lp-hero {
  height: min(520px, 66vh);
  min-height: 360px;
  aspect-ratio: auto;
}

.lp-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

/* Japanese LP banner final display: no crop, no distortion */
.lp-hero {
  height: auto;
  min-height: 0;
  aspect-ratio: auto;
  background: #ffffff;
}

.lp-hero img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
  object-position: center;
}

/* Japanese LP banner final band size: keep the band height fixed */
.lp-hero {
  height: min(520px, 66vh);
  min-height: 360px;
  aspect-ratio: auto;
  background: #101820;
}

.lp-hero img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

/* Japanese LP banner final 1920x520 asset */
.lp-hero {
  height: min(520px, 66vh);
  min-height: 360px;
  aspect-ratio: auto;
  background: #101820;
}

.lp-hero img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
/* Password setup dedicated page */
.password-setup-page {
  min-height: 100vh;
  background: linear-gradient(135deg, #f6f8f5 0%, #eef3f0 48%, #fffaf0 100%);
}

.password-setup-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 40px 18px;
}

.password-setup-panel {
  width: min(520px, 100%);
  border: 1px solid rgba(8, 83, 74, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 24px 70px rgba(13, 33, 38, 0.14);
  padding: 34px;
}

.setup-logo-wrap {
  display: flex;
  justify-content: center;
  margin-bottom: 22px;
}

.setup-logo {
  display: block;
  width: min(300px, 82%);
  height: auto;
  object-fit: contain;
}

.password-setup-panel h1 {
  margin: 0 0 8px;
  text-align: center;
  font-size: clamp(1.5rem, 4vw, 2rem);
}

.password-setup-panel .muted {
  text-align: center;
  margin-bottom: 22px;
}

.setup-account {
  display: grid;
  gap: 6px;
  border: 1px solid rgba(218, 171, 64, 0.45);
  border-radius: 8px;
  background: #fffbf1;
  padding: 14px 16px;
  margin-bottom: 20px;
}

.setup-account span {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.setup-account strong {
  color: var(--brand-dark);
  overflow-wrap: anywhere;
}

.setup-submit {
  width: 100%;
}

.setup-submit:disabled {
  cursor: not-allowed;
  border-color: var(--line);
  background: #dfe5e3;
  color: var(--muted);
}
.field-note {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.signup-password-panel {
  text-align: center;
}

.signup-password-panel .field {
  text-align: left;
}



/* Signup STEP4 lock state */
.signup-step4-active .site-footer .footer-links {
  display: none;
}

.legal-inner {
  width: min(860px, calc(100% - 32px));
}

.legal-list {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--paper);
}

.legal-list dt,
.legal-list dd {
  margin: 0;
  border-bottom: 1px solid var(--line);
  padding: 16px 18px;
}

.legal-list dt {
  background: var(--soft);
  font-weight: 800;
}

.legal-list dd {
  overflow-wrap: anywhere;
}

.legal-list dt:last-of-type,
.legal-list dd:last-of-type {
  border-bottom: 0;
}

@media (max-width: 700px) {
  .legal-list {
    grid-template-columns: 1fr;
  }

  .legal-list dt {
    border-bottom: 0;
    padding-bottom: 6px;
  }
}


/* Pricing tabs and campaign plan update */

/* ===================== 料金プランCSS ===================== */
.pricing-tabs-nav {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}
.pricing-tab-btn {
  padding: 8px 20px;
  border-radius: 20px;
  border: 1.5px solid var(--line);
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
}
.pricing-tab-btn.active {
  background: var(--accent);
  border-color: #BA7517;
  color: #fff;
}
.pricing-tab-content { display: none; }
.pricing-tab-content.active { display: block; }

/* 案内バナー */
.pricing-info-banner {
  background: var(--soft);
  border: 0.5px solid var(--line);
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  margin-bottom: 1.25rem;
  text-align: center;
  font-size: 12px;
  color: var(--muted);
}
.pricing-info-banner strong { color: #A32D2D; }

/* キャンペーンバナー */
.campaign-banner {
  background: #FAEEDA;
  border: 2px solid var(--accent);
  border-radius: var(--radius);
  padding: 0.875rem 1.25rem;
  margin-bottom: 1.25rem;
  text-align: center;
}
.campaign-banner p { margin: 0; line-height: 1.7; }
.campaign-banner .banner-sub { font-size: 11px; color: #633806; font-weight: 500; }
.campaign-banner .banner-main { font-size: 15px; font-weight: 500; color: #412402; }
.campaign-banner .banner-main span { color: #A32D2D; font-size: 18px; }
.campaign-banner .banner-note { font-size: 11px; color: #633806; }

/* 3列グリッド */
.plan-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}
/* 単体2列 */
.plan-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  max-width: 560px;
  margin: 0 auto;
}

/* プランカード */
.plan-card-v2 {
  background: var(--paper);
  border: 0.5px solid var(--line);
  border-radius: var(--radius);
  padding: 1rem;
  position: relative;
}
.plan-card-v2.popular { border: 2px solid var(--brand); }
.plan-card-v2.premium { border: 0.5px solid var(--accent); }
.plan-card-v2.campaign-popular { background: #FAEEDA; border: 2px solid var(--accent); }
.plan-card-v2.secondary { background: var(--soft); }
.plan-card-v2.selected,
.premium-card.selected {
  border: 3px solid var(--brand);
  background: #eaf8f3;
  box-shadow: 0 0 0 4px rgba(45, 156, 121, 0.18), 0 14px 28px rgba(24, 32, 42, 0.16);
}
.plan-card-v2.selected::after,
.premium-card.selected::after {
  content: "✓";
  position: absolute;
  top: 10px;
  right: 10px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--brand);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 800;
}

/* カードヘッダー */
.plan-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  min-height: 36px;
  margin-bottom: 8px;
}
.plan-name {
  min-width: 0;
  color: #18202a;
  font-size: 18px;
  font-weight: 800;
  line-height: 1.25;
  margin: 0 0 8px;
}
.plan-card-header .plan-name {
  margin: 0;
}
.plan-name.campaign { color: #633806; }

.plan-badge-row {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 6px;
}

/* バッジ */
.badge-popular {
  display: inline-block;
  background: var(--brand);
  color: #fff;
  font-size: 10px;
  padding: 2px 10px;
  border-radius: var(--radius);
  margin-bottom: 4px;
}
.badge-popular.campaign { background: var(--accent); }
.badge-custom {
  display: inline-block;
  background: #FAC775;
  color: #633806;
  font-size: 10px;
  padding: 2px 10px;
  border-radius: var(--radius);
  margin-bottom: 4px;
}
.badge-saving {
  display: inline-block;
  background: #FCEBEB;
  color: #A32D2D;
  font-size: 14px;
  padding: 5px 12px;
  border-radius: var(--radius);
  font-weight: 700;
  border: 1.5px solid #A32D2D;
}
.badge-saving.campaign {
  background: #A32D2D;
  color: #fff;
}
.badge-free {
  display: inline-block;
  background: #A32D2D;
  color: #fff;
  font-size: 10px;
  padding: 2px 8px;
  border-radius: var(--radius);
  margin-bottom: 4px;
}

/* 価格 */
.plan-price-strikethrough {
  font-size: 12px;
  color: var(--muted);
  text-decoration: line-through;
  margin: 0;
}
.plan-price-main {
  font-size: 20px;
  font-weight: 500;
  margin: 0 0 4px;
  color: var(--ink);
}
.plan-price-main.campaign { color: #A32D2D; }
.plan-price-main span { font-size: 11px; font-weight: 400; color: var(--muted); }
.plan-campaign-note {
  font-size: 10px;
  color: #633806;
  margin: 0 0 10px;
}

/* 機能リスト */
.plan-features {
  font-size: 12px;
  color: var(--muted);
  line-height: 2.1;
  list-style: none;
  padding: 0;
  margin: 0;
}
.plan-features li.yes { color: #1B5E20; background: #C8E6C9; padding: 2px 5px; border-radius: 3px; font-weight: 500; }
.plan-features li.no { color: #999999; }

/* プレミアム展開ボタン */
.btn-premium-toggle {
  width: 100%;
  padding: 6px;
  background: var(--accent);
  border: none;
  border-radius: var(--radius);
  color: #fff;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  border-bottom: 3px solid #633806;
  transition: transform 0.1s, border-bottom-width 0.1s;
  margin-top: 8px;
}
.btn-premium-toggle:active { transform: translateY(2px); border-bottom-width: 1px; }

/* プレミアム詳細エリア */
.premium-detail {
  display: none;
  border: 2px solid var(--accent);
  border-radius: var(--radius);
  padding: 1rem;
  background: #FAEEDA;
  margin-bottom: 12px;
}
.premium-detail.open { display: block; }
.premium-detail-title {
  font-size: 12px;
  color: #633806;
  font-weight: 500;
  margin: 0 0 12px;
  text-align: center;
}
.premium-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.premium-card {
  background: var(--paper);
  border: 0.5px solid var(--accent);
  border-radius: var(--radius);
  padding: 0.875rem;
  position: relative;
}
.premium-card.diamond { border: 2px solid var(--accent); }

/* 申し込みボタン（LP用） */
.btn-signup {
  display: block;
  width: 100%;
  margin-top: 12px;
  padding: 10px;
  background: var(--brand);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  border-bottom: 4px solid var(--brand-dark);
  transition: transform 0.1s, border-bottom-width 0.1s;
  text-align: center;
  text-decoration: none;
}
.btn-signup:hover { background: #0d8066; }
.btn-signup:active { transform: translateY(2px); border-bottom-width: 2px; }

.pricing-footer-note {
  font-size: 12px;
  color: var(--muted);
  text-align: center;
  margin-top: 8px;
}

/* ===================== キャンペーンPOP CSS ===================== */

/* オーバーレイ */
.campaign-pop-overlay {
  display: none;
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0,0,0,0.5);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  padding: 12px;
}
.campaign-pop-overlay.open {
  display: flex;
}

/* POPウィンドウ本体 */
.campaign-pop {
  position: relative;
  background: #ffffff;
  border-radius: 4px;
  border: 3px solid #EF9F27;
  padding: 1.25rem;
  width: min(520px, calc(100vw - 24px));
  max-height: calc(100dvh - 24px);
  overflow-y: auto;
}

.pop-lang-toggle {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 3;
  min-width: 42px;
  min-height: 32px;
  border: 1px solid #BA7517;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  color: var(--brand-dark);
  cursor: pointer;
  font-weight: 800;
  line-height: 1;
}

.pop-lang-toggle:hover {
  background: #fff7e8;
}

/* 金色装飾枠（四隅） */
.campaign-pop::before,
.campaign-pop::after {
  content: '';
  position: absolute;
  width: 52px;
  height: 52px;
}
/* 四隅の装飾はdivで実装 */
.pop-corner {
  position: absolute;
  width: 52px;
  height: 52px;
}
.pop-corner.tl { top: -3px; left: -3px; border-top: 10px solid #BA7517; border-left: 10px solid #BA7517; border-radius: 4px 0 0 0; }
.pop-corner.tr { top: -3px; right: -3px; border-top: 10px solid #BA7517; border-right: 10px solid #BA7517; border-radius: 0 4px 0 0; }
.pop-corner.bl { bottom: -3px; left: -3px; border-bottom: 10px solid #BA7517; border-left: 10px solid #BA7517; border-radius: 0 0 0 4px; }
.pop-corner.br { bottom: -3px; right: -3px; border-bottom: 10px solid #BA7517; border-right: 10px solid #BA7517; border-radius: 0 0 4px 0; }

.pop-corner-inner {
  position: absolute;
  width: 28px;
  height: 28px;
}
.pop-corner-inner.tl { top: 10px; left: 10px; border-top: 3px solid #FAC775; border-left: 3px solid #FAC775; }
.pop-corner-inner.tr { top: 10px; right: 10px; border-top: 3px solid #FAC775; border-right: 3px solid #FAC775; }
.pop-corner-inner.bl { bottom: 10px; left: 10px; border-bottom: 3px solid #FAC775; border-left: 3px solid #FAC775; }
.pop-corner-inner.br { bottom: 10px; right: 10px; border-bottom: 3px solid #FAC775; border-right: 3px solid #FAC775; }

/* タイトルエリア */
.pop-title-block {
  background: #FAC775;
  border-radius: 8px;
  padding: 0.6rem 0.85rem;
  margin-bottom: 0.75rem;
  text-align: center;
}
.pop-title-sub {
  font-size: 12px;
  color: #633806;
  font-weight: 500;
  letter-spacing: 0.1em;
  margin: 0 0 4px;
}
.pop-title-main {
  font-size: 20px;
  font-weight: 500;
  color: #412402;
  margin: 0;
  line-height: 1.3;
}
.pop-subtitle {
  font-size: 16px;
  font-weight: 500;
  margin: 0 0 0.5rem;
  color: #18202a;
  text-align: center;
}
.pop-desc {
  font-size: 13px;
  color: #667085;
  margin: 0 0 0.9rem;
  line-height: 1.7;
  text-align: center;
}

/* 特典リストエリア */
.pop-benefits {
  border: 0.5px solid #FAC775;
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 0.9rem;
}
.pop-benefit-item {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 0.58rem 0.85rem;
  background: #FAEEDA;
}
.pop-benefit-item + .pop-benefit-item {
  border-top: none;
}
.pop-benefit-num {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #EF9F27;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 13px;
  font-weight: 500;
  color: #fff;
}
.pop-benefit-body {}
.pop-benefit-title {
  font-size: 14px;
  font-weight: 500;
  margin: 0 0 2px;
  color: #18202a;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}
.pop-benefit-title .highlight {
  color: #A32D2D;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.2;
  border-left: none;
  border-radius: 0;
  background: transparent;
  padding: 0;
  margin: 0;
}
.pop-benefit-text {
  font-size: 12px;
  color: #667085;
  margin: 0;
  line-height: 1.6;
}

/* お知らせボックス */
.pop-notice {
  background: #FAEEDA;
  border: 0.5px solid #FAC775;
  border-radius: 8px;
  padding: 0.65rem 0.85rem;
  margin-bottom: 0.9rem;
  text-align: center;
}
.pop-notice p {
  font-size: 13px;
  color: #633806;
  margin: 0;
  line-height: 1.9;
}
.pop-notice .price-before {
  text-decoration: line-through;
  color: #BA7517;
}
.pop-notice .price-after {
  font-weight: 500;
  font-size: 16px;
  color: #412402;
}

/* ボタン */
.pop-btn-primary {
  display: block;
  width: 100%;
  padding: 0.78rem;
  background: #EF9F27;
  border: none;
  border-radius: 8px;
  color: #fff;
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
  border-bottom: 5px solid #633806;
  transition: transform 0.1s ease, border-bottom-width 0.1s ease;
  margin-bottom: 10px;
  text-align: center;
}
.pop-btn-primary:hover { background: #FAB740; }
.pop-btn-primary:active { transform: translateY(3px); border-bottom-width: 2px; }

.pop-btn-secondary {
  display: block;
  width: 100%;
  padding: 0.58rem;
  background: transparent;
  border: 0.5px solid #d9e2e7;
  border-radius: 8px;
  color: #667085;
  font-size: 13px;
  cursor: pointer;
  text-align: center;
}
.pop-btn-secondary:hover { background: #f4f8f7; }

.step2-plan-summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #f4f8f7;
  border: 1.5px solid var(--brand, #10a37f);
  border-radius: 8px;
  padding: 0.75rem 1rem;
  margin-bottom: 1.25rem;
}
#step2-plan-name {
  font-size: 14px;
  font-weight: 500;
  color: #18202a;
}
#step2-plan-price {
  font-size: 18px;
  font-weight: 700;
  color: var(--brand, #10a37f);
}
/* ===== Confetti effect ===== */
.confetti-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 99999;
  overflow: hidden;
}

.confetti-piece {
  position: absolute;
  top: -20px;
  width: 10px;
  height: 10px;
  border-radius: 2px;
  opacity: 0;
  animation: confettiFall linear forwards;
}

@keyframes confettiFall {
  0% {
    opacity: 1;
    transform: translateY(0) rotate(0deg);
  }
  100% {
    opacity: 0;
    transform: translateY(100vh) rotate(720deg);
  }
}
.chrome-notice {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #FFF8E1;
  border: 1.5px solid #FAC775;
  border-radius: 8px;
  padding: 10px 16px;
  margin-bottom: 16px;
  font-size: 13px;
  color: #633806;
}
.chrome-notice a {
  color: #1a73e8;
  text-decoration: underline;
  white-space: nowrap;
}


.campaign-flow-note {
  border: 1px solid #e0a63a;
  border-radius: 8px;
  background: #fff7e4;
  color: #633806;
  padding: 14px 16px;
  margin: 0 0 16px;
  display: grid;
  gap: 4px;
}
.campaign-flow-note strong {
  font-size: 15px;
}
.campaign-flow-note span {
  font-size: 14px;
}


/* campaign flow corrections */
#pricing-tab-campaign .plan-grid-3 {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  overflow-x: visible;
  padding-bottom: 8px;
}
#pricing-tab-campaign .plan-card-v2,
#pricing-tab-campaign .plan-card-v2.campaign-popular {
  background: var(--paper);
  border: 1px solid var(--line);
}
.plan-card-v2 {
  cursor: pointer;
}
.plan-price-strikethrough {
  font-size: 15px;
}
.plan-campaign-note {
  font-size: 17px;
  line-height: 1.45;
  font-weight: 800;
}
.plan-campaign-note + .plan-campaign-note {
  font-size: 14px;
  font-weight: 700;
}
@media (max-width: 1180px) {
  #pricing-tab-campaign .plan-grid-3 {
    grid-template-columns: repeat(5, minmax(220px, 1fr));
    overflow-x: auto;
  }
}
@media (max-width: 820px) {
  #pricing-tab-campaign .plan-grid-3 {
    grid-template-columns: 1fr;
    overflow-x: visible;
  }
}

/* Mobile layout corrections */
.three-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin: 28px 0 10px;
}

.three-card {
  display: grid;
  place-items: center;
  gap: 8px;
  min-height: 132px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  padding: 18px 14px;
  text-align: center;
}

.three-card .num {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--brand);
  color: var(--paper);
  font-weight: 900;
  line-height: 1;
}

.three-card .lbl {
  font-size: 16px;
  font-weight: 800;
  line-height: 1.6;
}

@media (max-width: 820px) {
  .brand-logo {
    width: 220px;
    height: 72px;
  }

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

  .nav {
    top: 96px;
  }

  .nav.nav-inline {
    position: static;
    display: flex;
    width: auto;
    flex-direction: row;
    align-items: center;
    padding: 0;
    border-bottom: 0;
    background: transparent;
  }

  .nav.nav-inline .lang-toggle {
    min-width: 52px;
    text-align: center;
  }

  .mobile-tabs {
    top: 96px;
    z-index: 25;
    padding: 8px 12px;
  }

  .mobile-tabs a {
    max-width: 158px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .three-cards {
    grid-template-columns: 1fr;
    gap: 10px;
    margin: 24px 0 8px;
  }

  .three-card {
    grid-template-columns: 42px minmax(0, 1fr);
    place-items: center stretch;
    min-height: 0;
    padding: 12px 14px;
    text-align: left;
  }

  .three-card .lbl {
    font-size: 15px;
    line-height: 1.55;
  }

  .signup-page-body .steps-indicator {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    align-items: start;
    gap: 6px;
    margin-bottom: 24px;
  }

  .signup-page-body .steps-indicator .step-line {
    display: none;
  }

  .signup-page-body .steps-indicator .step {
    min-width: 0;
    gap: 6px;
  }

  .signup-page-body .steps-indicator .step-number {
    width: 34px;
    height: 34px;
    margin: 0 auto;
    font-size: 15px;
  }

  .signup-page-body .steps-indicator .step-label {
    width: 100%;
    font-size: 11px;
    line-height: 1.45;
    text-align: center;
    overflow-wrap: anywhere;
  }
}
