/* =========================================================
   İkimizin — stil
   ========================================================= */

:root {
  --bg: #140f16;
  --bg-soft: #1c1520;
  --card: rgba(255, 255, 255, 0.045);
  --card-strong: rgba(255, 255, 255, 0.075);
  --line: rgba(255, 255, 255, 0.1);
  --cream: #f7eee4;
  --muted: #b6a4b0;
  --accent: #e79aa2;
  --accent-2: #c76b7c;
  --gold: #d9b26f;
  --radius: 22px;
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

[data-theme="gece"] {
  --accent: #a3b1ea;
  --accent-2: #6f7fc9;
  --gold: #b9c4e8;
}

[data-theme="kum"] {
  --accent: #e2c28c;
  --accent-2: #b98f52;
  --gold: #e6cfa3;
}

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

body {
  min-height: 100vh;
  background:
    radial-gradient(900px 600px at 12% -10%, rgba(199, 107, 124, 0.22), transparent 60%),
    radial-gradient(800px 700px at 100% 0%, rgba(217, 178, 111, 0.1), transparent 55%),
    radial-gradient(700px 700px at 50% 120%, rgba(120, 80, 140, 0.18), transparent 60%),
    var(--bg);
  color: var(--cream);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23n)'/%3E%3C/svg%3E");
}

h1, h2, h3 { font-family: var(--serif); font-weight: 500; letter-spacing: -0.01em; margin: 0; }
p { margin: 0; }

button { font-family: inherit; cursor: pointer; }
input, textarea { font-family: inherit; font-size: 1rem; }

.view { position: relative; z-index: 2; }
[hidden] { display: none !important; }

/* ---------------- ortak parçalar ---------------- */

.brand {
  font-family: var(--serif);
  font-size: 1.35rem;
  letter-spacing: -0.02em;
  color: var(--cream);
}
.brand.small { font-size: 1.1rem; }

.eyebrow {
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 14px;
}

.btn {
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 0.85rem 1.6rem;
  font-size: 0.95rem;
  font-weight: 500;
  background: transparent;
  color: var(--cream);
  transition: transform 0.18s ease, background 0.18s ease, border-color 0.18s ease, opacity 0.18s;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #201318;
  font-weight: 600;
  box-shadow: 0 12px 30px -12px rgba(199, 107, 124, 0.7);
}
.btn-primary:hover { opacity: 0.94; }

.btn-ghost { border-color: var(--line); color: var(--cream); }
.btn-ghost:hover { background: var(--card); border-color: rgba(255, 255, 255, 0.2); }

.btn-small {
  padding: 0.5rem 1rem;
  font-size: 0.82rem;
  border-color: var(--line);
  background: var(--card);
}
.btn-small:hover { background: var(--card-strong); }

.btn-block { width: 100%; }

.link-back, .link-quiet {
  background: none;
  border: none;
  color: var(--muted);
  font-size: 0.85rem;
  padding: 0;
  letter-spacing: 0.02em;
}
.link-back:hover, .link-quiet:hover { color: var(--cream); }
.link-back { margin-bottom: 26px; display: inline-block; }

/* ---------------- landing ---------------- */

.landing {
  max-width: 1060px;
  margin: 0 auto;
  padding: clamp(22px, 5vw, 44px) clamp(20px, 5vw, 40px) 60px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.landing-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: clamp(60px, 12vh, 130px);
}
.landing-note { font-size: 0.78rem; color: var(--muted); letter-spacing: 0.18em; text-transform: uppercase; }

.landing-hero { max-width: 760px; }
.landing-hero h1 {
  font-size: clamp(2.9rem, 8.5vw, 5.6rem);
  line-height: 0.98;
  font-weight: 400;
  margin-bottom: 28px;
}
.landing-hero h1 em {
  font-style: italic;
  color: var(--accent);
  font-weight: 400;
}

.lede {
  max-width: 520px;
  color: var(--muted);
  font-size: 1.02rem;
  line-height: 1.7;
  margin-bottom: 38px;
}

.landing-actions { display: flex; flex-wrap: wrap; gap: 12px; }

.landing-steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: clamp(70px, 12vh, 130px);
  padding-top: 40px;
  border-top: 1px solid var(--line);
}
.step-no {
  font-size: 0.72rem;
  color: var(--gold);
  letter-spacing: 0.18em;
}
.step h3 { font-size: 1.15rem; margin: 10px 0 6px; }
.step p { color: var(--muted); font-size: 0.88rem; line-height: 1.6; }

.landing-foot {
  margin-top: auto;
  padding-top: 60px;
  font-size: 0.76rem;
  color: rgba(182, 164, 176, 0.7);
  letter-spacing: 0.04em;
}

/* ---------------- panel (create / login) ---------------- */

.view-center {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px 20px;
}

.panel {
  width: 100%;
  max-width: 460px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.025));
  border: 1px solid var(--line);
  border-radius: 26px;
  padding: clamp(26px, 5vw, 40px);
  backdrop-filter: blur(18px);
  box-shadow: 0 40px 80px -40px rgba(0, 0, 0, 0.8);
}

