/* ============================================================
   BOLOGNA İLHAMI — TOPRAK TONLARI
   ============================================================ */
:root {
  --cream:      #F3EBDD;   /* Bologna sıvası / arka plan */
  --cream-deep: #EADFCB;
  --terracotta: #A14328;   /* tuğla kırmızısı — birincil */
  --terra-soft: #C46A4A;   /* yumuşak terracotta */
  --ochre:      #C68A3E;   /* safran / okra — vurgu */
  --olive:      #5E5A3E;   /* zeytin — ikincil metin */
  --espresso:   #3B2A1E;   /* koyu kahve — başlıklar */
  --ink:        #2C211A;   /* gövde metni */
  --line:       rgba(59,42,30,.22);

  --maxw: 980px;
  --gut: clamp(20px, 5vw, 64px);

  --fz-display: clamp(2.8rem, 9vw, 6rem);
  --fz-h2:      clamp(1.7rem, 4.2vw, 2.8rem);
  --fz-lead:    clamp(1rem, 2.2vw, 1.18rem);

  --ease: cubic-bezier(.22,.61,.36,1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: "DM Sans", system-ui, sans-serif;
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  /* ince kağıt dokusu hissi */
  background-image:
    radial-gradient(circle at 20% 10%, rgba(198,138,62,.05), transparent 40%),
    radial-gradient(circle at 80% 80%, rgba(161,67,40,.05), transparent 45%);
}

h1, h2, h3 {
  font-family: "Fraunces", Georgia, serif;
  font-weight: 500;
  color: var(--espresso);
  line-height: 1.05;
  margin: 0;
}

a { color: inherit; }
img, svg { display: block; max-width: 100%; }

/* ---------- NAV ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px var(--gut);
  background: color-mix(in srgb, var(--cream) 82%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav__brand {
  font-family: "Fraunces", serif; font-size: 1.15rem; letter-spacing: .04em;
  color: var(--terracotta); text-decoration: none; font-weight: 600;
}
.nav__links { display: flex; gap: clamp(12px, 2vw, 26px); }
.nav__links a {
  font-size: .82rem; letter-spacing: .08em; text-transform: uppercase;
  text-decoration: none; color: var(--olive);
  position: relative; padding: 4px 0; transition: color .25s var(--ease);
}
.nav__links a::after {
  content: ""; position: absolute; left: 0; right: 100%; bottom: 0; height: 1px;
  background: var(--terracotta); transition: right .3s var(--ease);
}
.nav__links a:hover { color: var(--terracotta); }
.nav__links a:hover::after { right: 0; }

.nav__toggle { display: none; background: none; border: 0; cursor: pointer; flex-direction: column; gap: 5px; padding: 6px; }
.nav__toggle span { width: 24px; height: 2px; background: var(--espresso); transition: .3s var(--ease); }

@media (max-width: 768px) {
  /* Mobilde: marka adı ve hamburger gizli; linkler doğrudan krem barda yan yana */
  .nav { padding: 10px 12px; }
  .nav__brand { display: none; }
  .nav__toggle { display: none; }
  .nav__links {
    display: flex; flex-direction: row; position: static;
    width: 100%; justify-content: space-between; align-items: center;
    gap: 6px; max-height: none; overflow: visible; background: none; border: 0;
  }
  .nav__links a {
    font-size: .7rem; letter-spacing: .04em; padding: 4px 0;
    width: auto; text-align: center; white-space: nowrap;
  }
}

/* ---------- HERO ---------- */
.hero {
  display: grid; place-items: center;
  padding: clamp(48px, 9vh, 110px) var(--gut) clamp(40px, 7vh, 80px);
  min-height: 100vh;
  min-height: 100svh; /* mobil: tarayıcı chrome'unu hariç tutar */
  position: relative; overflow: hidden;
  /* Fotoğraf arka plan — tam ekran kaplar */
  background: var(--espresso) url('/assets/hero.jpeg') center center / cover no-repeat;
}
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(160deg, rgba(59,42,30,.52), rgba(59,42,30,.32));
}
.hero__arch { position: relative; z-index: 1; width: min(440px, 100%); padding: 0 8px; }
.arch-frame { position: absolute; inset: -2% -4% auto; width: 108%; height: 112%; opacity: .55; }
.arch-frame path { stroke: var(--terracotta); stroke-width: 1.4; }

