/* NimbusDrive uygulama arayüzü — "Gökyüzü saati"
   İki tema (data-theme="day" | "night") anlamsal token'larla; theme.js gün doğumu/batımına
   göre (ya da kullanıcı seçimiyle) değiştirir. Tanıtım sayfasının gece paletinden türetildi.
   Sınıf adları site.js ve sunucu testleriyle sözleşmedir: yeniden adlandırmadan önce kontrol et. */

/* ---------------------------------------------------------------- tokens */
:root,
:root[data-theme="day"] {
    --bg: #F2F4FA;
    --bg-glow: radial-gradient(70% 50% at 85% -10%, #E3E0FF 0%, transparent 60%), radial-gradient(60% 40% at -5% 0%, #DDEEFF 0%, transparent 60%);
    --surface: #FFFFFF;
    --surface-2: #F6F7FC;
    --surface-3: #ECEEF7;
    --ink: #14163A;
    --ink-2: #393D62;
    --muted: #63688C;
    --line: #E1E4EF;
    --line-strong: #CCD1E2;
    --primary: #5B4CF0;
    --primary-hover: #4A3BE0;
    --primary-ink: #FFFFFF;
    --primary-soft: #EEEBFF;
    --primary-soft-ink: #4335C8;
    --star: #F5A623;
    --danger: #D92D45;
    --danger-soft: #FDECEF;
    --success: #0E8F63;
    --success-soft: #E2F6EC;
    --warning: #B86200;
    --warning-soft: #FFF1DC;
    --shadow-1: 0 1px 2px rgba(20, 22, 58, .05), 0 6px 16px -8px rgba(20, 22, 58, .14);
    --shadow-2: 0 24px 60px -24px rgba(20, 22, 58, .35), 0 2px 6px rgba(20, 22, 58, .06);
    --scrim: rgba(20, 22, 58, .36);
    --topbar-bg: rgba(242, 244, 250, .82);
    --invert-bg: #14163A;
    --invert-ink: #FFFFFF;
    --stars: none;
}

:root[data-theme="night"] {
    --bg: #0D0A26;
    --bg-glow: radial-gradient(60% 45% at 90% -10%, rgba(139, 92, 246, .28) 0%, transparent 60%), radial-gradient(50% 40% at -5% 100%, rgba(255, 77, 141, .14) 0%, transparent 60%);
    --surface: #15113A;
    --surface-2: #1B1646;
    --surface-3: #251F58;
    --ink: #EEEBFF;
    --ink-2: #D0CBF3;
    --muted: #A29DCB;
    --line: rgba(255, 255, 255, .08);
    --line-strong: rgba(255, 255, 255, .17);
    --primary: #8E80FF;
    --primary-hover: #A397FF;
    --primary-ink: #0D0A26;
    --primary-soft: rgba(142, 128, 255, .17);
    --primary-soft-ink: #C9C1FF;
    --star: #FFC53D;
    --danger: #FF6B81;
    --danger-soft: rgba(255, 107, 129, .14);
    --success: #34D399;
    --success-soft: rgba(52, 211, 153, .13);
    --warning: #FFB547;
    --warning-soft: rgba(255, 181, 71, .13);
    --shadow-1: 0 1px 0 rgba(255, 255, 255, .03) inset, 0 10px 24px -14px rgba(0, 0, 0, .7);
    --shadow-2: 0 30px 70px -24px rgba(0, 0, 0, .8), 0 0 0 1px rgba(255, 255, 255, .06);
    --scrim: rgba(5, 3, 20, .62);
    --topbar-bg: rgba(13, 10, 38, .76);
    --invert-bg: #EEEBFF;
    --invert-ink: #0D0A26;
    /* çok seyrek yıldız tozu (yalnızca gece) */
    --stars: radial-gradient(1px 1px at 30px 40px, rgba(255, 255, 255, .45), transparent 60%),
             radial-gradient(1px 1px at 140px 110px, rgba(255, 255, 255, .3), transparent 60%),
             radial-gradient(1.4px 1.4px at 220px 20px, rgba(255, 255, 255, .35), transparent 60%);
}

:root {
    --font: "Segoe UI Variable Text", "SF Pro Text", -apple-system, system-ui, "Segoe UI", Roboto, sans-serif;
    --display: "Segoe UI Variable Display", "SF Pro Display", -apple-system, system-ui, "Segoe UI", sans-serif;
    --mono: ui-monospace, "Cascadia Code", "SF Mono", "JetBrains Mono", Menlo, Consolas, monospace;
    --topbar-h: 64px;
    --sidebar-w: 268px;
    --r-sm: 9px;
    --r: 12px;
    --r-lg: 18px;
    --ease: cubic-bezier(.2, .8, .2, 1);
    --spring: cubic-bezier(.34, 1.4, .64, 1);
}

/* Dosya türü renkleri (Spektrum) — gece arka planı yarı saydam */
.type-folder  { --type: #F59E0B; }
.type-doc     { --type: #3B82F6; }
.type-sheet   { --type: #10B981; }
.type-image   { --type: #8B5CF6; }
.type-video   { --type: #EC4899; }
.type-audio   { --type: #06B6D4; }
.type-pdf     { --type: #EF4444; }
.type-archive { --type: #A8A29E; }
.type-other   { --type: #7C82A6; }
[class*="type-"] { --type-bg: color-mix(in srgb, var(--type) 13%, var(--surface)); }
:root[data-theme="night"] [class*="type-"] { --type-bg: color-mix(in srgb, var(--type) 20%, transparent); }

/* Tema geçişi: gün doğumu/batımında renkler yumuşakça akar */
html.theme-anim, html.theme-anim *, html.theme-anim *::before, html.theme-anim *::after {
    transition: background-color .9s var(--ease), color .9s var(--ease), border-color .9s var(--ease),
                fill .9s var(--ease), stroke .9s var(--ease), box-shadow .9s var(--ease) !important;
}

/* ---------------------------------------------------------------- base */
* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: var(--font);
    font-size: 14.5px;
    line-height: 1.5;
    color: var(--ink);
    background: var(--bg-glow), var(--bg);
    background-attachment: fixed;
    -webkit-font-smoothing: antialiased;
}
/* Gece yıldız tozu: ayrı sabit katman (döşeme boyutu tema katman sayısından bağımsız) */
body::before {
    content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
    background: var(--stars); background-size: 260px 160px;
}

h1, h2, h3 { font-family: var(--display); color: var(--ink); letter-spacing: -.02em; }
a { color: var(--primary); }
.hidden { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.inline-form { display: inline; margin: 0; }
.text-danger { color: var(--danger); }
body.modal-open { overflow: hidden; }

.i {
    width: 18px; height: 18px; flex: none;
    fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
}

kbd {
    font: 600 11px/1 var(--mono);
    padding: 3px 6px; border-radius: 6px;
    background: var(--surface-3); color: var(--muted);
    box-shadow: inset 0 -1px 0 var(--line-strong);
}

.skip {
    position: fixed; left: 12px; top: -60px; z-index: 200;
    padding: 8px 14px; border-radius: 10px;
    background: var(--primary); color: var(--primary-ink); font-weight: 700; text-decoration: none;
}
.skip:focus { top: 12px; }

:focus-visible { outline: 2.5px solid var(--primary); outline-offset: 2px; border-radius: 8px; }

/* ---------------------------------------------------------------- buttons */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    height: 38px; padding: 0 15px;
    border: 1px solid transparent; border-radius: var(--r);
    font: 600 14px/1 var(--font);
    cursor: pointer; text-decoration: none; white-space: nowrap;
    transition: background .15s, border-color .15s, color .15s, transform .2s var(--spring), box-shadow .2s;
}
.btn:active { transform: scale(.97); }
.btn .i { width: 17px; height: 17px; }
.btn-primary { background: var(--primary); color: var(--primary-ink); box-shadow: 0 6px 16px -8px color-mix(in srgb, var(--primary) 80%, transparent); }
.btn-primary:hover { background: var(--primary-hover); }
.btn-ghost { background: var(--surface); color: var(--ink); border-color: var(--line-strong); }
.btn-ghost:hover { background: var(--surface-3); }
.btn-ghost.active { background: var(--primary-soft); color: var(--primary-soft-ink); border-color: transparent; }
.btn-sm { height: 32px; padding: 0 11px; font-size: 13px; border-radius: var(--r-sm); gap: 6px; }
.btn-sm .i { width: 15px; height: 15px; }
.btn-danger { color: var(--danger); }
.btn-ghost.btn-danger:hover { background: var(--danger-soft); border-color: transparent; }
.btn[disabled] { opacity: .5; pointer-events: none; }

.btn-icon {
    display: inline-grid; place-items: center;
    width: 34px; height: 34px; padding: 0;
    border: 0; border-radius: var(--r-sm);
    background: transparent; color: var(--muted);
    cursor: pointer; text-decoration: none;
    transition: background .15s, color .15s, transform .2s var(--spring);
}
.btn-icon:hover { background: var(--surface-3); color: var(--ink); }
.btn-icon:active { transform: scale(.9); }
.star-btn.starred { color: var(--star); }
.star-btn.starred .i, .star-mark { fill: currentColor; }
.star-btn.starred:hover { color: var(--star); }

/* ---------------------------------------------------------------- forms */
input[type="text"], input[type="email"], input[type="password"], input[type="number"],
input[type="search"], select, textarea {
    height: 40px; padding: 0 12px;
    border: 1px solid var(--line-strong); border-radius: var(--r-sm);
    background: var(--surface); color: var(--ink);
    font: 14.5px var(--font);
    transition: border-color .15s, box-shadow .15s;
}
textarea { height: auto; padding: 10px 12px; }
input::placeholder { color: var(--muted); opacity: .8; }
input:focus, select:focus, textarea:focus {
    outline: none; border-color: var(--primary);
    box-shadow: 0 0 0 4px var(--primary-soft);
}
input[type="checkbox"] { width: 17px; height: 17px; accent-color: var(--primary); vertical-align: -3px; margin-right: 6px; }

.form-card {
    width: 100%; max-width: 460px;
    margin: 0 0 20px;
    padding: 28px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    box-shadow: var(--shadow-1);
}
.form-card h1 { margin: 0 0 6px; font-size: 28px; }
.form-card h2 { margin: 0 0 6px; font-size: 19px; }
.form-card > .file-meta, .form-card > p { margin: 0 0 18px; }
.form-group { margin-bottom: 16px; }
.form-group label { display: block; margin-bottom: 6px; font-weight: 600; font-size: 13.5px; color: var(--ink-2); }
.form-group input[type="text"], .form-group input[type="email"], .form-group input[type="password"], .form-group input[type="number"] { width: 100%; }
.form-aux { margin: 16px 0 0; font-size: 13.5px; }
.form-card .btn + .btn { margin-left: 6px; }
.validation-error { display: block; margin-top: 4px; color: var(--danger); font-size: 12.5px; }
.validation-summary-errors { color: var(--danger); margin-bottom: 14px; font-size: 13.5px; }
.validation-summary-errors ul { margin: 0; padding-left: 1.1rem; }
.validation-summary-valid { display: none; }

/* ---------------------------------------------------------------- alerts / badges */
.alert {
    display: flex; gap: 10px; align-items: flex-start;
    padding: 12px 16px; margin-bottom: 18px;
    border-radius: var(--r); border: 1px solid transparent;
    font-size: 14px;
    animation: drop-in .35s var(--ease);
}
.alert-danger { background: var(--danger-soft); color: var(--danger); border-color: color-mix(in srgb, var(--danger) 25%, transparent); }
.alert-success { background: var(--success-soft); color: var(--success); border-color: color-mix(in srgb, var(--success) 25%, transparent); }
.alert-warning { background: var(--warning-soft); color: var(--warning); border-color: color-mix(in srgb, var(--warning) 25%, transparent); }

.badge {
    display: inline-flex; align-items: center;
    padding: 3px 9px; border-radius: 999px;
    font: 600 11.5px/1.2 var(--mono);
    background: var(--surface-3); color: var(--ink-2);
}
.badge-danger { background: var(--danger-soft); color: var(--danger); }
.badge-success { background: var(--success-soft); color: var(--success); }
.badge-warn { background: var(--warning-soft); color: var(--warning); }

.file-meta { font: 12.5px/1.5 var(--mono); color: var(--muted); }
.tag { font: 600 12px var(--mono); }

/* ---------------------------------------------------------------- topbar */
.topbar {
    position: sticky; top: 0; z-index: 50;
    display: flex; align-items: center; gap: 16px;
    height: var(--topbar-h); padding: 0 20px 0 16px;
    background: var(--topbar-bg);
    backdrop-filter: saturate(1.4) blur(16px);
    border-bottom: 1px solid var(--line);
}
.brand {
    display: inline-flex; align-items: center; gap: 10px;
    width: calc(var(--sidebar-w) - 32px);
    color: var(--ink); text-decoration: none;
    font: 750 18px/1 var(--display); letter-spacing: -.02em;
}
.brand-mark {
    display: grid; place-items: center;
    width: 34px; height: 34px; border-radius: 10px;
    background: linear-gradient(135deg, #22D3EE, #8B5CF6 55%, #FF4D8D);
    color: #fff; box-shadow: 0 6px 14px -6px rgba(139, 92, 246, .8);
}
.brand-mark .i { width: 20px; height: 20px; stroke-width: 2; }
.nav-toggle { display: none; }

.search-form { position: relative; flex: 1; max-width: 640px; }
.search-form input {
    width: 100%; height: 42px; padding: 0 44px 0 42px;
    border-radius: 999px;
    background: var(--surface-2); border-color: var(--line);
}
.search-form input:focus { background: var(--surface); }
.search-icon { position: absolute; left: 14px; top: 50%; translate: 0 -50%; color: var(--muted); pointer-events: none; }
.search-kbd { position: absolute; right: 12px; top: 50%; translate: 0 -50%; pointer-events: none; }
.search-form input:focus ~ .search-kbd { opacity: 0; }
.search-form input::-webkit-search-cancel-button { cursor: pointer; }

.topbar-nav { display: flex; align-items: center; gap: 10px; margin-left: auto; }

.avatar {
    display: grid; place-items: center;
    width: 38px; height: 38px; border-radius: 50%;
    background: linear-gradient(135deg, #8B5CF6, #FF4D8D);
    color: #fff; font: 750 15px/1 var(--display);
    cursor: pointer; list-style: none;
    box-shadow: 0 0 0 3px var(--surface), 0 0 0 4px var(--line);
}
.avatar::-webkit-details-marker { display: none; }
.avatar-lg { width: 42px; height: 42px; font-size: 17px; box-shadow: none; flex: none; }

/* ---------------------------------------------------------------- menus (<details>) */
.menu { position: relative; }
.menu > summary { list-style: none; cursor: pointer; }
.menu > summary::-webkit-details-marker { display: none; }
.menu-pop {
    position: absolute; right: 0; top: calc(100% + 6px); z-index: 70;
    min-width: 214px; padding: 6px;
    background: var(--surface);
    border: 1px solid var(--line); border-radius: 14px;
    box-shadow: var(--shadow-2);
    animation: pop .16s var(--ease);
    transform-origin: top right;
}
.menu.up .menu-pop { top: auto; bottom: calc(100% + 6px); transform-origin: bottom right; }
@keyframes pop { from { opacity: 0; transform: scale(.96) translateY(-4px); } }
.menu-item {
    display: flex; align-items: center; gap: 11px; width: 100%;
    padding: 9px 11px; border: 0; border-radius: var(--r-sm);
    background: none; color: var(--ink); text-align: left; text-decoration: none;
    font: 500 14px/1.2 var(--font); cursor: pointer;
}
.menu-item .i { color: var(--muted); }
.menu-item:hover, .menu-item:focus-visible { background: var(--surface-3); outline: none; }
.menu-item.danger, .menu-item.danger .i { color: var(--danger); }
.menu-item.danger:hover { background: var(--danger-soft); }
.menu-sep { border: 0; border-top: 1px solid var(--line); margin: 5px 4px; }
.menu-head { display: flex; align-items: center; gap: 10px; padding: 10px 10px 12px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.user-email { color: var(--ink); font-weight: 600; text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 200px; }
.user-menu .menu-pop { min-width: 260px; }

/* ---------------------------------------------------------------- shell */
.app-shell { display: flex; align-items: flex-start; min-height: calc(100vh - var(--topbar-h)); }

.sidebar {
    position: sticky; top: var(--topbar-h);
    width: var(--sidebar-w); flex: none;
    height: calc(100vh - var(--topbar-h));
    overflow-y: auto; overscroll-behavior: contain;
    padding: 16px 14px 18px;
    display: flex; flex-direction: column; gap: 18px;
    border-right: 1px solid var(--line);
    scrollbar-width: thin;
}

/* Kenar çubuğu sütunu: gökyüzü saati, menü ve depolama sabit boyda kalır; yalnızca klasör ağacı
   kendi içinde kayar (çok klasörde saat ezilmez, ağaç depolama kartının arkasına taşmaz). */
.sidebar > * { flex-shrink: 0; }

/* İçerik en az ekran boyu: az öğeli/boş sayfada da altta boş alan kalır → oradan sürükleyerek
   seçim başlatılabilir ve boşa tıklayınca seçim temizlenir. */
.content { flex: 1; min-width: 0; min-height: calc(100vh - var(--topbar-h)); padding: 26px 32px 90px; max-width: 1640px; }

/* ---------------------------------------------------------------- sky clock (imza) */
.sky-clock {
    border-radius: var(--r-lg);
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-1);
    overflow: hidden;
}
.sky-scene {
    position: relative; height: 96px; overflow: hidden;
    background: linear-gradient(180deg, #5AA9FF 0%, #A6D6FF 65%, #E6F4FF 100%);
    transition: background 1.2s var(--ease);
}
:root[data-phase="dawn"] .sky-scene { background: linear-gradient(180deg, #6D5CF0 0%, #FF9DB4 58%, #FFD69B 100%); }
:root[data-phase="dusk"] .sky-scene { background: linear-gradient(180deg, #34206E 0%, #C2457D 58%, #FF9F5A 100%); }
:root[data-phase="night"] .sky-scene { background: linear-gradient(180deg, #08061C 0%, #1C1550 70%, #2D2170 100%); }
.sky-stars {
    position: absolute; inset: 0;
    background:
        radial-gradient(1.2px 1.2px at 12% 22%, #fff, transparent 60%),
        radial-gradient(1px 1px at 30% 60%, #fff, transparent 60%),
        radial-gradient(1.4px 1.4px at 48% 18%, #fff, transparent 60%),
        radial-gradient(1px 1px at 66% 42%, #fff, transparent 60%),
        radial-gradient(1.2px 1.2px at 84% 16%, #fff, transparent 60%),
        radial-gradient(1px 1px at 92% 58%, #fff, transparent 60%);
    opacity: 0; transition: opacity 1.2s;
    animation: twinkle 3.5s ease-in-out infinite;
}
.sky-clock.is-night .sky-stars { opacity: .9; }
@keyframes twinkle { 50% { filter: brightness(.55); } }
.sky-arc {
    position: absolute; left: 8%; right: 8%; top: 20%; height: 116%;
    border: 1.5px dashed rgba(255, 255, 255, .45); border-bottom: 0;
    border-radius: 50% 50% 0 0 / 100% 100% 0 0;
}
.sky-body {
    position: absolute; left: 50%; top: 40%;
    width: 22px; height: 22px; translate: -50% -50%;
    transition: left 1.2s var(--ease), top 1.2s var(--ease);
}
.sky-body .sun, .sky-body .moon { position: absolute; inset: 0; border-radius: 50%; transition: opacity 1s, transform 1s var(--spring); }
.sky-body .sun { background: radial-gradient(circle at 40% 40%, #FFF3B0, #FFC53D 60%, #FF9F1C); box-shadow: 0 0 18px 6px rgba(255, 197, 61, .55); }
.sky-body .moon { background: transparent; box-shadow: inset -6px -2px 0 1px #F3EFFF; opacity: 0; transform: scale(.4) rotate(-30deg); filter: drop-shadow(0 0 6px rgba(243, 239, 255, .6)); }
.sky-clock.is-night .sun { opacity: 0; transform: scale(.4); }
.sky-clock.is-night .moon { opacity: 1; transform: none; }
.sky-cloud {
    position: absolute; height: 14px; border-radius: 999px;
    background: rgba(255, 255, 255, .75);
    filter: blur(.4px);
    animation: drift 38s linear infinite;
}
.sky-cloud::before { content: ""; position: absolute; left: 22%; bottom: 40%; width: 46%; height: 150%; border-radius: 50%; background: inherit; }
.sky-cloud.c1 { width: 52px; top: 30%; left: -20%; }
.sky-cloud.c2 { width: 36px; top: 54%; left: -30%; animation-duration: 52s; animation-delay: -20s; opacity: .8; }
.sky-clock.is-night .sky-cloud { background: rgba(160, 150, 220, .22); }
@keyframes drift { to { left: 120%; } }
.sky-horizon {
    position: absolute; left: -5%; right: -5%; bottom: -14px; height: 34px;
    background: radial-gradient(60% 100% at 25% 100%, rgba(20, 22, 58, .55), transparent 70%),
                radial-gradient(55% 100% at 78% 100%, rgba(20, 22, 58, .45), transparent 70%);
}
.sky-info { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px 4px; }
.sky-label { font-weight: 650; font-size: 13px; color: var(--ink); }
.sky-times { font: 11.5px var(--mono); color: var(--muted); }
.theme-switch { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; padding: 8px 10px 10px; }
.theme-switch button {
    display: flex; flex-direction: column; align-items: center; gap: 3px;
    padding: 7px 4px; border: 0; border-radius: var(--r-sm);
    background: var(--surface-2); color: var(--muted);
    font: 600 11px/1 var(--font); cursor: pointer;
    transition: background .15s, color .15s;
}
.theme-switch button .i { width: 16px; height: 16px; }
.theme-switch button:hover { color: var(--ink); background: var(--surface-3); }
.theme-switch button.is-on { background: var(--primary-soft); color: var(--primary-soft-ink); }

/* ---------------------------------------------------------------- sidebar nav */
.side-nav { display: flex; flex-direction: column; gap: 2px; }
.side-link {
    display: flex; align-items: center; gap: 12px;
    padding: 9px 12px; border-radius: var(--r);
    color: var(--ink-2); text-decoration: none;
    font-weight: 560; font-size: 14.5px;
    transition: background .15s, color .15s;
}
.side-link .i { color: var(--muted); transition: color .15s; }
.side-link:hover { background: var(--surface-3); color: var(--ink); }
.side-link.active { background: var(--primary-soft); color: var(--primary-soft-ink); }
.side-link.active .i { color: var(--primary); }

.folder-tree {
    flex: 1 1 auto; min-height: 96px;
    overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin;
    margin-right: -8px; padding-right: 8px; /* kaydırma çubuğu metnin üstüne binmesin */
}
/* Kısa ekranlarda (dizüstü, yarım pencere) sabit bloklar biraz sıkılaşır → ağaca yer kalır,
   panelin kendisi ikinci bir kaydırma çubuğu açmaz. */
@media (max-height: 820px) {
    .sidebar { gap: 12px; padding-top: 12px; padding-bottom: 12px; }
    .sky-scene { height: 64px; }
    .folder-tree { min-height: 72px; }
}
.tree-title {
    font: 700 11px/1 var(--font); letter-spacing: .08em; text-transform: uppercase;
    color: var(--muted); margin: 0 0 8px 12px;
}
.tree-list { list-style: none; margin: 0; padding: 0; }
.tree-list .tree-list { margin-left: 20px; padding-left: 8px; border-left: 1px solid var(--line); }
.tree-link {
    display: flex; align-items: center; gap: 9px;
    padding: 6px 10px; border-radius: var(--r-sm);
    color: var(--ink-2); text-decoration: none; font-size: 13.5px;
}
.tree-link span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tree-link .i { width: 16px; height: 16px; color: #F59E0B; }
.tree-link:hover { background: var(--surface-3); color: var(--ink); }

/* ---------------------------------------------------------------- quota */
.quota { max-width: 420px; }
.sidebar-quota { margin-top: auto; padding: 14px; border-radius: var(--r-lg); background: var(--surface-2); border: 1px solid var(--line); }
.quota-head { display: flex; justify-content: space-between; font-weight: 650; font-size: 13px; margin-bottom: 8px; }
.quota-pct { font: 600 12px var(--mono); color: var(--muted); }
.quota-bar { height: 8px; border-radius: 99px; background: var(--surface-3); overflow: hidden; }
.quota-fill { height: 100%; border-radius: inherit; background: linear-gradient(90deg, #22D3EE, var(--primary)); transition: width .8s var(--ease); }
.quota-fill.warn { background: linear-gradient(90deg, #FFC53D, #FF9F1C); }
.quota-fill.full { background: linear-gradient(90deg, #FF8A65, var(--danger)); }
.quota-label { margin-top: 7px; font: 12px var(--mono); color: var(--muted); }
.storage-cta {
    display: flex; align-items: center; justify-content: center; gap: 8px;
    margin-top: 12px; padding: 8px; border-radius: var(--r-sm);
    background: var(--surface); border: 1px solid var(--line);
    color: var(--ink-2); font-weight: 600; font-size: 13px; text-decoration: none;
}
.storage-cta .i { width: 16px; height: 16px; }
.storage-cta:hover { border-color: var(--primary); color: var(--primary-soft-ink); }
.storage-cta.urgent { background: var(--danger-soft); border-color: transparent; color: var(--danger); }
.over-quota {
    margin: 10px 0 0; padding: 9px 10px; border-radius: var(--r-sm);
    background: var(--danger-soft); color: var(--danger);
    font-size: 12.5px; line-height: 1.4;
}
.over-quota strong { display: block; margin-bottom: 2px; }

/* ---------------------------------------------------------------- page head */
.page-head {
    display: flex; align-items: flex-end; justify-content: space-between; flex-wrap: wrap; gap: 14px 20px;
    margin-bottom: 20px;
}
.page-head h1 { margin: 0; font-size: 30px; font-weight: 780; line-height: 1.1; overflow-wrap: anywhere; }
.page-sub { margin: 6px 0 0; font: 12.5px var(--mono); color: var(--muted); }
.page-tools { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }

.breadcrumb { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; margin-bottom: 8px; font-size: 13.5px; }
.breadcrumb a { color: var(--muted); text-decoration: none; padding: 2px 6px; margin: 0 -2px; border-radius: 6px; }
.breadcrumb a:hover { color: var(--ink); background: var(--surface-3); }
.crumb-sep { color: var(--line-strong); }
.crumb-current { color: var(--ink-2); font-weight: 600; padding: 2px 4px; }

.segmented { display: inline-flex; padding: 3px; gap: 2px; border-radius: var(--r); background: var(--surface-3); }
.seg {
    display: inline-flex; align-items: center; gap: 7px;
    height: 32px; padding: 0 11px; border: 0; border-radius: var(--r-sm);
    background: transparent; color: var(--muted);
    font: 600 13px var(--font); cursor: pointer;
}
.seg .i { width: 16px; height: 16px; }
.seg:hover { color: var(--ink); }
.seg.active { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-1); }

.new-folder .menu-pop { width: 290px; padding: 14px; }
.new-folder-form { display: grid; gap: 8px; }
.new-folder-form label { font-weight: 600; font-size: 13px; color: var(--ink-2); }
.new-folder-form input { width: 100%; }
.new-folder-form .btn { justify-self: end; }

.info-strip {
    display: flex; align-items: center; gap: 10px;
    margin: 0 0 16px; padding: 11px 14px; border-radius: var(--r);
    background: var(--surface-2); border: 1px solid var(--line);
    color: var(--muted); font-size: 13.5px;
}

/* ---------------------------------------------------------------- selection bar */
.selection-bar {
    position: sticky; top: calc(var(--topbar-h) + 10px); z-index: 40;
    display: flex; align-items: center; flex-wrap: wrap; gap: 8px;
    padding: 8px 10px 8px 16px; margin-bottom: 16px;
    border-radius: 999px;
    background: var(--invert-bg); color: var(--invert-ink);
    box-shadow: var(--shadow-2);
    animation: drop-in .25s var(--ease);
}
#selection-count { font-weight: 700; margin-right: auto; }
.selection-bar .btn { background: transparent; color: inherit; border-color: color-mix(in srgb, currentColor 22%, transparent); border-radius: 999px; }
.selection-bar .btn:hover { background: color-mix(in srgb, currentColor 12%, transparent); }
.selection-bar .btn-danger { color: color-mix(in srgb, var(--danger) 70%, var(--invert-ink)); }
.selection-bar kbd { background: color-mix(in srgb, currentColor 14%, transparent); color: inherit; box-shadow: none; }
@keyframes drop-in { from { opacity: 0; transform: translateY(-8px); } }

/* ---------------------------------------------------------------- list */
.table-wrap { position: relative; }
.file-table {
    width: 100%;
    border-collapse: separate; border-spacing: 0;
    background: var(--surface);
    border: 1px solid var(--line); border-radius: var(--r-lg);
    box-shadow: var(--shadow-1);
}
.file-table th {
    padding: 12px 16px; text-align: left;
    font: 700 11px/1 var(--font); letter-spacing: .07em; text-transform: uppercase;
    color: var(--muted); border-bottom: 1px solid var(--line);
}
.file-table td { padding: 10px 16px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.file-table tbody tr:last-child td { border-bottom: 0; }
.file-table tbody tr:last-child td:first-child { border-bottom-left-radius: var(--r-lg); }
.file-table tbody tr:last-child td:last-child { border-bottom-right-radius: var(--r-lg); }
.file-table tbody tr { transition: background .12s; }
.file-table tbody tr:hover td { background: var(--surface-2); }
.file-table tr.selected td { background: var(--primary-soft) !important; }
.file-table tr.selected td:first-child { box-shadow: inset 3px 0 0 var(--primary); }

.file-name { display: flex; align-items: center; gap: 12px; min-width: 0; }
td.file-name { display: table-cell; }
.file-name > * { vertical-align: middle; }
.name-icon {
    display: inline-grid; place-items: center; flex: none;
    width: 38px; height: 38px; margin-right: 12px; border-radius: 11px;
    background: var(--type-bg); color: var(--type);
    overflow: hidden; position: relative;
}
.name-icon .i { width: 20px; height: 20px; }
.list-thumb { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.name-icon:has(img.list-thumb) .type-emoji { display: none; }
.name-text { color: var(--ink); font-weight: 560; text-decoration: none; overflow-wrap: anywhere; }
a.name-text:hover { color: var(--primary); text-decoration: underline; text-underline-offset: 3px; }
.star-mark { width: 14px; height: 14px; margin-left: 8px; color: var(--star); vertical-align: -2px; }
.col-size, .col-date { white-space: nowrap; }

.row-actions { width: 1%; white-space: nowrap; text-align: right; }
.actions { display: flex; align-items: center; justify-content: flex-end; gap: 2px; }
.actions .quick { opacity: 0; transition: opacity .15s; }
[data-entry-row]:hover .quick, [data-entry-row]:focus-within .quick, [data-entry-row].selected .quick, .quick.starred { opacity: 1; }
@media (hover: none) { .actions .quick { opacity: 1; } }

/* Satır seçimi için metin seçimi kapalı */
[data-entry-row] { user-select: none; }

/* ---------------------------------------------------------------- grid */
.file-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(214px, 1fr)); gap: 18px; }
.file-card {
    position: relative;
    display: flex; flex-direction: column;
    background: var(--surface);
    border: 1px solid var(--line); border-radius: var(--r-lg);
    box-shadow: var(--shadow-1);
    transition: transform .22s var(--spring), box-shadow .22s, border-color .15s;
}
.file-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-2); }
/* Üzerine gelinen kartın transform'u kendi yığın katmanını açar; içindeki "⋯" menüsü o katmanın
   üstüne çıkamaz ve sonraki kart menünün önünde boyanırdı. Menüsü açık kart/satır en üstte. */
.file-card:has(.menu[open]), [data-entry-row]:has(.menu[open]) { position: relative; z-index: 30; }
.file-card.selected { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-soft), var(--shadow-1); }
.card-body { display: block; padding: 10px 10px 4px; color: var(--ink); text-decoration: none; }
.card-thumb {
    position: relative; height: 148px;
    display: grid; place-items: center;
    border-radius: 12px; overflow: hidden;
    background: var(--type-bg);
}
.card-thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .4s var(--ease); }
.file-card:hover .card-thumb img { transform: scale(1.04); }
.card-thumb:has(img) .card-icon { display: none; }
.card-icon { color: var(--type); }
.card-icon .i { width: 46px; height: 46px; stroke-width: 1.4; }
.card-name { display: flex; align-items: center; gap: 8px; margin: 11px 4px 2px; font-weight: 600; min-width: 0; }
.card-name span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.type-ico { width: 16px; height: 16px; color: var(--type); }
.card-body .file-meta { margin: 0 4px 6px 28px; }
.card-actions { padding: 2px 8px 8px; margin-top: auto; }

/* ---------------------------------------------------------------- empty */
.empty-state { display: grid; justify-items: center; text-align: center; padding: 60px 16px; color: var(--muted); }
.empty-art { width: 170px; margin-bottom: 8px; }
.empty-art svg { display: block; width: 100%; }
.ea-cloud { fill: var(--surface-3); stroke: var(--line-strong); stroke-width: 1.5; }
.ea-orb { fill: var(--star); opacity: .85; }
:root[data-theme="night"] .ea-orb { fill: #E9E4FF; }
.ea-line { stroke: var(--line-strong); stroke-width: 1.5; stroke-dasharray: 4 6; }
.empty-art svg { animation: float 6s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-5px); } }
.empty-title { margin: 6px 0 4px; font-size: 17px; font-weight: 650; color: var(--ink); }
.empty-sub { margin: 0; max-width: 420px; font-size: 14px; }
.empty-state .btn { margin-top: 16px; }

/* ---------------------------------------------------------------- modal & dialog */
.modal {
    position: fixed; inset: 0; z-index: 90;
    display: flex; align-items: center; justify-content: center;
    padding: 16px;
    background: var(--scrim);
    backdrop-filter: blur(4px);
    animation: fade .18s;
}
@keyframes fade { from { opacity: 0; } }
.modal-card {
    width: min(460px, 100%); max-height: 86vh;
    display: flex; flex-direction: column;
    padding: 22px;
    background: var(--surface); color: var(--ink);
    border: 1px solid var(--line); border-radius: 20px;
    box-shadow: var(--shadow-2);
    animation: rise .22s var(--spring);
}
@keyframes rise { from { opacity: 0; transform: translateY(12px) scale(.98); } }
.modal-card h2 { margin: 0 0 14px; font-size: 19px; }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; }
.dialog-text { margin: 0 0 4px; color: var(--ink-2); }
.dialog-input { width: 100%; margin-top: 4px; }
.btn-danger-solid { background: var(--danger); color: #fff; box-shadow: 0 6px 16px -8px var(--danger); }
.btn-danger-solid:hover { background: color-mix(in srgb, var(--danger) 85%, #000); }

.picker-tree { flex: 1; min-height: 120px; overflow-y: auto; padding: 6px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface-2); }
.picker-item { display: flex; align-items: center; gap: 8px; padding: 7px 9px; border-radius: var(--r-sm); cursor: pointer; }
.picker-item:hover { background: var(--surface-3); }
.picker-item input { margin: 0; }

#share-modal .modal-card { width: min(520px, 100%); }
.share-section { margin-bottom: 18px; }
.share-section .tree-title { margin-left: 0; }
.share-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.share-row input[type="email"] { flex: 1 1 200px; }
.share-link-result { display: flex; gap: 8px; margin-top: 10px; }
.share-link-result input { flex: 1; font: 12.5px var(--mono); }
.share-list { list-style: none; margin: 0; padding: 0; max-height: 220px; overflow-y: auto; }
.share-item { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; padding: 9px 0; border-bottom: 1px solid var(--line); }
.share-item:last-child { border-bottom: 0; }
.share-who { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.share-item select { height: 32px; }

/* Önizleme: neredeyse tam ekran */
.preview-card { width: 96vw; height: 94vh; max-height: none; padding: 12px; }
.preview-head { display: flex; align-items: center; gap: 6px; padding: 0 2px 10px; border-bottom: 1px solid var(--line); }
.preview-title { margin-right: auto; font-weight: 650; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.preview-body { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; overflow: auto; padding-top: 12px; }
.preview-body img, .preview-body video { max-width: 100%; max-height: 100%; border-radius: var(--r); box-shadow: var(--shadow-2); }
.preview-body audio { width: min(640px, 100%); }
.preview-pdf { width: 100%; height: 100%; border: 0; border-radius: var(--r); background: #fff; }
.preview-text, .preview-sheet { width: 100%; height: 100%; overflow: auto; margin: 0; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface-2); }
.preview-text { padding: 16px; font: 13px/1.6 var(--mono); white-space: pre-wrap; word-break: break-word; color: var(--ink); }
.preview-sheet table { border-collapse: collapse; font-size: 13px; width: max-content; }
.preview-sheet td, .preview-sheet th { border: 1px solid var(--line); padding: 6px 10px; white-space: nowrap; }
.preview-sheet tr:first-child td, .preview-sheet th { position: sticky; top: 0; background: var(--primary-soft); color: var(--primary-soft-ink); font-weight: 650; }
.preview-message, .preview-loading { color: var(--muted); }

/* ---------------------------------------------------------------- toast / upload / drop */
#toast-container {
    position: fixed; left: 50%; bottom: 22px; translate: -50% 0; z-index: 120;
    display: flex; flex-direction: column; align-items: center; gap: 8px;
}
.toast {
    display: flex; align-items: center; gap: 16px;
    padding: 12px 16px 12px 18px; border-radius: 14px;
    background: var(--invert-bg); color: var(--invert-ink);
    box-shadow: var(--shadow-2); font-weight: 500;
    animation: toast-in .3s var(--spring);
}
@keyframes toast-in { from { opacity: 0; transform: translateY(14px) scale(.96); } }
.toast-error { background: var(--danger); color: #fff; }
.toast-undo {
    border: 0; padding: 6px 10px; border-radius: 8px; cursor: pointer;
    background: color-mix(in srgb, currentColor 14%, transparent); color: inherit;
    font-weight: 700;
}
.toast-undo:hover { background: color-mix(in srgb, currentColor 24%, transparent); }

.upload-panel {
    position: fixed; right: 20px; bottom: 20px; z-index: 60;
    width: min(360px, calc(100vw - 32px)); max-height: 52vh; overflow-y: auto;
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg);
    box-shadow: var(--shadow-2);
    animation: rise .25s var(--spring);
}
.upload-panel-head {
    position: sticky; top: 0; display: flex; align-items: center; justify-content: space-between;
    padding: 10px 10px 10px 16px; background: var(--surface); border-bottom: 1px solid var(--line);
    font-weight: 700;
}
.upload-panel-head span { display: inline-flex; align-items: center; gap: 8px; }
#upload-items { list-style: none; margin: 0; padding: 8px 16px 12px; }
.upload-item { padding: 8px 0; }
.upload-item + .upload-item { border-top: 1px solid var(--line); }
.upload-item-row { display: flex; align-items: center; gap: 6px; font-size: 13.5px; }
.upload-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.upload-status { font: 12px var(--mono); color: var(--muted); }
.upload-bar { height: 6px; margin-top: 7px; border-radius: 99px; background: var(--surface-3); overflow: hidden; }
.upload-fill { width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #22D3EE, var(--primary), #FF4D8D); transition: width .2s; }
.upload-item.done .upload-fill { background: var(--success); }
.upload-item.failed .upload-fill { background: var(--danger); }
.upload-item.failed .upload-status { color: var(--danger); }

.drop-overlay {
    position: fixed; inset: 0; z-index: 95;
    display: grid; place-items: center;
    background: color-mix(in srgb, var(--primary) 12%, var(--scrim));
    backdrop-filter: blur(3px);
    pointer-events: none;
}
.drop-overlay::before {
    content: ""; position: absolute; inset: 16px;
    border: 3px dashed var(--primary); border-radius: 26px;
    animation: dash-pulse 1.4s ease-in-out infinite;
}
@keyframes dash-pulse { 50% { opacity: .5; } }
.drop-overlay:not(.hidden) { pointer-events: auto; }
.drop-message {
    position: relative;
    display: grid; justify-items: center; gap: 6px;
    padding: 26px 36px; border-radius: 22px;
    background: var(--surface); color: var(--ink);
    box-shadow: var(--shadow-2); text-align: center;
    animation: rise .25s var(--spring);
}
.drop-message .i { width: 40px; height: 40px; color: var(--primary); animation: bob 1s ease-in-out infinite; }
.drop-message strong { font-size: 19px; }
.drop-message span { color: var(--muted); font-size: 13.5px; }
@keyframes bob { 50% { transform: translateY(-5px); } }

/* ---------------------------------------------------------------- admin / storage / misc */
.admin-nav { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 20px; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.stat-card { padding: 18px 20px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-1); }
.stat-value { font: 780 28px/1.1 var(--display); color: var(--ink); letter-spacing: -.02em; }
.stat-label { margin-top: 6px; font-size: 13px; color: var(--muted); }
.section-title { margin: 30px 0 12px; font-size: 18px; }
.lead-note { max-width: 72ch; margin: 0 0 6px; color: var(--muted); font-size: 14.5px; line-height: 1.65; }
.lead-note code { font: 12.5px var(--mono); padding: 1px 6px; border-radius: 6px; background: var(--surface-3); color: var(--ink-2); }
.content > h1 { font-size: 30px; font-weight: 780; margin: 0 0 18px; }

.plan-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; margin: 18px 0; }
.plan-card {
    display: flex; flex-direction: column; align-items: center; text-align: center;
    padding: 24px 20px; border-radius: var(--r-lg);
    background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-1);
    transition: transform .22s var(--spring), box-shadow .22s, border-color .15s;
}
.plan-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-2); border-color: var(--primary); }
.plan-name { font: 780 22px/1.1 var(--display); }
.plan-size { margin: 4px 0 14px; color: var(--muted); }
.plan-price { margin-bottom: 16px; font: 800 38px/1 var(--display); color: var(--primary); }
.plan-price-note { display: block; margin-top: 4px; font: 500 12.5px var(--font); color: var(--muted); }
.plan-card form { width: 100%; }
.plan-card .btn { width: 100%; }

.sub-list { display: grid; gap: 10px; }
.sub-card {
    display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr) auto; align-items: center; gap: 16px;
    padding: 16px 18px; border-radius: var(--r-lg);
    background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-1);
    border-left: 4px solid var(--success);
}
.sub-card.is-canceled { border-left-color: var(--warning); }
.sub-card .plan-name { font-size: 19px; }
.sub-state { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.sub-card form { margin: 0; }
.sub-ended { padding-left: 1.1rem; }

/* Admin plan tablosu gibi sayfalarda form satırları */
.content .share-section input, .content .share-section select { margin-right: 6px; }

/* ---------------------------------------------------------------- oturumsuz sayfalar */
body.anon .content {
    display: grid; justify-items: center; align-content: center;
    min-height: calc(100vh - var(--topbar-h));
    max-width: none; padding: 40px 16px;
}
body.anon .form-card { box-shadow: var(--shadow-2); }
body.anon .brand { width: auto; }
body.anon .content > .empty-state { max-width: 520px; }

/* ---------------------------------------------------------------- responsive */
@media (max-width: 1020px) {
    .nav-toggle { display: inline-grid; }
    .brand { width: auto; }
    .sidebar {
        position: fixed; z-index: 85; top: 0; left: 0;
        height: 100vh; height: 100dvh;
        background: var(--bg); box-shadow: var(--shadow-2);
        transform: translateX(-105%);
        transition: transform .28s var(--ease);
    }
    body.nav-open .sidebar { transform: none; }
    .nav-scrim { position: fixed; inset: 0; z-index: 80; background: var(--scrim); opacity: 0; pointer-events: none; transition: opacity .25s; }
    body.nav-open .nav-scrim { opacity: 1; pointer-events: auto; }
    .content { padding: 22px 22px 90px; }
}

@media (max-width: 640px) {
    .topbar { gap: 8px; padding: 0 10px; }
    .brand-name, .search-kbd { display: none; }
    .search-form input { padding-right: 14px; }
    .content { padding: 18px 14px 90px; }
    .page-head { align-items: flex-start; }
    .page-head h1 { font-size: 25px; }
    .page-tools { width: 100%; }
    .seg span { display: none; }
    .col-size, .col-date { display: none; }
    .file-table td, .file-table th { padding: 10px 10px; }
    .name-icon { width: 34px; height: 34px; margin-right: 10px; }
    .actions .quick { display: none; }
    .file-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
    .card-thumb { height: 116px; }
    .selection-bar { border-radius: 18px; }
    .sub-card { grid-template-columns: 1fr; }
    .form-card { padding: 22px; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ---------------------------------------------------------------- video kareleri (istemcide çözülür) */
.video-thumb { position: absolute; inset: 0; opacity: 0; transition: opacity .3s; }
.video-thumb.ready { opacity: 1; }
.video-thumb video { width: 100%; height: 100%; object-fit: cover; display: block; }
.card-thumb:has(.video-thumb.ready) .card-icon,
.name-icon:has(.video-thumb.ready) .type-emoji { display: none; }
.card-thumb .video-thumb.ready::after {
    content: ""; position: absolute; left: 10px; bottom: 10px;
    width: 26px; height: 26px; border-radius: 50%;
    background: rgba(13, 10, 38, .6) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M9 7v10l8-5z' fill='white'/%3E%3C/svg%3E") center / 16px no-repeat;
    backdrop-filter: blur(4px);
    transition: opacity .2s;
}
.file-card:hover .video-thumb.ready::after { opacity: 0; }

/* ---------------------------------------------------------------- sürükleyerek seçim */
.select-band {
    position: fixed; z-index: 45; pointer-events: none;
    border: 1.5px solid var(--primary); border-radius: 6px;
    background: color-mix(in srgb, var(--primary) 14%, transparent);
}
body.is-band-selecting, body.is-band-selecting * { user-select: none !important; cursor: crosshair; }

/* ---------------------------------------------------------------- yarım kalan yükleme şeridi */
.resume-strip {
    display: flex; align-items: center; flex-wrap: wrap; gap: 10px;
    margin: -6px 0 18px; padding: 10px 12px 10px 16px; border-radius: var(--r);
    background: var(--warning-soft); color: var(--ink);
    border: 1px solid color-mix(in srgb, var(--warning) 30%, transparent);
    animation: drop-in .3s var(--ease);
}
.resume-strip span { flex: 1 1 260px; font-size: 14px; }

/* ---------------------------------------------------------------- herkese açık paylaşım sayfası */
.share-page { width: 100%; max-width: 1180px; justify-self: stretch; margin: 0 auto; }
body.anon .content:has(.share-page) { align-content: start; justify-items: stretch; }
.share-head {
    display: flex; align-items: center; flex-wrap: wrap; gap: 16px 20px;
    padding: 22px; margin-bottom: 18px;
    background: var(--surface); border: 1px solid var(--line); border-radius: 22px;
    box-shadow: var(--shadow-1);
}
.share-head-icon {
    display: grid; place-items: center; flex: none;
    width: 58px; height: 58px; border-radius: 16px;
    background: var(--type-bg, var(--primary-soft)); color: var(--type, var(--primary));
}
.share-head-icon .i { width: 28px; height: 28px; }
.share-head-text { flex: 1; min-width: 0; }
.share-head-text h1 { margin: 2px 0 0; font-size: 26px; font-weight: 780; overflow-wrap: anywhere; }
.share-kicker { display: inline-flex; align-items: center; gap: 6px; margin: 0; font: 700 11.5px/1 var(--font); letter-spacing: .08em; text-transform: uppercase; color: var(--primary-soft-ink); }
.share-kicker .i { width: 14px; height: 14px; }
.share-file { display: grid; place-items: center; }
.share-media { max-width: 100%; max-height: 72vh; border-radius: var(--r-lg); box-shadow: var(--shadow-2); background: #000; }
.share-pdf { width: 100%; height: 76vh; border: 0; border-radius: var(--r-lg); background: #fff; box-shadow: var(--shadow-1); }
.share-audio { display: flex; align-items: center; gap: 14px; width: min(560px, 100%); padding: 22px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); }
.share-audio .i { width: 28px; height: 28px; color: #06B6D4; }
.share-audio audio { flex: 1; }
.share-file-card {
    display: grid; justify-items: center; gap: 8px; text-align: center;
    width: min(440px, 100%); padding: 36px 24px; border-radius: 22px;
    background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-1);
}
.share-file-icon { display: grid; place-items: center; width: 76px; height: 76px; border-radius: 20px; background: var(--type-bg); color: var(--type); margin-bottom: 6px; }
.share-file-icon .i { width: 38px; height: 38px; stroke-width: 1.5; }
.share-file-actions { display: flex; gap: 8px; margin-top: 12px; }
.share-browse[data-view="list"] .view-grid, .share-browse[data-view="grid"] .view-list { display: none; }
.share-foot { margin: 28px 0 0; text-align: center; font-size: 13px; color: var(--muted); }
.share-foot a { color: var(--primary-soft-ink); }
.share-items { display: block; margin-top: 2px; }
