/* Bible Planner — companion site. Matches the iOS app palette. */

:root {
  --bg:           #F2EDE2;
  --bg-deep:      #E8E0CE;
  --surface:      #FAF6EB;
  --surface-soft: #EFE8D6;
  --surface-lift: #FFFCF3;
  --navy:         #1A2238;
  --navy-soft:    #2C3450;
  --navy-muted:   #4A5168;
  --mute:         #6F6856;
  --mute-soft:    #9A8F77;
  --hairline:        rgba(26, 34, 56, 0.10);
  --hairline-soft:   rgba(26, 34, 56, 0.06);
  --hairline-heavy:  rgba(26, 34, 56, 0.18);
  --wine:         #6E1F2B;
  --wine-soft:    #F0E2DF;
  --wine-softer:  #F8EDEB;
  --wine-ink:     #4E141E;
  --gold:         #A8842E;
  --gold-soft:    #C9A249;
  --success:      #4A6A3B;

  --serif: "Noto Serif KR", "Nanum Myeongjo", "New York", Georgia, serif;
  --sans:  "Noto Sans KR", -apple-system, BlinkMacSystemFont, "Inter", system-ui, sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--navy);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.container {
  max-width: 1040px;
  margin: 0 auto;
  padding: 0 24px;
}

/* -- Top bar ----------------------------------------------------------- */

.topbar {
  position: sticky; top: 0; z-index: 10;
  background: var(--bg);
  border-bottom: 1px solid var(--hairline-soft);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}
.topbar-inner {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 0;
}
.brand {
  display: inline-flex; align-items: center; gap: 12px;
  text-decoration: none; color: inherit;
}
.brand img {
  width: 36px; height: 36px; border-radius: 8px;
  border: 1px solid var(--hairline);
}
.brand .name {
  font-family: var(--serif);
  font-size: 18px; font-weight: 500;
  letter-spacing: 0.2px;
}
.brand .sub {
  font-size: 11px;
  letter-spacing: 1.6px; text-transform: uppercase;
  color: var(--mute); font-weight: 600;
  margin-top: 1px;
}
.nav { display: flex; align-items: center; }
.nav a {
  color: var(--navy-soft); text-decoration: none;
  font-weight: 500; font-size: 15px;
  margin-left: 22px;
}
.nav a:hover { color: var(--wine); }
.nav a.active { color: var(--wine); font-weight: 700; }

/* Inline segmented language control. Mirrors the iOS app's Settings
   SegmentedControl. Lives inside .settings-row > .control. */
.lang-switch {
  display: inline-flex;
  border: 1px solid var(--hairline);
  border-radius: 10px;
  padding: 2px;
  background: var(--bg-deep);
}
.lang-switch button {
  appearance: none;
  background: transparent;
  border: 0; cursor: pointer;
  padding: 8px 16px;
  border-radius: 8px;
  font: 500 14px/1.2 var(--sans);
  color: var(--mute);
  transition: background .15s ease, color .15s ease, font-weight .15s ease;
  min-width: 60px;
}
.lang-switch button:hover { color: var(--wine); }
.lang-switch button.active {
  background: var(--surface);
  color: var(--navy);
  font-weight: 700;
  box-shadow: 0 1px 3px rgba(26, 34, 56, 0.10);
}

/* Settings list — mirrors the iOS app's section-with-rounded-rows layout. */
.settings-section {
  margin-bottom: 28px;
}
.settings-section h2 {
  font: 700 11px/1.4 var(--sans);
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: var(--mute);
  margin: 0 0 10px 4px;
}
.settings-card {
  background: var(--surface);
  border: 1px solid var(--hairline-soft);
  border-radius: 16px;
  overflow: hidden;
}
.settings-row {
  display: flex; align-items: center; gap: 18px;
  padding: 16px 20px;
  min-height: 64px;
  border-bottom: 1px solid var(--hairline-soft);
}
.settings-row:last-child { border-bottom: 0; }
.settings-row .label {
  font: 500 16px/1.35 var(--sans);
  color: var(--navy);
}
.settings-row .sublabel {
  font: 400 13px/1.4 var(--sans);
  color: var(--mute);
  margin-top: 2px;
}
.settings-row .text { flex: 1; min-width: 0; }
.settings-row .control { flex-shrink: 0; }
.settings-note {
  margin-top: 14px;
  font: 400 13px/1.55 var(--sans);
  color: var(--mute);
  padding: 0 4px;
}

/* -- Hero -------------------------------------------------------------- */

.hero {
  padding: 64px 0 48px;
  position: relative;
  background: radial-gradient(ellipse at top, var(--surface) 0%, var(--bg) 60%);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 56px;
  align-items: center;
}
.hero h1 {
  font-family: var(--serif);
  font-size: 56px; line-height: 1.05; font-weight: 500;
  letter-spacing: -1.5px;
  margin: 0 0 14px;
}
.hero h1 .accent { color: var(--wine); }
.hero p.kr {
  font-family: var(--serif);
  font-size: 18px; color: var(--mute);
  margin: 0 0 8px;
}
.hero p.lede {
  font-size: 19px; color: var(--navy-soft);
  margin: 0 0 28px;
  max-width: 38ch;
}
.cta-row {
  display: flex; gap: 12px; flex-wrap: wrap; align-items: center;
}
.cta {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 22px;
  border-radius: 14px;
  font-family: var(--sans);
  font-size: 16px; font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: transform .08s ease, background .15s ease, color .15s ease;
}
.cta.primary {
  background: var(--wine);
  color: var(--surface);
  border: 1px solid var(--wine);
}
.cta.primary:hover { background: var(--wine-ink); }
.cta.outlined {
  background: transparent;
  color: var(--wine);
  border: 1.5px solid var(--wine);
}
.cta.outlined:hover { background: var(--wine-soft); }
.cta:active { transform: scale(0.985); }