.hero__inner {
  position: relative; text-align: center;
  padding: clamp(40px, 10vw, 72px) clamp(8px,3vw,28px) 8px;
  background: color-mix(in srgb, var(--cream) 92%, transparent);
  border-radius: 2px;
}
.hero__eyebrow { letter-spacing: .42em; font-size: .72rem; color: var(--ochre); margin: 0 0 18px; }
.hero__names {
  font-size: var(--fz-display);
  font-weight: 400; letter-spacing: -.01em;
  background: linear-gradient(180deg, var(--terracotta), var(--espresso));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero__tagline { font-style: italic; font-family: "Fraunces", serif; color: var(--olive); font-size: var(--fz-lead); margin: 16px auto 0; max-width: 30ch; }

.ornament { margin: 26px auto; width: 130px; }
.ornament svg path { stroke: var(--ochre); stroke-width: 1.5; fill: none; }
.ornament--light svg path { stroke: rgba(243,235,221,.7); }

/* İki etkinlik tarihi alt alta (dikey) */
.hero__dates {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: clamp(10px, 3vw, 18px);
  margin: 6px 0 28px;
}
.hero__event { display: grid; gap: 2px; justify-items: center; text-align: center; }
.hero__events-sep {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  font-family: "Fraunces", serif; font-style: italic;
  color: var(--olive); font-size: 1rem;
}
.hero__events-sep::before,
.hero__events-sep::after {
  content: ""; width: 24px; height: 1px; background: var(--olive); opacity: .6;
}
.hero__day    { font-family: "Fraunces", serif; font-size: clamp(2.4rem,9vw,4.2rem); color: var(--espresso); line-height: .9; }
.hero__month  { letter-spacing: .3em; font-size: .82rem; color: var(--terracotta); }
.hero__weekday { letter-spacing: .38em; font-size: .68rem; color: var(--olive); }

.hero__cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ---------- BUTONLAR ---------- */
.btn {
  display: inline-block; cursor: pointer; text-decoration: none;
  font-family: "DM Sans", sans-serif; font-size: .82rem; font-weight: 500;
  letter-spacing: .1em; text-transform: uppercase;
  padding: 13px 26px; border-radius: 2px; border: 1.4px solid var(--terracotta);
  transition: all .25s var(--ease); background: none;
}
.btn--solid { background: var(--terracotta); color: var(--cream); }
.btn--solid:hover { background: var(--espresso); border-color: var(--espresso); transform: translateY(-2px); }
.btn--ghost { color: var(--terracotta); }
.btn--ghost:hover { background: var(--terracotta); color: var(--cream); transform: translateY(-2px); }

/* ---------- SECTION TEMELİ ---------- */
.section {
  max-width: var(--maxw); margin: 0 auto;
  padding: clamp(56px, 10vh, 110px) var(--gut);
  text-align: center;
}
.section__eyebrow { letter-spacing: .34em; font-size: .72rem; color: var(--ochre); margin: 0 0 14px; }
.section__title { font-size: var(--fz-h2); margin: 0 auto; max-width: 18ch; }
.section__lead { font-size: var(--fz-lead); color: var(--olive); max-width: 52ch; margin: 18px auto 28px; }
.section__lead--small { font-size: .95rem; margin-top: 34px; }
.section__lead b { color: var(--terracotta); }

/* ---------- DIVIDER ---------- */
.divider { width: min(560px, 80%); margin: 0 auto; opacity: .8; }
.divider svg path { stroke: var(--line); stroke-width: 1.4; fill: none; }

/* ---------- GERİ SAYIM ---------- */
.countdown { display: flex; justify-content: center; gap: clamp(10px, 4vw, 36px); margin-top: 14px; flex-wrap: nowrap; }
.countdown__cell { display: grid; gap: 8px; min-width: 64px; }
.countdown__num {
  font-family: "Fraunces", serif; font-size: clamp(2.4rem, 8vw, 4rem);
  color: var(--espresso); line-height: 1; font-variant-numeric: tabular-nums;
}
.countdown__lbl { letter-spacing: .2em; font-size: .68rem; text-transform: uppercase; color: var(--olive); }
.countdown__done { font-family: "Fraunces", serif; font-size: var(--fz-lead); color: var(--terracotta); }

/* ---------- PROGRAM (yatay timeline) ---------- */
.timeline {
  list-style: none; margin: 8px 0 0; padding: 8px 4px 22px;
  display: flex; gap: 20px; overflow-x: auto; scroll-snap-type: x mandatory;
  text-align: left; justify-content: flex-start;
}
.timeline::-webkit-scrollbar { height: 6px; }
.timeline::-webkit-scrollbar-thumb { background: var(--line); border-radius: 99px; }
.timeline li {
  scroll-snap-align: center; flex: 0 0 min(260px, 78vw);
  background: var(--cream); border: 1px solid var(--line); border-radius: 4px;
  padding: 26px 24px; display: grid; gap: 8px; align-content: start;
  box-shadow: 0 1px 0 rgba(59,42,30,.04);
}
.timeline .tl__icon { width: 40px; color: var(--terracotta); margin-bottom: 6px; }
.timeline .tl__icon svg { stroke: currentColor; stroke-width: 1.4; fill: none; }
.timeline .tl__time { font-family: "Fraunces", serif; font-size: 1.5rem; color: var(--espresso); }
.timeline .tl__title { font-weight: 500; letter-spacing: .02em; }
.timeline .tl__place { color: var(--olive); font-size: .92rem; }
@media (min-width: 720px) { .timeline { justify-content: center; flex-wrap: wrap; overflow: visible; } }

/* ---------- MEKÂNLAR ---------- */
.venues { display: grid; gap: 28px; margin-top: 10px; }
@media (min-width: 740px) { .venues { grid-template-columns: 1fr 1fr; } }
.venue {
  background: var(--cream); border: 1px solid var(--line); border-radius: 4px;
  overflow: hidden; text-align: left; display: flex; flex-direction: column;
  max-width: 100%; word-break: break-word; overflow-wrap: break-word;
}
.venue__btn { word-break: break-word; overflow-wrap: break-word; }
.venue__head { padding: 22px 24px 8px; }
.venue__icon { width: 36px; color: var(--terracotta); margin-bottom: 10px; }
.venue__icon svg { stroke: currentColor; stroke-width: 1.4; fill: none; }
.venue__tag { letter-spacing: .2em; font-size: .68rem; text-transform: uppercase; color: var(--ochre); }
.venue__time { font-family: "Fraunces", serif; font-size: 1.3rem; color: var(--espresso); margin: 4px 0; }
.venue__name { font-weight: 500; letter-spacing: .04em; color: var(--terracotta); word-break: break-word; overflow-wrap: break-word; }
.venue__addr { color: var(--olive); font-size: .92rem; padding: 4px 24px 10px; word-break: break-word; overflow-wrap: break-word; }
.venue__note { font-size: .85rem; color: var(--olive); font-style: italic; padding: 0 24px 14px; }
.venue__btn { margin: 14px 24px 22px; }

/* ---------- LCV ---------- */
.rsvp { max-width: 560px; margin: 0 auto; text-align: left; }
.rsvp__choice { display: flex; gap: 14px; justify-content: center; margin-bottom: 26px; flex-wrap: wrap; }
.choice {
  cursor: pointer; display: flex; align-items: center; gap: 10px;
  padding: 14px 22px; border: 1.4px solid var(--line); border-radius: 3px;
  transition: all .2s var(--ease); background: var(--cream);
}
.choice input { position: absolute; opacity: 0; pointer-events: none; }
.choice__icon { width: 22px; color: var(--olive); }
.choice__icon svg { stroke: currentColor; stroke-width: 2.4; fill: none; }
.choice__txt { font-weight: 500; letter-spacing: .02em; }
.choice:has(input:checked).choice--yes { border-color: var(--olive); background: color-mix(in srgb, var(--olive) 12%, var(--cream)); }
.choice:has(input:checked).choice--yes .choice__icon { color: var(--olive); }
.choice:has(input:checked).choice--no { border-color: var(--terracotta); background: color-mix(in srgb, var(--terracotta) 10%, var(--cream)); }
.choice:has(input:checked).choice--no .choice__icon { color: var(--terracotta); }
.choice:has(input:focus-visible) { outline: 2px solid var(--ochre); outline-offset: 2px; }

.rsvp__fields { display: grid; gap: 16px; grid-template-columns: 1fr 1fr; }
.field { display: grid; gap: 6px; }
.field--full { grid-column: 1 / -1; }
.field span { font-size: .8rem; letter-spacing: .04em; color: var(--olive); }
.field input, .field textarea {
  font: inherit; padding: 12px 14px; border: 1.4px solid var(--line);
  border-radius: 3px; background: var(--cream); color: var(--ink); resize: vertical;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--terracotta); }
