/* ============================================================
   TEMA: GECE YILDIZLARI - derin lacivert + altın
   3 katman paralax (stars / twinkling / clouds) + ay + shooting stars
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { width: 100%; height: 100%; }

:root {
    --bg-deep:    #050a20;
    --bg-navy:    #0a1232;
    --bg-indigo:  #131a44;
    --bg-violet:  #1f1850;

    --gold:       #d4af37;
    --gold-l:     #f0d97c;
    --gold-d:     #a8862a;
    --silver:     #c5cae3;
    --star:       #ffffff;

    --ink:        #f0e8d2;
    --ink-2:      #d4cdb3;
    --ink-3:      #a89c80;
    --muted:      #6a6280;

    --card-bg:    rgba(var(--kas-card-rgb), 0.65);
    --card-bg-2:  rgba(var(--kas-card-rgb), 0.55);
    --line:       rgba(var(--kas-title-rgb), 0.28);
    --line-soft:  rgba(var(--kas-title-rgb), 0.16);

    --font-h:     'Cormorant Garamond', Georgia, serif;
    --font-b:     'Lora', Georgia, serif;
    --font-caps:  'Cinzel', Georgia, serif;
    --font-script:'Great Vibes', cursive;

    --ease:       cubic-bezier(0.22, 1, 0.36, 1);
}

body {
    font-family: var(--font-b); color: var(--ink); line-height: 1.7;
    /* Codepen referansı: stars katmanı kendi siyah bg'sini taşıyor - body'de yedek olarak siyah */
    background: black;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    /* Entry açıkken scroll kilitli; "Yıldızları Aç" tıklanınca is-reading → scroll açılır, sayfa baştan başlar */
    overflow: hidden;
}
body.is-reading {
    overflow-x: hidden;
    overflow-y: auto;
}

img { max-width: 100%; height: auto; display: block; }
button { font: inherit; cursor: pointer; color: inherit; background: 0; border: 0; padding: 0; }
::selection { background: var(--gold); color: var(--bg-deep); }

/* ═══════════════════════════════════════════════════════════
   BACKGROUND-CONTAINER - codepen agoodwin/NMJoER birebir
   ═══════════════════════════════════════════════════════════ */
