/* ============================================================
   DAVETNAME KLASİK — Theme Stylesheet
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,500;0,600;1,500&family=Jost:wght@300;400&display=swap&subset=latin-ext');
@import '../../shared/core.css';

/* ── Design tokens ──────────────────────────────────────────── */
:root {
  --navy:      #1F2A44;
  --ivory:     #F6F1E7;
  --ink-60:    rgba(31, 42, 68, 0.60);
  --ivory-70:  rgba(246, 241, 231, 0.70);

  --accent-on-navy:  #C9A227;
  --accent-on-ivory: #C9A227;

  --serif: 'Cormorant Garamond', Georgia, serif;
  --sans:  'Jost', 'Segoe UI', sans-serif;

  --content-max: 680px;
  --section-gap: clamp(96px, 18vh, 160px);
  --h-pad: 24px;
}

/* Silver varak override (applied by main.js when accent=silver) */
.accent-silver {
  --accent-on-navy:  #C7CCD6;
  --accent-on-ivory: #8E96A3;
}

/* ── Base ───────────────────────────────────────────────────── */
html { font-size: 16px; }

body {
  font-family: var(--sans);
  background: var(--ivory);
  color: var(--navy);
  overflow-x: hidden;
}

.content {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 0 var(--h-pad);
}

section { position: relative; }

.section-gap { padding-top: var(--section-gap); padding-bottom: var(--section-gap); }

/* Dark sections */
.bg-navy { background: var(--navy); }

/* ── Music badge ────────────────────────────────────────────── */
#music-badge {
  border: 1px solid var(--accent-on-navy);
}
.bg-ivory ~ #music-badge,
body:not(.on-dark) #music-badge {
  border-color: var(--navy);
}
#music-badge .bar { background: var(--accent-on-navy); height: 12px; }

/* ── Section 1 — Opening screen ─────────────────────────────── */
#section-opening {
  position: fixed;
  inset: 0;
  background: var(--navy);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 500;
  cursor: pointer;
  user-select: none;
}

#section-opening .monogram {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 500;
  font-size: 72px;
  color: var(--ivory);
  animation: monogram-pulse 4s ease-in-out infinite;
}

@keyframes monogram-pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.92; }
}

#section-opening .gold-line {
  width: 64px;
  height: 1px;
  background: var(--accent-on-navy);
  margin: 32px auto 24px;
}

#section-opening .tap-hint {
  font-family: var(--sans);
  font-weight: 300;
  font-size: 12px;
  letter-spacing: 0.35em;
  color: var(--ivory-70);
  opacity: 0;
  transition: opacity 0.6s ease;
}
#section-opening .tap-hint.visible {
  opacity: 1;
}

#section-opening .brand-mark {
  position: absolute;
  bottom: 24px;
  font-family: var(--sans);
  font-weight: 300;
  font-size: 11px;
  letter-spacing: 0.35em;
  color: var(--ivory-70);
}

/* Curtain lift animation */
#section-opening.lifting {
  animation: curtain-lift 1100ms cubic-bezier(0.77, 0, 0.18, 1) forwards;
  pointer-events: none;
}

@keyframes curtain-lift {
  to { transform: translateY(-100%); }
}

/* ── Section 2 — Hero / Invite ───────────────────────────────── */
#section-hero {
  background: var(--ivory);
  text-align: center;
  padding: clamp(80px, 15vh, 130px) var(--h-pad) var(--section-gap);
  min-height: 100svh;
  display: flex;
  align-items: center;
}

#section-hero .inner { width: 100%; max-width: var(--content-max); margin: 0 auto; }

.hero-eyebrow {
  font-family: var(--sans);
  font-weight: 300;
  font-size: 12px;
  letter-spacing: 0.35em;
  color: var(--ink-60);
  margin-bottom: 40px;
}

.hero-names {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
}

.hero-name {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(44px, 12vw, 96px);
  color: var(--navy);
  line-height: 1.05;
}