.rsvp__submit { margin: 24px auto 0; display: block; }
.rsvp__status { text-align: center; min-height: 1.4em; margin-top: 14px; font-weight: 500; }
.rsvp__status.is-ok { color: var(--olive); }
.rsvp__status.is-err { color: var(--terracotta); }
@media (max-width: 520px) { .rsvp__fields { grid-template-columns: 1fr; } }

/* ---------- ANILAR / UPLOAD ---------- */
.upload { max-width: 560px; margin: 6px auto 0; }
.upload__drop {
  display: grid; place-items: center; gap: 10px; cursor: pointer;
  padding: 40px 24px; border: 1.6px dashed var(--terracotta); border-radius: 6px;
  background: color-mix(in srgb, var(--terracotta) 5%, var(--cream));
  transition: all .2s var(--ease);
}
.upload__drop.is-drag { background: color-mix(in srgb, var(--ochre) 16%, var(--cream)); border-color: var(--ochre); }
.upload__icon { width: 44px; color: var(--terracotta); }
.upload__icon svg { stroke: currentColor; stroke-width: 1.6; fill: none; }
.upload__cta { font-weight: 500; letter-spacing: .02em; }
.upload__hint { font-size: .82rem; color: var(--olive); }
.upload__list { list-style: none; padding: 0; margin: 18px 0 0; display: grid; gap: 8px; text-align: left; }
.upload__list li {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px 14px; border: 1px solid var(--line); border-radius: 3px; font-size: .9rem;
}
.upload__list .rm { cursor: pointer; border: 0; background: none; color: var(--terracotta); font-size: 1.1rem; line-height: 1; }
.upload [data-upload-send] { margin: 18px auto 0; display: block; }
.upload__status { text-align: center; min-height: 1.4em; margin-top: 12px; font-weight: 500; }
.upload__status.is-ok { color: var(--olive); }
.upload__status.is-err { color: var(--terracotta); }