.background-container {
    position: fixed;
    top: 0; left: 0; bottom: 0; right: 0;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

/* Katman 1: yıldız tile - codepen birebir, sabit */
.stars {
    background: black url('/gorseller/themes/gece-yildizlari/stars.webp') repeat;
    position: absolute;
    top: 0; bottom: 0; left: 0; right: 0;
    display: block;
    z-index: 0;
}

/* Katman 2: parıldayan yıldız tile - paralax kayar (70s) */
.twinkling {
    width: 10000px; height: 100%;
    background: transparent url('/gorseller/themes/gece-yildizlari/twinkling.webp') repeat;
    background-size: 1000px 1000px;
    position: absolute;
    right: 0; top: 0; bottom: 0;
    z-index: 2;
    animation: drift-left 70s linear infinite;
}

/* Katman 3: bulutlar - tek görselin random 6 kopyası, farklı hızlarda soldan sağa drift */
.cloud {
    position: absolute;
    background: url('/gorseller/themes/gece-yildizlari/clouds.webp') no-repeat center / contain;
    pointer-events: none;
    z-index: 3;
    will-change: transform;
}
/* Boyut/opaklık/yer çeşitliliği - küçükten büyüğe, çok hafif şeffaf */
.cloud.c1 { --s: 0.7;  --r:  -3deg; width: 180px; height:  70px; top:   6%; left: -20%; opacity: 0.18; animation: cloud-drift 140s linear infinite; }
.cloud.c2 { --s: 1.4;  --r:   2deg; width: 420px; height: 160px; top:  18%; left: -32%; opacity: 0.22; animation: cloud-drift 180s linear infinite -30s; }
.cloud.c3 { --s: 0.5;  --r:  -5deg; width: 130px; height:  50px; top:  34%; left: -15%; opacity: 0.14; animation: cloud-drift 100s linear infinite -65s; }
.cloud.c4 { --s: 1.0;  --r:   4deg; width: 280px; height: 105px; top:  46%; left: -25%; opacity: 0.20; animation: cloud-drift 160s linear infinite -90s; }
.cloud.c5 { --s: 0.85; --r:  -2deg; width: 220px; height:  85px; top:  62%; left: -18%; opacity: 0.16; animation: cloud-drift 130s linear infinite -45s; }
.cloud.c6 { --s: 1.55; --r:   3deg; width: 460px; height: 175px; top:  76%; left: -38%; opacity: 0.24; animation: cloud-drift 200s linear infinite -120s; }
.cloud.c7 { --s: 0.6;  --r:  -1deg; width: 150px; height:  60px; top:  88%; left: -12%; opacity: 0.15; animation: cloud-drift 110s linear infinite -20s; }
.cloud.c8 { --s: 0.9;  --r:   5deg; width: 250px; height:  95px; top:  28%; left: -22%; opacity: 0.18; animation: cloud-drift 170s linear infinite -150s; }

@keyframes drift-left {
    from { transform: translate3d(0, 0, 0); }
    to   { transform: translate3d(-1000px, 0, 0); }
}
@keyframes cloud-drift {
    from { transform: translateX(0)     scale(var(--s, 1)) rotate(var(--r, 0deg)); }
    to   { transform: translateX(150vw) scale(var(--s, 1)) rotate(var(--r, 0deg)); }
}

/* Ay - yukarıda (top ~28%), entry'de orta boy; içerik açılınca sağ üst köşede küçülür */
.background-container img {
    height: 45vh; width: 45vh;
    position: absolute;
    z-index: 4;
    right: 4vw;
    top: 28%;
    transition: top .8s var(--ease), right .8s var(--ease),
                width .8s var(--ease), height .8s var(--ease),
                opacity .8s var(--ease);
}

/* İçerik açıldığında ay sağ üst köşeye daha küçük yerleşir */
body.is-reading .background-container img {
    top: 4vh; right: 4vw;
    width: clamp(90px, 14vw, 160px);
    height: clamp(90px, 14vw, 160px);
    opacity: 0.85;
}

@media (max-width: 768px) {
    .background-container img { height: 30vh; width: 30vh; right: 4vw; top: 10%; opacity: 0.8; }
    body.is-reading .background-container img { top: 2vh; right: 4vw; width: 22vh; height: 22vh; opacity: 0.6; }
}

/* Kayan yıldız (rastgele aralıklarla) */
.shoot {
    position: fixed; pointer-events: none;
    width: 100px; height: 1px;
    background: linear-gradient(90deg, transparent, var(--gold-l), white);
    opacity: 0; z-index: 4;
    box-shadow: 0 0 4px white, 0 0 12px rgba(240,217,124,0.6);
    animation: shoot 6s ease-out infinite;
}
.shoot::after {
    content: ''; position: absolute; right: 0; top: -1px;
    width: 3px; height: 3px; border-radius: 50%;
    background: white; box-shadow: 0 0 8px white, 0 0 20px var(--gold-l);
}
.shoot.s1 { top: 15%; left: 0; animation-delay: 1s; }
.shoot.s2 { top: 35%; left: 0; animation-delay: 4.5s; animation-duration: 5s; }
.shoot.s3 { top: 60%; left: 0; animation-delay: 8s; animation-duration: 7s; }
@keyframes shoot {
    0%   { transform: translate(0, 0) rotate(15deg); opacity: 0; }
    5%   { opacity: 1; }
    50%  { opacity: 1; }
    100% { transform: translate(110vw, 60vh) rotate(15deg); opacity: 0; }
}

/* ═══════════════════════════════════════════════
   1. ENTRY - celestial kart
   ═══════════════════════════════════════════════ */
.entry {
    position: fixed; inset: 0; z-index: 100;
    display: flex; align-items: center; justify-content: center;
    padding: 24px; overflow: hidden;
    transition: opacity .8s var(--ease), transform .8s var(--ease);
}
.entry.is-leaving { opacity: 0; transform: scale(1.04); pointer-events: none; }

.entry-card {
    position: relative; z-index: 5;
    width: 100%; max-width: 440px;
    padding: 56px 36px 44px;
    background:
        radial-gradient(ellipse at 30% 25%, rgba(var(--kas-title-rgb), 0.08), transparent 60%),
        linear-gradient(135deg, rgba(10, 18, 50, 0.92) 0%, rgba(5, 10, 32, 0.95) 100%);
    backdrop-filter: blur(18px) saturate(1.4);
    -webkit-backdrop-filter: blur(18px) saturate(1.4);
    border: 1px solid rgba(var(--kas-title-rgb), 0.45);
    border-radius: 4px;
    text-align: center;
    color: var(--ink);
    animation: entry-rise 1s var(--ease) .3s both;
}
.entry-card::before {
    content: ''; position: absolute; inset: 12px;
    border: 1px solid rgba(var(--kas-title-rgb), 0.35);
    border-radius: 2px; pointer-events: none;
}
.entry-card::after {
    content: ''; position: absolute; inset: 18px;
    border-top: 1px solid rgba(var(--kas-title-rgb), 0.16);
    border-bottom: 1px solid rgba(var(--kas-title-rgb), 0.16);
    pointer-events: none;
}
@keyframes entry-rise {
    from { opacity: 0; transform: translateY(28px) scale(0.96); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

.entry-ribbon { display: flex; align-items: center; justify-content: center; gap: 12px; margin-bottom: 18px; }
.entry-ribbon-line { width: 36px; height: 1px; background: var(--gold); opacity: 0.7; }
.entry-ribbon-star { color: var(--gold-l); }
.entry-ribbon-star svg { width: 12px; height: 12px; display: block; }

.entry-eyebrow {
    font-family: var(--font-caps);
    font-size: 11px; letter-spacing: 0.55em;
    text-transform: uppercase;
    color: var(--gold-l); font-weight: 500;
    margin-bottom: 22px; padding-left: 0.55em;
}

/* Constellation SVG */
.entry-const { margin: 0 auto 22px; width: 110px; height: 110px; display: block; }

.entry-couple {
    font-family: var(--font-h); font-style: italic;
    font-weight: 500;
    font-size: clamp(34px, 6vw, 46px);
    color: var(--ink); line-height: 1.05;
    margin: 0 0 8px;
    letter-spacing: -0.005em;
}
.entry-amp {
    font-family: var(--font-script); font-style: normal;
    color: var(--gold-l); margin: 0 4px;
    font-size: 1.1em;
}

.entry-sub {
    font-family: var(--font-h); font-style: italic;
    font-size: clamp(15px, 2.4vw, 18px);
    color: var(--ink-3);
    margin: 0 0 34px;
}

.entry-btn {
    min-height: 52px; padding: 0 32px;
    background: transparent;
    color: var(--gold-l);
    border: 1px solid var(--gold);
    border-radius: 3px;
    font-family: var(--font-caps);
    font-size: 11px; font-weight: 500;
    letter-spacing: 0.4em; text-transform: uppercase;
    display: inline-flex; align-items: center; gap: 12px;
    transition: background .3s ease, color .3s ease, box-shadow .3s ease;
    padding-left: calc(32px + 0.4em);
}
.entry-btn:hover { background: var(--gold); color: var(--bg-deep); }
.entry-btn svg { width: 12px; height: 12px; }

.entry-foot {
    margin-top: 26px;
    font-family: var(--font-caps);
    font-size: 9.5px; letter-spacing: 0.5em;
    text-transform: uppercase;
    color: var(--muted); padding-left: 0.5em;
}

.entry-brand {
    position: absolute; bottom: 22px; left: 50%;
    transform: translateX(-50%); z-index: 6;
    font-family: var(--font-caps); font-size: 9.5px;
    letter-spacing: 0.5em; color: rgba(240, 232, 210, 0.5);
}

/* ═══════════════════════════════════════════════
   2. OPENING - yıldız tüneli + parıltı
   ═══════════════════════════════════════════════ */
.opening {
    position: fixed; inset: 0; z-index: 95;
    display: flex; align-items: center; justify-content: center;
    background: transparent; /* gerçek gece göğü arkadan görünsün, mavi laci tonu yok */
    opacity: 0;
    transition: opacity .5s ease;
    overflow: hidden;
    pointer-events: none; /* arka sky'in tıklanabilirliği için */
}
.opening.is-active { opacity: 1; }
.opening.is-done   { opacity: 0; pointer-events: none; }

/* Kayan yıldız (meteor) - büyük, gerçekçi, parlak baş + uzun fade trail
   Animasyon: sayfa yüklenince DEĞİL, opening.is-active olunca tetiklenir */
.meteor {
    position: absolute;
    top: 15%; left: -400px;
    width: 460px; height: 3px;
    background: linear-gradient(90deg,
        transparent 0%,
        rgba(255, 240, 200, 0.08) 25%,
        rgba(255, 245, 220, 0.45) 65%,
        rgba(255, 255, 255, 1) 100%);
    border-radius: 999px;
    transform: rotate(18deg);
    transform-origin: right center;
    filter: blur(0.6px);
    opacity: 0;
}
.opening.is-active .meteor {
    animation: meteor-streak 2.4s cubic-bezier(0.25, 0.1, 0.3, 1) forwards;
}
.meteor::before {
    /* Parlak baş - yıldızın kafası (büyük + güçlü halo) */
    content: '';
    position: absolute;
    right: -4px; top: 50%;
    width: 12px; height: 12px;
    border-radius: 50%;
    background: #fff;
    transform: translateY(-50%);
    box-shadow:
        0 0 10px #fff,
        0 0 24px rgba(255, 245, 220, 0.95),
        0 0 48px rgba(240, 217, 124, 0.7),
        0 0 90px rgba(240, 217, 124, 0.35);
}
.meteor::after {
    /* Geniş halo */
    content: '';
    position: absolute;
    right: -16px; top: 50%;
    width: 28px; height: 28px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255,245,220,0.3), transparent 70%);
    transform: translateY(-50%);
}
@keyframes meteor-streak {
    0%   { transform: translate(0, 0)        rotate(18deg); opacity: 0; }
    8%   { opacity: 1; }
    85%  { opacity: 1; }
    100% { transform: translate(130vw, 60vh) rotate(18deg); opacity: 0; }
}

/* ═══════════════════════════════════════════════
   3. MEMORY PAGE
   ═══════════════════════════════════════════════ */
.memory {
    position: relative;
    padding-bottom: calc(120px + env(safe-area-inset-bottom, 0px));
    opacity: 0; transition: opacity .9s var(--ease);
    z-index: 5;
}
.memory.is-visible { opacity: 1; }

.block {
    position: relative;
    max-width: 760px; margin: 0 auto;
    padding: 56px 24px; z-index: 5;
}
@media (min-width: 768px) { .block { padding: 80px 32px; } }

.block-head { text-align: center; margin-bottom: 36px; }
.block-eyebrow {
    font-family: var(--font-caps);
    font-size: 11px; letter-spacing: 0.5em;
    text-transform: uppercase; color: var(--gold-l);
    margin-bottom: 14px; padding-left: 0.5em;
    font-weight: 500;
}
.block-title {
    font-family: var(--font-h); font-style: italic; font-weight: 500;
    font-size: clamp(30px, 5.5vw, 44px);
    line-height: 1.15; color: var(--ink);
    margin: 0; letter-spacing: -0.015em;
}
.block-ornament {
    display: flex; align-items: center; justify-content: center;
    gap: 12px; max-width: 240px;
    margin: 18px auto 0;
}
.block-ornament-line { flex: 1; height: 1px; background: linear-gradient(90deg, transparent, var(--gold), transparent); }
.block-ornament svg { width: 14px; height: 14px; color: var(--gold-l); flex-shrink: 0; }

/* Altın çift bordürlü gold frame (foto) - shadow yok, sadece bordür + glow */
.frame {
    position: relative;
    padding: 12px;
    background: linear-gradient(135deg, rgba(var(--kas-title-rgb),0.18), rgba(168,134,42,0.1));
    border-radius: 3px;
    border: 1px solid rgba(var(--kas-title-rgb),0.4);
    transition: transform .4s var(--ease), border-color .4s var(--ease);
    overflow: hidden;
}
.frame::before {
    content: ''; position: absolute; inset: 4px;
    border: 1px solid rgba(var(--kas-title-rgb),0.5);
    border-radius: 2px; pointer-events: none; z-index: 2;
}
.frame img {
    border-radius: 1px; width: 100%; display: block;
    aspect-ratio: 4/5; object-fit: cover;
    filter: brightness(0.85) contrast(1.05) saturate(0.9);
}
.frame:hover { transform: translateY(-3px); border-color: rgba(240,217,124,0.7); }
.frame.frame-sm { padding: 6px; }
.frame.frame-sm::before { inset: 3px; }
.frame.frame-sm img { aspect-ratio: 4/3; }

/* ─── HERO ─── */
.hero {
    position: relative; z-index: 5;
    min-height: 100vh; min-height: 100dvh;
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    text-align: center; padding: 110px 24px 60px;
    overflow: hidden;
}
.hero-eyebrow {
    font-family: var(--font-caps); font-size: 11px;
    letter-spacing: 0.5em; text-transform: uppercase;
    color: var(--gold-l); font-weight: 500;
    margin-bottom: 16px; padding-left: 0.5em;
    animation: fade-up .9s var(--ease) .2s both;
}
.hero-divider {
    width: 60px; height: 1px;
    background: var(--gold);
    margin: 0 auto 30px;
    animation: scale-x .8s var(--ease) .3s both;
}
@keyframes scale-x { from { transform: scaleX(0); } to { transform: scaleX(1); } }

.hero-couple {
    font-family: var(--font-script);
    font-size: clamp(48px, 10vw, 80px);
    color: var(--gold-l); line-height: 1;
    margin: 0 0 16px;
    animation: fade-up .9s var(--ease) .4s both;
}
.hero-title {
    font-family: var(--font-h);
    font-weight: 500; margin: 0 0 26px;
    line-height: 1.04; color: var(--ink);
    letter-spacing: -0.025em;
    animation: fade-up .9s var(--ease) .5s both;
}
.hero-title span {
    display: block; font-style: normal; font-weight: 500;
    font-size: clamp(24px, 4vw, 32px);
    color: var(--ink-3);
}
.hero-title em {
    display: block; font-style: italic;
    font-weight: 500;
    font-size: clamp(38px, 7vw, 58px);
    color: var(--ink);
    margin-top: 4px;
}
.hero-since {
    display: inline-flex; align-items: center; gap: 14px;
    font-family: var(--font-caps); font-size: 11px;
    letter-spacing: 0.4em; text-transform: uppercase;
    color: var(--ink-3); font-weight: 500;
    margin-bottom: 38px; padding-left: 0.4em;
    animation: fade-up .9s var(--ease) .6s both;
}
.hero-since-line { width: 30px; height: 1px; background: var(--gold); }
.hero-photo {
    max-width: 340px; width: 80%;
    animation: fade-up 1.1s var(--ease) .7s both;
}
@keyframes fade-up { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }

.hero-scroll {
    position: absolute; bottom: 30px; left: 50%;
    transform: translateX(-50%);
    font-family: var(--font-caps); font-size: 10px;
    letter-spacing: 0.4em; text-transform: uppercase;
    color: var(--muted); opacity: 0.7; padding-left: 0.4em;
}
.hero-scroll::before {
    content: ''; display: block; width: 1px; height: 24px;
    margin: 0 auto 8px;
    background: linear-gradient(180deg, transparent, var(--gold));
    animation: pulse-line 2.4s ease-in-out infinite;
}
@keyframes pulse-line { 0%, 100% { transform: scaleY(1); opacity: 0.6; } 50% { transform: scaleY(0.4); opacity: 0.2; } }

/* ─── DAY COUNTER ─── */
.day-counter { text-align: center; }
.day-counter-card {
    display: inline-flex; flex-direction: column;
    align-items: center; gap: 6px;
    padding: 44px 56px;
    background: var(--card-bg);
    backdrop-filter: blur(14px) saturate(1.4);
    -webkit-backdrop-filter: blur(14px) saturate(1.4);
    border: 1px solid var(--line);
    border-radius: 4px;
    position: relative;
}
.day-counter-card::before {
    content: ''; position: absolute; inset: 10px;
    border: 1px solid rgba(var(--kas-title-rgb),0.22);
    border-radius: 2px; pointer-events: none;
}
.day-counter-star {
    color: var(--gold-l);
    margin-bottom: 8px;
}
.day-counter-star svg { width: 24px; height: 24px; }
.day-counter-eyebrow {
    font-family: var(--font-caps); font-size: 10px;
    letter-spacing: 0.5em; text-transform: uppercase;
    color: var(--gold-l); margin-bottom: 4px; padding-left: 0.5em;
    font-weight: 500;
}
.day-counter-num {
    font-family: var(--font-h); font-style: italic; font-weight: 500;
    font-size: clamp(64px, 14vw, 120px);
    line-height: 1; color: var(--gold-l);
    letter-spacing: -0.03em;
    font-variant-numeric: tabular-nums;
    margin: 6px 0;
}
.day-counter-label {
    font-family: var(--font-h); font-style: italic;
    font-size: clamp(18px, 3vw, 22px);
    color: var(--ink); line-height: 1.3;
}
.day-counter-foot {
    margin-top: 18px;
    font-family: var(--font-caps); font-size: 10px;
    letter-spacing: 0.4em; text-transform: uppercase;
    color: var(--ink-3); padding-left: 0.4em;
}

/* ─── MESSAGE ─── */
.message-card {
    position: relative;
    padding: 46px 32px;
    background: var(--card-bg);
    backdrop-filter: blur(14px) saturate(1.4);
    -webkit-backdrop-filter: blur(14px) saturate(1.4);
    border: 1px solid var(--line);
    border-radius: 4px;
}
@media (min-width: 768px) { .message-card { padding: 60px 48px; } }
.message-card::before {
    content: ''; position: absolute; inset: 10px;
    border: 1px solid rgba(var(--kas-title-rgb),0.22); border-radius: 2px;
    pointer-events: none;
}
.message-icon { display: flex; justify-content: center; margin-bottom: 18px; color: var(--gold-l); }
.message-icon svg { width: 30px; height: 30px; }
.message-text {
    font-family: var(--font-h); font-style: italic;
    font-size: clamp(18px, 4vw, 22px);
    line-height: 1.7; color: var(--ink);
    text-align: center; margin: 0;
}
.message-sig {
    margin-top: 26px;
    font-family: var(--font-script);
    font-size: 34px; color: var(--gold-l);
    text-align: center; line-height: 1;
}

/* ─── GALLERY (slider) ─── */
.slider {
    position: relative;
    max-width: 560px; margin: 0 auto;
}
.slider-track { position: relative; aspect-ratio: 4/5; overflow: hidden; }
.slide {
    position: absolute; inset: 0;
    opacity: 0; transform: scale(1.02);
    transition: opacity .8s var(--ease), transform 1s var(--ease);
}
.slide.is-active { opacity: 1; transform: scale(1); z-index: 2; }
.slide .frame { width: 100%; height: 100%; padding: 14px; }
.slide .frame img { height: 100%; aspect-ratio: auto; }
.slide-cap {
    position: absolute; left: 36px; bottom: 36px;
    font-family: var(--font-script);
    font-size: 28px; color: var(--gold-l);
    text-shadow: 0 2px 8px rgba(0,0,0,0.7);
    z-index: 3;
}
.slider-nav {
    display: flex; align-items: center; justify-content: center;
    gap: 24px; margin-top: 28px;
}
.slider-arrow {
    width: 38px; height: 38px; border-radius: 50%;
    background: rgba(var(--kas-card-rgb), 0.6);
    border: 1px solid var(--line);
    color: var(--gold-l);
    display: flex; align-items: center; justify-content: center;
    transition: all .2s var(--ease);
}
.slider-arrow:hover { background: var(--gold); color: var(--bg-deep); }
.slider-arrow svg { width: 14px; height: 14px; }
.slider-dots { display: flex; gap: 8px; }
.dot {
    width: 8px; height: 8px;
    background: rgba(var(--kas-title-rgb), 0.3);
    cursor: pointer;
    transition: all .3s var(--ease);
}
.dot.is-active { width: 30px; background: var(--gold-l); }

/* ─── NOTE ─── */
.note { max-width: 520px; text-align: center; }
.note-text {
    font-family: var(--font-h); font-style: italic;
    font-size: clamp(22px, 4.5vw, 32px);
    line-height: 1.5; color: var(--gold-l);
}
.note-text::before, .note-text::after {
    display: inline-block;
    font-family: var(--font-h); font-style: italic;
    color: var(--gold); opacity: 0.4;
    font-size: 1.4em; line-height: 0;
    vertical-align: -0.2em; margin: 0 0.1em;
}
.note-text::before { content: '“'; }
.note-text::after  { content: '”'; }

/* ─── LETTER ─── */
.letter { max-width: 640px; }
.letter-paper {
    position: relative;
    padding: 44px 34px 38px;
    background:
        radial-gradient(ellipse at 25% 20%, rgba(var(--kas-title-rgb),0.06), transparent 55%),
        linear-gradient(180deg, rgba(var(--kas-card-rgb), 0.7), rgba(var(--kas-card-rgb), 0.7));
    backdrop-filter: blur(14px) saturate(1.4);
    -webkit-backdrop-filter: blur(14px) saturate(1.4);
    border: 1px solid var(--line);
    border-radius: 4px;
}
@media (min-width: 768px) { .letter-paper { padding: 64px 56px 52px; } }
.letter-mark {
    display: inline-flex; align-items: center; gap: 10px;
    font-family: var(--font-caps); font-size: 10px;
    letter-spacing: 0.45em; text-transform: uppercase;
    color: var(--gold-l); font-weight: 500;
    margin-bottom: 28px; padding-left: 0.45em;
}
.letter-mark::before { content: ''; width: 24px; height: 1px; background: var(--gold); }
.letter-to {
    font-family: var(--font-script);
    font-size: clamp(34px, 5.5vw, 44px);
    color: var(--gold-l);
    margin-bottom: 22px; line-height: 1.05;
}
.letter-body {
    font-family: var(--font-b); font-style: italic;
    font-size: 15.5px; line-height: 2;
    color: var(--ink-2);
}
.letter-body p { margin: 0 0 14px; }
.letter-body p:last-child { margin-bottom: 0; }
.letter-from { margin-top: 30px; text-align: right; }
.letter-from-name {
    font-family: var(--font-script);
    font-size: 32px; color: var(--gold-l);
}

/* ─── TIMELINE ─── */
.timeline-list {
    list-style: none; margin: 0;
    padding: 0 0 0 36px; position: relative;
}
.timeline-list::before {
    content: ''; position: absolute;
    left: 13px; top: 14px; bottom: 14px;
    width: 1px;
    background: linear-gradient(180deg, var(--gold) 0%, var(--gold-l) 50%, var(--gold-d) 100%);
    opacity: 0.6;
}
.tl-item { position: relative; padding: 0 0 40px 24px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-dot {
    position: absolute; left: -36px; top: 6px;
    width: 28px; height: 28px;
    border-radius: 50%;
    background: var(--bg-navy);
    border: 1.5px solid var(--gold);
    display: flex; align-items: center; justify-content: center;
    z-index: 2;
}
.tl-dot svg { width: 12px; height: 12px; color: var(--gold-l); }
.tl-card {
    display: flex; gap: 18px; flex-wrap: wrap;
    padding: 18px;
    background: var(--card-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--line);
    border-radius: 4px;
}
.tl-photo { width: 130px; flex-shrink: 0; }
.tl-text { flex: 1; min-width: 200px; }
.tl-date {
    display: inline-block;
    font-family: var(--font-caps); font-size: 10px;
    letter-spacing: 0.35em; text-transform: uppercase;
    color: var(--gold-l); font-weight: 500;
    margin-bottom: 10px;
    padding: 3px 12px 3px calc(12px + 0.35em);
    background: rgba(var(--kas-title-rgb), 0.1);
    border: 1px solid rgba(var(--kas-title-rgb), 0.25);
    border-radius: 2px;
}
.tl-title {
    font-family: var(--font-h); font-style: italic; font-weight: 600;
    font-size: clamp(20px, 4vw, 24px);
    line-height: 1.25; color: var(--ink);
    margin: 0 0 6px;
}
.tl-desc {
    font-family: var(--font-b); font-style: italic;
    font-size: 14.5px; line-height: 1.7;
    color: var(--ink-3); margin: 0;
}

/* ─── SURPRISE (gold orb) ─── */
.surprise { text-align: center; padding: 50px 24px; }
.surprise-orb-wrap {
    position: relative;
    display: inline-flex; flex-direction: column;
    align-items: center; gap: 24px;
    padding: 44px; cursor: pointer;
}
.surprise-orb-wrap::before {
    content: ''; position: absolute;
    top: 4px; left: 50%; transform: translateX(-50%);
    width: 196px; height: 196px; border-radius: 50%;
    background: radial-gradient(circle, rgba(var(--kas-title-rgb),0.22) 0%, transparent 66%);
    pointer-events: none;
}
.surprise-ring {
    position: absolute; top: 27px; left: 50%;
    transform: translateX(-50%);
    width: 150px; height: 150px;
    border: 2px dashed rgba(var(--kas-title-rgb),0.55);
    border-radius: 50%;
    animation: ring-spin 28s linear infinite;
    pointer-events: none;
}
.surprise-ring.r2 {
    top: 44px;
    width: 116px; height: 116px;
    border: 1.5px solid rgba(var(--kas-title-rgb),0.5);
    animation: ring-pulse 2.8s ease-out infinite;
}
@keyframes ring-spin { to { transform: translateX(-50%) rotate(360deg); } }
@keyframes ring-pulse {
    0%   { transform: translateX(-50%) scale(0.78); opacity: 0.75; }
    100% { transform: translateX(-50%) scale(1.5); opacity: 0; }
}
.surprise-orb {
    position: relative; z-index: 1;
    width: 116px; height: 116px;
    border-radius: 50%;
    background:
        radial-gradient(circle at 32% 26%, var(--gold-l) 0%, var(--gold) 52%, var(--gold-d) 100%);
    display: flex; align-items: center; justify-content: center;
    box-shadow:
        0 20px 48px -10px rgba(var(--kas-title-rgb),0.55),
        inset 0 2px 8px rgba(255,255,255,0.4),
        inset 0 -12px 22px rgba(0,0,0,0.18);
    transition: transform .4s var(--ease);
    color: #fff;
}
.surprise-orb-wrap:hover .surprise-orb { transform: scale(1.08); }
.surprise-orb svg { width: 44px; height: 44px; }
.surprise-label {
    display: inline-flex; align-items: center; gap: 8px;
    font-family: var(--font-script);
    font-size: 26px; color: var(--gold-l);
}
.surprise-label svg { width: 19px; height: 19px; opacity: .8; }
.surprise-card {
    margin: 16px auto 0; max-width: 480px;
    display: none;
    animation: reveal-up .7s cubic-bezier(0.34, 1.4, 0.5, 1) both;
}
.surprise-card.is-open { display: block; }
@keyframes reveal-up {
    from { opacity: 0; transform: translateY(20px) scale(0.95); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}
.surprise-text {
    font-family: var(--font-h); font-style: italic;
    font-size: clamp(18px, 4vw, 21px);
    line-height: 1.7; color: var(--ink);
    text-align: center; margin: 0;
}

/* ─── DİLEK YILDIZI (signature surprise) ─── */
.wish-star-wrap {
    display: inline-flex; flex-direction: column;
    align-items: center; gap: 14px;
    background: none; border: 0; padding: 8px;
    cursor: pointer; -webkit-tap-highlight-color: transparent;
    transition: transform .35s var(--ease);
}
.wish-star {
    position: relative;
    width: 150px; height: 150px;
    display: block;
    will-change: transform, opacity;
    animation: wish-bob 5.5s ease-in-out infinite;
}
.wish-star-svg { width: 100%; height: 100%; overflow: visible; display: block; }

/* gentle idle bob */
@keyframes wish-bob {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50%      { transform: translateY(-7px) rotate(2deg); }
}

/* star body: soft twinkle scale + glow */
.wish-body {
    transform-origin: 60px 60px;
    filter: drop-shadow(0 10px 26px rgba(var(--kas-title-rgb), 0.5));
    animation: wish-twinkle 3.2s ease-in-out infinite;
}
@keyframes wish-twinkle {
    0%, 100% { transform: scale(1); }
    50%      { transform: scale(1.045); }
}

/* halo pulse */
.wish-halo {
    transform-origin: 60px 60px;
    animation: wish-halo-pulse 3.2s ease-in-out infinite;
}
@keyframes wish-halo-pulse {
    0%, 100% { transform: scale(0.92); opacity: 0.8; }
    50%      { transform: scale(1.12); opacity: 1; }
}

/* highlight glint travels subtly */
.wish-glint { animation: wish-glint 3.2s ease-in-out infinite; transform-origin: center; }
@keyframes wish-glint {
    0%, 100% { opacity: 0.5; transform: scale(0.8); }
    50%      { opacity: 0.95; transform: scale(1.15); }
}

/* trail hidden while idle */
.wish-trail { opacity: 0; transform-origin: 64px 56px; }

/* drifting sparks */
.wish-spark { transform-origin: center; }
.wish-spark.sp1 { animation: wish-spark 2.6s ease-in-out infinite; }
.wish-spark.sp2 { animation: wish-spark 3.1s ease-in-out .6s infinite; }
.wish-spark.sp3 { animation: wish-spark 2.3s ease-in-out 1.1s infinite; }
@keyframes wish-spark {
    0%, 100% { opacity: 0; transform: scale(0.4); }
    50%      { opacity: 1; transform: scale(1.1); }
}

/* hover: lift + brighten */
.wish-star-wrap:hover { transform: translateY(-3px); }
.wish-star-wrap:hover .wish-body { filter: drop-shadow(0 14px 32px rgba(var(--kas-title-rgb), 0.7)); }

/* ── reveal: shoot away like a falling star, leaving a trail ── */
.wish-star-wrap.is-gone { pointer-events: none; }
.wish-star-wrap.is-gone .wish-star {
    animation: none;
    transform: translate(60px, -56px) scale(0.35) rotate(38deg);
    opacity: 0;
    transition: transform .45s cubic-bezier(0.5, 0, 0.7, 0.4), opacity .45s ease-in .12s;
}
.wish-star-wrap.is-gone .wish-body,
.wish-star-wrap.is-gone .wish-halo,
.wish-star-wrap.is-gone .wish-glint,
.wish-star-wrap.is-gone .wish-spark { animation: none; }
.wish-star-wrap.is-gone .wish-trail {
    opacity: 1;
    animation: wish-streak .45s ease-out forwards;
}
@keyframes wish-streak {
    0%   { opacity: 0; stroke-dasharray: 0 80; }
    40%  { opacity: 1; }
    100% { opacity: 0; stroke-dasharray: 80 0; }
}
.wish-star-wrap.is-gone .surprise-label {
    opacity: 0;
    transition: opacity .25s ease;
}

@media (prefers-reduced-motion: reduce) {
    .wish-star, .wish-body, .wish-halo, .wish-glint, .wish-spark { animation: none !important; }
    .wish-star-wrap.is-gone .wish-star { transition: opacity .3s ease; transform: none; }
}

/* ─── GUESTBOOK ─── */
.guestbook { max-width: 640px; }
.gb-list { display: flex; flex-direction: column; gap: 14px; margin-bottom: 24px; }
.gb-entry {
    padding: 20px 24px;
    background: var(--card-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--line);
    border-radius: 4px;
}
.gb-head {
    display: flex; justify-content: space-between; align-items: baseline;
    margin-bottom: 8px;
}
.gb-head strong {
    font-family: var(--font-h); font-style: italic;
    font-size: 17px; color: var(--gold-l); font-weight: 600;
}
.gb-head time {
    font-family: var(--font-caps); font-size: 9.5px;
    letter-spacing: 0.25em; text-transform: uppercase;
    color: var(--muted); padding-left: 0.25em;
}
.gb-entry p {
    font-family: var(--font-b); font-style: italic;
    font-size: 14.5px; line-height: 1.7;
    color: var(--ink-2); margin: 0;
}
.gb-form {
    display: flex; flex-direction: column; gap: 10px;
    padding: 20px;
    background: rgba(var(--kas-card-rgb), 0.4);
    border: 1px solid var(--line-soft);
    border-radius: 4px;
}
.gb-form input, .gb-form textarea {
    width: 100%; padding: 11px 14px;
    background: rgba(5, 10, 32, 0.55);
    color: var(--ink);
    border: 1px solid var(--line-soft);
    border-radius: 3px;
    font-family: var(--font-b); font-size: 14px;
    outline: none;
    transition: border-color .2s ease, box-shadow .2s ease;
}
.gb-form input::placeholder, .gb-form textarea::placeholder { color: var(--muted); }
.gb-form textarea { resize: vertical; min-height: 70px; }
.gb-form input:focus, .gb-form textarea:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(var(--kas-title-rgb),0.1); }
.gb-form button {
    align-self: flex-end;
    min-height: 44px; padding: 0 24px;
    background: transparent;
    color: var(--gold-l);
    border: 1px solid var(--gold); border-radius: 3px;
    font-family: var(--font-caps); font-size: 11px; font-weight: 500;
    letter-spacing: 0.32em; text-transform: uppercase;
    padding-left: calc(24px + 0.32em);
    transition: background .2s ease, color .2s ease, box-shadow .2s ease;
}
.gb-form button:hover { background: var(--gold); color: var(--bg-deep); }

/* ─── FOOTER ─── */
.footer { text-align: center; padding: 60px 24px 40px; }
.footer-star { color: var(--gold-l); margin-bottom: 14px; }
.footer-star svg { width: 28px; height: 28px; }
.footer-couple {
    font-family: var(--font-script);
    font-size: clamp(40px, 8vw, 56px);
    color: var(--gold-l); margin: 0 0 8px; line-height: 1;
}
.footer-since {
    font-family: var(--font-caps); font-size: 10.5px;
    letter-spacing: 0.45em; text-transform: uppercase;
    color: var(--ink-3); margin-bottom: 24px; padding-left: 0.45em;
    font-weight: 500;
}
.footer-counter {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 8px 16px 8px calc(16px + 0.22em);
    background: rgba(var(--kas-card-rgb), 0.55);
    border: 1px solid var(--line); border-radius: 3px;
    font-family: var(--font-caps); font-size: 10.5px;
    letter-spacing: 0.22em; text-transform: uppercase;
    color: var(--ink-3); font-weight: 500;
}
.footer-counter-num { color: var(--gold-l); font-weight: 600; font-variant-numeric: tabular-nums; }
.footer-brand {
    margin-top: 32px;
    font-family: var(--font-caps); font-size: 9.5px;
    letter-spacing: 0.5em; text-transform: uppercase;
    color: var(--muted); opacity: 0.7; padding-left: 0.5em;
}

/* ═══ STICKY MÜZİK PLAYER (dark + gold) ═══ */
/* ortalı, yuvarlak yüzen pill (full-width değil) - diğer temalarla aynı düzen */
.player {
    position: fixed; left: 50%; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); z-index: 50;
    width: min(340px, calc(100% - 32px));
    display: flex; align-items: center; gap: 12px; padding: 10px 16px;
    border-radius: 100px; overflow: hidden;
    background: linear-gradient(180deg, rgba(10, 18, 50, 0.92) 0%, rgba(5, 10, 32, 0.96) 100%);
    backdrop-filter: blur(16px) saturate(1.4);
    -webkit-backdrop-filter: blur(16px) saturate(1.4);
    border: 1px solid var(--line); box-shadow: 0 18px 40px -14px rgba(0,0,0,.6);
    transform: translate(-50%, 180%); transition: transform .6s var(--ease) .3s;
}
body.is-reading .player { transform: translate(-50%, 0); }
.player-progress {
    position: absolute; left: 0; right: 0; bottom: 0; top: auto;
    height: 3px; background: rgba(var(--kas-title-rgb),0.14);
}
.player-progress-fill {
    height: 100%; width: 0;
    background: linear-gradient(90deg, var(--gold-d), var(--gold-l));
    transition: width .2s linear;
}
.player-controls { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.player-btn {
    width: 30px; height: 30px; border-radius: 50%;
    color: var(--gold-l);
    display: flex; align-items: center; justify-content: center;
    transition: background .15s ease;
}
.player-btn:hover { background: rgba(var(--kas-title-rgb),0.12); }
.player-btn svg { width: 16px; height: 16px; }
.player-btn.player-play {
    width: 34px; height: 34px;
    background: linear-gradient(180deg, var(--gold-l), var(--gold-d));
    color: var(--bg-deep);
    border: 1px solid var(--gold-d);
}
.player-btn.player-play:hover { background: linear-gradient(180deg, var(--gold), var(--gold-d)); }
.player-btn.player-play svg { width: 14px; height: 14px; }
.player-info { flex: 1; min-width: 0; }
.player-title {
    font-family: var(--font-h); font-style: italic;
    font-size: 14px; font-weight: 500; color: var(--ink);
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.player-meta {
    display: flex; align-items: center; gap: 8px;
    font-family: var(--font-caps); font-size: 10px;
    letter-spacing: 0.22em; color: var(--ink-3);
    margin-top: 2px; padding-left: 0.22em;
    font-variant-numeric: tabular-nums;
}
.player-meta span:nth-child(2) { opacity: 0.5; }
.player-note { flex-shrink: 0; color: var(--gold-l); opacity: 0.8; }
.player-note svg { width: 18px; height: 18px; }

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

/* === Düzenlenebilir renkler (başlık/accent, metin, kart) - opaklık & blur sabit === */
body.kas-tpl-gece-yildizlari {
    --kas-title: #d4af37; --kas-title-rgb: 212,175,55;
    --kas-text:  #f0e8d2; --kas-text-rgb:  240,232,210;
    --kas-card-rgb: 19,26,68;
    --gold: var(--kas-title); --gold-l: var(--kas-title); --gold-d: var(--kas-title);
    --ink: var(--kas-text); --ink-2: var(--kas-text);
    --card-bg: rgba(var(--kas-card-rgb), 0.65);
    --card-bg-2: rgba(var(--kas-card-rgb), 0.55);
}
