/* SullyTransfer UI — deliberately dependency-free. */
:root {
  color-scheme: dark;
  --bg: #f5f6fa;
  --bg-raised: #fafbfe;
  --surface: rgba(255, 255, 255, .9);
  --surface-solid: #fff;
  --surface-soft: #f8f8fc;
  --surface-hover: #f2f0fb;
  --text: #191827;
  --text-soft: #5f6071;
  --text-faint: #8d8d9d;
  --border: #e8e7ef;
  --border-strong: #dad8e5;
  --brand: #7454e8;
  --brand-deep: #5734d1;
  --brand-soft: #eee9ff;
  --brand-faint: #f7f4ff;
  --blue: #4b8bf5;
  --green: #20a879;
  --green-soft: #e7f8f2;
  --amber: #db8b20;
  --amber-soft: #fff5df;
  --red: #dc5362;
  --red-soft: #fff0f2;
  --shadow-sm: 0 1px 2px rgba(21, 19, 34, .04), 0 7px 20px rgba(31, 25, 60, .035);
  --shadow-md: 0 2px 4px rgba(21, 19, 34, .04), 0 16px 50px rgba(38, 31, 75, .08);
  --shadow-lg: 0 24px 70px rgba(25, 19, 53, .17);
  --ring: 0 0 0 3px rgba(116, 84, 232, .22);
  --radius-sm: 9px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --header-h: 72px;
  --content-w: 1220px;
  --ease: cubic-bezier(.22, 1, .36, 1);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #111018;
  --bg-raised: #16151f;
  --surface: rgba(28, 27, 39, .92);
  --surface-solid: #1c1b27;
  --surface-soft: #22212e;
  --surface-hover: #2a2838;
  --text: #f1f0f6;
  --text-soft: #b4b2c1;
  --text-faint: #858391;
  --border: #302e3c;
  --border-strong: #403d4d;
  --brand: #9a7af8;
  --brand-deep: #8260ed;
  --brand-soft: #32294e;
  --brand-faint: #252034;
  --blue: #70a3fa;
  --green: #48c79a;
  --green-soft: #17372e;
  --amber: #efac4f;
  --amber-soft: #382d1d;
  --red: #f17986;
  --red-soft: #3d2229;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .12), 0 9px 24px rgba(0, 0, 0, .12);
  --shadow-md: 0 2px 4px rgba(0, 0, 0, .16), 0 18px 48px rgba(0, 0, 0, .2);
  --shadow-lg: 0 24px 80px rgba(0, 0, 0, .38);
  --ring: 0 0 0 3px rgba(154, 122, 248, .25);
}

* { box-sizing: border-box; }
html { min-width: 320px; scroll-behavior: smooth; }
body { margin: 0; min-height: 100vh; background: var(--bg); color: var(--text); font-size: 16px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
body::before { content: ""; position: fixed; inset: 0; z-index: -2; pointer-events: none; background: radial-gradient(circle at 9% 4%, rgba(126, 91, 235, .05), transparent 24%), radial-gradient(circle at 95% 90%, rgba(77, 139, 245, .04), transparent 22%); }
button, input, select, textarea { font: inherit; }
button, select { cursor: pointer; }
button { color: inherit; }
a { color: inherit; }
img, svg { display: block; }
[hidden] { display: none !important; }
::selection { background: rgba(116, 84, 232, .25); }
:focus { outline: none; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; }
input:focus-visible, select:focus-visible { outline: none; }

.visually-hidden { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important; overflow: hidden !important; clip: rect(0, 0, 0, 0) !important; white-space: nowrap !important; border: 0 !important; }
.skip-link { position: fixed; left: 18px; top: 12px; z-index: 1000; padding: 9px 14px; border-radius: 8px; background: var(--text); color: var(--surface-solid); transform: translateY(-150%); transition: transform .2s; text-decoration: none; font-weight: 700; }
.skip-link:focus { transform: translateY(0); }
.surface { background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow-sm); }