/* ---------- İKİ ETKİNLİK YAN YANA GRID ---------- */
.events-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  max-width: var(--maxw);
  margin: 0 auto;
  overflow-x: hidden;
}
/* İçteki .section sınıfını grid düzenine uy */
.events-grid .section {
  max-width: none;
  margin: 0;
  padding: clamp(48px, 8vh, 90px) clamp(16px, 3vw, 44px);
  overflow: hidden; /* içerik kolon sınırını aşmasın */
}
/* İki kolon arasındaki ince dikey çizgi */
.events-grid .section--event + .section--event {
  border-left: 1px solid var(--line);
}
/* Mobilde iki kolon yan yana korunur; içerik sıkılaştırılır */
@media (max-width: 768px) {
  /* Grid her zaman 1fr 1fr — dikey çizgi korunur; kolon arası 8px */
  .events-grid { gap: 8px; overflow-x: hidden; }
  .events-grid .section {
    padding-top: clamp(24px, 4vh, 56px);
    padding-bottom: clamp(20px, 3.5vh, 48px);
    padding-inline: 10px;
  }

  /* Başlık ve metinler */
  .events-grid .section__eyebrow { font-size: .6rem; letter-spacing: .1em; }
  .events-grid .section__title { font-size: clamp(.85rem, 3vw, 1.3rem); }
  .events-grid .section__lead { font-size: .8rem; margin: 8px auto 14px; }
  .events-grid .event__sub-eyebrow { margin-top: 24px; }
  .events-grid .event__sub-title { font-size: clamp(.9rem, 2.4vw, 1.3rem); }

  /* Geri sayım: eşit genişlik flex, küçük font, min-width yok */
  .events-grid .countdown { gap: 3px; margin-top: 8px; }
  .events-grid .countdown__num { font-size: clamp(1rem, 5vw, 2rem); }
  .events-grid .countdown__cell { min-width: 0; flex: 1; overflow: hidden; }
  .events-grid .countdown__lbl { font-size: .55rem; letter-spacing: 0; white-space: nowrap; }

  /* Program kartları: mobilde alt alta (dikey), kolon genişliğinde */
  .events-grid .timeline { flex-direction: column; overflow: visible; padding-inline: 4px; }
  .events-grid .timeline li { flex: 0 0 auto; width: 100%; padding: 12px; font-size: .8rem; }
  .events-grid .tl__icon { width: 28px; }
  .events-grid .tl__time { font-size: 1.1rem; }
  .events-grid .tl__title { font-size: .8rem; }
  .events-grid .tl__place { font-size: .78rem; }

  /* Mekân kartı */
  .events-grid .venue__head { padding: 12px 12px 6px; }
  .events-grid .venue__icon { width: 20px; max-width: 20px; }
  .events-grid .venue__icon svg { max-width: 20px; }
  .events-grid .venue__name { font-size: .78rem; }
  .events-grid .venue__addr { font-size: .78rem; padding: 4px 12px 8px; }
  .events-grid .venue__note { font-size: .78rem; padding: 0 12px 10px; }
  .events-grid .venue__btn { margin: 8px 12px 14px; font-size: .65rem; padding: 6px 10px; }
}

