:root {
  --bg: #FAF7F2;
  --surface: #FFFFFF;
  --surface-2: #FDFBF7;
  --line: #E8E1D5;
  --gold: #B99659;
  --gold-soft: #D3B67E;
  --ink: #2B2530;
  --muted: #5F5868;
  --ok: #4E9E77;
  --err: #C96A6A;
  --radius: 18px;
  --shadow: 0 18px 50px -28px rgba(43, 37, 48, .25);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Inter", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.app {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 20px calc(40px + env(safe-area-inset-bottom));
  min-height: 100vh;
}

/* ---------- HERO: sadece isimler ---------- */
.hero {
  text-align: center;
  padding: 56px 0 30px;
}
.names {
  font-family: "Pinyon Script", cursive;
  font-weight: 400;
  font-size: 58px;
  line-height: 1.05;
  margin: 0;
  color: var(--ink);
}

/* ---------- CARD ---------- */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px 20px;
  box-shadow: var(--shadow);
}
.upload-card {
  max-width: 460px;
  margin: 0 auto;
}
.card-title {
  font-family: "Fraunces", serif;
  font-weight: 600;
  font-size: 24px;
  margin: 0 0 6px;
}
.card-sub {
  margin: 0 0 20px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

/* ---------- DROPZONE ---------- */
.dropzone {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 32px 16px;
  border: 1.5px dashed var(--line);
  border-radius: 14px;
  color: var(--gold);
  cursor: pointer;
  transition: border-color .2s, background .2s;
  text-align: center;
}
.dropzone:hover, .dropzone:focus-visible, .dropzone.drag {
  border-color: var(--gold);
  background: rgba(185, 150, 89, .06);
  outline: none;
}
.dropzone-main { color: var(--ink); font-weight: 500; font-size: 15px; }
.dropzone-hint { color: var(--muted); font-size: 13px; font-weight: 500; }

/* ---------- PREVIEW ---------- */
.preview-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}
.thumb {
  position: relative;
  width: 72px; height: 72px;
  border-radius: 10px;
  overflow: hidden;
  border: 2px solid var(--line);
  box-shadow: 0 6px 14px -8px rgba(43, 37, 48, .35);
}
.thumb img, .thumb video { width: 100%; height: 100%; object-fit: cover; }
.thumb .rm {
  position: absolute; top: 2px; right: 2px;
  width: 20px; height: 20px; border: none; border-radius: 50%;
  background: rgba(43, 37, 48, .8); color: #fff;
  font-size: 13px; line-height: 20px; cursor: pointer;
}

/* ---------- NAME FIELD ---------- */
.name-field { display: block; margin: 20px 0 4px; }
.name-field span { display: block; font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.name-field input {
  width: 100%; padding: 12px 14px;
  background: var(--surface-2); color: var(--ink);
  border: 1px solid var(--line); border-radius: 12px;
  font-size: 15px; font-family: inherit;
}
.name-field input:focus { outline: none; border-color: var(--gold); }

/* ---------- BUTTON ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 100%; margin-top: 18px; padding: 15px 18px;
  background: linear-gradient(180deg, var(--gold-soft), var(--gold));
  color: #fff; font-weight: 600; font-size: 16px;
  border: none; border-radius: 12px; cursor: pointer;
  font-family: inherit; text-decoration: none;
  transition: transform .1s, opacity .2s;
}
.btn:active { transform: scale(.99); }
.btn:disabled { opacity: .45; cursor: not-allowed; }

/* ---------- PROGRESS + STATUS ---------- */
.progress {
  margin-top: 16px; height: 6px; border-radius: 6px;
  background: var(--line); overflow: hidden;
}
.progress-bar {
  height: 100%; width: 0%;
  background: linear-gradient(90deg, var(--gold), var(--gold-soft));
  transition: width .3s ease;
}
.status { margin: 14px 0 0; font-size: 14px; text-align: center; min-height: 20px; }
.status.ok { color: var(--ok); }
.status.err { color: var(--err); }

/* ---------- GALERİ ---------- */
.eyebrow {
  margin: 0;
  font-size: 11px;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--gold);
}
.gallery-section {
  margin-top: 40px;
}
.gallery-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}
.gallery-title {
  margin: 4px 0 0;
  font-family: "Fraunces", serif;
  font-size: 24px;
  font-weight: 600;
}
.gallery-retry {
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  color: var(--gold);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}
.gallery-retry:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}
.gallery-status {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 13px;
}
.gallery-status:empty { display: none; }

/* Masonry: fotoğraflar orijinal en-boy oranında akar */
.gallery-grid {
  columns: 3 240px;
  column-gap: 12px;
}
.gallery-tile {
  break-inside: avoid;
  margin-bottom: 12px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: var(--surface);
  box-shadow: 0 8px 20px -16px rgba(43, 37, 48, .4);
}
.gallery-tile img {
  display: block;
  width: 100%;
  height: auto;
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}