.panel h2 { font-size: 1.75rem; margin-bottom: 8px; }
.panel-sub { color: var(--muted); font-size: 0.9rem; margin-bottom: 26px; line-height: 1.6; }

.form { display: flex; flex-direction: column; gap: 16px; }

.field { display: flex; flex-direction: column; gap: 7px; }
.field > span {
  font-size: 0.76rem;
  letter-spacing: 0.06em;
  color: var(--muted);
  text-transform: uppercase;
}

.field input, .field textarea {
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid var(--line);
  border-radius: 13px;
  padding: 0.8rem 0.95rem;
  color: var(--cream);
  outline: none;
  transition: border-color 0.18s, background 0.18s;
  width: 100%;
}
.field textarea { resize: vertical; min-height: 80px; line-height: 1.55; }
.field input:focus, .field textarea:focus {
  border-color: var(--accent);
  background: rgba(0, 0, 0, 0.4);
}
.field input::placeholder, .field textarea::placeholder { color: rgba(182, 164, 176, 0.45); }

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

.form-error {
  color: #f2a1a1;
  font-size: 0.84rem;
  background: rgba(242, 161, 161, 0.08);
  border: 1px solid rgba(242, 161, 161, 0.25);
  border-radius: 10px;
  padding: 9px 12px;
}

.hint { font-size: 0.76rem; color: rgba(182, 164, 176, 0.7); }

/* kod kutusu */
.code-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px dashed rgba(231, 154, 162, 0.45);
  border-radius: 16px;
  padding: 18px 20px;
  margin: 8px 0 18px;
}
#created-code {
  font-family: var(--serif);
  font-size: clamp(1.5rem, 6vw, 2.1rem);
  letter-spacing: 0.16em;
  color: var(--accent);
}
.copy-btn {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--cream);
  font-size: 0.78rem;
  padding: 0.45rem 0.9rem;
  white-space: nowrap;
}
.copy-btn:hover { background: var(--card-strong); }

.warn {
  font-size: 0.78rem;
  color: var(--gold);
  background: rgba(217, 178, 111, 0.08);
  border: 1px solid rgba(217, 178, 111, 0.22);
  border-radius: 10px;
  padding: 10px 12px;
  margin-bottom: 20px;
  line-height: 1.5;
}

#login-code {
  font-family: var(--serif);
  font-size: 1.6rem;
  letter-spacing: 0.22em;
  text-align: center;
  text-transform: uppercase;
}

/* ---------------- app ---------------- */

.app-top {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px clamp(18px, 4vw, 34px);
  background: rgba(20, 15, 22, 0.72);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}
.app-top-right { display: flex; align-items: center; gap: 18px; }

.theme-dots { display: flex; gap: 8px; }
.theme-dots button {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.3);
  padding: 0;
}
.theme-dots button[data-theme="gul"] { background: #e79aa2; }
.theme-dots button[data-theme="gece"] { background: #a3b1ea; }
.theme-dots button[data-theme="kum"] { background: #e2c28c; }
.theme-dots button.active { box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.18); }

.app-main {
  max-width: 980px;
  margin: 0 auto;
  padding: clamp(22px, 4vw, 40px) clamp(18px, 4vw, 34px) 90px;
}

.hero-card {
  background:
    radial-gradient(500px 240px at 15% 0%, rgba(231, 154, 162, 0.16), transparent 70%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.02));
  border: 1px solid var(--line);
  border-radius: 28px;
  padding: clamp(26px, 5vw, 46px);
  margin-bottom: 42px;
}
.hero-names { font-size: clamp(2rem, 6vw, 3.2rem); line-height: 1.05; margin-bottom: 22px; }
.hero-days { display: flex; align-items: baseline; gap: 12px; margin-bottom: 30px; }
.hero-days span {
  font-family: var(--serif);
  font-size: clamp(2.6rem, 9vw, 4.2rem);
  color: var(--accent);
  line-height: 1;
}
.hero-days small { color: var(--muted); font-size: 0.9rem; }

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  border-top: 1px solid var(--line);
  padding-top: 22px;
}
.hero-stats > div { display: flex; flex-direction: column; gap: 2px; }
.hero-stats strong { font-family: var(--serif); font-size: 1.3rem; font-weight: 500; }
.hero-stats span { font-size: 0.72rem; color: var(--muted); letter-spacing: 0.06em; text-transform: uppercase; }

.block { margin-bottom: 48px; }
.block-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}
.block-head h2 { font-size: 1.45rem; }

/* timeline */
.timeline {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
}

.memory {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, border-color 0.2s ease;
}
.memory:hover { transform: translateY(-2px); border-color: rgba(255, 255, 255, 0.18); }

.memory-photo {
  aspect-ratio: 4 / 3.4;
  width: 100%;
  object-fit: cover;
  display: block;
  background: var(--bg-soft);
}
.memory-body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 6px; }
.memory-date {
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
}
.memory-title { font-family: var(--serif); font-size: 1.15rem; line-height: 1.25; }
.memory-note { font-size: 0.87rem; color: var(--muted); line-height: 1.6; white-space: pre-wrap; }