.hero-ampersand {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 500;
  font-size: clamp(28px, 7vw, 56px);
  color: var(--accent-on-ivory);
  display: block;
  line-height: 1.3;
}

.hero-invite-line {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 500;
  font-size: clamp(17px, 4.5vw, 22px);
  color: var(--accent-on-ivory);
  margin-top: 32px;
  line-height: 1.5;
}

.hero-info {
  font-family: var(--sans);
  font-weight: 400;
  font-size: 15px;
  color: var(--navy);
  margin-top: 40px;
  line-height: 1.7;
}

.hero-scroll-hint {
  margin-top: clamp(48px, 10vh, 80px);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--accent-on-ivory);
  animation: scroll-float 2.5s ease-in-out infinite;
}

@keyframes scroll-float {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(6px); }
}

.hero-scroll-hint svg { width: 12px; height: 12px; }

/* ── Section 3 — Photo & Families ───────────────────────────── */
#section-photo {
  background: var(--ivory);
  padding-top: 0;
  padding-bottom: var(--section-gap);
}

.hero-photo-wrap {
  position: relative;
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 0 var(--h-pad);
}

.hero-photo {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  display: block;
  /* Passe-partout */
  outline: 1px solid var(--accent-on-ivory);
  outline-offset: 12px;
}

.families {
  text-align: center;
  margin-top: 64px;
  padding: 0 var(--h-pad);
  max-width: var(--content-max);
  margin-left: auto;
  margin-right: auto;
}

.families-line {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 22px;
  color: var(--navy);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}

.families-dot {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--accent-on-ivory);
  flex-shrink: 0;
}

.welcome-note {
  font-family: var(--sans);
  font-weight: 400;
  font-size: 15px;
  color: var(--ink-60);
  line-height: 1.7;
  margin-top: 16px;
  text-align: center;
  max-width: var(--content-max);
  margin-left: auto;
  margin-right: auto;
  padding: 0 var(--h-pad);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ── Section 4 — Countdown ──────────────────────────────────── */
#section-countdown {
  padding: clamp(72px, 12vh, 112px) var(--h-pad);
  text-align: center;
}

#section-countdown .eyebrow {
  color: var(--ivory-70);
  margin-bottom: 40px;
}

#section-countdown .countdown-num {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(40px, 10vw, 72px);
  color: var(--ivory);
}

#section-countdown .countdown-label {
  font-family: var(--sans);
  font-weight: 300;
  font-size: 12px;
  letter-spacing: 0.3em;
  color: var(--accent-on-navy);
}

.countdown-sep {
  font-family: var(--serif);
  font-size: clamp(28px, 6vw, 44px);
  color: var(--ivory);
  opacity: 0.3;
  align-self: flex-end;
  padding-bottom: 24px;
  margin: 0 4px;
}

[data-cd="ended"] {
  display: none;
  font-family: var(--serif);
  font-style: italic;
  font-size: 28px;
  color: var(--ivory);
}

/* ── Section 5 — Schedule ───────────────────────────────────── */
#section-schedule {
  background: var(--ivory);
}

#section-schedule .eyebrow {
  color: var(--ink-60);
  margin-bottom: 40px;
}

.timeline {
  position: relative;
  padding-left: 32px;
  max-width: var(--content-max);
  margin: 0 auto;
  padding-left: calc(var(--h-pad) + 32px);
  padding-right: var(--h-pad);
}

.timeline-line {
  position: absolute;
  left: calc(var(--h-pad) + 8px);
  top: 0;
  width: 1px;
  height: 100%;
  background: rgba(31, 42, 68, 0.2);
  transform-origin: top;
  transform: scaleY(0);
  transition: transform 0.8s ease;
}

.timeline-line.drawn { transform: scaleY(1); }

.timeline-item {
  position: relative;
  padding-bottom: 40px;
}

.timeline-item:last-child { padding-bottom: 0; }