.hero-art {
  display: flex; justify-content: center;
  position: relative;
}
.phone {
  width: min(320px, 90%);
  border-radius: 38px;
  overflow: hidden;
  box-shadow:
    0 1px 2px rgba(26,34,56,0.06),
    0 30px 80px -30px rgba(26,34,56,0.35),
    0 0 0 8px #1a1a1a,
    0 0 0 9px rgba(255,255,255,0.06) inset;
  background: #000;
}
.phone img {
  width: 100%; display: block;
}

/* -- Section primitives ----------------------------------------------- */

section {
  padding: 64px 0;
  border-top: 1px solid var(--hairline-soft);
}
.eyebrow {
  font-size: 12px; letter-spacing: 1.8px; text-transform: uppercase;
  color: var(--mute); font-weight: 700;
  margin-bottom: 14px;
}
h2 {
  font-family: var(--serif);
  font-size: 36px; line-height: 1.1; font-weight: 500;
  letter-spacing: -0.6px;
  margin: 0 0 16px;
}
h3 {
  font-family: var(--serif);
  font-size: 22px; line-height: 1.2; font-weight: 500;
  letter-spacing: -0.2px;
  margin: 0 0 6px;
}
section p { color: var(--navy-soft); max-width: 60ch; }

.gilt {
  height: 2px;
  background: linear-gradient(90deg, transparent 0%, var(--gold) 30%, var(--gold) 70%, transparent 100%);
  opacity: 0.55;
}

/* -- Feature grid ----------------------------------------------------- */

.feature-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 22px;
  margin-top: 28px;
}
.feature {
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 18px;
  padding: 24px;
  position: relative;
}
.feature .gilt { position: absolute; top: 0; left: 24px; right: 24px; }
.feature h3 { margin-bottom: 6px; }
.feature p { font-size: 15px; color: var(--mute); margin: 0; }
.feature .kr {
  font-family: var(--serif);
  color: var(--mute); font-size: 14px;
  margin-top: 2px;
}

/* -- Screenshot row --------------------------------------------------- */

.shot-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
  margin-top: 32px;
}
.shot {
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 22px;
  padding: 28px;
  text-align: center;
}
.shot img {
  width: 70%; max-width: 280px;
  border-radius: 28px;
  box-shadow: 0 1px 2px rgba(26,34,56,0.04), 0 18px 40px -22px rgba(26,34,56,0.32);
}
.shot p { margin: 18px auto 0; font-size: 14px; color: var(--mute); }

/* -- Translations panel ---------------------------------------------- */

.translations {
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 22px;
  padding: 32px;
  position: relative;
  margin-top: 28px;
}
.translations .gilt { position: absolute; top: 0; left: 32px; right: 32px; }
.translations dl {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 12px 24px;
  margin: 0;
}
.translations dt {
  font-family: var(--serif);
  font-weight: 600; color: var(--navy);
  font-size: 18px;
}
.translations dd {
  margin: 0; color: var(--navy-soft);
}
.translations small {
  display: block; color: var(--mute); font-size: 13px;
}

/* -- Footer ----------------------------------------------------------- */

footer {
  padding: 36px 0 44px;
  border-top: 1px solid var(--hairline-soft);
  color: var(--mute);
  font-size: 14px;
}
footer .row {
  display: flex; gap: 22px; flex-wrap: wrap; align-items: center; justify-content: space-between;
}
footer a {
  color: var(--mute);
  text-decoration: none;
  margin-left: 18px;
}
footer a:first-child { margin-left: 0; }
footer a:hover { color: var(--wine); }

/* -- Content pages (privacy, support, copyright) --------------------- */

.page {
  padding: 56px 0 80px;
}
.page-inner {
  max-width: 720px;
  margin: 0 auto;
}
.page h1 {
  font-family: var(--serif);
  font-size: 42px; line-height: 1.1; font-weight: 500;
  letter-spacing: -0.8px;
  margin: 0 0 6px;
}
.page .lede {
  color: var(--mute);
  font-size: 15px;
  margin: 0 0 36px;
}
.page h2 {
  font-family: var(--serif);
  font-size: 22px; line-height: 1.25; font-weight: 600;
  letter-spacing: -0.2px;
  margin: 36px 0 10px;
}
.page p, .page li {
  color: var(--navy-soft);
  font-size: 16px;
  line-height: 1.7;
}
.page ul { padding-left: 22px; }
.page strong { color: var(--navy); }
.page code {
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: 13px;
  background: var(--bg-deep);
  padding: 2px 6px;
  border-radius: 4px;
}
.page .callout {
  background: var(--wine-softer);
  border-left: 3px solid var(--wine);
  padding: 14px 18px;
  border-radius: 0 10px 10px 0;
  margin: 16px 0;
  color: var(--wine-ink);
  font-size: 15px;
}

/* -- Mobile ---------------------------------------------------------- */

@media (max-width: 800px) {
  .hero { padding: 40px 0 32px; }
  .hero-grid { grid-template-columns: 1fr; gap: 32px; }
  .hero h1 { font-size: 36px; }
  .feature-grid { grid-template-columns: 1fr; }
  .shot-row { grid-template-columns: 1fr; }
  .nav a { margin-left: 14px; font-size: 14px; }
  .lang-switch { margin-left: 14px; }
  h2 { font-size: 28px; }
  .page h1 { font-size: 34px; }
}

/* Korean glyph balance — slightly tighter line-height for Korean body. */
html[lang^="ko"] body { line-height: 1.7; }
html[lang^="ko"] .hero h1 { letter-spacing: -1px; }
html[lang^="ko"] h2 { letter-spacing: -0.3px; }