.memory-del {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(20, 15, 22, 0.65);
  color: var(--cream);
  font-size: 0.9rem;
  line-height: 1;
  opacity: 0;
  transition: opacity 0.18s;
  backdrop-filter: blur(6px);
}
.memory:hover .memory-del { opacity: 1; }
.memory-del:hover { background: rgba(199, 107, 124, 0.5); }

/* kilitli ani */
.memory.locked {
  justify-content: center;
  align-items: center;
  text-align: center;
  min-height: 260px;
  padding: 28px;
  background:
    radial-gradient(300px 200px at 50% 0%, rgba(231, 154, 162, 0.16), transparent 70%),
    var(--card);
}
.memory.locked .lock-icon {
  width: 34px;
  height: 34px;
  margin-bottom: 14px;
  color: var(--accent);
}
.memory.locked h3 { font-size: 1.1rem; margin-bottom: 6px; }
.memory.locked p { font-size: 0.82rem; color: var(--muted); }
.memory.locked .countdown {
  margin-top: 12px;
  font-family: var(--serif);
  font-size: 1.05rem;
  color: var(--gold);
}

/* bos durum */
.empty {
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  padding: clamp(24px, 4vw, 36px);
  text-align: center;
  margin-bottom: 20px;
}
.empty-title { font-family: var(--serif); font-size: 1.25rem; margin-bottom: 6px; }
.empty-sub { color: var(--muted); font-size: 0.86rem; margin-bottom: 18px; }
.prompts { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.prompts button {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--cream);
  font-size: 0.82rem;
  padding: 0.5rem 0.95rem;
}
.prompts button:hover { background: var(--card-strong); border-color: var(--accent); }

/* ozel gunler */
.inline-form {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.inline-form input {
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.65rem 0.85rem;
  color: var(--cream);
  outline: none;
  flex: 1;
  min-width: 140px;
}
.inline-form input:focus { border-color: var(--accent); }

.dates { display: flex; flex-direction: column; gap: 10px; }
.date-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 15px;
  padding: 14px 18px;
}
.date-row .date-label { font-size: 0.95rem; }
.date-row .date-when { font-size: 0.78rem; color: var(--muted); }
.date-row .date-left {
  font-family: var(--serif);
  font-size: 1rem;
  color: var(--gold);
  white-space: nowrap;
}
.date-row button {
  background: none;
  border: none;
  color: rgba(182, 164, 176, 0.6);
  font-size: 1rem;
  padding: 4px;
}
.date-row button:hover { color: #f2a1a1; }

/* ---------------- modal ---------------- */

.modal {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(10, 7, 12, 0.72);
  backdrop-filter: blur(8px);
  overflow-y: auto;
}
.modal-card {
  width: 100%;
  max-width: 520px;
  background: linear-gradient(180deg, #241a28, #1a1320);
  border: 1px solid var(--line);
  border-radius: 26px;
  padding: clamp(22px, 4vw, 32px);
  box-shadow: 0 50px 100px -40px rgba(0, 0, 0, 0.9);
  margin: auto;
}
.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 22px;
}
.modal-head h2 { font-size: 1.4rem; }

.drop {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 140px;
  border: 1px dashed var(--line);
  border-radius: 16px;
  background: rgba(0, 0, 0, 0.22);
  cursor: pointer;
  overflow: hidden;
  position: relative;
  transition: border-color 0.18s;
}
.drop:hover, .drop.dragover { border-color: var(--accent); }
.drop img { width: 100%; height: 220px; object-fit: cover; }
.drop-text { font-size: 0.85rem; color: var(--muted); }
.drop-text small { opacity: 0.6; }

/* ---------------- toast ---------------- */

.toast {
  position: fixed;
  left: 50%;
  bottom: 26px;
  transform: translateX(-50%);
  z-index: 90;
  background: #2a1e2e;
  border: 1px solid var(--line);
  color: var(--cream);
  font-size: 0.85rem;
  padding: 0.7rem 1.2rem;
  border-radius: 999px;
  box-shadow: 0 20px 40px -20px rgba(0, 0, 0, 0.9);
  animation: toast-in 0.25s ease;
}
@keyframes toast-in {
  from { opacity: 0; transform: translate(-50%, 8px); }
  to { opacity: 1; transform: translate(-50%, 0); }
}

/* ---------------- responsive ---------------- */

@media (max-width: 760px) {
  .landing-steps { grid-template-columns: 1fr; gap: 26px; }
  .landing-top { margin-bottom: 56px; }
  .timeline { grid-template-columns: 1fr; }
  .hero-stats { grid-template-columns: repeat(3, 1fr); gap: 8px; }
  .hero-stats strong { font-size: 1.1rem; }
  .field-row { grid-template-columns: 1fr; }
  .memory-del { opacity: 1; }
  .date-row { flex-wrap: wrap; }
}

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