/* ---------- ETKİNLİK ALT BAŞLIKLARI ---------- */
.event__sub-eyebrow { margin-top: 52px; }
.event__sub-title {
  font-family: "Fraunces", Georgia, serif; font-weight: 500;
  font-size: clamp(1.15rem, 2.6vw, 1.7rem);
  color: var(--espresso); margin: 6px auto 0; max-width: 24ch;
}

/* ---------- FOOTER ---------- */
.footer {
  background: var(--espresso); color: var(--cream);
  text-align: center; padding: 56px var(--gut);
}
.footer__names { font-family: "Fraunces", serif; font-size: 1.8rem; margin: 8px 0 4px; color: var(--cream); }
.footer__city { letter-spacing: .28em; font-size: .76rem; color: var(--ochre); text-transform: uppercase; }
.footer__admin { display: inline-block; margin-top: 22px; font-size: .74rem; letter-spacing: .14em; text-transform: uppercase; color: rgba(243,235,221,.5); text-decoration: none; }
.footer__admin:hover { color: var(--ochre); }

/* ---------- REVEAL ANİMASYON ---------- */
.section, .hero__inner, .divider { opacity: 0; transform: translateY(18px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.is-visible { opacity: 1 !important; transform: none !important; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .section, .hero__inner, .divider { opacity: 1; transform: none; transition: none; }
  .btn:hover { transform: none; }
}

:focus-visible { outline: 2px solid var(--ochre); outline-offset: 3px; }

/* ================================================================
   MOBIL OPTİMİZASYONLAR — 390px (iPhone 14/15) hedefi
   ================================================================ */

/* Upload: uzun dosya adlarını kısalt, taşmayı önle */
.upload__list li span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
  min-width: 0;
}

/* ---- ≤520px: form/upload butonları tam genişlik ---- */
@media (max-width: 520px) {
  .rsvp__submit { width: 100%; }
  .upload [data-upload-send] { width: 100%; }
}

/* ---- ≤480px: küçük ekran ince ayarları ---- */
@media (max-width: 480px) {
  /* Hero isim fontu: daha küçük minimum (taşma önlemi) */
  :root { --fz-display: clamp(2rem, 8vw, 6rem); }

  /* Hero arch: kenarlardan uzak kalsın */
  .hero__arch { padding: 0 16px; }

  /* Geri sayım: daha küçük font, sıkı aralık */
  .countdown { gap: clamp(6px, 2.5vw, 16px); }
  .countdown__num { font-size: clamp(1.6rem, 6.2vw, 4rem); }
  .countdown__cell { min-width: unset; }
  .countdown__lbl { font-size: .58rem; letter-spacing: .12em; }

  /* Program kartları: yatay kaydırmada nefes alanı */
  .timeline { padding-left: 16px; padding-right: 16px; }

  /* Footer: dikey dolgu sıkılaştır */
  .footer { padding-top: 40px; padding-bottom: 40px; }
  .footer__names { font-size: 1.5rem; }
}