/* Brand */
.brand { display: inline-flex; align-items: center; gap: 10px; min-width: max-content; text-decoration: none; }
.brand-mark { position: relative; display: inline-block; width: 34px; height: 34px; overflow: hidden; border-radius: 10px; background: linear-gradient(145deg, #9273f7, #603cd9); box-shadow: 0 7px 17px rgba(91, 57, 211, .25); }
.brand-mark::before, .brand-mark::after { content: ""; position: absolute; left: 8px; width: 19px; height: 7px; background: #fff; transform: skewX(-34deg); }
.brand-mark::before { top: 8px; border-radius: 3px 4px 2px 3px; }
.brand-mark::after { bottom: 8px; opacity: .76; border-radius: 2px 3px 3px 4px; }
.brand-arrow::before, .brand-arrow::after { content: ""; position: absolute; z-index: 2; width: 0; height: 0; border-style: solid; }
.brand-arrow::before { right: 6px; top: 7px; border-width: 4px 0 4px 5px; border-color: transparent transparent transparent #dcd2ff; }
.brand-arrow::after { left: 6px; bottom: 7px; border-width: 4px 5px 4px 0; border-color: transparent #dcd2ff transparent transparent; }
.brand-word { display: flex; align-items: baseline; letter-spacing: -.45px; font-size: 18px; }
.brand-word strong { font-weight: 790; }
.brand-word span { color: var(--text-soft); font-weight: 480; }

/* App chrome */
.app-header { position: sticky; top: 0; z-index: 100; height: var(--header-h); background: color-mix(in srgb, var(--bg) 84%, transparent); border-bottom: 1px solid color-mix(in srgb, var(--border) 85%, transparent); -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px); }
.header-inner { width: min(var(--content-w), calc(100% - 48px)); height: 100%; margin: auto; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 24px; }
.main-nav { align-self: stretch; display: flex; align-items: center; gap: 6px; }
.nav-link { position: relative; display: flex; align-items: center; gap: 8px; padding: 9px 13px; border-radius: 10px; color: var(--text-soft); font-size: 15px; font-weight: 650; text-decoration: none; transition: color .2s, background .2s; }
.nav-link svg { width: 17px; height: 17px; fill: currentColor; }
.nav-link:hover { color: var(--text); background: var(--surface-soft); }
.nav-link.is-active { color: var(--brand-deep); background: var(--brand-soft); }
:root[data-theme="dark"] .nav-link.is-active { color: #baa6ff; }
.nav-link.is-active::after { content: ""; position: absolute; left: 14px; right: 14px; bottom: -18px; height: 2px; background: var(--brand); border-radius: 4px 4px 0 0; }
.header-actions { justify-self: end; display: flex; align-items: center; gap: 9px; }
.icon-button { width: 38px; height: 38px; padding: 0; display: inline-grid; place-items: center; flex: 0 0 auto; border: 1px solid var(--border); border-radius: 10px; background: var(--surface-solid); color: var(--text-soft); transition: border-color .2s, background .2s, color .2s, transform .2s; }
.icon-button:hover { border-color: var(--border-strong); background: var(--surface-hover); color: var(--text); }
.icon-button:active { transform: scale(.96); }
.icon-button svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon-button.compact { width: 31px; height: 31px; border-radius: 8px; }
.icon-button.compact svg { width: 16px; height: 16px; }
.theme-icon { fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.8; }
.theme-icon-moon { display: none; }
:root[data-theme="dark"] .theme-icon-sun { display: none; }
:root[data-theme="dark"] .theme-icon-moon { display: block; }
.profile-menu { position: relative; }
.profile-menu summary { list-style: none; }
.profile-menu summary::-webkit-details-marker { display: none; }
.profile-trigger { display: flex; align-items: center; gap: 9px; padding: 4px 6px 4px 4px; min-width: 166px; border: 1px solid transparent; border-radius: 11px; cursor: pointer; transition: background .2s, border-color .2s; }
.profile-trigger:hover, .profile-menu[open] .profile-trigger { background: var(--surface-solid); border-color: var(--border); }
.avatar { width: 34px; height: 34px; display: inline-grid; place-items: center; flex: 0 0 auto; border-radius: 10px; background: linear-gradient(145deg, var(--brand-soft), #dfe9ff); color: var(--brand-deep); font-size: 14px; font-weight: 800; text-transform: uppercase; }
:root[data-theme="dark"] .avatar { background: linear-gradient(145deg, #41355f, #273c5c); color: #c9bbff; }
.profile-copy { display: flex; min-width: 0; flex-direction: column; line-height: 1.25; }
.profile-copy strong { max-width: 100px; overflow: hidden; text-overflow: ellipsis; font-size: 14px; white-space: nowrap; }
.profile-copy small { color: var(--text-faint); font-size: 13px; }
.profile-trigger > svg { width: 14px; height: 14px; margin-left: auto; fill: none; stroke: currentColor; stroke-width: 1.6; }
.profile-menu[open] .profile-trigger > svg { transform: rotate(180deg); }
.profile-popover { position: absolute; top: calc(100% + 11px); right: 0; z-index: 10; width: 250px; padding: 8px; border: 1px solid var(--border); border-radius: 15px; background: var(--surface-solid); box-shadow: var(--shadow-lg); animation: pop-in .2s var(--ease); }
.profile-popover-head { display: flex; gap: 10px; align-items: center; padding: 10px 9px 13px; margin-bottom: 6px; border-bottom: 1px solid var(--border); }
.avatar-large { width: 40px; height: 40px; border-radius: 12px; }
.profile-popover-head > div { display: flex; min-width: 0; flex-direction: column; }
.profile-popover-head strong, .profile-popover-head span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.profile-popover-head strong { font-size: 14px; }
.profile-popover-head span { color: var(--text-faint); font-size: 13px; }
.profile-popover a, .menu-button { width: 100%; padding: 9px 10px; display: flex; align-items: center; gap: 10px; border: 0; border-radius: 9px; background: transparent; color: var(--text-soft); text-decoration: none; font-size: 14px; font-weight: 600; }
.profile-popover a:hover, .menu-button:hover { background: var(--surface-soft); color: var(--text); }
.profile-popover a svg, .menu-button svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

.app-main { min-height: calc(100vh - var(--header-h)); }
.page-shell { width: min(var(--content-w), calc(100% - 48px)); margin: 0 auto; padding: 46px 0 72px; }
.page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 32px; margin-bottom: 30px; }
.page-heading h1 { margin: 5px 0 8px; font-size: clamp(29px, 3vw, 42px); line-height: 1.08; letter-spacing: -1.5px; font-weight: 780; }
.page-heading h1 em { color: var(--brand); font-family: Georgia, serif; font-weight: 500; }
.page-heading p { max-width: 660px; margin: 0; color: var(--text-soft); font-size: 16px; }
.eyebrow { display: flex; align-items: center; gap: 8px; color: var(--brand-deep); font-size: 13px; font-weight: 800; letter-spacing: .11em; text-transform: uppercase; }
:root[data-theme="dark"] .eyebrow { color: #b7a4ff; }
.eyebrow > span { width: 18px; height: 2px; border-radius: 2px; background: currentColor; }

/* Buttons, fields and reusable controls */
.button { min-height: 40px; padding: 9px 16px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid transparent; border-radius: 10px; text-decoration: none; font-size: 14px; font-weight: 720; line-height: 1.2; white-space: nowrap; transition: transform .18s, box-shadow .18s, background .18s, border-color .18s, color .18s; }
.button:hover { transform: translateY(-1px); }
.button:active { transform: translateY(0) scale(.98); }
.button:disabled { cursor: not-allowed; opacity: .48; transform: none; }
.button svg { width: 17px; height: 17px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.button-primary { background: linear-gradient(145deg, #8061ed, #6542db); color: #fff; box-shadow: 0 7px 17px rgba(91, 57, 211, .18); }
.button-primary:hover:not(:disabled) { background: linear-gradient(145deg, #896cf0, #5c38d2); box-shadow: 0 10px 23px rgba(91, 57, 211, .27); }
.button-secondary { border-color: var(--border-strong); background: var(--surface-solid); color: var(--text); }
.button-secondary:hover:not(:disabled) { background: var(--surface-hover); border-color: color-mix(in srgb, var(--brand) 35%, var(--border)); }
.button-ghost { background: transparent; color: var(--text-soft); }
.button-ghost:hover:not(:disabled) { background: var(--surface-hover); color: var(--text); }
.button-danger { background: var(--red); color: #fff; }
.button-subtle-danger { background: transparent; color: var(--red); }
.button-subtle-danger:hover:not(:disabled) { background: var(--red-soft); }
.button-wide { width: 100%; }
.button-large { min-height: 50px; padding: 13px 20px; border-radius: 12px; font-size: 15px; }
.button-small { min-height: 33px; padding: 7px 11px; border-radius: 8px; font-size: 14px; }
.button-spinner { display: none; width: 15px; height: 15px; border: 2px solid rgba(255, 255, 255, .42); border-top-color: #fff; border-radius: 50%; animation: spin .7s linear infinite; }
.button.is-loading .button-spinner { display: inline-block; }
.button.is-loading > svg, .button.is-loading > span:not(.button-spinner) { display: none; }
.field { display: flex; flex-direction: column; gap: 7px; }
.field-label, .field-label-row { color: var(--text); font-size: 14px; font-weight: 720; }
.field-label small { margin-left: 4px; color: var(--text-faint); font-weight: 500; }
.input-wrap { position: relative; display: flex; align-items: center; min-height: 44px; border: 1px solid var(--border-strong); border-radius: 10px; background: var(--surface-solid); transition: border-color .2s, box-shadow .2s, background .2s; }
.input-wrap:focus-within { border-color: var(--brand); box-shadow: var(--ring); }
.input-wrap > svg { width: 18px; height: 18px; flex: 0 0 auto; margin-left: 13px; color: var(--text-faint); fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.input-wrap input { width: 100%; min-width: 0; padding: 10px 13px; border: 0; outline: 0; background: transparent; color: var(--text); }
.input-wrap > svg + input { padding-left: 9px; }
.input-wrap input::placeholder, .search-field input::placeholder { color: color-mix(in srgb, var(--text-faint) 83%, transparent); }
.input-wrap-plain > input { padding-left: 13px; }
.input-wrap.is-readonly { background: var(--surface-soft); }
.input-wrap.is-readonly input { color: var(--text-soft); cursor: default; }
.input-action { width: 42px; height: 42px; display: grid; place-items: center; border: 0; background: none; color: var(--text-faint); }
.input-action:hover { color: var(--text); }
.input-action svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.input-action .eye-closed { display: none; }
.input-action.is-visible .eye-open { display: none; }
.input-action.is-visible .eye-closed { display: block; }
.field-error { min-height: 0; color: var(--red); font-size: 13px; }
.field-help { color: var(--text-faint); font-size: 13px; }
.select-wrap { position: relative; display: flex; align-items: center; }
.select-wrap select { width: 100%; height: 44px; padding: 0 38px 0 12px; appearance: none; border: 1px solid var(--border-strong); border-radius: 10px; outline: 0; background: var(--surface-solid); color: var(--text); }
.select-wrap select:focus { border-color: var(--brand); box-shadow: var(--ring); }
.select-wrap svg { position: absolute; right: 12px; width: 16px; height: 16px; pointer-events: none; fill: none; stroke: var(--text-soft); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.check-row { display: flex; align-items: center; gap: 9px; cursor: pointer; color: var(--text-soft); font-size: 14px; }
.check-row input { position: absolute; opacity: 0; pointer-events: none; }
.custom-check { width: 18px; height: 18px; display: grid; place-items: center; flex: 0 0 auto; border: 1px solid var(--border-strong); border-radius: 5px; background: var(--surface-solid); transition: background .2s, border-color .2s, box-shadow .2s; }
.custom-check svg { width: 12px; height: 12px; fill: none; stroke: #fff; stroke-width: 2.3; stroke-linecap: round; stroke-linejoin: round; opacity: 0; }
.check-row input:checked + .custom-check { border-color: var(--brand); background: var(--brand); }
.check-row input:checked + .custom-check svg { opacity: 1; }
.check-row input:focus-visible + .custom-check { box-shadow: var(--ring); }
.switch { position: relative; display: inline-flex; flex: 0 0 auto; }
.switch input { position: absolute; opacity: 0; }
.switch > span { position: relative; width: 42px; height: 24px; border-radius: 20px; background: var(--border-strong); transition: background .22s; }
.switch > span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 2px 6px rgba(0, 0, 0, .18); transition: transform .25s var(--ease); }
.switch input:checked + span { background: var(--brand); }
.switch input:checked + span::after { transform: translateX(18px); }
.switch input:focus-visible + span { box-shadow: var(--ring); }
.text-button { padding: 5px; display: inline-flex; align-items: center; gap: 5px; border: 0; background: none; color: var(--brand-deep); font-size: 14px; font-weight: 700; }
:root[data-theme="dark"] .text-button { color: #b9a8ff; }
.text-button svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; }

/* Flash messages, toasts and modals */
.flash-stack { position: fixed; z-index: 300; top: calc(var(--header-h) + 15px); left: 50%; width: min(450px, calc(100% - 30px)); transform: translateX(-50%); display: grid; gap: 8px; }
.flash { min-height: 47px; padding: 9px 10px 9px 14px; display: flex; align-items: center; gap: 10px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-solid); box-shadow: var(--shadow-md); color: var(--text-soft); font-size: 14px; animation: slide-down .35s var(--ease); }
.flash > span:nth-child(2) { flex: 1; }
.flash-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--blue); }
.flash-success .flash-dot { background: var(--green); }
.flash-error .flash-dot, .flash-danger .flash-dot { background: var(--red); }
.toast-region { position: fixed; right: 20px; bottom: 20px; z-index: 500; width: min(360px, calc(100% - 40px)); display: grid; gap: 9px; pointer-events: none; }
.toast { padding: 12px 14px; display: flex; align-items: center; gap: 11px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-solid); box-shadow: var(--shadow-lg); color: var(--text); font-size: 14px; pointer-events: auto; animation: toast-in .35s var(--ease); }
.toast.is-leaving { animation: toast-out .25s ease forwards; }
.toast-icon { width: 24px; height: 24px; display: grid; place-items: center; flex: none; border-radius: 50%; background: var(--green-soft); color: var(--green); }
.toast-error .toast-icon { background: var(--red-soft); color: var(--red); }
.toast-icon svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2.3; stroke-linecap: round; stroke-linejoin: round; }
.toast div { min-width: 0; flex: 1; }
.toast strong, .toast span { display: block; }
.toast strong { font-size: 14px; }
.toast span { overflow-wrap: anywhere; color: var(--text-soft); font-size: 13px; }
dialog { color: var(--text); }
.modal { width: min(480px, calc(100% - 30px)); max-height: calc(100dvh - 30px); padding: 0; overflow: auto; border: 1px solid var(--border); border-radius: 20px; background: var(--surface-solid); box-shadow: var(--shadow-lg); }
.modal::backdrop { background: rgba(15, 12, 27, .52); -webkit-backdrop-filter: blur(5px); backdrop-filter: blur(5px); }
.modal[open] { animation: modal-in .28s var(--ease); }
.modal > form { position: relative; margin: 0; padding: 30px; }
.modal h2 { margin: 12px 0 7px; font-size: 21px; letter-spacing: -.5px; }
.modal h2 + p { margin: 0 0 23px; color: var(--text-soft); font-size: 14px; }
.modal-icon { width: 45px; height: 45px; display: grid; place-items: center; border-radius: 14px; }
.modal-icon svg { width: 23px; height: 23px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.modal-icon-danger { background: var(--red-soft); color: var(--red); }
.modal-icon-brand { background: var(--brand-soft); color: var(--brand); }
.modal-close { position: absolute; top: 18px; right: 18px; border-color: transparent; background: transparent; }
.modal-actions { margin-top: 25px; display: flex; justify-content: flex-end; gap: 9px; }
.confirm-modal { width: min(410px, calc(100% - 30px)); }

/* Authentication */
.auth-shell { min-height: 100vh; display: grid; grid-template-columns: minmax(420px, 44%) 1fr; background: var(--surface-solid); }
.auth-panel { position: relative; min-height: 100vh; padding: 37px clamp(36px, 6vw, 90px); display: flex; flex-direction: column; }
.auth-brand { align-self: flex-start; }
.auth-content { width: min(390px, 100%); margin: auto; padding: 50px 0 80px; }
.auth-content h1 { margin: 10px 0 5px; font-size: clamp(33px, 4vw, 44px); line-height: 1.12; letter-spacing: -1.6px; }
.auth-lead { margin: 0 0 32px; color: var(--text-soft); }
.auth-form { display: grid; gap: 19px; }
.auth-form .check-row { margin: -1px 0 1px; }
.auth-footnote { margin: 24px 0 0; display: flex; align-items: flex-start; gap: 8px; color: var(--text-faint); font-size: 13px; }
.auth-footnote svg { width: 16px; height: 16px; flex: none; fill: none; stroke: var(--green); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.auth-theme { position: absolute; left: clamp(36px, 6vw, 90px); bottom: 28px; }
.auth-visual { position: relative; min-height: 100vh; overflow: hidden; background: linear-gradient(145deg, #26203b, #171524 57%, #211936); color: #fff; }
.visual-grid { position: absolute; inset: 0; opacity: .11; background-image: linear-gradient(rgba(255,255,255,.2) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.2) 1px, transparent 1px); background-size: 48px 48px; mask-image: linear-gradient(to bottom right, #000, transparent 85%); }
.visual-orb { position: absolute; border-radius: 50%; filter: blur(1px); }
.visual-orb-one { width: 560px; height: 560px; right: -180px; top: -170px; background: radial-gradient(circle at 40% 40%, rgba(145, 105, 255, .65), rgba(102, 68, 214, .05) 68%, transparent 70%); }
.visual-orb-two { width: 380px; height: 380px; left: -170px; bottom: -100px; background: radial-gradient(circle, rgba(64, 135, 245, .25), transparent 70%); }
.visual-copy { position: absolute; left: clamp(55px, 8vw, 120px); top: 17%; z-index: 2; width: min(590px, calc(100% - 110px)); }
.visual-badge { display: inline-flex; align-items: center; gap: 8px; padding: 7px 11px; border: 1px solid rgba(255,255,255,.13); border-radius: 20px; background: rgba(255,255,255,.07); color: rgba(255,255,255,.76); font-size: 13px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; backdrop-filter: blur(10px); }
.visual-badge span { width: 6px; height: 6px; border-radius: 50%; background: #a38cff; box-shadow: 0 0 0 4px rgba(163,140,255,.12); }
.visual-copy h2 { margin: 24px 0 15px; font-size: clamp(37px, 5vw, 68px); line-height: 1.04; letter-spacing: -2.5px; }
.visual-copy h2 em { color: #ad96ff; font-family: Georgia, serif; font-weight: 400; }
.visual-copy p { width: min(490px, 100%); color: rgba(255,255,255,.59); font-size: 16px; line-height: 1.7; }
.visual-transfer-card { position: absolute; z-index: 3; display: flex; align-items: center; gap: 12px; border: 1px solid rgba(255,255,255,.14); border-radius: 17px; background: rgba(255,255,255,.09); box-shadow: 0 20px 50px rgba(0,0,0,.21); backdrop-filter: blur(18px); }
.card-one { left: clamp(50px, 9vw, 140px); right: 18%; bottom: 20%; padding: 17px 18px 22px; transform: rotate(-1.5deg); }
.card-two { right: 8%; bottom: 10%; padding: 14px 17px; transform: rotate(2.5deg); }
.mini-file-icon { width: 39px; height: 39px; display: grid; place-items: center; flex: none; border-radius: 11px; background: linear-gradient(145deg, rgba(151,116,255,.35), rgba(102,67,219,.24)); }
.mini-file-icon::before { content: ""; width: 0; height: 0; margin-left: 3px; border-top: 7px solid transparent; border-bottom: 7px solid transparent; border-left: 11px solid #c7b8ff; }
.mini-file-copy { min-width: 0; display: flex; flex: 1; flex-direction: column; }
.mini-file-copy strong { overflow: hidden; text-overflow: ellipsis; font-size: 14px; white-space: nowrap; }
.mini-file-copy span { color: rgba(255,255,255,.5); font-size: 13px; }
.visual-transfer-card > b { color: #bba8ff; font-size: 14px; }
.mini-progress { position: absolute; right: 18px; bottom: 10px; left: 69px; height: 3px; overflow: hidden; border-radius: 4px; background: rgba(255,255,255,.1); }
.mini-progress i { display: block; width: 72%; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #8768ee, #b5a0ff); }
.mini-success { width: 33px; height: 33px; display: grid; place-items: center; flex: none; border-radius: 50%; background: rgba(80,210,162,.17); color: #72dbb4; }
.mini-success svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.visual-lock { position: absolute; right: 11%; top: 12%; width: 54px; height: 54px; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.13); border-radius: 16px; background: rgba(255,255,255,.08); color: rgba(255,255,255,.75); transform: rotate(8deg); backdrop-filter: blur(12px); }
.visual-lock svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.6; }

/* Dashboard upload composer */
.dashboard-heading { margin-bottom: 27px; }
.storage-chip { min-width: 190px; padding: 11px 13px; display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 3px 9px; border: 1px solid var(--border); border-radius: 13px; background: var(--surface); box-shadow: var(--shadow-sm); }
.storage-chip > svg { grid-row: 1 / 3; width: 24px; height: 24px; color: var(--brand); fill: none; stroke: currentColor; stroke-width: 1.6; }
.storage-chip > span { display: flex; align-items: baseline; gap: 4px; color: var(--text-faint); font-size: 13px; }
.storage-chip > span strong { color: var(--text); font-size: 14px; }
.storage-chip > i { height: 3px; overflow: hidden; border-radius: 4px; background: var(--border); }
.storage-chip > i b { display: block; width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--brand), var(--blue)); transition: width .5s var(--ease); }
.upload-composer { position: relative; display: flex; overflow: hidden; border-radius: var(--radius-lg); }
.composer-main { min-width: 0; flex: 1; padding: 25px 27px 0; }
.section-heading > div { display: flex; align-items: center; gap: 12px; }
.compact-heading { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-bottom: 20px; }
.compact-heading h2 { margin: 0 0 2px; font-size: 16px; letter-spacing: -.2px; }
.compact-heading p { margin: 0; color: var(--text-faint); font-size: 13px; }
.heading-icon { width: 39px; height: 39px; display: grid; place-items: center; flex: none; border-radius: 12px; }
.heading-icon-upload { background: var(--brand-soft); color: var(--brand); }
.heading-icon svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.secure-label { padding: 5px 8px; display: inline-flex; align-items: center; gap: 5px; border-radius: 7px; background: var(--green-soft); color: var(--green); font-size: 13px; font-weight: 750; }
.secure-label svg { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.upload-form { display: grid; }
.drop-zone { position: relative; min-height: 194px; padding: 28px 22px; display: flex; flex-direction: column; align-items: center; justify-content: center; overflow: hidden; border: 1.5px dashed color-mix(in srgb, var(--brand) 43%, var(--border)); border-radius: 15px; background: linear-gradient(145deg, var(--brand-faint), color-mix(in srgb, var(--surface-soft) 78%, transparent)); cursor: pointer; transition: border-color .25s, background .25s, transform .25s, box-shadow .25s; }
.drop-zone::before { content: ""; position: absolute; width: 210px; height: 210px; border-radius: 50%; background: radial-gradient(circle, rgba(116,84,232,.08), transparent 70%); }
.drop-zone:hover, .drop-zone.is-dragover { border-color: var(--brand); background: color-mix(in srgb, var(--brand-soft) 48%, var(--surface-solid)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brand) 12%, transparent); }
.drop-zone.is-dragover { transform: scale(1.004); }
.drop-zone:focus-within { border-color: var(--brand); box-shadow: var(--ring); }
.drop-art { position: relative; z-index: 1; width: 66px; height: 55px; margin-bottom: 10px; }
.drop-art-back, .drop-art-front { position: absolute; display: block; border-radius: 9px; }
.drop-art-back { width: 44px; height: 34px; top: 10px; left: 9px; background: color-mix(in srgb, var(--brand) 18%, var(--surface-solid)); transform: rotate(-8deg); }
.drop-art-front { width: 47px; height: 40px; right: 4px; bottom: 1px; display: grid; place-items: center; background: linear-gradient(145deg, #8c6bf0, #6743dc); color: #fff; box-shadow: 0 9px 18px rgba(94,61,205,.22); transform: rotate(4deg); }
.drop-art-front::before { content: ""; position: absolute; top: 0; right: 0; border-style: solid; border-width: 0 9px 9px 0; border-color: transparent rgba(255,255,255,.35) transparent transparent; }
.drop-art-front svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.drop-spark { position: absolute; width: 4px; height: 4px; border-radius: 50%; background: var(--brand); opacity: .6; }
.spark-one { left: 1px; top: 7px; }
.spark-two { right: 0; top: 2px; width: 3px; height: 3px; }
.spark-three { left: 4px; bottom: 2px; width: 3px; height: 3px; }
.drop-copy { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; color: var(--text-soft); font-size: 14px; }
.drop-copy strong { color: var(--text); font-size: 15px; }
.drop-copy u { color: var(--brand-deep); font-weight: 700; text-underline-offset: 2px; }
:root[data-theme="dark"] .drop-copy u { color: #b7a4ff; }
.drop-hint { position: relative; z-index: 1; margin-top: 7px; color: var(--text-faint); font-size: 13px; }
.selected-files { margin-top: 4px; }
.selected-head { min-height: 38px; display: flex; align-items: center; justify-content: space-between; }
.selected-head > div { display: flex; align-items: baseline; gap: 7px; }
.selected-head strong { font-size: 14px; }
.selected-head span { color: var(--text-faint); font-size: 13px; }
.upload-file-list { max-height: 276px; padding-right: 3px; display: grid; gap: 7px; overflow-y: auto; scrollbar-width: thin; scrollbar-color: var(--border-strong) transparent; }
.upload-file { min-height: 61px; padding: 9px 10px; display: flex; align-items: center; gap: 10px; border: 1px solid var(--border); border-radius: 11px; background: var(--surface-soft); transition: border-color .2s, background .2s; }
.upload-file[data-state="error"] { border-color: color-mix(in srgb, var(--red) 45%, var(--border)); background: var(--red-soft); }
.upload-file[data-state="done"] { border-color: color-mix(in srgb, var(--green) 30%, var(--border)); }
.upload-file-icon { width: 40px; height: 40px; display: grid; place-items: center; flex: none; border-radius: 10px; background: var(--brand-soft); color: var(--brand); }
.upload-file-icon[data-kind="video"] { background: #e9efff; color: #5b7be3; }
:root[data-theme="dark"] .upload-file-icon[data-kind="video"] { background: #24314c; color: #83a1ff; }
.upload-file-icon[data-kind="archive"] { background: var(--amber-soft); color: var(--amber); }
.upload-file-icon[data-kind="image"] { background: var(--green-soft); color: var(--green); }
.upload-file-icon svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.55; stroke-linecap: round; stroke-linejoin: round; }
.upload-file-icon:not([data-kind="video"]) .kind-glyph { display: none; }
.upload-file-main { min-width: 0; flex: 1; }
.upload-file-line { display: flex; align-items: center; gap: 10px; }
.upload-file-line strong { min-width: 0; flex: 1; overflow: hidden; text-overflow: ellipsis; font-size: 13px; white-space: nowrap; }
.upload-file-line span { flex: none; color: var(--text-faint); font-size: 13px; }
.upload-file-main > small { display: block; margin-top: 2px; color: var(--text-faint); font-size: 12px; }
.upload-file[data-state="error"] .upload-file-main > small { color: var(--red); }
.upload-file[data-state="done"] .upload-file-main > small { color: var(--green); }
.file-progress-row { margin-top: 5px; display: flex; align-items: center; gap: 8px; }
.file-progress-row progress { flex: 1; height: 4px; }
.file-progress-row span { width: 28px; color: var(--text-soft); font-size: 12px; text-align: right; }
.upload-file-actions { display: flex; gap: 3px; }
.remove-file { border-color: transparent; background: transparent; }
.remove-file:hover { background: var(--red-soft); color: var(--red); }
.retry-file { color: var(--red); }
.transfer-options { margin-top: 18px; display: grid; grid-template-columns: minmax(210px, .75fr) minmax(370px, 1.25fr); gap: 18px; }
.transfer-name-field .input-wrap { min-height: 42px; }
.overlay-option { min-height: 69px; padding: 8px 9px 8px 12px; display: flex; align-items: center; gap: 12px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-soft); }
.switch-row { min-width: 0; display: flex; flex: 1; align-items: center; justify-content: space-between; gap: 12px; cursor: pointer; }
.switch-copy { min-width: 0; display: flex; align-items: center; gap: 9px; }
.switch-icon { width: 33px; height: 33px; display: grid; place-items: center; flex: none; border-radius: 9px; background: var(--brand-soft); color: var(--brand); }
.switch-icon svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.switch-copy > span:last-child { min-width: 0; display: flex; flex-direction: column; }
.switch-copy strong { overflow: hidden; text-overflow: ellipsis; font-size: 13px; white-space: nowrap; }
.switch-copy small { color: var(--text-faint); font-size: 12px; }
.position-field { position: relative; min-width: 118px; display: flex; flex-direction: column; }
.position-field > span { margin: 0 0 2px 2px; color: var(--text-faint); font-size: 12px; font-weight: 700; text-transform: uppercase; }
.position-field select { width: 100%; height: 31px; padding: 0 25px 0 8px; appearance: none; border: 1px solid var(--border); border-radius: 8px; outline: 0; background: var(--surface-solid); color: var(--text); font-size: 13px; }
.position-field select:focus { border-color: var(--brand); box-shadow: var(--ring); }
.position-field svg { position: absolute; right: 7px; bottom: 8px; width: 13px; height: 13px; pointer-events: none; fill: none; stroke: currentColor; stroke-width: 1.8; }
.position-field.is-disabled { opacity: .45; }
.composer-footer { min-height: 73px; margin-top: 17px; display: flex; align-items: center; gap: 7px; border-top: 1px solid var(--border); }
.composer-spacer { flex: 1; }
.queue-total { display: flex; align-items: center; gap: 8px; }
.queue-total-icon { width: 30px; height: 30px; display: grid; place-items: center; border-radius: 8px; background: var(--surface-soft); color: var(--text-soft); }
.queue-total-icon svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; }
.queue-total > span:last-child { display: flex; flex-direction: column; }
.queue-total strong { font-size: 13px; }
.queue-total small { color: var(--text-faint); font-size: 12px; }
.button-upload { min-width: 135px; }

.upload-status-panel { width: 295px; flex: 0 0 auto; border-left: 1px solid var(--border); background: linear-gradient(160deg, color-mix(in srgb, var(--brand-faint) 60%, var(--surface-solid)), var(--surface-soft)); animation: panel-in .4s var(--ease); }
.status-panel-head { height: 57px; padding: 0 17px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--border); }
.status-panel-head > div { display: flex; align-items: center; gap: 8px; color: var(--text-soft); font-size: 13px; font-weight: 750; letter-spacing: .08em; text-transform: uppercase; }
.status-panel-head .icon-button { border-color: transparent; background: transparent; }
.live-dot { position: relative; width: 8px; height: 8px; display: block; }
.live-dot::before { content: ""; position: absolute; inset: -3px; border: 1px solid var(--green); border-radius: 50%; animation: pulse-ring 1.8s ease-out infinite; }
.live-dot i { display: block; width: 8px; height: 8px; border-radius: 50%; background: var(--green); }
.status-panel-body { padding: 22px 21px; display: flex; flex-direction: column; align-items: center; }
.upload-ring { position: relative; width: 112px; height: 112px; }
.upload-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.upload-ring circle { fill: none; stroke-width: 7; }
.ring-track { stroke: var(--border); }
.ring-value { stroke: var(--brand); stroke-linecap: round; stroke-dasharray: 295.31; stroke-dashoffset: 295.31; transition: stroke-dashoffset .35s ease; }
.upload-ring > span { position: absolute; inset: 0; display: flex; align-items: baseline; justify-content: center; padding-top: 39px; }
.upload-ring strong { font-size: 25px; letter-spacing: -1px; }
.upload-ring small { color: var(--text-faint); font-size: 13px; }
.status-copy { width: 100%; margin-top: 11px; display: flex; flex-direction: column; align-items: center; text-align: center; }
.status-copy strong { width: 100%; overflow: hidden; text-overflow: ellipsis; font-size: 13px; white-space: nowrap; }
.status-copy span { color: var(--text-faint); font-size: 12px; }
.status-metrics { width: 100%; margin: 20px 0; padding: 13px 0; display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.status-metrics > div { display: flex; flex-direction: column; align-items: center; gap: 2px; border-right: 1px solid var(--border); }
.status-metrics > div:last-child { border: 0; }
.status-metrics span { color: var(--text-faint); font-size: 12px; }
.status-metrics strong { font-size: 13px; }
.status-actions { width: 100%; display: flex; justify-content: center; gap: 5px; }
.resume-icon { display: none; }
.is-paused .pause-icon { display: none; }
.is-paused .resume-icon { display: block; }
.upload-status-panel.is-collapsed { width: 61px; }
.upload-status-panel.is-collapsed .status-panel-body, .upload-status-panel.is-collapsed .status-panel-head > div { display: none; }
.upload-status-panel.is-collapsed .status-panel-head { justify-content: center; padding: 0; border: 0; }
.upload-status-panel.is-collapsed .status-panel-head .icon-button svg { transform: rotate(180deg); }

/* Transfer library */
.transfers-section { margin-top: 42px; }
.section-toolbar { margin-bottom: 16px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.section-toolbar > div:first-child { display: flex; align-items: center; gap: 8px; }
.section-toolbar h2 { margin: 0; font-size: 18px; letter-spacing: -.35px; }
.count-badge, .tab-count { min-width: 24px; height: 24px; padding: 0 7px; display: inline-grid; place-items: center; border-radius: 12px; background: var(--brand-soft); color: var(--brand-deep); font-size: 12px; font-weight: 800; }
.toolbar-actions { display: flex; align-items: center; gap: 7px; }
.search-field { position: relative; min-width: 220px; display: flex; align-items: center; }
.search-field > svg { position: absolute; left: 11px; width: 16px; height: 16px; pointer-events: none; color: var(--text-faint); fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
.search-field input { width: 100%; height: 39px; padding: 0 43px 0 35px; border: 1px solid var(--border); border-radius: 10px; outline: 0; background: var(--surface-solid); color: var(--text); font-size: 13px; }
.search-field input:focus { border-color: var(--brand); box-shadow: var(--ring); }
.search-field kbd { position: absolute; right: 8px; padding: 2px 5px; border: 1px solid var(--border); border-radius: 5px; background: var(--surface-soft); color: var(--text-faint); font: 12px inherit; }
.filter-select { position: relative; }
.filter-select select { height: 39px; padding: 0 33px 0 12px; appearance: none; border: 1px solid var(--border); border-radius: 10px; outline: 0; background: var(--surface-solid); color: var(--text-soft); font-size: 13px; }
.filter-select select:focus { border-color: var(--brand); box-shadow: var(--ring); }
.filter-select svg { position: absolute; right: 10px; top: 12px; width: 15px; height: 15px; pointer-events: none; fill: none; stroke: currentColor; stroke-width: 1.8; }
.refresh-button { width: 39px; height: 39px; }
.refresh-button.is-spinning svg { animation: spin .8s linear infinite; }
.transfer-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.transfer-card { position: relative; min-width: 0; min-height: 286px; padding: 18px 18px 14px; display: flex; flex-direction: column; overflow: visible; border-radius: 15px; transition: transform .25s var(--ease), box-shadow .25s, border-color .25s; }
.transfer-card:hover { z-index: 3; transform: translateY(-2px); border-color: color-mix(in srgb, var(--brand) 18%, var(--border)); box-shadow: var(--shadow-md); }
.transfer-accent { position: absolute; top: -1px; left: 21px; width: 31px; height: 3px; border-radius: 0 0 5px 5px; background: var(--text-faint); }
.transfer-accent.status-ready { background: var(--green); }
.transfer-accent.status-uploading { background: var(--blue); }
.transfer-accent.status-processing, .transfer-accent.status-queued { background: var(--brand); }
.transfer-accent.status-verifying { background: var(--amber); }
.transfer-accent.status-failed, .transfer-accent.status-cancelled { background: var(--red); }
.transfer-card-head { position: relative; display: flex; align-items: center; gap: 10px; }
.transfer-type-icon { width: 38px; height: 38px; display: grid; place-items: center; flex: none; border-radius: 10px; background: var(--surface-soft); color: var(--text-soft); }
.transfer-type-icon svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.55; stroke-linecap: round; stroke-linejoin: round; }
.transfer-title { min-width: 0; flex: 1; }
.transfer-title h3 { margin: 0; overflow: hidden; text-overflow: ellipsis; font-size: 14px; white-space: nowrap; }
.transfer-title p { margin: 2px 0 0; color: var(--text-faint); font-size: 12px; }
.overflow-button { width: 30px; height: 30px; border-color: transparent; background: transparent; }
.overflow-button svg { fill: currentColor; stroke: none; }
.card-menu { position: absolute; top: 34px; right: 0; z-index: 5; width: 140px; padding: 5px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface-solid); box-shadow: var(--shadow-md); animation: pop-in .18s var(--ease); }
.card-menu button { width: 100%; padding: 8px; display: flex; align-items: center; gap: 8px; border: 0; border-radius: 7px; background: transparent; color: var(--text-soft); font-size: 13px; font-weight: 650; text-align: left; }
.card-menu button:hover { background: var(--surface-hover); color: var(--text); }
.card-menu button.danger { color: var(--red); }
.card-menu button svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.transfer-status-row { margin: 16px 0 12px; display: flex; align-items: center; justify-content: space-between; }
.transfer-status-row time { color: var(--text-faint); font-size: 12px; }
.status-pill { padding: 4px 7px; display: inline-flex; align-items: center; gap: 5px; border-radius: 7px; background: var(--surface-soft); color: var(--text-soft); font-size: 12px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.status-pill b { font: inherit; }
.status-pill i { width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.status-pill.status-ready { background: var(--green-soft); color: var(--green); }
.status-pill.status-uploading { background: #eaf2ff; color: var(--blue); }
:root[data-theme="dark"] .status-pill.status-uploading { background: #21304a; }
.status-pill.status-processing, .status-pill.status-queued { background: var(--brand-soft); color: var(--brand); }
.status-pill.status-verifying { background: var(--amber-soft); color: var(--amber); }
.status-pill.status-failed, .status-pill.status-cancelled { background: var(--red-soft); color: var(--red); }
.status-pill.status-processing i, .status-pill.status-uploading i, .status-pill.status-verifying i { animation: blink 1.2s ease infinite; }
.card-progress { margin: -3px 0 12px; }
.card-progress > div { margin-bottom: 4px; display: flex; justify-content: space-between; color: var(--text-faint); font-size: 12px; }
.card-progress strong { color: var(--text-soft); }
progress { overflow: hidden; appearance: none; border: 0; border-radius: 5px; background: var(--border); }
progress::-webkit-progress-bar { background: var(--border); }
progress::-webkit-progress-value { border-radius: 5px; background: linear-gradient(90deg, var(--brand), var(--blue)); transition: width .3s; }
progress::-moz-progress-bar { border-radius: 5px; background: linear-gradient(90deg, var(--brand), var(--blue)); }
.card-progress progress { width: 100%; height: 4px; display: block; }
.transfer-files-preview { min-height: 70px; display: grid; align-content: start; gap: 5px; }
.transfer-files-preview > div { min-width: 0; display: flex; align-items: center; gap: 6px; color: var(--text-soft); font-size: 12px; }
.transfer-files-preview > div > span:nth-child(2) { min-width: 0; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.transfer-files-preview small { color: var(--text-faint); font-size: 12px; }
.file-dot { width: 6px; height: 6px; flex: none; border-radius: 2px; background: var(--brand); }
.file-dot.file-video { background: var(--blue); }
.file-dot.file-image { background: var(--green); }
.file-dot.file-archive { background: var(--amber); }
.transfer-files-preview > button { justify-self: start; padding: 2px 0; border: 0; background: transparent; color: var(--brand); font-size: 12px; font-weight: 700; }
.transfer-card-footer { min-height: 43px; margin-top: auto; padding-top: 11px; display: flex; align-items: center; justify-content: space-between; gap: 8px; border-top: 1px solid var(--border); }
.transfer-card-footer > span { min-width: 0; display: flex; align-items: center; gap: 4px; color: var(--text-faint); font-size: 12px; }
.transfer-card-footer > span svg { width: 12px; height: 12px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.transfer-card-footer .button { flex: none; }
.empty-state { padding: 58px 20px; display: flex; flex-direction: column; align-items: center; border: 1px dashed var(--border-strong); border-radius: 16px; background: color-mix(in srgb, var(--surface-soft) 50%, transparent); text-align: center; }
.empty-art { position: relative; width: 82px; height: 68px; margin-bottom: 12px; display: grid; place-items: center; }
.empty-art span { position: absolute; inset: 0; border-radius: 50%; background: var(--brand-soft); opacity: .65; }
.empty-art svg { position: relative; width: 52px; height: 52px; fill: none; stroke: var(--brand); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.empty-state h3 { margin: 0 0 4px; font-size: 15px; }
.empty-state p { max-width: 380px; margin: 0 0 17px; color: var(--text-faint); font-size: 13px; }
.loading-state { padding: 50px; display: flex; align-items: center; justify-content: center; gap: 5px; color: var(--text-faint); }
.loading-state span { width: 6px; height: 6px; border-radius: 50%; background: var(--brand); animation: bounce .8s ease infinite alternate; }
.loading-state span:nth-child(2) { animation-delay: .14s; }
.loading-state span:nth-child(3) { animation-delay: .28s; }
.loading-state p { margin-left: 7px; font-size: 13px; }
.share-result { margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--border); }
.share-result label > span:first-child { display: block; margin-bottom: 6px; font-size: 13px; font-weight: 700; }
.copy-field { display: flex; gap: 6px; }
.copy-field input { min-width: 0; flex: 1; height: 41px; padding: 0 11px; border: 1px solid var(--border); border-radius: 9px; outline: 0; background: var(--surface-soft); color: var(--text-soft); font-size: 13px; }
.share-result > small { display: block; margin-top: 6px; color: var(--text-faint); font-size: 13px; }
.details-modal { width: min(580px, calc(100% - 30px)); }
.details-dialog-inner { position: relative; padding: 29px; }
.details-head { padding-right: 30px; display: flex; align-items: flex-start; gap: 13px; }
.details-head > div { min-width: 0; }
.details-head h2 { margin: 6px 0 1px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.details-head p { margin: 0; color: var(--text-faint); font-size: 13px; }
.details-progress { margin: 20px 0 13px; padding: 12px; border-radius: 10px; background: var(--surface-soft); }
.details-progress > div { margin-bottom: 6px; display: flex; justify-content: space-between; color: var(--text-soft); font-size: 12px; }
.details-progress progress { width: 100%; height: 5px; display: block; }
.details-file-list { max-height: 290px; margin-top: 20px; display: grid; gap: 6px; overflow-y: auto; }
.details-file { padding: 9px 10px; display: flex; align-items: center; gap: 10px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface-soft); }
.details-file > .file-dot { width: 8px; height: 8px; }
.details-file > div { min-width: 0; flex: 1; display: flex; flex-direction: column; }
.details-file strong { overflow: hidden; text-overflow: ellipsis; font-size: 13px; white-space: nowrap; }
.details-file span { color: var(--text-faint); font-size: 12px; }
.details-file .icon-button { border-color: transparent; background: transparent; }
.details-error { margin-top: 13px; padding: 10px; display: flex; align-items: flex-start; gap: 8px; border-radius: 9px; background: var(--red-soft); color: var(--red); font-size: 12px; }
.details-error svg { width: 16px; height: 16px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
.details-actions { padding-top: 17px; border-top: 1px solid var(--border); }

/* Admin */
.admin-heading { margin-bottom: 25px; }
.health-chip { padding: 10px 14px 10px 10px; display: flex; align-items: center; gap: 10px; border: 1px solid color-mix(in srgb, var(--green) 18%, var(--border)); border-radius: 12px; background: var(--surface); }
.health-chip > span { width: 33px; height: 33px; display: grid; place-items: center; border-radius: 10px; background: var(--green-soft); }
.health-chip > span i { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 4px color-mix(in srgb, var(--green) 13%, transparent); }
.health-chip > div { display: flex; flex-direction: column; }
.health-chip strong { font-size: 13px; }
.health-chip small { color: var(--text-faint); font-size: 12px; }
.health-chip.has-warning { border-color: color-mix(in srgb, var(--amber) 28%, var(--border)); }
.health-chip.has-warning > span { background: var(--amber-soft); }
.health-chip.has-warning > span i { background: var(--amber); box-shadow: 0 0 0 4px color-mix(in srgb, var(--amber) 13%, transparent); }
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.stat-card { min-height: 112px; padding: 18px; display: flex; align-items: flex-start; gap: 13px; border-radius: 14px; }
.stat-icon { width: 38px; height: 38px; display: grid; place-items: center; flex: none; border-radius: 11px; }
.stat-icon svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.stat-icon-purple { background: var(--brand-soft); color: var(--brand); }
.stat-icon-blue { background: #e9f1ff; color: var(--blue); }
.stat-icon-amber { background: var(--amber-soft); color: var(--amber); }
.stat-icon-green { background: var(--green-soft); color: var(--green); }
:root[data-theme="dark"] .stat-icon-blue { background: #20314d; }
.stat-card > div { display: flex; min-width: 0; flex-direction: column; }
.stat-card > div > span { color: var(--text-soft); font-size: 12px; font-weight: 650; }
.stat-card > div > strong { margin: 1px 0; font-size: 23px; line-height: 1.25; letter-spacing: -.7px; }
.stat-card > div > small { display: flex; align-items: center; gap: 4px; color: var(--text-faint); font-size: 12px; }
.stat-card small i { width: 5px; height: 5px; border-radius: 50%; background: var(--text-faint); }
.stat-card small i.positive { background: var(--green); }
.stat-card small i.live { background: var(--amber); animation: blink 1.2s infinite; }
.admin-tabs { margin: 27px 0 11px; display: flex; gap: 4px; border-bottom: 1px solid var(--border); }
.admin-tab { position: relative; min-height: 43px; padding: 0 13px; display: flex; align-items: center; gap: 7px; border: 0; background: transparent; color: var(--text-faint); font-size: 13px; font-weight: 700; }
.admin-tab:hover { color: var(--text); }
.admin-tab.is-active { color: var(--brand-deep); }
:root[data-theme="dark"] .admin-tab.is-active { color: #baa7ff; }
.admin-tab.is-active::after { content: ""; position: absolute; right: 8px; bottom: -1px; left: 8px; height: 2px; border-radius: 2px 2px 0 0; background: var(--brand); }
.admin-tab svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.admin-tab .tab-count { height: 22px; min-width: 22px; padding: 0 5px; font-size: 12px; }
.admin-panel { overflow: hidden; border-radius: 15px; }
.panel-heading { min-height: 80px; padding: 18px 21px; display: flex; align-items: center; justify-content: space-between; gap: 20px; border-bottom: 1px solid var(--border); }
.panel-heading h2 { margin: 0 0 2px; font-size: 16px; }
.panel-heading p { margin: 0; color: var(--text-faint); font-size: 13px; }
.table-toolbar { min-height: 58px; padding: 9px 18px; display: flex; align-items: center; justify-content: space-between; background: var(--surface-soft); }
.table-toolbar .search-field { min-width: 240px; }
.table-toolbar > span { color: var(--text-faint); font-size: 12px; }
.data-table-wrap { overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; }
.data-table th { height: 36px; padding: 0 14px; border-bottom: 1px solid var(--border); color: var(--text-faint); font-size: 12px; font-weight: 750; letter-spacing: .06em; text-align: left; text-transform: uppercase; white-space: nowrap; }
.data-table th:first-child, .data-table td:first-child { padding-left: 20px; }
.data-table th:last-child, .data-table td:last-child { padding-right: 20px; }
.data-table td { height: 66px; padding: 9px 14px; border-bottom: 1px solid var(--border); color: var(--text-soft); font-size: 13px; white-space: nowrap; }
.data-table td:last-child, .job-row { position: relative; }
.inline-action-menu { position: absolute; z-index: 12; top: calc(50% + 16px); right: 17px; width: 135px; padding: 5px; display: grid; border: 1px solid var(--border); border-radius: 10px; background: var(--surface-solid); box-shadow: var(--shadow-md); animation: pop-in .18s var(--ease); }
.inline-action-menu button { padding: 8px; border: 0; border-radius: 7px; background: transparent; color: var(--text-soft); font-size: 12px; font-weight: 650; text-align: left; }
.inline-action-menu button:hover:not(:disabled) { background: var(--surface-hover); color: var(--text); }
.inline-action-menu button.danger { color: var(--red); }
.inline-action-menu button:disabled { opacity: .4; cursor: not-allowed; }
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table tbody tr:hover { background: color-mix(in srgb, var(--surface-soft) 60%, transparent); }
.table-user { display: flex; align-items: center; gap: 9px; }
.table-user .avatar { width: 34px; height: 34px; }
.table-user > div { display: flex; flex-direction: column; }
.table-user strong { color: var(--text); font-size: 13px; }
.table-user span { color: var(--text-faint); font-size: 12px; }
.role-pill { padding: 4px 7px; border-radius: 6px; background: var(--surface-soft); color: var(--text-soft); font-size: 12px; font-weight: 700; }
.role-pill.role-admin { background: var(--brand-soft); color: var(--brand); }
.status-label { display: inline-flex; align-items: center; gap: 5px; color: var(--text-faint); font-size: 12px; }
.status-label b { font: inherit; }
.status-label i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.status-label.is-active { color: var(--green); }
.status-label.is-disabled { color: var(--text-faint); }
.table-primary { display: block; color: var(--text-soft); font-size: 12px; }
.data-table td > small { display: block; color: var(--text-faint); font-size: 12px; }
.panel-empty { padding: 58px 20px; display: flex; flex-direction: column; align-items: center; text-align: center; }
.empty-icon { width: 47px; height: 47px; display: grid; place-items: center; border-radius: 14px; background: var(--brand-soft); color: var(--brand); }
.empty-icon svg { width: 23px; height: 23px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.panel-empty h3 { margin: 11px 0 3px; font-size: 14px; }
.panel-empty p { margin: 0; color: var(--text-faint); font-size: 13px; }
.security-callout { margin: 17px 18px 4px; padding: 11px 13px; display: flex; align-items: center; gap: 10px; border: 1px solid color-mix(in srgb, var(--blue) 17%, var(--border)); border-radius: 10px; background: color-mix(in srgb, #e9f1ff 55%, var(--surface-solid)); }
:root[data-theme="dark"] .security-callout { background: #1d283c; }
.security-callout > svg { width: 21px; height: 21px; flex: none; color: var(--blue); fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.security-callout > div { display: flex; flex-direction: column; }
.security-callout strong { font-size: 12px; }
.security-callout span { color: var(--text-faint); font-size: 12px; }
.jobs-list { padding: 10px 18px 18px; display: grid; gap: 7px; }
.job-row { min-height: 76px; padding: 11px 12px; display: flex; align-items: center; gap: 12px; border: 1px solid var(--border); border-radius: 11px; background: var(--surface-soft); }
.job-file-icon { width: 40px; height: 40px; display: grid; place-items: center; flex: none; border-radius: 10px; background: var(--brand-soft); color: var(--brand); }
.job-file-icon svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.job-main { min-width: 0; flex: 1; }
.job-main > div:first-child { display: flex; align-items: center; gap: 7px; }
.job-main strong { max-width: 65%; overflow: hidden; text-overflow: ellipsis; font-size: 13px; white-space: nowrap; }
.job-main > span { display: block; margin: 1px 0 6px; color: var(--text-faint); font-size: 12px; }
.job-progress { display: flex; align-items: center; gap: 8px; }
.job-progress progress { width: min(340px, 100%); height: 4px; }
.job-progress b { color: var(--text-soft); font-size: 12px; }
.job-meta { width: 85px; display: flex; flex-direction: column; }
.job-meta span { color: var(--text-faint); font-size: 12px; }
.job-meta strong { font-size: 12px; }
.storage-layout { padding: 30px; display: grid; grid-template-columns: 1fr 1fr; gap: 50px; }
.storage-donut-wrap { display: flex; align-items: center; justify-content: center; gap: 24px; }
.storage-donut { --percent: 0; position: relative; width: 142px; height: 142px; display: grid; place-items: center; flex: none; border-radius: 50%; background: conic-gradient(var(--brand) calc(var(--percent) * 1%), var(--border) 0); }
.storage-donut::before { content: ""; position: absolute; inset: 12px; border-radius: 50%; background: var(--surface-solid); }
.storage-donut > span { position: relative; display: flex; flex-direction: column; align-items: center; }
.storage-donut strong { font-size: 24px; line-height: 1.1; letter-spacing: -.8px; }
.storage-donut small { color: var(--text-faint); font-size: 12px; }
.storage-summary h3 { margin: 0; font-size: 23px; letter-spacing: -.7px; }
.storage-summary p { margin: 1px 0 12px; color: var(--text-faint); font-size: 13px; }
.storage-available { display: flex; align-items: center; gap: 5px; color: var(--text-faint); font-size: 12px; }
.storage-available i { width: 6px; height: 6px; border-radius: 50%; background: var(--green); }
.storage-available b { color: var(--green); }
.storage-breakdown { padding-left: 35px; border-left: 1px solid var(--border); }
.storage-breakdown h3 { margin: 0 0 20px; font-size: 14px; }
.storage-bar { height: 8px; margin-bottom: 17px; display: flex; overflow: hidden; border-radius: 5px; background: var(--border); }
.storage-bar i { display: block; transition: width .5s var(--ease); }
.bar-videos { width: 45%; background: var(--brand); }
.bar-originals { width: 35%; background: var(--blue); }
.bar-other { width: 10%; background: var(--amber); }
.storage-breakdown ul { margin: 0; padding: 0; display: grid; gap: 9px; list-style: none; }
.storage-breakdown li { display: flex; justify-content: space-between; color: var(--text-soft); font-size: 12px; }
.storage-breakdown li span { display: flex; align-items: center; gap: 6px; }
.storage-breakdown li i { width: 7px; height: 7px; border-radius: 2px; }
.legend-videos { background: var(--brand); }
.legend-originals { background: var(--blue); }
.legend-other { background: var(--amber); }
.retention-note { margin: 0 20px 20px; padding: 13px; display: flex; align-items: center; gap: 11px; border-radius: 10px; background: var(--surface-soft); }
.retention-note svg { width: 22px; height: 22px; flex: none; color: var(--text-faint); fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.retention-note > div { display: flex; flex-direction: column; }
.retention-note strong { font-size: 12px; }
.retention-note span { color: var(--text-faint); font-size: 12px; }
.form-modal { width: min(535px, calc(100% - 30px)); }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-span { grid-column: 1 / -1; }
.modal-security-note { margin: 18px 0 0; }

/* Settings */
.settings-shell { width: min(1050px, calc(100% - 48px)); }
.password-gate-banner { margin: -5px 0 22px; padding: 18px 20px; display: flex; align-items: center; gap: 15px; border: 1px solid color-mix(in srgb, var(--brand) 32%, var(--border)); border-radius: 16px; background: linear-gradient(135deg, var(--brand-soft), var(--surface-solid)); box-shadow: var(--shadow-sm); }
.password-gate-icon { width: 44px; height: 44px; display: grid; flex: none; place-items: center; border-radius: 13px; background: var(--brand); color: #fff; }
.password-gate-icon svg { width: 23px; height: 23px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.password-gate-banner > div { min-width: 0; flex: 1; }
.password-gate-banner strong { display: block; margin-bottom: 3px; font-size: 14px; }
.password-gate-banner p { margin: 0; color: var(--text-soft); font-size: 13px; line-height: 1.5; }
.password-gate-banner .button { flex: none; }
.settings-layout { display: grid; grid-template-columns: 230px 1fr; align-items: start; gap: 20px; }
.settings-nav { position: sticky; top: calc(var(--header-h) + 20px); padding: 7px; display: grid; gap: 3px; border-radius: 14px; }
.settings-nav a { padding: 11px; display: flex; align-items: center; gap: 10px; border-radius: 9px; color: var(--text-soft); text-decoration: none; }
.settings-nav a:hover { background: var(--surface-soft); color: var(--text); }
.settings-nav a.is-active { background: var(--brand-soft); color: var(--brand-deep); }
.settings-nav a > svg { width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.settings-nav a > span { display: flex; flex-direction: column; }
.settings-nav strong { font-size: 13px; }
.settings-nav small { color: var(--text-faint); font-size: 12px; }
.settings-content { display: grid; gap: 16px; }
.settings-card { padding: 0 24px 23px; border-radius: 15px; scroll-margin-top: calc(var(--header-h) + 20px); }
.settings-shell[data-password-setup-required="true"] #security { order: -1; border-color: color-mix(in srgb, var(--brand) 38%, var(--border)); box-shadow: var(--shadow-md); }
.settings-card-head { min-height: 75px; margin-bottom: 21px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--border); }
.settings-card-head h2 { margin: 0 0 2px; font-size: 16px; }
.settings-card-head p { margin: 0; color: var(--text-faint); font-size: 13px; }
.profile-editor { margin-bottom: 21px; display: flex; align-items: center; gap: 12px; }
.avatar-xl { width: 56px; height: 56px; border-radius: 16px; font-size: 19px; }
.profile-editor > div { display: flex; flex-direction: column; }
.profile-editor strong { font-size: 14px; }
.profile-editor span { color: var(--text-faint); font-size: 12px; }
.settings-actions { margin-top: 21px; padding-top: 16px; display: flex; align-items: center; justify-content: space-between; border-top: 1px solid var(--border); }
.save-status { color: var(--green); font-size: 13px; }
.password-strength { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; }
.password-strength i { height: 3px; border-radius: 3px; background: var(--border); }
.password-strength small { grid-column: 1 / -1; color: var(--text-faint); font-size: 12px; }
.password-strength[data-strength="1"] i:nth-child(1) { background: var(--red); }
.password-strength[data-strength="2"] i:nth-child(-n+2) { background: var(--amber); }
.password-strength[data-strength="3"] i:nth-child(-n+3), .password-strength[data-strength="4"] i { background: var(--green); }
.session-row { margin-top: 22px; padding: 13px; display: flex; align-items: center; gap: 11px; border: 1px solid var(--border); border-radius: 11px; background: var(--surface-soft); }
.session-icon { width: 37px; height: 37px; display: grid; place-items: center; border-radius: 10px; background: var(--brand-soft); color: var(--brand); }
.session-icon svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.6; }
.session-row > div { min-width: 0; display: flex; flex: 1; flex-direction: column; }
.session-row strong { font-size: 13px; }
.session-row div span { color: var(--text-faint); font-size: 12px; }
.preference-group { min-height: 75px; padding: 15px 0; display: flex; align-items: center; justify-content: space-between; gap: 20px; border-bottom: 1px solid var(--border); }
.preference-group:last-child { border: 0; }
.preference-copy { display: flex; flex-direction: column; }
.preference-copy strong { font-size: 13px; }
.preference-copy span { color: var(--text-faint); font-size: 12px; }
.theme-picker { display: flex; gap: 7px; }
.theme-picker button { width: 84px; padding: 6px; border: 1px solid var(--border); border-radius: 9px; background: transparent; color: var(--text-soft); }
.theme-picker button:hover { border-color: var(--border-strong); }
.theme-picker button[aria-checked="true"] { border-color: var(--brand); box-shadow: var(--ring); color: var(--brand-deep); }
.theme-picker button > span:last-child { margin-top: 4px; display: flex; align-items: center; justify-content: center; gap: 4px; font-size: 12px; font-weight: 700; }
.theme-picker button svg { width: 11px; height: 11px; fill: none; stroke: currentColor; stroke-width: 1.7; }
.theme-preview { height: 38px; display: grid; grid-template-columns: 12px 1fr; gap: 4px; padding: 5px; border-radius: 5px; background: #f4f4f8; }
.theme-preview i { border-radius: 3px; background: #e3e0ed; }
.theme-preview b { border-radius: 3px; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.06); }
.preview-dark { background: #15141c; }
.preview-dark i { background: #2d2b3a; }
.preview-dark b { background: #23212d; }
.preview-system { background: linear-gradient(90deg, #f4f4f8 50%, #15141c 50%); }
.preview-system i { background: linear-gradient(90deg, #e3e0ed 50%, #2d2b3a 50%); }
.preview-system b { background: linear-gradient(90deg, #fff 50%, #23212d 50%); }

/* Public share */
.share-shell { position: relative; min-height: 100vh; padding: 95px 20px 55px; overflow: hidden; }
.share-backdrop { position: fixed; inset: 0; z-index: -1; overflow: hidden; background: linear-gradient(145deg, var(--bg), color-mix(in srgb, var(--brand-faint) 52%, var(--bg))); }
.share-grid { position: absolute; inset: 0; opacity: .3; background-image: linear-gradient(var(--border) 1px, transparent 1px), linear-gradient(90deg, var(--border) 1px, transparent 1px); background-size: 55px 55px; mask-image: radial-gradient(circle at center, #000, transparent 70%); }
.share-orb { position: absolute; border-radius: 50%; filter: blur(2px); }
.share-orb-one { width: 480px; height: 480px; top: -270px; right: -170px; background: radial-gradient(circle, color-mix(in srgb, var(--brand) 18%, transparent), transparent 70%); }
.share-orb-two { width: 380px; height: 380px; bottom: -250px; left: -160px; background: radial-gradient(circle, color-mix(in srgb, var(--blue) 13%, transparent), transparent 70%); }
.share-header { position: absolute; top: 25px; left: 50%; width: min(1000px, calc(100% - 40px)); display: flex; align-items: center; justify-content: space-between; transform: translateX(-50%); }
.share-card { width: min(610px, 100%); margin: auto; padding: 33px; border-radius: 22px; box-shadow: var(--shadow-md); }
.share-card-head { display: flex; flex-direction: column; align-items: center; text-align: center; }
.share-hero-icon { width: 58px; height: 58px; margin-bottom: 15px; display: grid; place-items: center; border-radius: 17px; background: linear-gradient(145deg, #8a6af0, #6240d7); color: #fff; box-shadow: 0 10px 26px rgba(91,57,211,.23); }
.share-hero-icon.expired { background: var(--surface-soft); color: var(--text-faint); box-shadow: none; }
.share-hero-icon svg { width: 28px; height: 28px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.share-card-head h1, .share-expired h1, .share-password h1 { margin: 9px 0 5px; font-size: 24px; line-height: 1.2; letter-spacing: -.7px; }
.share-card-head > p, .share-expired > p, .share-password > p { margin: 0; color: var(--text-soft); font-size: 13px; }
.mid-dot { margin: 0 6px; color: var(--text-faint); }
.shared-file-list { max-height: 292px; margin: 25px 0 17px; padding: 5px 0; display: grid; gap: 6px; overflow-y: auto; }
.shared-file { min-height: 60px; padding: 8px 9px; display: flex; align-items: center; gap: 10px; border: 1px solid var(--border); border-radius: 11px; background: var(--surface-soft); }
.shared-file-icon { width: 39px; height: 39px; display: grid; place-items: center; flex: none; border-radius: 10px; background: var(--brand-soft); color: var(--brand); }
.shared-file-icon.file-video { background: #eaf1ff; color: var(--blue); }
:root[data-theme="dark"] .shared-file-icon.file-video { background: #21304a; }
.shared-file-icon svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.shared-file > div { min-width: 0; flex: 1; display: flex; flex-direction: column; }
.shared-file strong { overflow: hidden; text-overflow: ellipsis; font-size: 13px; white-space: nowrap; }
.shared-file div span { display: flex; align-items: center; gap: 4px; color: var(--text-faint); font-size: 12px; }
.shared-file div b { display: inline-flex; align-items: center; gap: 2px; color: var(--green); font-weight: 650; }
.shared-file div b svg { width: 10px; height: 10px; fill: none; stroke: currentColor; stroke-width: 2; }
.shared-file > .icon-button { border-color: transparent; background: transparent; }
.share-download { position: relative; }
.share-download small { position: absolute; right: 16px; color: rgba(255,255,255,.72); font-size: 12px; font-weight: 500; }
.share-expiry { margin-top: 13px; display: flex; align-items: center; justify-content: center; gap: 5px; color: var(--text-faint); font-size: 12px; }
.share-expiry svg { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 1.7; }
.share-expired, .share-password { padding: 25px 20px; display: flex; flex-direction: column; align-items: center; text-align: center; }
.share-password-form { width: min(330px, 100%); margin-top: 23px; display: grid; gap: 12px; text-align: left; }
.share-footer { margin: 22px auto 0; display: flex; align-items: center; justify-content: center; gap: 11px; color: var(--text-faint); font-size: 12px; }
.share-footer span { display: flex; align-items: center; gap: 4px; }
.share-footer svg { width: 12px; height: 12px; fill: none; stroke: var(--green); stroke-width: 1.8; }
.share-footer > i { width: 2px; height: 2px; border-radius: 50%; background: var(--text-faint); }

/* Error pages */
.error-shell { position: relative; min-height: 100vh; padding: 45px 20px; display: grid; place-items: center; overflow: hidden; }
.error-backdrop { position: fixed; inset: 0; z-index: -1; overflow: hidden; background: var(--bg); }
.error-backdrop span { position: absolute; border-radius: 50%; filter: blur(2px); }
.error-backdrop span:first-child { width: 500px; height: 500px; top: -300px; right: -180px; background: radial-gradient(circle, color-mix(in srgb, var(--brand) 15%, transparent), transparent 70%); }
.error-backdrop span:last-child { width: 430px; height: 430px; bottom: -280px; left: -160px; background: radial-gradient(circle, color-mix(in srgb, var(--blue) 10%, transparent), transparent 70%); }
.error-card { width: min(560px, 100%); padding: 27px 38px 38px; display: flex; flex-direction: column; align-items: center; border-radius: 22px; text-align: center; box-shadow: var(--shadow-md); }
.error-card > .brand { align-self: flex-start; }
.error-art { position: relative; width: 180px; height: 145px; margin: 12px 0 -5px; display: grid; place-items: center; }
.error-code { position: absolute; top: 7px; color: var(--brand-soft); font-size: 80px; font-weight: 850; letter-spacing: -6px; }
.error-art svg { position: relative; width: 115px; height: 95px; margin-top: 31px; fill: var(--surface-soft); stroke: var(--brand); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.error-card h1 { margin: 10px 0 5px; font-size: 24px; letter-spacing: -.7px; }
.error-card > p { max-width: 410px; margin: 0; color: var(--text-soft); font-size: 13px; }
.error-actions { margin-top: 22px; display: flex; gap: 8px; }
.request-id { margin-top: 17px; color: var(--text-faint); font: 12px ui-monospace, monospace; }

/* Animation and responsiveness */
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pop-in { from { opacity: 0; transform: translateY(-5px) scale(.98); } }
@keyframes modal-in { from { opacity: 0; transform: translateY(12px) scale(.97); } }
@keyframes slide-down { from { opacity: 0; transform: translateY(-12px); } }
@keyframes toast-in { from { opacity: 0; transform: translateX(22px); } }
@keyframes toast-out { to { opacity: 0; transform: translateX(18px); } }
@keyframes panel-in { from { opacity: 0; transform: translateX(20px); } }
@keyframes pulse-ring { 0% { transform: scale(.7); opacity: .8; } 80%, 100% { transform: scale(1.7); opacity: 0; } }
@keyframes blink { 50% { opacity: .35; } }
@keyframes bounce { to { transform: translateY(-5px); opacity: .45; } }

@media (max-width: 1080px) {
  .transfer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .auth-shell { grid-template-columns: minmax(400px, 50%) 1fr; }
  .visual-copy { left: 45px; width: calc(100% - 90px); }
  .visual-copy h2 { font-size: 45px; }
  .card-one { left: 40px; right: 8%; }
  .storage-layout { gap: 25px; }
  .storage-donut-wrap { gap: 15px; }
  .storage-breakdown { padding-left: 22px; }
}

@media (max-width: 820px) {
  :root { --header-h: 64px; }
  .header-inner { width: calc(100% - 28px); grid-template-columns: auto 1fr auto; }
  .main-nav { justify-self: center; }
  .nav-link { padding: 9px; }
  .nav-link span, .profile-copy, .profile-trigger > svg { display: none; }
  .profile-trigger { min-width: 0; padding: 2px; }
  .nav-link.is-active::after { bottom: -13px; }
  .page-shell, .settings-shell { width: calc(100% - 30px); padding-top: 32px; }
  .page-heading { align-items: flex-start; }
  .upload-composer { flex-direction: column; }
  .upload-status-panel { width: 100%; border-top: 1px solid var(--border); border-left: 0; }
  .upload-status-panel.is-collapsed { width: 100%; height: 58px; }
  .status-panel-body { display: grid; grid-template-columns: auto 1fr; column-gap: 22px; align-items: center; }
  .upload-ring { grid-row: 1 / 4; }
  .status-copy { align-items: flex-start; text-align: left; }
  .status-metrics { margin: 12px 0; }
  .status-actions { justify-content: flex-start; }
  .transfer-options { grid-template-columns: 1fr; }
  .overlay-option { min-height: 68px; }
  .auth-shell { display: block; }
  .auth-panel { min-height: 100vh; }
  .auth-visual { display: none; }
  .settings-layout { grid-template-columns: 1fr; }
  .settings-nav { position: static; display: flex; overflow-x: auto; }
  .settings-nav a { min-width: max-content; }
  .storage-layout { grid-template-columns: 1fr; }
  .storage-breakdown { padding: 25px 0 0; border-top: 1px solid var(--border); border-left: 0; }
  .data-table { min-width: 760px; }
}

@media (max-width: 640px) {
  .input-wrap input, .select-wrap select, .search-field input, .filter-select select,
  .position-field select, .copy-field input, textarea { font-size: 16px; }
  .header-inner { gap: 9px; }
  .brand-word { display: none; }
  .header-actions { gap: 5px; }
  .page-shell { width: calc(100% - 22px); padding-top: 25px; padding-bottom: 45px; }
  .page-heading { margin-bottom: 22px; flex-direction: column; gap: 15px; }
  .page-heading h1 { font-size: 31px; }
  .storage-chip, .health-chip { align-self: stretch; }
  .composer-main { padding: 19px 16px 0; }
  .drop-zone { min-height: 175px; padding: 23px 15px; }
  .drop-hint { text-align: center; }
  .overlay-option { align-items: stretch; flex-direction: column; }
  .position-field { margin-left: 42px; }
  .composer-footer { flex-wrap: wrap; padding: 12px 0; }
  .queue-total { width: 100%; }
  .composer-spacer { display: none; }
  .composer-footer .button { flex: 1; }
  .status-panel-body { display: flex; }
  .status-copy { align-items: center; text-align: center; }
  .status-actions { justify-content: center; }
  .section-toolbar { align-items: stretch; flex-direction: column; }
  .toolbar-actions { display: grid; grid-template-columns: 1fr auto auto; }
  .search-field { min-width: 0; }
  .search-field kbd { display: none; }
  .search-field input { padding-right: 12px; }
  .transfer-grid { grid-template-columns: 1fr; }
  .transfer-card { min-height: 275px; }
  .stat-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
  .stat-card { min-height: 100px; padding: 13px; gap: 9px; }
  .stat-icon { width: 32px; height: 32px; }
  .stat-card > div > strong { font-size: 19px; }
  .admin-tabs { overflow-x: auto; }
  .admin-tab { min-width: max-content; }
  .panel-heading { align-items: flex-start; flex-direction: column; }
  .panel-heading .button { width: 100%; }
  .table-toolbar .search-field { min-width: 0; flex: 1; }
  .job-meta { display: none; }
  .storage-layout { padding: 22px 16px; }
  .storage-donut-wrap { flex-direction: column; text-align: center; }
  .form-grid { grid-template-columns: 1fr; }
  .form-span { grid-column: auto; }
  .modal > form { padding: 25px 19px; }
  .password-gate-banner { align-items: flex-start; flex-wrap: wrap; padding: 16px; }
  .password-gate-banner .button { width: 100%; }
  .settings-card { padding: 0 16px 18px; }
  .settings-nav a small { display: none; }
  .settings-nav a { padding: 10px; }
  .preference-group { align-items: flex-start; flex-direction: column; }
  .theme-picker { width: 100%; }
  .theme-picker button { flex: 1; }
  .share-shell { padding: 85px 11px 40px; }
  .share-header { width: calc(100% - 24px); top: 18px; }
  .share-card { padding: 25px 16px; }
  .share-card-head h1 { font-size: 21px; }
  .error-card { padding: 24px 18px 30px; }
  .error-actions { width: 100%; flex-direction: column; }
  .auth-panel { padding: 27px 22px; }
  .auth-content { padding-top: 75px; }
  .auth-theme { left: 22px; bottom: 20px; }
}

@media (max-width: 380px) {
  .main-nav { gap: 0; }
  .nav-link { padding: 8px; }
  .theme-toggle { display: none; }
  .stat-grid { grid-template-columns: 1fr; }
  .toolbar-actions { grid-template-columns: 1fr auto; }
  .filter-select { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

@media (prefers-contrast: more) {
  :root { --border: #bbb9c7; --border-strong: #85828f; }
  :root[data-theme="dark"] { --border: #656170; --border-strong: #918c9d; }
  .button-primary { background: var(--brand-deep); }
}

/* --------------------------------------------------------------------------
   SULLY / SUMMERHOUSE visual system
   Original, code-built East London estate / control-room direction.
   -------------------------------------------------------------------------- */
:root {
  --bg: #eee9df;
  --bg-raised: #e4dfd5;
  --surface: rgba(246, 242, 233, .94);
  --surface-solid: #f6f2e9;
  --surface-soft: #e9e3d8;
  --surface-hover: #ddd6ca;
  --text: #151917;
  --text-soft: #4e5752;
  --text-faint: #626963;
  --border: #c9c2b6;
  --border-strong: #a9a196;
  --brand: #c46d22;
  --brand-deep: #8c4315;
  --brand-soft: #ead5b8;
  --brand-faint: #f1e5d1;
  --blue: #4d675d;
  --green: #426b59;
  --green-soft: #dce8df;
  --amber: #b8731f;
  --amber-soft: #efe0c5;
  --red: #9c3e34;
  --red-soft: #efdbd7;
  --shadow-sm: 3px 3px 0 rgba(21, 25, 23, .08);
  --shadow-md: 7px 7px 0 rgba(21, 25, 23, .10);
  --shadow-lg: 12px 12px 0 rgba(0, 0, 0, .22);
  --ring: 0 0 0 3px rgba(196, 109, 34, .28);
  --radius-sm: 2px;
  --radius-md: 3px;
  --radius-lg: 5px;
  --radius-xl: 7px;
  --header-h: 68px;
  --content-w: 1320px;
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
}

:root[data-theme="dark"] {
  --bg: #0b0e0d;
  --bg-raised: #101412;
  --surface: rgba(18, 23, 22, .94);
  --surface-solid: #121716;
  --surface-soft: #1b211f;
  --surface-hover: #242b28;
  --text: #e6ded0;
  --text-soft: #a9aaa1;
  --text-faint: #858b85;
  --border: #2e3633;
  --border-strong: #48514d;
  --brand: #d89a36;
  --brand-deep: #e3a644;
  --brand-soft: #3c3020;
  --brand-faint: #251f17;
  --blue: #69877b;
  --green: #6f927f;
  --green-soft: #1d3028;
  --amber: #d89a36;
  --amber-soft: #392d1c;
  --red: #d36658;
  --red-soft: #3b2421;
  --shadow-sm: 3px 3px 0 rgba(0, 0, 0, .34);
  --shadow-md: 7px 7px 0 rgba(0, 0, 0, .4);
  --shadow-lg: 12px 12px 0 rgba(0, 0, 0, .56);
  --ring: 0 0 0 3px rgba(216, 154, 54, .28);
}

html { background: var(--bg); }
body {
  background-color: var(--bg);
  background-image:
    radial-gradient(circle at 15% 9%, color-mix(in srgb, var(--brand) 7%, transparent) 0 1px, transparent 2px),
    repeating-linear-gradient(97deg, transparent 0 88px, color-mix(in srgb, var(--text) 2.5%, transparent) 89px 90px),
    repeating-linear-gradient(2deg, transparent 0 62px, color-mix(in srgb, var(--text) 2%, transparent) 63px 64px);
  background-size: 31px 31px, auto, auto;
}
body::before {
  opacity: .48;
  background:
    linear-gradient(90deg, transparent 0 4%, color-mix(in srgb, var(--brand) 5%, transparent) 4% 4.15%, transparent 4.15% 100%),
    linear-gradient(180deg, transparent 0 73%, color-mix(in srgb, var(--text) 4%, transparent) 73% 73.2%, transparent 73.2% 100%);
}
::selection { background: color-mix(in srgb, var(--brand) 45%, transparent); }

.page-heading h1,
.auth-content h1,
.visual-copy h2,
.share-card h1,
.error-card h1,
.download-command h2 {
  font-family: Impact, Haettenschweiler, "Arial Narrow Bold", "Arial Narrow", sans-serif;
  font-weight: 500;
  letter-spacing: .015em;
  text-transform: uppercase;
}
.page-heading h1 { font-size: clamp(38px, 5vw, 66px); line-height: .92; letter-spacing: .01em; }
.page-heading h1 em, .visual-copy h2 em { color: var(--brand); font-family: inherit; font-style: normal; font-weight: inherit; }
.eyebrow, .secure-label, .status-pill, .role-pill, .output-pill, .queue-live, .browser-support,
.download-stat span, .download-stat small, .download-row-state, .command-index {
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  letter-spacing: .09em;
  text-transform: uppercase;
}
.eyebrow { color: var(--brand-deep); font-size: 13px; }
:root[data-theme="dark"] .eyebrow { color: var(--brand); }
.eyebrow > span { border-radius: 0; }

.surface { border-color: var(--border); background: var(--surface); box-shadow: var(--shadow-sm); }
.app-header {
  background: color-mix(in srgb, var(--bg) 94%, transparent);
  border-bottom: 1px solid var(--border-strong);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}
.app-header::after { display: none; }
.brand { gap: 11px; }
.brand-mark { width: 36px; height: 36px; overflow: visible; border: 1px solid var(--brand); border-radius: 1px; background: var(--text); box-shadow: 4px 4px 0 var(--brand); }
.brand-mark::before, .brand-mark::after { left: 8px; width: 20px; height: 5px; border-radius: 0; background: var(--brand); transform: skewX(-28deg); }
.brand-mark::before { top: 9px; }
.brand-mark::after { bottom: 9px; opacity: 1; }
.brand-arrow::before { right: 4px; top: 7px; border-left-color: var(--surface-solid); }
.brand-arrow::after { left: 4px; bottom: 7px; border-right-color: var(--surface-solid); }
.brand-word { gap: 5px; font-family: Impact, Haettenschweiler, "Arial Narrow Bold", sans-serif; font-size: 19px; letter-spacing: .03em; }
.brand-word strong { color: var(--text); font-weight: 500; }
.brand-word span { color: var(--brand-deep); font: 12px ui-monospace, monospace; letter-spacing: .16em; }
:root[data-theme="dark"] .brand-word span { color: var(--brand); }

.nav-link, .icon-button, .profile-trigger, .profile-popover, .profile-popover a, .menu-button,
.avatar, .button, .input-wrap, .select-wrap select, .search-field, .filter-select, .admin-tab,
.modal, .flash, .toast, .status-pill, .role-pill { border-radius: 2px; }
.nav-link { color: var(--text-soft); font-size: 14px; text-transform: uppercase; letter-spacing: .04em; }
.nav-link.is-active { color: var(--text); background: var(--brand-soft); }
:root[data-theme="dark"] .nav-link.is-active { color: var(--brand); }
.nav-link.is-active::after { left: 9px; right: 9px; height: 3px; border-radius: 0; background: var(--brand); }
.avatar { background: var(--text); color: var(--brand); }
:root[data-theme="dark"] .avatar { background: var(--brand); color: #11140f; }

.button { border-radius: 2px; text-transform: uppercase; letter-spacing: .045em; }
.button-primary { border-color: color-mix(in srgb, var(--brand) 60%, #000); background: var(--brand); color: #151710; box-shadow: 4px 4px 0 color-mix(in srgb, var(--text) 75%, transparent); }
.button-primary:hover:not(:disabled) { background: color-mix(in srgb, var(--brand) 88%, #fff); box-shadow: 6px 6px 0 color-mix(in srgb, var(--text) 75%, transparent); }
.button-secondary { background: var(--surface-solid); }
.button:hover { transform: translate(-1px, -1px); }
.button:active { transform: translate(1px, 1px); box-shadow: 1px 1px 0 transparent; }
.input-wrap, .select-wrap select { background: var(--surface-solid); }
.switch > span { border-radius: 2px; background: var(--border-strong); }
.switch > span::after { border-radius: 1px; box-shadow: none; }
.switch input:checked + span { background: var(--brand); }
.custom-check { border-radius: 1px; }
.text-button, :root[data-theme="dark"] .text-button, :root[data-theme="dark"] .drop-copy u { color: var(--brand); }

.page-shell { position: relative; padding-top: 55px; }
.page-heading { align-items: flex-end; margin-bottom: 34px; }
.page-heading p { max-width: 620px; font-size: 15px; }
.dashboard-shell::before, .downloads-shell::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: 10px;
  right: -4vw;
  width: min(40vw, 500px);
  height: 230px;
  opacity: .12;
  background:
    repeating-linear-gradient(90deg, transparent 0 20px, var(--text) 21px 34px, transparent 35px 48px),
    repeating-linear-gradient(180deg, var(--text) 0 4px, transparent 5px 28px),
    linear-gradient(var(--text), var(--text));
  clip-path: polygon(18% 18%, 76% 18%, 76% 0, 100% 0, 100% 100%, 0 100%, 0 35%, 18% 35%);
}

.storage-chip, .health-chip { border: 1px solid var(--border-strong); border-radius: 2px; background: var(--surface-solid); box-shadow: 3px 3px 0 color-mix(in srgb, var(--text) 13%, transparent); }
.storage-chip i, .storage-chip i b { border-radius: 0; }
.storage-chip i b { background: var(--brand); }

/* Immediate filename-preserving upload */
.upload-composer { border-width: 1px; }
.upload-composer-simple { position: relative; overflow: visible; }
.upload-composer-simple::before { display: none; }
.composer-main { padding-top: 25px; }
.section-heading h2, .section-toolbar h2, .panel-heading h2 { font-family: "Arial Narrow", Arial, sans-serif; text-transform: uppercase; letter-spacing: .04em; }
.heading-icon { border-radius: 1px; background: var(--brand-soft); color: var(--brand-deep); }
.quick-upload-option { margin-bottom: 12px; padding: 10px 12px; display: flex; align-items: center; gap: 18px; border: 1px solid var(--border); background: var(--surface-soft); }
.quick-upload-option .switch-row { min-width: 0; flex: 1; }
.quick-upload-option .switch-icon { border-radius: 1px; background: var(--text); color: var(--brand); }
.quick-upload-option .position-field { min-width: 178px; }
.drop-zone { min-height: 280px; border: 1px dashed var(--border-strong); border-radius: 2px; background-color: color-mix(in srgb, var(--surface-solid) 70%, transparent); background-image: linear-gradient(90deg, color-mix(in srgb, var(--text) 4%, transparent) 1px, transparent 1px), linear-gradient(color-mix(in srgb, var(--text) 4%, transparent) 1px, transparent 1px); background-size: 34px 34px; }
.drop-zone:hover, .drop-zone.is-dragover { border-color: var(--brand); background-color: var(--brand-faint); box-shadow: inset 0 0 0 3px var(--brand), 7px 7px 0 color-mix(in srgb, var(--brand) 20%, transparent); }
.drop-art-back { border-radius: 1px; background: var(--text); transform: rotate(-5deg); }
.drop-art-front { border-radius: 1px; background: var(--brand); color: #111; box-shadow: 4px 4px 0 color-mix(in srgb, var(--text) 60%, transparent); }
.drop-copy strong { font-family: Impact, Haettenschweiler, "Arial Narrow Bold", sans-serif; font-size: 26px; font-weight: 500; letter-spacing: .025em; text-transform: uppercase; }
.drop-hint { font-family: ui-monospace, monospace; font-size: 13px; text-transform: uppercase; letter-spacing: .04em; }
.upload-file, .selected-files { border-radius: 2px; }
.upload-file-icon { border-radius: 1px; }
.upload-file-icon[data-kind="video"], :root[data-theme="dark"] .upload-file-icon[data-kind="video"] { background: var(--green-soft); color: var(--green); }
.upload-file progress, .card-progress progress, .job-progress progress { border-radius: 0; }
.upload-file progress::-webkit-progress-value, .card-progress progress::-webkit-progress-value, .job-progress progress::-webkit-progress-value { background: var(--brand); }
.composer-footer { border-top-style: dashed; }
.upload-status-panel { background: var(--text); color: var(--bg); }
:root[data-theme="dark"] .upload-status-panel { background: #080a09; color: var(--text); }
.upload-status-panel .status-copy span, .upload-status-panel .status-metrics span { color: color-mix(in srgb, currentColor 65%, transparent); }
.ring-value { stroke: var(--brand); }

/* Transfer cards become production dockets instead of SaaS tiles. */
.transfer-grid { gap: 14px; }
.transfer-card { border-radius: 2px; box-shadow: 4px 4px 0 color-mix(in srgb, var(--text) 10%, transparent); }
.transfer-accent { top: 0; bottom: 0; left: 0; width: 4px; height: auto; border-radius: 0; background: var(--brand); }
.transfer-type-icon { border-radius: 1px; background: var(--text); color: var(--brand); }
.transfer-title h3 { font-family: "Arial Narrow", Arial, sans-serif; letter-spacing: .02em; text-transform: uppercase; }
.transfer-files-preview > div { border-radius: 1px; background: var(--surface-soft); }
.status-pill { border-radius: 1px; }
.card-menu, .inline-action-menu { border-radius: 2px; box-shadow: var(--shadow-md); }

/* Operations */
.stat-grid { gap: 12px; }
.stat-card, .admin-panel, .settings-card, .settings-nav { border-radius: 2px; }
.stat-card { border-top: 3px solid var(--brand); }
.stat-icon { border-radius: 1px; background: var(--text) !important; color: var(--brand) !important; }
.admin-tabs { border-bottom: 1px solid var(--border-strong); }
.admin-tab { text-transform: uppercase; letter-spacing: .04em; }
.admin-tab.is-active { color: var(--text); background: var(--brand-soft); }
.admin-tab.is-active::after { border-radius: 0; background: var(--brand); }
.data-table th { font: 12px ui-monospace, monospace; letter-spacing: .09em; text-transform: uppercase; }
.security-callout, :root[data-theme="dark"] .security-callout { border-radius: 2px; background: var(--green-soft); }

/* Download room */
.downloads-heading { margin-bottom: 24px; }
.queue-live { min-width: 170px; padding: 10px 12px; display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 2px 8px; border: 1px solid var(--border-strong); background: var(--surface-solid); font-size: 12px; }
.queue-live i { grid-row: 1 / 3; width: 9px; height: 9px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 4px color-mix(in srgb, var(--green) 18%, transparent); }
.queue-live strong { color: var(--text-soft); font: 13px ui-monospace, monospace; text-transform: none; letter-spacing: 0; }
.download-command { position: relative; padding: 24px; display: grid; grid-template-columns: minmax(280px, 1.5fr) minmax(180px, .7fr) auto; align-items: center; gap: 24px; border-left: 5px solid var(--brand); }
.download-command::after { display: none; }
.command-copy { display: flex; align-items: flex-start; gap: 14px; }
.command-index { padding-top: 4px; color: var(--brand-deep); font-size: 13px; }
:root[data-theme="dark"] .command-index { color: var(--brand); }
.command-copy h2 { margin: 0 0 5px; font-size: 25px; }
.command-copy p { max-width: 600px; margin: 0; color: var(--text-soft); font-size: 14px; }
.folder-status { min-width: 0; padding: 10px; display: flex; align-items: center; gap: 9px; border: 1px dashed var(--border-strong); }
.folder-status.is-selected { border-style: solid; border-color: var(--green); background: var(--green-soft); }
.folder-status svg { width: 22px; height: 22px; fill: none; stroke: var(--brand); stroke-width: 1.7; }
.folder-status div { min-width: 0; display: flex; flex-direction: column; }
.folder-status span { color: var(--text-faint); font: 12px ui-monospace, monospace; letter-spacing: .08em; text-transform: uppercase; }
.folder-status strong { overflow: hidden; text-overflow: ellipsis; font-size: 14px; white-space: nowrap; }
.command-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }
.browser-support { grid-column: 1 / -1; margin: -7px 0 0; display: flex; align-items: center; gap: 7px; color: var(--green); font-size: 12px; }
.browser-support span { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.browser-support.has-warning { color: var(--amber); }
.download-stats { margin: 14px 0 34px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; border: 1px solid var(--border); background: var(--border); }
.download-stat { position: relative; min-height: 92px; padding: 14px 17px; display: grid; grid-template-columns: 1fr auto; align-items: center; background: var(--surface-solid); }
.download-stat::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--brand); }
.download-stat.is-processing::before { background: var(--amber); }
.download-stat.is-complete::before { background: var(--green); }
.download-stat span { align-self: end; color: var(--text-soft); font-size: 12px; }
.download-stat strong { grid-row: 1 / 3; grid-column: 2; font: 38px Impact, Haettenschweiler, sans-serif; }
.download-stat small { align-self: start; color: var(--text-faint); font-size: 12px; }
.download-library { position: relative; }
.download-toolbar { align-items: end; }
.segmented-control { display: flex; border: 1px solid var(--border-strong); background: var(--surface-solid); }
.segmented-control button { min-height: 38px; padding: 7px 12px; border: 0; border-right: 1px solid var(--border); background: transparent; color: var(--text-soft); font-size: 13px; }
.segmented-control button:last-child { border-right: 0; }
.segmented-control button.is-active { background: var(--text); color: var(--bg); }
.download-list { overflow: hidden; }
.download-row { min-height: 92px; padding: 13px 15px; display: grid; grid-template-columns: 48px 44px minmax(0, 1fr) 150px auto; align-items: center; gap: 12px; border-bottom: 1px solid var(--border); }
.download-row:last-child { border-bottom: 0; }
.download-row:hover { background: var(--surface-soft); }
.download-row[data-delivery-state="downloaded"] { opacity: .72; }
.download-row-state { align-self: stretch; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 7px; border-right: 1px solid var(--border); color: var(--text-faint); font-size: 12px; }
.download-row-state i { width: 8px; height: 8px; border-radius: 50%; background: var(--brand); }
.download-row[data-delivery-state="downloaded"] .download-row-state i { background: var(--green); }
.download-file-icon { width: 40px; height: 46px; display: grid; place-items: center; border: 1px solid var(--border-strong); background: var(--text); color: var(--brand); box-shadow: 3px 3px 0 color-mix(in srgb, var(--brand) 25%, transparent); }
.download-file-icon svg { width: 23px; height: 23px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.download-file-copy { min-width: 0; }
.download-file-copy > div:first-child { display: flex; align-items: center; gap: 8px; }
.download-file-copy strong { overflow: hidden; text-overflow: ellipsis; font-size: 14px; white-space: nowrap; }
.output-pill { flex: 0 0 auto; padding: 2px 5px; border: 1px solid color-mix(in srgb, var(--brand) 50%, var(--border)); color: var(--brand-deep); font-size: 12px; }
:root[data-theme="dark"] .output-pill { color: var(--brand); }
.output-pill.is-original { color: var(--red); border-color: color-mix(in srgb, var(--red) 45%, var(--border)); }
.download-file-copy p { margin: 4px 0 0; display: flex; align-items: center; gap: 6px; overflow: hidden; color: var(--text-faint); font-size: 13px; white-space: nowrap; }
.download-file-copy p span { overflow: hidden; text-overflow: ellipsis; }
.download-file-copy p i { font-style: normal; }
.download-file-meta { min-width: 0; display: flex; flex-direction: column; align-items: flex-end; }
.download-file-meta strong { font: 13px ui-monospace, monospace; }
.download-file-meta span { margin-top: 4px; color: var(--text-faint); font-size: 12px; text-align: right; }
.download-row-actions { display: flex; justify-content: flex-end; gap: 4px; }
.row-progress { margin-top: 8px; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 8px; }
.row-progress progress, .download-progress-dock progress { width: 100%; height: 5px; appearance: none; border: 0; border-radius: 0; background: var(--border); }
.row-progress progress::-webkit-progress-bar, .download-progress-dock progress::-webkit-progress-bar { background: var(--border); }
.row-progress progress::-webkit-progress-value, .download-progress-dock progress::-webkit-progress-value { background: var(--brand); }
.row-progress span { font: 12px ui-monospace, monospace; }
.download-empty { border: 1px solid var(--border); background: var(--surface); }
.download-progress-dock { position: fixed; z-index: 250; right: 22px; bottom: 22px; width: min(510px, calc(100% - 44px)); padding: 16px; border-left: 4px solid var(--brand); box-shadow: var(--shadow-lg); }
.progress-dock-head { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 10px; }
.progress-dock-head > div { min-width: 0; }
.progress-dock-head strong, .progress-dock-head span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.progress-dock-head strong { font-size: 14px; }
.progress-dock-head span { color: var(--text-soft); font-size: 12px; }
.progress-dock-head b { font: 25px Impact, Haettenschweiler, sans-serif; }
.download-progress-dock > progress { margin-top: 12px; height: 8px; }
.progress-dock-meta { margin-top: 8px; display: flex; justify-content: space-between; color: var(--text-faint); font: 12px ui-monospace, monospace; text-transform: uppercase; }

/* Login / share: hard architectural field instead of floating SaaS gradients. */
.auth-panel { background: var(--surface-solid); border-right: 1px solid var(--border-strong); }
.auth-content h1 { font-size: clamp(44px, 5.2vw, 75px); line-height: .9; }
.auth-visual { background: #101412; }
.auth-visual::before { content: ""; position: absolute; inset: 8% 5% 0 18%; opacity: .36; background: repeating-linear-gradient(90deg, transparent 0 28px, #d89a36 29px 37px, transparent 38px 61px), repeating-linear-gradient(180deg, #29302d 0 6px, transparent 7px 43px), linear-gradient(90deg, #1c2220 0 38%, transparent 38% 45%, #1c2220 45% 100%); clip-path: polygon(8% 14%, 38% 14%, 38% 0, 72% 0, 72% 22%, 100% 22%, 100% 100%, 0 100%, 0 32%, 8% 32%); }
.visual-grid { opacity: .12; background-image: linear-gradient(rgba(216,154,54,.28) 1px, transparent 1px), linear-gradient(90deg, rgba(216,154,54,.28) 1px, transparent 1px); }
.visual-copy { z-index: 2; }
.visual-copy h2 { font-size: clamp(48px, 5vw, 78px); line-height: .88; }
.visual-badge { border-radius: 1px; background: #d89a36; color: #111; font-family: ui-monospace, monospace; text-transform: uppercase; }
.visual-badge span { background: #111; box-shadow: 0 0 0 4px rgba(17,17,17,.12); }
.visual-transfer-card { z-index: 2; border: 1px solid #48514d; border-radius: 2px; background: rgba(11, 14, 13, .92); box-shadow: 7px 7px 0 rgba(0,0,0,.45); }
.mini-file-icon { border-radius: 1px; background: var(--brand-soft); }
.mini-file-icon::before { border-left-color: var(--brand); }
.visual-transfer-card > b { color: var(--brand); }
.mini-progress i { background: var(--brand); }
.mini-success { border-radius: 1px; background: var(--green-soft); color: var(--green); }
.visual-lock { border-radius: 2px; }
.visual-orb { display: none; }
.share-backdrop { background: var(--bg); }
.share-grid { opacity: .25; }
.share-card { border-radius: 2px; box-shadow: var(--shadow-md); }
.share-hero-icon, .shared-file, .shared-file-icon { border-radius: 1px; }
.share-hero-icon { background: var(--brand); color: #151710; box-shadow: 4px 4px 0 color-mix(in srgb, var(--text) 65%, transparent); }
.shared-file-icon.file-video, :root[data-theme="dark"] .shared-file-icon.file-video { background: var(--green-soft); color: var(--green); }

@media (max-width: 1080px) {
  .download-command { grid-template-columns: 1fr 1fr; }
  .command-copy { grid-column: 1 / -1; }
  .download-row { grid-template-columns: 38px 40px minmax(0, 1fr) 125px; }
  .download-row-actions { grid-column: 3 / -1; }
}

@media (max-width: 820px) {
  .app-header::after { display: none; }
  .quick-upload-option { align-items: stretch; flex-direction: column; }
  .quick-upload-option .position-field { min-width: 0; margin-left: 42px; }
  .download-command { grid-template-columns: 1fr; }
  .command-copy, .browser-support { grid-column: auto; }
  .command-actions { justify-content: stretch; }
  .command-actions .button { flex: 1; }
  .download-toolbar { align-items: stretch; }
  .download-toolbar .toolbar-actions { flex-wrap: wrap; }
  .download-row { grid-template-columns: 34px 38px minmax(0, 1fr); }
  .download-file-meta { grid-column: 3; align-items: flex-start; }
  .download-file-meta span { text-align: left; }
  .download-row-actions { grid-column: 3; justify-content: flex-start; flex-wrap: wrap; }
}

@media (max-width: 640px) {
  .page-heading h1 { font-size: 45px; }
  .drop-zone { min-height: 230px; }
  .drop-copy strong { font-size: 21px; text-align: center; }
  .download-stats { grid-template-columns: 1fr; }
  .download-stat { min-height: 76px; }
  .download-toolbar .toolbar-actions { display: flex; }
  .segmented-control { width: 100%; overflow-x: auto; }
  .segmented-control button { flex: 1; white-space: nowrap; }
  .download-toolbar .search-field { flex: 1; }
  .download-row { padding: 12px 9px; gap: 8px; }
  .download-row-state { display: none; }
  .download-row { grid-template-columns: 38px minmax(0, 1fr); }
  .download-file-meta, .download-row-actions { grid-column: 2; }
  .output-pill { display: none; }
  .download-progress-dock { right: 10px; bottom: 10px; width: calc(100% - 20px); }
  .progress-dock-meta span:nth-child(2) { display: none; }
}

/* Night-only, single-action upload flow. */
.dashboard-shell::before { display: none; }
.upload-stage { width: min(880px, 100%); margin: 0 auto 64px; }
.upload-stage-head { margin-bottom: 22px; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 28px; }
.upload-stage-head h1 { margin: 0; font-family: inherit; font-size: clamp(42px, 5vw, 60px); font-weight: 720; line-height: 1; letter-spacing: -.045em; text-transform: none; }
.upload-stage-head p { max-width: 580px; margin: 10px 0 0; color: var(--text-soft); font-size: 16px; line-height: 1.55; }
.upload-stage .storage-chip { min-width: 176px; box-shadow: none; }

.upload-stage .upload-composer { display: block; overflow: hidden; border: 1px solid var(--border-strong); border-radius: 18px; background: var(--surface-solid); box-shadow: 0 24px 70px rgba(0, 0, 0, .26); }
.upload-stage .upload-composer.is-queue-dragover::after { content: "Drop to queue another transfer"; position: absolute; z-index: 20; inset: 12px; display: grid; place-items: center; border: 2px dashed var(--brand); border-radius: 13px; background: color-mix(in srgb, #0b0e0d 91%, transparent); color: var(--text); font-size: 18px; font-weight: 720; pointer-events: none; }
.upload-stage .composer-main { padding: 24px; }
.upload-stage .upload-form { display: block; }
.upload-stage .drop-zone { min-height: 300px; padding: 42px 28px; border: 1px dashed #57605c; border-radius: 14px; background: #0e1211; background-image: none; box-shadow: none; }
.upload-stage .drop-zone::before { display: none; }
.upload-stage .drop-zone:hover, .upload-stage .drop-zone.is-dragover { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 7%, #0e1211); box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--brand) 34%, transparent), 0 0 0 4px color-mix(in srgb, var(--brand) 9%, transparent); transform: none; }
.upload-stage .drop-art { width: 70px; height: 70px; margin-bottom: 20px; }
.upload-stage .drop-art-front { inset: 0; width: 70px; height: 70px; border-radius: 50%; background: var(--brand); color: #11140f; box-shadow: none; transform: none; }
.upload-stage .drop-art-front::before { display: none; }
.upload-stage .drop-art-front svg { width: 30px; height: 30px; stroke-width: 1.8; }
.upload-stage .drop-copy { gap: 4px; color: var(--text-soft); font-size: 16px; line-height: 1.4; }
.upload-stage .drop-copy strong { font-family: inherit; font-size: 24px; font-weight: 720; letter-spacing: -.02em; text-transform: none; }
.upload-stage .drop-hint { max-width: 520px; margin-top: 14px; color: var(--text-faint); font-family: inherit; font-size: 13px; line-height: 1.5; letter-spacing: 0; text-align: center; text-transform: none; }

.upload-stage .selected-files { margin: 0; }
.upload-stage .selected-head { min-height: 42px; margin-bottom: 8px; }
.upload-stage .selected-head strong { font-size: 16px; }
.upload-stage .selected-head span { font-size: 13px; }
.upload-stage .queue-transfer-button { min-height: 38px; flex: none; font-size: 14px; }
.upload-stage .upload-file-list { max-height: 360px; gap: 8px; }
.upload-stage .upload-file { min-height: 70px; padding: 11px 12px; border-color: var(--border); border-radius: 11px; background: var(--surface-soft); }
.upload-stage .upload-file-icon { width: 44px; height: 44px; border-radius: 10px; }
.upload-stage .upload-file-line strong { font-size: 15px; }
.upload-stage .upload-file-line span, .upload-stage .upload-file-main > small { font-size: 13px; }
.upload-stage .file-progress-row progress { height: 6px; }
.upload-stage .file-progress-row span { width: 38px; font-size: 13px; }

.upload-stage .quick-upload-option { margin: 18px 0 0; padding: 14px 16px; border-color: var(--border); border-radius: 12px; background: var(--surface-soft); }
.upload-stage .quick-upload-option .switch-icon { border-radius: 9px; background: #0a0d0c; color: var(--brand); }
.upload-stage .switch-copy strong { font-size: 14px; text-transform: none; }
.upload-stage .switch-copy small { margin-top: 2px; font-size: 13px; }
.upload-stage .quick-upload-option .position-field { min-width: 180px; }
.upload-stage .position-field > span { margin-bottom: 5px; font-size: 12px; }
.upload-stage .position-field select { height: 39px; padding-right: 34px; border-color: var(--border-strong); border-radius: 8px; background: #0d1110; font-size: 14px; }
.upload-stage .position-field svg { right: 10px; bottom: 12px; }

.upload-stage .queue-total { display: none !important; }
.upload-stage .composer-footer { min-height: 0; margin: 0; display: none; border: 0; }
.upload-stage .composer-footer:has([data-start-upload]:not([hidden])),
.upload-stage .composer-footer:has([data-clear-files]:not([hidden])) { margin-top: 16px; padding-top: 16px; display: flex; border-top: 1px solid var(--border); }

.upload-stage .upload-status-panel { width: auto; border-top: 1px solid var(--border-strong); border-left: 0; background: #0a0e0d; color: var(--text); }
.upload-stage .status-panel-head { height: auto; min-height: 58px; padding: 16px 22px 8px; display: grid; grid-template-columns: minmax(0, 1fr) auto; border: 0; }
.upload-stage .status-panel-head > div:first-child { display: flex; color: var(--text-soft); font-family: inherit; font-size: 13px; font-weight: 720; letter-spacing: .04em; text-transform: uppercase; }
.upload-stage .upload-total { display: flex; align-items: baseline; justify-content: flex-end; gap: 2px; color: var(--text); letter-spacing: 0; }
.upload-stage .upload-total strong { font-size: 28px; line-height: 1; }
.upload-stage .upload-total span { color: var(--text-soft); font-size: 14px; }
.upload-stage .status-panel-body { padding: 6px 22px 20px; display: grid; grid-template-columns: minmax(190px, 1fr) minmax(320px, auto) auto; align-items: center; gap: 24px; }
.upload-stage .status-copy { margin: 0; align-items: flex-start; text-align: left; }
.upload-stage .status-copy strong { font-size: 15px; }
.upload-stage .status-copy span { margin-top: 3px; font-size: 13px; }
.upload-stage .status-metrics { width: auto; min-width: 320px; margin: 0; padding: 0; border: 0; }
.upload-stage .status-metrics > div { min-width: 96px; padding: 2px 14px; align-items: flex-start; }
.upload-stage .status-metrics > div:first-child { padding-left: 0; }
.upload-stage .status-metrics span { font-size: 12px; }
.upload-stage .status-metrics strong { margin-top: 2px; font-size: 14px; }
.upload-stage .status-actions { width: auto; justify-content: flex-end; }
.upload-stage .upload-status-panel.is-collapsed { width: auto; height: auto; }

.upload-stage .queued-transfers { margin-top: 14px; overflow: hidden; border: 1px solid var(--border-strong); border-radius: 14px; background: var(--surface-solid); box-shadow: none; }
.upload-stage .queued-transfers-head { min-height: 68px; padding: 13px 16px; display: flex; align-items: center; justify-content: space-between; gap: 18px; border-bottom: 1px solid var(--border); }
.upload-stage .queued-transfers-head h2 { margin: 0; font-family: inherit; font-size: 17px; font-weight: 720; letter-spacing: 0; text-transform: none; }
.upload-stage .queued-transfers-head p { margin: 3px 0 0; color: var(--text-faint); font-size: 14px; }
.upload-stage .queued-transfers-head > span { flex: none; color: var(--text-soft); font-size: 14px; }
.upload-stage .queued-transfer-list { display: grid; }
.upload-stage .queued-transfer { min-height: 66px; padding: 10px 12px; display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; align-items: center; gap: 12px; border-bottom: 1px solid var(--border); }
.upload-stage .queued-transfer:last-child { border-bottom: 0; }
.upload-stage .queued-transfer-icon { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 10px; background: var(--surface-soft); color: var(--brand); }
.upload-stage .queued-transfer-icon svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.55; stroke-linecap: round; stroke-linejoin: round; }
.upload-stage .queued-transfer-copy { min-width: 0; display: flex; flex-direction: column; }
.upload-stage .queued-transfer-copy strong { overflow: hidden; text-overflow: ellipsis; font-size: 15px; white-space: nowrap; }
.upload-stage .queued-transfer-copy span { margin-top: 2px; color: var(--text-faint); font-size: 14px; }
.upload-stage .queued-transfer-state { display: inline-flex; align-items: center; gap: 7px; color: var(--text-soft); font-size: 14px; }
.upload-stage .queued-transfer-state i { width: 7px; height: 7px; border-radius: 50%; background: var(--brand); }

.dashboard-shell > .transfers-section { margin-top: 0; }

@media (max-width: 820px) {
  .upload-stage { margin-bottom: 48px; }
  .upload-stage-head { grid-template-columns: 1fr; align-items: start; gap: 18px; }
  .upload-stage .storage-chip { width: 100%; }
  .upload-stage .upload-composer { flex-direction: initial; }
  .upload-stage .quick-upload-option { align-items: center; flex-direction: row; }
  .upload-stage .quick-upload-option .position-field { margin-left: 0; }
  .upload-stage .status-panel-body { grid-template-columns: minmax(0, 1fr) auto; }
  .upload-stage .status-metrics { grid-column: 1 / -1; grid-row: 2; width: 100%; }
  .upload-stage .status-actions { grid-column: 2; grid-row: 1; }
}

@media (max-width: 640px) {
  .dashboard-shell { padding-top: 34px; }
  .upload-stage-head h1 { font-size: 40px; }
  .upload-stage-head p { font-size: 15px; }
  .upload-stage .composer-main { padding: 16px; }
  .upload-stage .drop-zone { min-height: 250px; padding: 34px 18px; }
  .upload-stage .drop-copy strong { font-size: 22px; }
  .upload-stage .drop-hint { font-size: 13px; }
  .upload-stage .quick-upload-option { align-items: stretch; flex-direction: column; }
  .upload-stage .quick-upload-option .position-field { width: 100%; min-width: 0; margin-left: 0; padding-left: 42px; }
  .upload-stage .status-panel-head { padding: 15px 16px 8px; }
  .upload-stage .status-panel-body { padding: 6px 16px 18px; display: flex; align-items: stretch; gap: 16px; }
  .upload-stage .status-metrics { min-width: 0; }
  .upload-stage .status-metrics > div { min-width: 0; padding: 2px 9px; }
  .upload-stage .status-actions { justify-content: flex-start; }
  .upload-stage .status-actions .button { flex: 1; }
  .upload-stage .selected-head { align-items: stretch; flex-direction: column; gap: 10px; }
  .upload-stage .queue-transfer-button { width: 100%; }
  .upload-stage .queued-transfer { grid-template-columns: auto minmax(0, 1fr) auto; }
  .upload-stage .queued-transfer-state { grid-column: 2; }
  .upload-stage .queued-transfer > .icon-button { grid-column: 3; grid-row: 1 / 3; }
}