.timeline-dot {
  position: absolute;
  left: calc(-32px + 4px);
  top: 4px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent-on-ivory);
}

.timeline-time {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 20px;
  color: var(--navy);
}

.timeline-label {
  font-family: var(--sans);
  font-weight: 400;
  font-size: 15px;
  color: var(--ink-60);
  margin-top: 2px;
}

/* ── Section 6 — Gallery ────────────────────────────────────── */
#section-gallery {
  background: var(--ivory);
}

#section-gallery .eyebrow {
  color: var(--ink-60);
  margin-bottom: 32px;
}

.gallery-grid {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 0 var(--h-pad);
}

.gallery-row {
  display: grid;
  gap: 12px;
  margin-bottom: 12px;
}

.gallery-row.large   { grid-template-columns: 1fr; }
.gallery-row.pair    { grid-template-columns: 1fr 1fr; }

.gallery-img {
  width: 100%;
  object-fit: cover;
  display: block;
}

.gallery-row.large .gallery-img  { aspect-ratio: 4 / 3; }
.gallery-row.pair  .gallery-img  { aspect-ratio: 1 / 1; }

@media (min-width: 768px) {
  .gallery-row.desktop-60-40 { grid-template-columns: 60fr 40fr; }
  .gallery-row.desktop-40-60 { grid-template-columns: 40fr 60fr; }
  .gallery-row.desktop-60-40 .gallery-img,
  .gallery-row.desktop-40-60 .gallery-img { aspect-ratio: 4 / 3; }
}

/* ── Section 7 — Venue ──────────────────────────────────────── */
#section-venue {
  background: var(--ivory);
}

#section-venue .eyebrow {
  color: var(--ink-60);
  margin-bottom: 24px;
}

.venue-name {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(22px, 5vw, 28px);
  color: var(--navy);
}

.venue-address {
  font-family: var(--sans);
  font-size: 15px;
  color: var(--ink-60);
  margin-top: 6px;
}

.maps-iframe {
  width: 100%;
  aspect-ratio: 16 / 10;
  border: 1px solid rgba(31, 42, 68, 0.15);
  margin-top: 24px;
  display: block;
}

.venue-actions {
  display: flex;
  gap: 12px;
  margin-top: 16px;
  flex-wrap: wrap;
}

.btn {
  font-family: var(--sans);
  font-weight: 400;
  font-size: 13px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 14px 28px;
  cursor: pointer;
  transition: opacity 0.2s, background 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.btn-primary {
  background: var(--navy);
  color: var(--ivory);
}
.btn-primary:hover { opacity: 0.92; }

.btn-outline {
  border: 1px solid var(--navy);
  color: var(--navy);
}
.btn-outline:hover { background: rgba(31, 42, 68, 0.06); }

/* ── Section 8 — LCV ────────────────────────────────────────── */
#section-lcv {
  background: var(--ivory);
}

#section-lcv .eyebrow { color: var(--ink-60); margin-bottom: 16px; }

.lcv-sub {
  font-family: var(--sans);
  font-size: 15px;
  color: var(--ink-60);
  margin-bottom: 32px;
}

.lcv-card {
  background: #FBF8F1;
  border: 1px solid var(--accent-on-ivory);
  padding: clamp(32px, 6vw, 56px);
}

/* Override core LCV styles for Classic theme */
#section-lcv .field-label {
  font-family: var(--sans);
  font-weight: 300;
  color: var(--ink-60);
}

#section-lcv .field-input {
  border-bottom-color: rgba(31, 42, 68, 0.30);
  color: var(--navy);
}

#section-lcv .field-input:focus {
  border-bottom-color: var(--accent-on-ivory);
  border-bottom-width: 2px;
}

#section-lcv .radio-custom {
  border-color: rgba(31, 42, 68, 0.40);
}
#section-lcv .radio-option.selected .radio-custom {
  border-color: var(--accent-on-ivory);
}
#section-lcv .radio-option.selected .radio-custom::after {
  background: var(--accent-on-ivory);
}

#section-lcv .lcv-submit {
  background: var(--navy);
  color: var(--ivory);
}

#section-lcv .lcv-success {
  font-family: var(--serif);
  font-style: italic;
  font-size: 22px;
  color: var(--navy);
  text-align: center;
}

#section-lcv .lcv-error { color: #6B1F2A; }

/* ── Section 8B — Memory Wall ───────────────────────────────── */
#section-memory {
  background: var(--ivory);
}

#section-memory .eyebrow { color: var(--ink-60); margin-bottom: 16px; }

.memory-invite-line {
  font-family: var(--serif);
  font-style: italic;
  font-size: 20px;
  color: var(--navy);
  margin-bottom: 32px;
}

.memory-upload-card {
  background: #FBF8F1;
  border: 1px solid var(--accent-on-ivory);
  padding: clamp(32px, 6vw, 56px);
  margin-bottom: 48px;
}

#section-memory .field-label {
  font-family: var(--sans);
  font-weight: 300;
  color: var(--ink-60);
}
#section-memory .field-input {
  border-bottom-color: rgba(31, 42, 68, 0.30);
  color: var(--navy);
}
#section-memory .field-input:focus {
  border-bottom-color: var(--accent-on-ivory);
  border-bottom-width: 2px;
}

#section-memory .photo-picker-btn {
  border-color: var(--navy);
  color: var(--navy);
}

.memory-consent {
  font-family: var(--sans);
  font-size: 12px;
  color: var(--ink-60);
}

.memory-submit {
  background: var(--navy);
  color: var(--ivory);
  font-family: var(--sans);
  font-weight: 400;
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 14px 32px;
  cursor: pointer;
  transition: opacity 0.2s;
}
.memory-submit:hover { opacity: 0.85; }
.memory-submit:disabled { opacity: 0.5; cursor: not-allowed; }

.memory-entry-name {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 18px;
  color: var(--navy);
}
.memory-entry-note {
  font-family: var(--sans);
  font-size: 14px;
  color: var(--ink-60);
  line-height: 1.6;
}

.memory-archived {
  display: none;
  font-family: var(--serif);
  font-style: italic;
  font-size: 18px;
  color: var(--ink-60);
  text-align: center;
}

/* ── Section 9 — Closing ────────────────────────────────────── */
#section-closing {
  min-height: 70vh;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  text-align: center;
  padding: var(--section-gap) var(--h-pad);
}

.closing-monogram {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 500;
  font-size: 56px;
  color: var(--ivory);
}

.closing-line-gold {
  width: 64px;
  height: 1px;
  background: var(--accent-on-navy);
  margin: 24px auto;
}

.closing-text {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 500;
  font-size: 20px;
  color: var(--ivory);
}

.brand-mark {
  font-family: var(--sans);
  font-weight: 300;
  font-size: 11px;
  letter-spacing: 0.3em;
  color: rgba(246, 241, 231, 0.40);
  text-decoration: none;
  transition: color 0.2s;
  text-transform: uppercase;
  margin-top: 48px;
}
.brand-mark:hover { color: rgba(246, 241, 231, 0.70); }

/* ── Archived state ─────────────────────────────────────────── */
body.archived .page-content { display: none; }
body.archived #section-closing { display: flex; }
body.archived .closing-archived-note {
  display: block;
  font-family: var(--sans);
  font-size: 14px;
  color: var(--ivory-70);
  margin-top: 12px;
}
.closing-archived-note { display: none; }

/* ── Responsive ─────────────────────────────────────────────── */
@media (min-width: 768px) {
  :root { --h-pad: 40px; }

  .hero-name { line-height: 1; }

  .timeline {
    padding-left: calc(var(--h-pad) + 40px);
  }
  .timeline-line { left: calc(var(--h-pad) + 12px); }
  .timeline-dot  { left: calc(-40px + 6px); }
}
