:root {
    --ink: #111319;
    --ink-soft: #333640;
    --muted: #737783;
    --muted-2: #9ba0aa;
    --bg: #f4f5f1;
    --surface: #ffffff;
    --surface-2: #f8f8f6;
    --surface-3: #eff0ed;
    --line: #e2e4df;
    --line-strong: #d3d6cf;
    --accent: #5b5cff;
    --accent-rgb: 91, 92, 255;
    --accent-soft: #ececff;
    --lime: #d9ff66;
    --lime-ink: #1c2800;
    --danger: #db3a4a;
    --danger-soft: #fff0f1;
    --success: #148966;
    --warning: #d58a00;
    --sidebar: #101217;
    --sidebar-2: #171a21;
    --sidebar-text: #f4f5f7;
    --sidebar-muted: #9297a3;
    --radius-sm: 10px;
    --radius: 16px;
    --radius-lg: 24px;
    --radius-xl: 32px;
    --shadow-sm: 0 1px 2px rgba(16, 18, 23, .05), 0 8px 24px rgba(16, 18, 23, .04);
    --shadow: 0 18px 60px rgba(18, 20, 28, .12);
    --sidebar-width: 252px;
    --ai-width: 356px;
    font-synthesis: none;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
    margin: 0;
    color: var(--ink);
    background: var(--bg);
    font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 14px;
    line-height: 1.45;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    overflow: hidden;
}
button, input, textarea, select { font: inherit; }
button { color: inherit; }
a { color: inherit; text-decoration: none; }
svg { display: block; }
::selection { background: rgba(var(--accent-rgb), .18); }

.app-root { min-height: 100%; }

/* Brand */
.brand-lockup { display: inline-flex; align-items: center; gap: 7px; min-width: 0; }
.brand-word { font-weight: 800; font-size: 20px; letter-spacing: -.8px; color: currentColor; }
.brand-product { font-weight: 500; font-size: 17px; color: var(--muted-2); letter-spacing: -.35px; }
.brand-mark { position: relative; width: 29px; height: 29px; display: inline-block; flex: 0 0 29px; }
.brand-mark i, .brand-mark b {
    position: absolute; width: 15px; height: 15px; border: 2px solid currentColor; border-radius: 5px; transform: rotate(45deg);
}
.brand-mark i { left: 2px; top: 6px; opacity: .92; }
.brand-mark b { right: 2px; top: 6px; }
.brand-mark em { position: absolute; width: 5px; height: 5px; border-radius: 99px; background: var(--lime); left: 12px; top: 12px; box-shadow: 0 0 0 3px rgba(217,255,102,.13); }

/* Boot */
.boot-screen {
    height: 100vh; display: grid; place-content: center; justify-items: center; gap: 22px;
    background:
        radial-gradient(circle at 50% 40%, rgba(91,92,255,.10), transparent 30%),
        linear-gradient(var(--bg), var(--bg));
}
.brand-lockup--boot { color: var(--ink); transform: scale(1.12); }
.boot-line { width: 148px; height: 3px; background: #e2e3de; border-radius: 99px; overflow: hidden; }
.boot-line span { display: block; width: 48%; height: 100%; background: var(--accent); border-radius: inherit; animation: boot 1.3s ease-in-out infinite alternate; }
.boot-screen p { margin: -8px 0 0; color: var(--muted); font-size: 13px; }
@keyframes boot { from { transform: translateX(-90%); } to { transform: translateX(200%); } }

/* Auth */
.auth-shell {
    height: 100vh; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(420px, .85fr); background: #f6f6f2;
}
.auth-story {
    position: relative; overflow: hidden; padding: clamp(34px, 5vw, 72px); color: #f7f8fa;
    background:
        radial-gradient(circle at 82% 18%, rgba(217,255,102,.17), transparent 22%),
        radial-gradient(circle at 20% 75%, rgba(91,92,255,.32), transparent 34%),
        #101217;
    display: flex; flex-direction: column; justify-content: space-between;
}
.auth-story::before {
    content: ""; position: absolute; inset: 0; opacity: .14;
    background-image: linear-gradient(rgba(255,255,255,.16) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.16) 1px, transparent 1px);
    background-size: 42px 42px;
    mask-image: linear-gradient(to bottom, black, transparent 86%);
}
.auth-story > * { position: relative; z-index: 1; }
.auth-story .brand-product { color: #9ca1ae; }
.auth-headline { max-width: 760px; margin: auto 0; padding: 60px 0; }
.auth-kicker { display: inline-flex; align-items: center; gap: 9px; color: #c7cad1; font-size: 12px; letter-spacing: .11em; text-transform: uppercase; font-weight: 700; }
.auth-kicker::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--lime); box-shadow: 0 0 0 6px rgba(217,255,102,.10); }
.auth-headline h1 { max-width: 740px; margin: 22px 0 20px; font-size: clamp(46px, 6vw, 86px); line-height: .96; letter-spacing: -.065em; font-weight: 720; }
.auth-headline h1 span { color: var(--lime); }
.auth-headline p { max-width: 630px; color: #b7bbc4; font-size: clamp(16px, 1.4vw, 20px); line-height: 1.6; margin: 0; }
.auth-benefits { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; max-width: 820px; }
.auth-benefit { padding: 15px 16px; border: 1px solid rgba(255,255,255,.10); background: rgba(255,255,255,.045); border-radius: 15px; backdrop-filter: blur(8px); }
.auth-benefit strong { display: block; font-size: 13px; margin-bottom: 3px; }
.auth-benefit span { color: #8f95a1; font-size: 12px; }
.auth-graph { position: absolute; right: -80px; bottom: 42px; width: 480px; height: 330px; opacity: .56; pointer-events: none; }
.graph-node { position: absolute; width: 13px; height: 13px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 6px rgba(255,255,255,.08); }
.graph-node:nth-child(1) { left: 15%; top: 48%; background: var(--lime); }
.graph-node:nth-child(2) { left: 43%; top: 18%; }
.graph-node:nth-child(3) { left: 70%; top: 39%; background: #8d8eff; }
.graph-node:nth-child(4) { left: 42%; top: 72%; }
.graph-node:nth-child(5) { left: 86%; top: 78%; background: var(--lime); }
.graph-line { position: absolute; height: 1px; transform-origin: 0 50%; background: linear-gradient(90deg, rgba(255,255,255,.65), rgba(255,255,255,.08)); }
.graph-line:nth-of-type(1) { width: 180px; left: 18%; top: 49%; transform: rotate(-31deg); }
.graph-line:nth-of-type(2) { width: 160px; left: 45%; top: 20%; transform: rotate(26deg); }
.graph-line:nth-of-type(3) { width: 190px; left: 17%; top: 50%; transform: rotate(30deg); }
.graph-line:nth-of-type(4) { width: 205px; left: 44%; top: 73%; transform: rotate(2deg); }
.graph-line:nth-of-type(5) { width: 170px; left: 44%; top: 72%; transform: rotate(-53deg); }

.auth-panel { position: relative; display: grid; place-items: center; padding: 36px; background: #f6f6f2; overflow-y: auto; }
.auth-panel::before { content: ""; position: absolute; width: 300px; height: 300px; border-radius: 50%; background: rgba(91,92,255,.07); filter: blur(70px); top: 8%; right: -80px; }
.auth-card { position: relative; width: min(100%, 430px); background: rgba(255,255,255,.86); border: 1px solid rgba(210,212,207,.85); border-radius: 28px; padding: 32px; box-shadow: var(--shadow); backdrop-filter: blur(18px); }
.auth-card h2 { font-size: 30px; line-height: 1.1; letter-spacing: -.04em; margin: 0 0 8px; }
.auth-card > p { margin: 0 0 26px; color: var(--muted); }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; background: #f0f1ee; padding: 4px; border-radius: 12px; margin-bottom: 24px; }
.auth-tab { border: 0; background: transparent; border-radius: 9px; padding: 10px; color: var(--muted); cursor: pointer; font-weight: 650; }
.auth-tab.is-active { background: #fff; color: var(--ink); box-shadow: 0 1px 4px rgba(0,0,0,.07); }
.form-stack { display: grid; gap: 15px; }
.field { display: grid; gap: 7px; }
.field label { font-size: 12px; font-weight: 700; color: var(--ink-soft); }
.field-input { width: 100%; border: 1px solid var(--line); border-radius: 12px; padding: 12px 13px; background: #fff; color: var(--ink); outline: none; transition: border-color .18s, box-shadow .18s; }
.field-input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(var(--accent-rgb), .10); }
.field-hint { color: var(--muted); font-size: 11px; }
.auth-submit { margin-top: 5px; width: 100%; border: 0; border-radius: 13px; background: var(--ink); color: #fff; padding: 13px 16px; font-weight: 700; cursor: pointer; display: inline-flex; justify-content: center; align-items: center; gap: 9px; transition: transform .17s, background .17s; }
.auth-submit:hover { background: #242733; transform: translateY(-1px); }
.auth-submit:disabled { opacity: .65; cursor: wait; transform: none; }
.auth-demo { margin-top: 18px; padding: 12px 13px; border-radius: 12px; background: var(--accent-soft); color: #3738a2; font-size: 12px; display: flex; gap: 9px; align-items: flex-start; }
.auth-demo strong { display: block; }
.auth-legal { text-align: center; margin-top: 18px; color: var(--muted-2); font-size: 11px; }

/* App shell */
.workspace-shell { height: 100vh; display: grid; grid-template-columns: var(--sidebar-width) minmax(0, 1fr) var(--ai-width); background: var(--bg); overflow: hidden; }
.workspace-shell.ai-closed { grid-template-columns: var(--sidebar-width) minmax(0, 1fr) 0; }
.sidebar { min-width: 0; height: 100vh; background: var(--sidebar); color: var(--sidebar-text); padding: 18px 14px 16px; display: flex; flex-direction: column; overflow: hidden; position: relative; }
.sidebar::after { content: ""; position: absolute; width: 210px; height: 210px; border-radius: 50%; background: rgba(91,92,255,.15); filter: blur(60px); left: -100px; bottom: -80px; pointer-events: none; }
.sidebar .brand-lockup { padding: 4px 9px 17px; color: #fff; }
.sidebar .brand-product { color: #7f8591; }
.space-switcher { position: relative; margin-bottom: 18px; }
.space-switcher-btn { width: 100%; display: grid; grid-template-columns: 34px minmax(0,1fr) 18px; align-items: center; gap: 10px; border: 1px solid rgba(255,255,255,.08); background: rgba(255,255,255,.055); color: #fff; padding: 8px; border-radius: 13px; cursor: pointer; text-align: left; }
.space-switcher-btn:hover { background: rgba(255,255,255,.08); }
.space-avatar { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; color: #fff; font-weight: 800; font-size: 12px; box-shadow: inset 0 0 0 1px rgba(255,255,255,.20); }
.space-switcher-copy { min-width: 0; }
.space-switcher-copy strong, .space-switcher-copy span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.space-switcher-copy strong { font-size: 12px; }
.space-switcher-copy span { font-size: 10px; color: var(--sidebar-muted); margin-top: 1px; }
.space-menu { position: absolute; z-index: 50; top: calc(100% + 8px); left: 0; right: 0; background: #20232b; border: 1px solid rgba(255,255,255,.1); border-radius: 14px; padding: 7px; box-shadow: 0 18px 48px rgba(0,0,0,.34); display: none; max-height: 320px; overflow: auto; }
.space-menu.is-open { display: block; animation: menuIn .15s ease-out; }
.space-menu-item { width: 100%; border: 0; background: transparent; color: #f5f6f8; padding: 8px; border-radius: 10px; display: grid; grid-template-columns: 31px minmax(0,1fr) 18px; gap: 9px; align-items: center; text-align: left; cursor: pointer; }
.space-menu-item:hover, .space-menu-item.is-active { background: rgba(255,255,255,.07); }
.space-menu-item .space-avatar { width: 31px; height: 31px; border-radius: 9px; }
.space-menu-item strong { display: block; font-size: 11px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.space-menu-item span { color: #8f95a2; font-size: 9px; }
.space-menu-add { border-top: 1px solid rgba(255,255,255,.08); margin-top: 5px; padding-top: 5px; }
.sidebar-section-title { padding: 0 10px 7px; color: #646a76; text-transform: uppercase; font-size: 9px; font-weight: 800; letter-spacing: .14em; }
.sidebar-nav { display: grid; gap: 3px; }
.nav-btn { width: 100%; border: 0; background: transparent; color: #aeb3bd; min-height: 38px; border-radius: 11px; padding: 0 10px; display: flex; align-items: center; gap: 10px; cursor: pointer; text-align: left; position: relative; }
.nav-btn:hover { background: rgba(255,255,255,.055); color: #fff; }
.nav-btn.is-active { background: rgba(255,255,255,.09); color: #fff; }
.nav-btn.is-active::before { content: ""; position: absolute; left: -5px; width: 3px; height: 18px; border-radius: 99px; background: var(--lime); }
.nav-btn svg { width: 17px; height: 17px; opacity: .92; }
.nav-btn span { font-size: 12px; font-weight: 580; }
.nav-badge { margin-left: auto; min-width: 20px; height: 20px; padding: 0 6px; display: grid; place-items: center; border-radius: 99px; background: rgba(255,255,255,.08); color: #9298a4; font-size: 9px; }
.sidebar-divider { height: 1px; background: rgba(255,255,255,.07); margin: 16px 8px; }
.sidebar-scrim { display: none; border: 0; padding: 0; margin: 0; }
.sidebar-spacer { flex: 1; }
.storage-widget { margin: 0 3px 12px; padding: 12px; border: 1px solid rgba(255,255,255,.07); background: rgba(255,255,255,.035); border-radius: 13px; position: relative; z-index: 1; }
.storage-widget-head { display: flex; justify-content: space-between; color: #c4c8d0; font-size: 10px; margin-bottom: 8px; }
.storage-widget-head strong { color: #fff; }
.storage-track { height: 5px; border-radius: 99px; background: rgba(255,255,255,.08); overflow: hidden; }
.storage-track span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--accent), #9697ff); }
.storage-widget p { margin: 7px 0 0; color: #767c88; font-size: 9px; }
.sidebar-profile { min-height: 48px; border-radius: 13px; padding: 7px; display: grid; grid-template-columns: 32px minmax(0,1fr) 20px; gap: 9px; align-items: center; cursor: pointer; position: relative; z-index: 1; }
.sidebar-profile:hover { background: rgba(255,255,255,.055); }
.user-avatar { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; color: #fff; font-weight: 800; font-size: 11px; }
.sidebar-profile strong, .sidebar-profile span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sidebar-profile strong { font-size: 11px; }
.sidebar-profile span { color: #757b87; font-size: 9px; }

.main-column { min-width: 0; height: 100vh; display: grid; grid-template-rows: 70px minmax(0,1fr); overflow: hidden; background: var(--bg); }
.topbar { min-width: 0; height: 70px; padding: 0 24px; display: grid; grid-template-columns: minmax(210px, 1fr) auto; align-items: center; gap: 18px; border-bottom: 1px solid var(--line); background: rgba(244,245,241,.88); backdrop-filter: blur(16px); position: relative; z-index: 20; }
.search-wrap { position: relative; max-width: 620px; }
.search-wrap svg { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); width: 17px; height: 17px; color: #8d929c; pointer-events: none; }
.global-search { width: 100%; height: 42px; border: 1px solid transparent; background: #e9ebe6; border-radius: 12px; padding: 0 92px 0 40px; outline: none; transition: background .18s, border-color .18s, box-shadow .18s; }
.global-search:focus { background: #fff; border-color: var(--line-strong); box-shadow: 0 7px 24px rgba(16,18,23,.07); }
.search-shortcut { position: absolute; right: 9px; top: 50%; transform: translateY(-50%); display: flex; gap: 3px; color: #9ba0aa; font-size: 9px; }
.search-shortcut kbd { min-width: 22px; height: 22px; display: grid; place-items: center; border: 1px solid #d5d7d1; background: #f7f8f5; border-radius: 6px; font-family: inherit; }
.topbar-actions { display: flex; align-items: center; gap: 8px; }
.icon-btn { width: 38px; height: 38px; border: 1px solid var(--line); border-radius: 11px; background: var(--surface); display: grid; place-items: center; cursor: pointer; color: var(--ink-soft); transition: transform .15s, border-color .15s, background .15s; }
.icon-btn:hover { transform: translateY(-1px); border-color: var(--line-strong); background: #fff; }
.icon-btn svg { width: 17px; height: 17px; }
.icon-btn.is-active { background: var(--ink); color: #fff; border-color: var(--ink); }
.primary-btn { height: 40px; border: 0; border-radius: 12px; background: var(--ink); color: #fff; padding: 0 15px; display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-weight: 680; font-size: 12px; box-shadow: 0 6px 18px rgba(17,19,25,.13); }
.primary-btn:hover { background: #262934; transform: translateY(-1px); }
.primary-btn svg { width: 16px; height: 16px; }
.primary-btn--accent { background: var(--accent); }
.primary-btn--accent:hover { background: #4b4ce8; }
.secondary-btn { height: 38px; border: 1px solid var(--line); border-radius: 11px; background: #fff; padding: 0 13px; display: inline-flex; align-items: center; gap: 7px; cursor: pointer; font-weight: 620; font-size: 12px; }
.secondary-btn:hover { border-color: var(--line-strong); background: #fbfbfa; }
.secondary-btn svg { width: 15px; height: 15px; }
.danger-btn { background: var(--danger); color: #fff; border-color: var(--danger); }
.danger-btn:hover { background: #c62f3e; }

.content-scroll { min-width: 0; overflow: auto; padding: 22px 24px 44px; scroll-behavior: smooth; }
.content-container { width: min(100%, 1360px); margin: 0 auto; }
.page-head { min-height: 54px; display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; margin-bottom: 18px; }
.page-head-copy { min-width: 0; }
.eyebrow { color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .12em; font-weight: 800; margin-bottom: 4px; }
.page-head h1 { font-size: clamp(24px, 2.4vw, 34px); line-height: 1.08; letter-spacing: -.045em; margin: 0; font-weight: 730; }
.page-subtitle { color: var(--muted); margin: 6px 0 0; font-size: 12px; }
.page-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }

.context-hero { position: relative; min-height: 190px; background: var(--ink); color: #fff; border-radius: 24px; padding: 26px 28px; overflow: hidden; margin-bottom: 22px; display: grid; grid-template-columns: minmax(0,1fr) 300px; gap: 24px; align-items: center; box-shadow: 0 14px 40px rgba(17,19,25,.12); }
.context-hero::before { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 75% 30%, rgba(var(--accent-rgb), .58), transparent 30%), radial-gradient(circle at 98% 95%, rgba(217,255,102,.17), transparent 23%); }
.context-hero::after { content: ""; position: absolute; inset: 0; opacity: .10; background-image: linear-gradient(rgba(255,255,255,.16) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.16) 1px, transparent 1px); background-size: 34px 34px; mask-image: linear-gradient(90deg, transparent 28%, black); }
.hero-copy, .hero-network { position: relative; z-index: 1; }
.hero-label { display: inline-flex; align-items: center; gap: 7px; color: #b8bdc7; font-size: 10px; text-transform: uppercase; letter-spacing: .12em; font-weight: 800; }
.hero-label i { width: 7px; height: 7px; background: var(--lime); border-radius: 50%; box-shadow: 0 0 0 5px rgba(217,255,102,.10); }
.hero-copy h2 { margin: 14px 0 8px; max-width: 620px; font-size: clamp(24px, 2.6vw, 38px); line-height: 1.04; letter-spacing: -.047em; font-weight: 690; }
.hero-copy p { margin: 0 0 17px; max-width: 600px; color: #aeb3bd; font-size: 13px; line-height: 1.58; }
.hero-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.hero-action { height: 36px; border: 1px solid rgba(255,255,255,.14); border-radius: 11px; background: rgba(255,255,255,.07); color: #fff; padding: 0 12px; display: inline-flex; align-items: center; gap: 7px; cursor: pointer; font-size: 11px; font-weight: 650; backdrop-filter: blur(8px); }
.hero-action:hover { background: rgba(255,255,255,.12); }
.hero-action svg { width: 15px; height: 15px; flex: 0 0 15px; }
.hero-action--lime { background: var(--lime); border-color: var(--lime); color: var(--lime-ink); }
.hero-action--lime:hover { background: #e4ff91; }
.hero-network { height: 150px; }
.hero-orbit { position: absolute; border: 1px solid rgba(255,255,255,.15); border-radius: 50%; }
.hero-orbit.o1 { width: 145px; height: 145px; right: 42px; top: 2px; }
.hero-orbit.o2 { width: 98px; height: 98px; right: 65px; top: 25px; border-style: dashed; animation: rotate 18s linear infinite; }
.hero-core { position: absolute; right: 99px; top: 59px; width: 32px; height: 32px; border-radius: 10px; background: var(--accent); display: grid; place-items: center; box-shadow: 0 0 0 12px rgba(var(--accent-rgb),.15); font-weight: 800; font-size: 10px; }
.hero-dot { position: absolute; width: 16px; height: 16px; border-radius: 6px; background: #fff; box-shadow: 0 0 0 5px rgba(255,255,255,.08); }
.hero-dot.d1 { right: 184px; top: 38px; }
.hero-dot.d2 { right: 25px; top: 66px; background: var(--lime); }
.hero-dot.d3 { right: 151px; top: 124px; background: #8f90ff; }
.hero-dot.d4 { right: 51px; top: 124px; }
.hero-connector { position: absolute; height: 1px; transform-origin: 0 50%; background: linear-gradient(90deg, rgba(255,255,255,.65), rgba(255,255,255,.08)); }
.hero-connector.c1 { width: 93px; right: 109px; top: 70px; transform: rotate(25deg); }
.hero-connector.c2 { width: 76px; right: 37px; top: 76px; transform: rotate(166deg); }
.hero-connector.c3 { width: 80px; right: 88px; top: 83px; transform: rotate(126deg); }
.hero-connector.c4 { width: 74px; right: 44px; top: 119px; transform: rotate(-129deg); }
@keyframes rotate { to { transform: rotate(360deg); } }

.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 10px; margin-bottom: 24px; }
.metric-card { min-width: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 14px; display: grid; grid-template-columns: 38px minmax(0,1fr); gap: 11px; align-items: center; box-shadow: var(--shadow-sm); }
.metric-icon { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; background: var(--surface-3); color: var(--ink-soft); }
.metric-icon svg { width: 17px; height: 17px; }
.metric-card:nth-child(2) .metric-icon { background: #e8f8f3; color: #12765c; }
.metric-card:nth-child(3) .metric-icon { background: #fff1db; color: #a45f00; }
.metric-card:nth-child(4) .metric-icon { background: var(--accent-soft); color: #4748cc; }
.metric-copy { min-width: 0; }
.metric-copy strong { display: block; font-size: 18px; letter-spacing: -.03em; line-height: 1.1; }
.metric-copy span { display: block; color: var(--muted); font-size: 10px; margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.section-head { min-height: 42px; display: flex; justify-content: space-between; gap: 14px; align-items: center; margin: 0 0 10px; }
.section-title { min-width: 0; display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.section-title h2 { margin: 0; font-size: 16px; letter-spacing: -.025em; }
.breadcrumb { display: flex; align-items: center; gap: 4px; min-width: 0; }
.crumb { border: 0; background: transparent; color: var(--muted); padding: 4px 3px; cursor: pointer; border-radius: 6px; max-width: 180px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }
.crumb:hover { color: var(--ink); background: var(--surface-3); }
.crumb.is-current { color: var(--ink); font-weight: 650; cursor: default; }
.crumb-sep { color: #b4b8bf; }
.view-tools { display: flex; gap: 5px; align-items: center; }
.segmented { display: flex; border: 1px solid var(--line); background: #fff; border-radius: 10px; padding: 3px; }
.segmented button { width: 29px; height: 27px; border: 0; border-radius: 7px; background: transparent; color: var(--muted); display: grid; place-items: center; cursor: pointer; }
.segmented button.is-active { background: var(--surface-3); color: var(--ink); }
.segmented svg { width: 14px; height: 14px; }

.items-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(184px, 1fr)); gap: 11px; }
.item-card { min-width: 0; position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 12px; min-height: 159px; display: flex; flex-direction: column; cursor: pointer; transition: transform .17s, border-color .17s, box-shadow .17s; box-shadow: var(--shadow-sm); }
.item-card:hover { transform: translateY(-2px); border-color: #cfd2cb; box-shadow: 0 12px 28px rgba(16,18,23,.08); }
.item-card.is-selected { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(var(--accent-rgb),.10); }
.item-card-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.file-visual { width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; background: var(--surface-3); color: var(--ink-soft); overflow: hidden; }
.file-visual svg { width: 25px; height: 25px; }
.file-visual.is-folder { width: 58px; height: 49px; border-radius: 10px 10px 13px 13px; position: relative; background: var(--folder-color, #ececff); color: rgba(17,19,25,.66); margin-top: 4px; }
.file-visual.is-folder::before { content: ""; position: absolute; width: 25px; height: 8px; background: inherit; border-radius: 5px 5px 0 0; left: 3px; top: -4px; }
.file-visual.image-thumb { padding: 0; background: #e7e9e4; }
.file-visual.image-thumb img { width: 100%; height: 100%; object-fit: cover; }
.file-visual.type-pdf { background: #fff0f1; color: #d63343; }
.file-visual.type-doc { background: #eaf2ff; color: #2871d5; }
.file-visual.type-sheet { background: #e9f8ef; color: #14865a; }
.file-visual.type-slide { background: #fff2df; color: #d46b00; }
.file-visual.type-code { background: #f0edff; color: #6748cf; }
.file-visual.type-video { background: #ffedf7; color: #c44286; }
.file-visual.type-archive { background: #f4f0e8; color: #826933; }
.item-more { width: 29px; height: 29px; border: 0; border-radius: 9px; display: grid; place-items: center; background: transparent; color: var(--muted); cursor: pointer; opacity: 0; transition: opacity .15s, background .15s; }
.item-card:hover .item-more, .item-more:focus { opacity: 1; }
.item-more:hover { background: var(--surface-3); color: var(--ink); }
.item-more svg { width: 16px; height: 16px; }
.item-card-body { margin-top: auto; min-width: 0; padding-top: 15px; }
.item-card-name { display: block; font-weight: 650; font-size: 12px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.item-card-meta { margin-top: 4px; color: var(--muted); font-size: 9.5px; display: flex; justify-content: space-between; gap: 7px; min-width: 0; }
.item-card-meta span { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.item-badges { position: absolute; right: 12px; bottom: 12px; display: flex; gap: 4px; }
.item-badge { width: 20px; height: 20px; border-radius: 7px; display: grid; place-items: center; background: var(--surface-3); color: var(--muted); }
.item-badge svg { width: 11px; height: 11px; }
.item-badge.favorite { color: #b87300; background: #fff5d9; }
.item-badge.shared { color: #4647c9; background: var(--accent-soft); }

.items-list { display: grid; gap: 3px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 5px; box-shadow: var(--shadow-sm); }
.list-header, .item-row { display: grid; grid-template-columns: minmax(220px, 1.7fr) minmax(120px,.8fr) 105px 126px 38px; gap: 12px; align-items: center; min-width: 0; }
.list-header { padding: 8px 11px; color: var(--muted); font-size: 9px; text-transform: uppercase; letter-spacing: .08em; font-weight: 750; }
.item-row { min-height: 49px; padding: 6px 8px; border-radius: 11px; cursor: pointer; }
.item-row:hover { background: var(--surface-2); }
.item-row.is-selected { background: var(--accent-soft); }
.row-name { min-width: 0; display: flex; align-items: center; gap: 10px; }
.row-icon { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: var(--surface-3); color: var(--ink-soft); flex: 0 0 34px; }
.row-icon.is-folder { background: var(--folder-color, #ececff); }
.row-icon svg { width: 17px; height: 17px; }
.row-name-copy { min-width: 0; }
.row-name-copy strong, .row-name-copy span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row-name-copy strong { font-size: 11.5px; }
.row-name-copy span { color: var(--muted); font-size: 9px; margin-top: 2px; }
.row-cell { color: var(--muted); font-size: 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row-actions { display: grid; place-items: center; }
.row-actions .item-more { opacity: 1; }

.empty-state { min-height: 300px; display: grid; place-items: center; text-align: center; padding: 40px; border: 1px dashed var(--line-strong); background: rgba(255,255,255,.42); border-radius: 20px; }
.empty-visual { width: 78px; height: 78px; margin: 0 auto 15px; position: relative; }
.empty-visual .ev-folder { position: absolute; width: 66px; height: 49px; border-radius: 10px 10px 16px 16px; background: var(--accent-soft); left: 6px; bottom: 4px; transform: rotate(-4deg); }
.empty-visual .ev-folder::before { content: ""; position: absolute; left: 3px; top: -8px; width: 28px; height: 10px; border-radius: 6px 6px 0 0; background: inherit; }
.empty-visual .ev-dot { position: absolute; width: 19px; height: 19px; border-radius: 7px; background: var(--lime); right: 1px; top: 0; box-shadow: 0 0 0 5px rgba(217,255,102,.20); }
.empty-state h3 { margin: 0 0 6px; font-size: 18px; letter-spacing: -.03em; }
.empty-state p { max-width: 390px; margin: 0 auto 16px; color: var(--muted); font-size: 12px; }
.empty-actions { display: flex; justify-content: center; gap: 8px; }

/* AI panel */
.ai-panel { min-width: 0; height: 100vh; border-left: 1px solid var(--line); background: #fbfbf9; display: grid; grid-template-rows: 70px minmax(0,1fr) auto; overflow: hidden; transition: transform .22s ease, opacity .18s; position: relative; }
.workspace-shell.ai-closed .ai-panel { transform: translateX(100%); opacity: 0; pointer-events: none; }
.ai-head { height: 70px; border-bottom: 1px solid var(--line); padding: 0 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.ai-title { display: flex; align-items: center; gap: 10px; min-width: 0; }
.ai-orb { width: 34px; height: 34px; border-radius: 11px; background: var(--ink); color: #fff; display: grid; place-items: center; position: relative; box-shadow: 0 7px 18px rgba(17,19,25,.16); }
.ai-orb::after { content: ""; position: absolute; width: 7px; height: 7px; border-radius: 50%; background: var(--lime); right: -1px; top: -1px; border: 2px solid #fbfbf9; }
.ai-orb svg { width: 17px; height: 17px; }
.ai-title-copy { min-width: 0; }
.ai-title-copy strong, .ai-title-copy span { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ai-title-copy strong { font-size: 12px; }
.ai-title-copy span { color: var(--muted); font-size: 9px; margin-top: 1px; }
.ai-head .icon-btn { width: 32px; height: 32px; border: 0; background: transparent; }
.ai-messages { min-height: 0; overflow-y: auto; padding: 17px 15px 22px; display: flex; flex-direction: column; gap: 13px; }
.ai-welcome { background: var(--ink); color: #fff; border-radius: 18px; padding: 17px; position: relative; overflow: hidden; }
.ai-welcome::after { content: ""; position: absolute; width: 130px; height: 130px; border-radius: 50%; background: rgba(var(--accent-rgb),.38); filter: blur(35px); right: -50px; top: -50px; }
.ai-welcome > * { position: relative; z-index: 1; }
.ai-welcome-badge { display: inline-flex; align-items: center; gap: 6px; color: #adb2bd; text-transform: uppercase; letter-spacing: .10em; font-size: 8px; font-weight: 800; }
.ai-welcome-badge i { width: 6px; height: 6px; border-radius: 50%; background: var(--lime); }
.ai-welcome h3 { font-size: 17px; letter-spacing: -.025em; margin: 11px 0 6px; }
.ai-welcome p { color: #acb1bc; font-size: 10.5px; line-height: 1.55; margin: 0; }
.ai-suggestions { display: grid; gap: 6px; }
.ai-suggestion { border: 1px solid var(--line); background: #fff; color: var(--ink-soft); border-radius: 11px; padding: 9px 10px; text-align: left; cursor: pointer; font-size: 10px; line-height: 1.35; }
.ai-suggestion:hover { border-color: #cfd2cb; background: var(--surface-2); }
.chat-message { display: flex; gap: 8px; align-items: flex-start; }
.chat-message.user { justify-content: flex-end; }
.chat-bubble { max-width: 88%; border-radius: 15px; padding: 10px 11px; font-size: 10.5px; line-height: 1.55; white-space: pre-wrap; word-break: break-word; }
.chat-message.assistant .chat-bubble { background: #fff; border: 1px solid var(--line); border-top-left-radius: 5px; }
.chat-message.user .chat-bubble { background: var(--ink); color: #fff; border-top-right-radius: 5px; }
.chat-avatar { width: 25px; height: 25px; flex: 0 0 25px; border-radius: 8px; display: grid; place-items: center; background: var(--ink); color: #fff; }
.chat-avatar svg { width: 13px; height: 13px; }
.chat-sources { margin-top: 8px; display: flex; flex-wrap: wrap; gap: 4px; }
.chat-source { max-width: 100%; border: 1px solid var(--line); background: var(--surface-2); border-radius: 7px; padding: 4px 6px; color: var(--muted); font-size: 8.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; cursor: pointer; }
.chat-thinking { display: inline-flex; gap: 4px; padding: 3px 0; }
.chat-thinking i { width: 5px; height: 5px; border-radius: 50%; background: #9ca0a9; animation: dots 1s ease-in-out infinite; }
.chat-thinking i:nth-child(2) { animation-delay: .15s; }
.chat-thinking i:nth-child(3) { animation-delay: .3s; }
@keyframes dots { 0%,100% { transform: translateY(0); opacity: .4; } 50% { transform: translateY(-3px); opacity: 1; } }
.ai-composer { border-top: 1px solid var(--line); padding: 12px 14px 14px; background: rgba(251,251,249,.96); }
.ai-context-pill { margin-bottom: 7px; color: var(--muted); font-size: 8.5px; display: flex; align-items: center; gap: 5px; }
.ai-context-pill svg { width: 11px; height: 11px; }
.ai-input-wrap { border: 1px solid var(--line); background: #fff; border-radius: 14px; padding: 9px 9px 8px 11px; display: grid; grid-template-columns: minmax(0,1fr) 32px; gap: 8px; align-items: end; box-shadow: 0 5px 16px rgba(16,18,23,.04); }
.ai-input-wrap:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(var(--accent-rgb),.08); }
.ai-input { width: 100%; border: 0; outline: 0; resize: none; max-height: 110px; min-height: 30px; line-height: 1.45; padding: 6px 0; font-size: 10.5px; background: transparent; }
.ai-send { width: 32px; height: 32px; border: 0; border-radius: 10px; background: var(--ink); color: #fff; display: grid; place-items: center; cursor: pointer; }
.ai-send:hover { background: var(--accent); }
.ai-send:disabled { opacity: .45; cursor: wait; }
.ai-send svg { width: 14px; height: 14px; }
.ai-footnote { margin: 6px 2px 0; text-align: center; color: #a3a7af; font-size: 7.5px; }

/* Menus, modals, toast */
.context-menu { position: fixed; z-index: 200; width: 194px; background: rgba(255,255,255,.97); border: 1px solid var(--line); border-radius: 13px; padding: 5px; box-shadow: 0 18px 50px rgba(15,18,25,.18); backdrop-filter: blur(12px); animation: menuIn .12s ease-out; }
@keyframes menuIn { from { opacity: 0; transform: translateY(-4px) scale(.98); } to { opacity: 1; transform: none; } }
.context-menu button { width: 100%; min-height: 34px; border: 0; background: transparent; border-radius: 8px; padding: 0 9px; display: flex; align-items: center; gap: 9px; cursor: pointer; color: var(--ink-soft); text-align: left; font-size: 10.5px; }
.context-menu button:hover { background: var(--surface-3); color: var(--ink); }
.context-menu button.danger { color: var(--danger); }
.context-menu button svg { width: 14px; height: 14px; }
.context-menu hr { border: 0; height: 1px; background: var(--line); margin: 4px; }
.modal-backdrop { position: fixed; z-index: 300; inset: 0; background: rgba(10,12,17,.46); backdrop-filter: blur(7px); display: grid; place-items: center; padding: 24px; animation: fadeIn .15s ease-out; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.modal { width: min(100%, 500px); max-height: min(88vh, 760px); background: #fff; border: 1px solid rgba(255,255,255,.6); border-radius: 23px; box-shadow: 0 30px 90px rgba(0,0,0,.24); overflow: hidden; display: grid; grid-template-rows: auto minmax(0,1fr) auto; animation: modalIn .17s ease-out; }
.modal.modal-wide { width: min(100%, 820px); }
.modal.modal-preview { width: min(100%, 1080px); height: min(88vh, 780px); }
@keyframes modalIn { from { opacity: 0; transform: translateY(10px) scale(.985); } to { opacity: 1; transform: none; } }
.modal-head { padding: 20px 22px 16px; display: flex; justify-content: space-between; gap: 18px; align-items: flex-start; border-bottom: 1px solid var(--line); }
.modal-title h2 { margin: 0; font-size: 19px; letter-spacing: -.03em; }
.modal-title p { margin: 5px 0 0; color: var(--muted); font-size: 10.5px; }
.modal-close { width: 32px; height: 32px; border: 0; border-radius: 10px; background: var(--surface-3); display: grid; place-items: center; cursor: pointer; color: var(--muted); }
.modal-close:hover { color: var(--ink); }
.modal-close svg { width: 15px; height: 15px; }
.modal-body { min-height: 0; overflow: auto; padding: 20px 22px; }
.modal-foot { border-top: 1px solid var(--line); padding: 13px 22px; display: flex; justify-content: flex-end; gap: 8px; background: #fafaf8; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-grid .span-2 { grid-column: 1 / -1; }
.modal textarea.field-input { min-height: 92px; resize: vertical; }
.radio-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.radio-card { position: relative; }
.radio-card input { position: absolute; opacity: 0; pointer-events: none; }
.radio-card label { display: block; min-height: 94px; border: 1px solid var(--line); border-radius: 13px; padding: 12px; cursor: pointer; background: #fff; }
.radio-card label:hover { border-color: var(--line-strong); }
.radio-card input:checked + label { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(var(--accent-rgb),.09); background: var(--accent-soft); }
.radio-card strong { display: block; margin: 6px 0 3px; font-size: 11px; }
.radio-card span { color: var(--muted); font-size: 9px; line-height: 1.35; }
.radio-card svg { width: 18px; height: 18px; }
.color-row { display: flex; gap: 8px; flex-wrap: wrap; }
.color-swatch { width: 30px; height: 30px; border-radius: 10px; border: 2px solid #fff; box-shadow: 0 0 0 1px var(--line); cursor: pointer; position: relative; }
.color-swatch.is-active::after { content: ""; position: absolute; inset: 8px; border-radius: 50%; background: #fff; }
.share-result { background: var(--surface-2); border: 1px solid var(--line); border-radius: 13px; padding: 11px; display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 8px; align-items: center; }
.share-url { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-soft); font-size: 10.5px; }
.copy-btn { height: 32px; border: 0; border-radius: 9px; background: var(--ink); color: #fff; padding: 0 10px; cursor: pointer; font-size: 10px; font-weight: 650; }
.preview-frame { width: 100%; height: 100%; border: 0; background: #f2f3f0; }
.preview-body { padding: 0; min-height: 0; }
.preview-fallback { height: 100%; display: grid; place-items: center; text-align: center; padding: 32px; }
.preview-fallback .file-visual { margin: 0 auto 14px; width: 70px; height: 70px; }
.member-list, .share-list, .version-list, .activity-list { display: grid; gap: 7px; }
.member-row, .share-row, .version-row, .activity-row { min-width: 0; border: 1px solid var(--line); border-radius: 12px; padding: 10px; display: grid; align-items: center; gap: 10px; }
.member-row { grid-template-columns: 34px minmax(0,1fr) 110px; }
.member-copy, .share-copy { min-width: 0; }
.member-copy strong, .member-copy span, .share-copy strong, .share-copy span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.member-copy strong, .share-copy strong { font-size: 11px; }
.member-copy span, .share-copy span { color: var(--muted); font-size: 9px; margin-top: 2px; }
.member-role { border: 1px solid var(--line); background: #fff; border-radius: 9px; padding: 7px; font-size: 9px; }
.share-row { grid-template-columns: 34px minmax(0,1fr) auto; }
.share-icon { width: 34px; height: 34px; border-radius: 10px; background: var(--accent-soft); color: #4b4cc8; display: grid; place-items: center; }
.share-icon svg { width: 15px; height: 15px; }
.row-mini-actions { display: flex; gap: 4px; }
.mini-btn { width: 30px; height: 30px; border: 1px solid var(--line); background: #fff; border-radius: 9px; display: grid; place-items: center; cursor: pointer; }
.mini-btn:hover { background: var(--surface-3); }
.mini-btn svg { width: 13px; height: 13px; }
.version-row { grid-template-columns: 42px minmax(0,1fr) auto; }
.version-number { width: 42px; height: 36px; border-radius: 10px; background: var(--surface-3); display: grid; place-items: center; font-size: 10px; font-weight: 800; }
.version-copy strong, .version-copy span { display: block; }
.version-copy strong { font-size: 10.5px; }
.version-copy span { color: var(--muted); font-size: 9px; margin-top: 2px; }

.toast-root { position: fixed; z-index: 500; right: 18px; bottom: 18px; display: grid; gap: 8px; pointer-events: none; }
.toast { width: min(360px, calc(100vw - 36px)); background: rgba(20,22,28,.96); color: #fff; border: 1px solid rgba(255,255,255,.08); border-radius: 13px; padding: 11px 12px; display: grid; grid-template-columns: 24px minmax(0,1fr); gap: 9px; align-items: center; box-shadow: 0 14px 40px rgba(0,0,0,.22); animation: toastIn .2s ease-out; pointer-events: auto; }
@keyframes toastIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.toast-icon { width: 24px; height: 24px; border-radius: 8px; display: grid; place-items: center; background: rgba(255,255,255,.10); }
.toast-icon svg { width: 13px; height: 13px; }
.toast strong { display: block; font-size: 10.5px; }
.toast span { display: block; color: #aeb3bd; font-size: 9px; margin-top: 1px; }
.toast.error .toast-icon { background: rgba(219,58,74,.18); color: #ff9aa5; }
.toast.success .toast-icon { background: rgba(20,137,102,.22); color: #71e6be; }

.upload-overlay { position: fixed; z-index: 260; inset: 14px; border: 2px dashed var(--accent); border-radius: 28px; background: rgba(244,245,241,.92); backdrop-filter: blur(14px); display: grid; place-items: center; color: var(--ink); pointer-events: none; animation: fadeIn .12s; }
.upload-overlay-content { text-align: center; }
.upload-overlay-icon { width: 78px; height: 78px; margin: 0 auto 16px; border-radius: 25px; background: var(--accent); color: #fff; display: grid; place-items: center; box-shadow: 0 16px 38px rgba(var(--accent-rgb),.26); }
.upload-overlay-icon svg { width: 32px; height: 32px; }
.upload-overlay h3 { margin: 0 0 6px; font-size: 24px; letter-spacing: -.04em; }
.upload-overlay p { margin: 0; color: var(--muted); }

.skeleton-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(184px,1fr)); gap: 11px; }
.skeleton-card { height: 159px; border-radius: 16px; border: 1px solid var(--line); background: linear-gradient(100deg, #f8f8f6 20%, #fff 40%, #f8f8f6 60%); background-size: 200% 100%; animation: shimmer 1.25s linear infinite; }
@keyframes shimmer { to { background-position-x: -200%; } }

/* Responsive */
@media (max-width: 1180px) {
    :root { --sidebar-width: 226px; --ai-width: 326px; }
    .context-hero { grid-template-columns: minmax(0,1fr) 240px; }
    .metric-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
}
@media (max-width: 980px) {
    :root { --sidebar-width: 210px; }
    .workspace-shell { grid-template-columns: var(--sidebar-width) minmax(0,1fr); }
    .ai-panel { position: fixed; z-index: 120; right: 0; top: 0; width: min(92vw, 370px); box-shadow: -18px 0 60px rgba(0,0,0,.15); transform: translateX(100%); opacity: 0; pointer-events: none; }
    .workspace-shell:not(.ai-closed) .ai-panel { transform: translateX(0); opacity: 1; pointer-events: auto; }
    .auth-shell { grid-template-columns: 1fr; }
    .auth-story { display: none; }
    .auth-panel { min-height: 100vh; }
    .context-hero { grid-template-columns: 1fr; }
    .hero-network { position: absolute; right: 0; top: 14px; opacity: .42; width: 260px; }
}
@media (max-width: 720px) {
    body { overflow: auto; }
    :root { --sidebar-width: 0px; }
    .workspace-shell { display: block; min-height: 100vh; height: auto; }
    .sidebar { position: fixed; z-index: 150; left: 0; top: 0; width: min(84vw, 280px); transform: translateX(-102%); transition: transform .2s ease; box-shadow: 18px 0 60px rgba(0,0,0,.22); }
    .workspace-shell.mobile-nav-open .sidebar { transform: translateX(0); }
    .workspace-shell.mobile-nav-open .sidebar-scrim { display: block; position: fixed; inset: 0 0 0 min(84vw, 280px); z-index: 140; background: rgba(12,14,19,.42); backdrop-filter: blur(2px); }
    .main-column { height: 100vh; }
    .topbar { padding: 0 12px; grid-template-columns: 38px minmax(0,1fr) auto; gap: 8px; }
    .mobile-menu-btn { display: grid !important; }
    .topbar .primary-btn span { display: none; }
    .topbar .primary-btn { width: 40px; padding: 0; justify-content: center; }
    .search-shortcut { display: none; }
    .global-search { padding-right: 12px; }
    .content-scroll { padding: 16px 12px 36px; }
    .page-head { flex-direction: column; gap: 12px; }
    .page-actions { justify-content: flex-start; }
    .context-hero { padding: 22px; min-height: 210px; }
    .hero-network { display: none; }
    .metric-grid { grid-template-columns: 1fr 1fr; }
    .metric-card { grid-template-columns: 34px minmax(0,1fr); padding: 11px; }
    .metric-icon { width: 34px; height: 34px; }
    .items-grid { grid-template-columns: repeat(2, minmax(0,1fr)); gap: 8px; }
    .item-card { min-height: 144px; }
    .list-header { display: none; }
    .item-row { grid-template-columns: minmax(0,1fr) 34px; }
    .item-row .row-cell { display: none; }
    .auth-panel { padding: 20px; }
    .auth-card { padding: 24px; border-radius: 22px; }
    .form-grid { grid-template-columns: 1fr; }
    .form-grid .span-2 { grid-column: auto; }
    .radio-cards { grid-template-columns: 1fr; }
    .modal-backdrop { padding: 10px; align-items: end; }
    .modal { border-radius: 22px 22px 14px 14px; max-height: 92vh; }
    .modal.modal-preview { height: 90vh; }
}
@media (max-width: 430px) {
    .metric-grid { grid-template-columns: 1fr; }
    .items-grid { grid-template-columns: 1fr 1fr; }
    .item-card { padding: 10px; }
    .file-visual { width: 46px; height: 46px; }
    .page-head h1 { font-size: 26px; }
}
.mobile-menu-btn { display: none; }
.hidden { display: none !important; }

/* LYNQ Space 0.2 — Memory Workspace */
.dashboard-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    margin: 2px 0 20px;
}
.dashboard-head h1 {
    margin: 3px 0 8px;
    font-size: clamp(30px, 4vw, 48px);
    line-height: 1;
    letter-spacing: -.055em;
    font-weight: 740;
}
.dashboard-head p { margin: 0; max-width: 690px; color: var(--muted); font-size: 13px; }
.dashboard-actions, .modal-foot-group { display: flex; align-items: center; gap: 8px; }
.briefing-card {
    position: relative;
    overflow: hidden;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 180px;
    gap: 28px;
    min-height: 286px;
    padding: clamp(24px, 3.3vw, 40px);
    border-radius: 30px;
    color: #fff;
    background:
        radial-gradient(circle at 88% 16%, rgba(var(--accent-rgb), .62), transparent 28%),
        radial-gradient(circle at 63% 115%, rgba(217,255,102,.12), transparent 28%),
        #101217;
    box-shadow: 0 28px 70px rgba(16,18,23,.18);
}
.briefing-card::before {
    content: "";
    position: absolute;
    inset: 0;
    opacity: .11;
    background-image: linear-gradient(rgba(255,255,255,.18) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.18) 1px, transparent 1px);
    background-size: 44px 44px;
    mask-image: linear-gradient(90deg, #000, transparent 82%);
}
.briefing-copy, .briefing-score { position: relative; z-index: 1; }
.briefing-kicker { display: flex; align-items: center; gap: 8px; color: #9da3af; font-size: 9px; font-weight: 760; letter-spacing: .12em; text-transform: uppercase; }
.briefing-kicker i { width: 7px; height: 7px; border-radius: 99px; background: var(--lime); box-shadow: 0 0 0 6px rgba(217,255,102,.09); }
.briefing-copy h2 { max-width: 760px; margin: 18px 0 20px; font-size: clamp(25px, 3vw, 39px); line-height: 1.05; letter-spacing: -.048em; font-weight: 680; }
.briefing-items { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 8px 16px; max-width: 850px; }
.briefing-item { display: grid; grid-template-columns: 27px minmax(0,1fr); gap: 8px; align-items: center; color: #c4c8d0; }
.briefing-item > span { width: 27px; height: 27px; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.09); border-radius: 9px; background: rgba(255,255,255,.055); color: var(--lime); }
.briefing-item svg { width: 13px; height: 13px; }
.briefing-item p { margin: 0; font-size: 10.5px; line-height: 1.4; }
.briefing-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 24px; }
.briefing-actions button { min-height: 38px; padding: 0 13px; border: 1px solid rgba(255,255,255,.12); border-radius: 11px; display: inline-flex; align-items: center; gap: 7px; background: rgba(255,255,255,.06); color: #fff; cursor: pointer; font-weight: 650; font-size: 10px; }
.briefing-actions button:first-child { background: var(--lime); color: var(--lime-ink); border-color: var(--lime); }
.briefing-actions svg { width: 14px; height: 14px; }
.briefing-score { display: grid; align-content: center; justify-items: center; gap: 12px; }
.score-ring { --score: 0; width: 134px; height: 134px; border-radius: 50%; display: grid; place-content: center; text-align: center; position: relative; background: conic-gradient(var(--lime) calc(var(--score) * 1%), rgba(255,255,255,.10) 0); }
.score-ring::before { content: ""; position: absolute; inset: 8px; border-radius: inherit; background: #171a21; box-shadow: inset 0 0 0 1px rgba(255,255,255,.07); }
.score-ring strong, .score-ring span { position: relative; z-index: 1; display: block; }
.score-ring strong { font-size: 31px; line-height: 1; letter-spacing: -.05em; }
.score-ring span { margin-top: 4px; color: #8f95a0; font-size: 8px; letter-spacing: .11em; text-transform: uppercase; }
.briefing-score p { margin: 0; color: #9da2ad; font-size: 9px; }
.dashboard-metrics { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 10px; margin: 13px 0 22px; }
.dashboard-metric { min-width: 0; min-height: 82px; padding: 13px 15px; border: 1px solid var(--line); border-radius: 17px; background: rgba(255,255,255,.82); box-shadow: var(--shadow-sm); display: grid; grid-template-columns: 40px minmax(0,1fr); align-items: center; gap: 11px; text-align: left; cursor: pointer; transition: .18s ease; }
.dashboard-metric:hover { transform: translateY(-2px); border-color: var(--line-strong); box-shadow: 0 13px 30px rgba(16,18,23,.08); }
.dashboard-metric > span { width: 40px; height: 40px; border-radius: 13px; display: grid; place-items: center; color: var(--ink-soft); background: var(--surface-3); }
.dashboard-metric:nth-child(2) > span { color: #936000; background: #fff1d7; }
.dashboard-metric:nth-child(3) > span { color: #0c7b64; background: #e6f7f2; }
.dashboard-metric:nth-child(4) > span { color: #5051d6; background: var(--accent-soft); }
.dashboard-metric svg { width: 18px; height: 18px; }
.dashboard-metric strong { display: block; font-size: 21px; line-height: 1; letter-spacing: -.035em; }
.dashboard-metric small { display: block; margin-top: 4px; color: var(--muted); font-size: 9.5px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(280px, .85fr); gap: 12px; align-items: start; }
.dashboard-section { min-width: 0; border: 1px solid var(--line); border-radius: 21px; background: rgba(255,255,255,.78); box-shadow: var(--shadow-sm); padding: 17px; }
.dashboard-section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 13px; }
.dashboard-section-head span { display: block; color: var(--muted-2); font-size: 8px; font-weight: 750; letter-spacing: .1em; text-transform: uppercase; }
.dashboard-section-head h2 { margin: 3px 0 0; font-size: 17px; letter-spacing: -.025em; }
.dashboard-section-head > button { border: 0; background: transparent; color: var(--muted); display: inline-flex; align-items: center; gap: 5px; padding: 5px; cursor: pointer; font-size: 9px; white-space: nowrap; }
.dashboard-section-head > button:hover { color: var(--ink); }
.dashboard-section-head svg { width: 12px; height: 12px; }
.dashboard-files { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 7px; }
.dashboard-file { min-width: 0; min-height: 61px; display: grid; grid-template-columns: 37px minmax(0,1fr) 18px; gap: 10px; align-items: center; border: 1px solid var(--line); border-radius: 13px; background: #fff; padding: 8px; text-align: left; cursor: pointer; }
.dashboard-file:hover { background: var(--surface-2); border-color: var(--line-strong); }
.dashboard-file > svg { width: 14px; height: 14px; color: var(--muted-2); }
.dashboard-file-icon { width: 37px; height: 37px; border-radius: 11px; display: grid; place-items: center; background: var(--surface-3); }
.dashboard-file-icon.type-pdf { background: #fff0f1; color: #c63a49; }
.dashboard-file-icon.type-doc { background: #eaf2ff; color: #2862b4; }
.dashboard-file-icon.type-sheet { background: #e9f8ef; color: #23774a; }
.dashboard-file-icon.type-slide { background: #fff1e7; color: #b75c20; }
.dashboard-file-icon svg { width: 17px; height: 17px; }
.dashboard-file-copy { min-width: 0; }
.dashboard-file-copy strong, .dashboard-file-copy small { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.dashboard-file-copy strong { font-size: 10.5px; }
.dashboard-file-copy small { color: var(--muted); font-size: 8.5px; margin-top: 3px; }
.dashboard-collections { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 8px; }
.dashboard-activity { display: grid; gap: 4px; }
.dashboard-activity-row { min-width: 0; display: grid; grid-template-columns: 30px minmax(0,1fr); gap: 8px; align-items: center; padding: 7px 4px; border-bottom: 1px solid var(--line); }
.dashboard-activity-row:last-child { border-bottom: 0; }
.dashboard-activity-row .user-avatar { width: 30px; height: 30px; font-size: 8px; }
.dashboard-activity-row span:last-child { min-width: 0; }
.dashboard-activity-row strong, .dashboard-activity-row small { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.dashboard-activity-row strong { font-size: 9.5px; }
.dashboard-activity-row small { color: var(--muted); margin-top: 2px; font-size: 8px; }
.dashboard-empty { grid-column: 1 / -1; min-height: 110px; display: grid; place-items: center; border: 1px dashed var(--line-strong); border-radius: 14px; color: var(--muted); text-align: center; padding: 18px; font-size: 10px; }
.dashboard-empty--compact { min-height: 76px; }

.collections-page-head { margin-bottom: 14px; }
.collections-intro { min-height: 176px; margin-bottom: 16px; padding: 24px 26px; display: flex; align-items: flex-end; justify-content: space-between; gap: 25px; border-radius: 24px; color: #fff; overflow: hidden; position: relative; background: radial-gradient(circle at 78% 20%, rgba(var(--accent-rgb),.55), transparent 30%), #15171d; }
.collections-intro::before { content: ""; position: absolute; width: 240px; height: 240px; right: -80px; bottom: -125px; border: 1px solid rgba(255,255,255,.13); border-radius: 50%; box-shadow: 0 0 0 28px rgba(255,255,255,.025), 0 0 0 62px rgba(255,255,255,.018); }
.collections-intro > * { position: relative; z-index: 1; }
.collections-intro > div > span { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 12px; background: var(--lime); color: var(--lime-ink); }
.collections-intro svg { width: 17px; height: 17px; }
.collections-intro h2 { margin: 13px 0 6px; max-width: 620px; font-size: clamp(20px, 2.5vw, 30px); line-height: 1.08; letter-spacing: -.04em; }
.collections-intro p { max-width: 650px; color: #aeb3bd; margin: 0; font-size: 10.5px; }
.collections-intro > button { height: 38px; padding: 0 13px; border: 1px solid rgba(255,255,255,.13); border-radius: 11px; background: rgba(255,255,255,.08); color: #fff; display: inline-flex; align-items: center; gap: 7px; cursor: pointer; white-space: nowrap; font-size: 10px; }
.collections-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px,1fr)); gap: 10px; }
.collection-card { --collection-color: var(--accent); position: relative; min-width: 0; min-height: 194px; padding: 16px; display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 19px; background: #fff; box-shadow: var(--shadow-sm); overflow: hidden; cursor: pointer; transition: .18s ease; }
.collection-card::before { content: ""; position: absolute; width: 150px; height: 150px; border-radius: 50%; right: -82px; top: -90px; background: color-mix(in srgb, var(--collection-color) 16%, transparent); }
.collection-card::after { content: ""; position: absolute; left: 0; top: 0; width: 100%; height: 3px; background: var(--collection-color); }
.collection-card:hover { transform: translateY(-3px); border-color: color-mix(in srgb, var(--collection-color) 38%, var(--line)); box-shadow: 0 15px 34px rgba(16,18,23,.09); }
.collection-card-top { position: relative; z-index: 1; display: flex; justify-content: space-between; align-items: flex-start; }
.collection-card-icon { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 13px; background: color-mix(in srgb, var(--collection-color) 13%, white); color: var(--collection-color); }
.collection-card-icon svg { width: 19px; height: 19px; }
.collection-card .item-more { opacity: 1; }
.collection-card-copy { position: relative; z-index: 1; margin-top: auto; padding-top: 22px; }
.collection-card-copy h3 { margin: 0; font-size: 15px; letter-spacing: -.025em; }
.collection-card-copy p { min-height: 34px; margin: 6px 0 0; color: var(--muted); font-size: 9.5px; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.collection-card-foot { position: relative; z-index: 1; display: flex; justify-content: space-between; gap: 8px; margin-top: 14px; padding-top: 10px; border-top: 1px solid var(--line); color: var(--muted); font-size: 8.5px; }
.collection-card--compact { min-height: 132px; padding: 13px; border-radius: 15px; }
.collection-card--compact .collection-card-icon { width: 34px; height: 34px; border-radius: 11px; }
.collection-card--compact .collection-card-copy { padding-top: 12px; }
.collection-card--compact .collection-card-copy h3 { font-size: 11px; }
.collection-card--compact .collection-card-copy p { display: none; }
.collection-card--compact .collection-card-foot { margin-top: 8px; padding-top: 7px; font-size: 7.5px; }
.collection-page-head { position: relative; padding-left: 18px; }
.collection-page-head::before { content: ""; position: absolute; left: 0; top: 3px; bottom: 3px; width: 4px; border-radius: 99px; background: var(--collection-color); }
.collection-section-title { display: flex; align-items: center; gap: 9px; }
.collection-section-title > span { width: 29px; height: 29px; border-radius: 9px; display: grid; place-items: center; color: #fff; }
.collection-section-title svg { width: 14px; height: 14px; }
.icon-picker { display: flex; flex-wrap: wrap; gap: 7px; }
.icon-picker button { width: 38px; height: 38px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 11px; background: #fff; color: var(--muted); cursor: pointer; }
.icon-picker button.is-active { color: var(--accent); border-color: var(--accent); background: var(--accent-soft); box-shadow: 0 0 0 3px rgba(var(--accent-rgb),.08); }
.icon-picker svg { width: 17px; height: 17px; }
.modal-foot { justify-content: space-between; }
.notice-card { display: flex; gap: 12px; align-items: flex-start; padding: 14px; border-radius: 14px; background: var(--surface-2); border: 1px solid var(--line); }
.notice-card > svg { width: 21px; height: 21px; flex: 0 0 auto; }
.notice-card strong { display: block; font-size: 11px; }
.notice-card p { margin: 4px 0 0; color: var(--muted); font-size: 10px; }
.notice-card--danger { color: var(--danger); background: var(--danger-soft); border-color: #ffdadd; }
.collection-picker-list { display: grid; gap: 7px; }
.collection-picker-row { --collection-color: var(--accent); min-width: 0; min-height: 58px; display: grid; grid-template-columns: 38px minmax(0,1fr) 27px; gap: 10px; align-items: center; padding: 8px; border: 1px solid var(--line); border-radius: 13px; background: #fff; text-align: left; cursor: pointer; }
.collection-picker-row:hover { background: var(--surface-2); }
.collection-picker-row.is-selected { border-color: color-mix(in srgb, var(--collection-color) 55%, var(--line)); background: color-mix(in srgb, var(--collection-color) 7%, white); }
.collection-picker-icon { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; color: var(--collection-color); background: color-mix(in srgb, var(--collection-color) 12%, white); }
.collection-picker-icon svg { width: 17px; height: 17px; }
.collection-picker-row strong, .collection-picker-row small { display: block; }
.collection-picker-row strong { font-size: 10.5px; }
.collection-picker-row small { margin-top: 2px; color: var(--muted); font-size: 8.5px; }
.collection-picker-row > i { width: 24px; height: 24px; display: grid; place-items: center; border-radius: 8px; color: transparent; background: var(--surface-3); }
.collection-picker-row.is-selected > i { color: #fff; background: var(--collection-color); }
.collection-picker-row > i svg { width: 13px; height: 13px; }

.item-signals { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 7px; }
.item-signal { min-height: 19px; padding: 0 6px; display: inline-flex; align-items: center; gap: 3px; border-radius: 6px; background: var(--surface-3); color: var(--muted); font-size: 7.5px; font-weight: 650; }
.item-signal svg { width: 9px; height: 9px; }
.item-signal.signal-collection { color: #4f50c5; background: var(--accent-soft); }


.modal.modal-document { width: min(96vw, 1180px); height: min(92vh, 860px); max-height: 92vh; }
.document-detail-body { padding: 0; overflow: hidden; }
.detail-loading { height: 100%; display: grid; grid-template-columns: 1.2fr .8fr; gap: 12px; padding: 18px; }
.detail-loading .skeleton-card { height: 100%; }
.document-detail-grid { height: 100%; min-height: 0; display: grid; grid-template-columns: minmax(0, 1.22fr) minmax(340px, .78fr); }
.document-preview-panel { min-width: 0; min-height: 0; display: grid; grid-template-rows: 43px minmax(0,1fr); background: #eceeea; border-right: 1px solid var(--line); }
.document-preview-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 0 13px; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.8); }
.document-preview-toolbar > div { display: flex; align-items: center; gap: 7px; }
.document-preview-toolbar span { min-height: 21px; display: inline-flex; align-items: center; padding: 0 6px; border-radius: 6px; background: var(--ink); color: #fff; font-size: 7px; font-weight: 800; }
.document-preview-toolbar strong { font-size: 9.5px; }
.document-preview-toolbar > a { width: 28px; height: 28px; border-radius: 9px; display: grid; place-items: center; color: var(--muted); }
.document-preview-toolbar > a:hover { background: var(--surface-3); color: var(--ink); }
.document-preview-toolbar svg { width: 13px; height: 13px; }
.document-preview-frame { width: 100%; height: 100%; border: 0; background: #f2f3f0; }
.document-preview-fallback { height: 100%; display: grid; place-content: center; justify-items: center; text-align: center; padding: 32px; }
.document-preview-fallback .file-visual { width: 74px; height: 74px; margin-bottom: 16px; }
.document-preview-fallback h3 { max-width: 480px; margin: 0 0 7px; font-size: 17px; }
.document-preview-fallback p { max-width: 460px; margin: 0 0 17px; color: var(--muted); font-size: 10px; }
.document-intelligence-panel { min-width: 0; min-height: 0; overflow-y: auto; padding: 13px; display: grid; grid-auto-rows: max-content; align-content: start; gap: 9px; background: #fafaf8; }
.intelligence-hero { padding: 15px; border-radius: 17px; background: var(--ink); color: #fff; overflow: hidden; position: relative; }
.intelligence-hero::after { content: ""; position: absolute; width: 140px; height: 140px; border-radius: 50%; right: -70px; top: -70px; background: rgba(var(--accent-rgb),.36); filter: blur(22px); }
.intelligence-hero > * { position: relative; z-index: 1; }
.intelligence-hero-head { display: grid; grid-template-columns: 34px minmax(0,1fr) auto; gap: 9px; align-items: center; }
.intelligence-hero .ai-orb { width: 34px; height: 34px; }
.intelligence-hero .ai-orb svg { width: 15px; height: 15px; }
.intelligence-hero-head small { display: block; color: #8e94a0; font-size: 7px; letter-spacing: .09em; text-transform: uppercase; }
.intelligence-hero-head h3 { margin: 3px 0 0; font-size: 13px; }
.risk-pill { min-height: 23px; display: inline-flex; align-items: center; padding: 0 7px; border-radius: 99px; font-size: 7px; font-weight: 750; }
.risk-pill.risk-low { color: #8ce8c8; background: rgba(20,137,102,.22); }
.risk-pill.risk-medium { color: #ffd574; background: rgba(213,138,0,.22); }
.risk-pill.risk-high { color: #ff9ca6; background: rgba(219,58,74,.24); }
.intelligence-hero > p { margin: 13px 0 0; color: #c2c6ce; font-size: 9.5px; line-height: 1.55; }
.insight-tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 12px; }
.insight-tags span { min-height: 20px; padding: 0 6px; border: 1px solid rgba(255,255,255,.09); border-radius: 6px; display: inline-flex; align-items: center; color: #b9bec8; background: rgba(255,255,255,.05); font-size: 7px; }
.intelligence-actions { display: flex; gap: 6px; margin-top: 12px; }
.intelligence-actions button { min-height: 31px; padding: 0 9px; display: inline-flex; align-items: center; gap: 5px; border: 1px solid rgba(255,255,255,.1); border-radius: 9px; background: rgba(255,255,255,.06); color: #fff; cursor: pointer; font-size: 8px; }
.intelligence-actions button:first-child { background: var(--lime); color: var(--lime-ink); border-color: var(--lime); }
.intelligence-actions svg { width: 12px; height: 12px; }
.detail-section { padding: 12px; border: 1px solid var(--line); border-radius: 15px; background: #fff; }
.detail-section-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; margin-bottom: 9px; }
.detail-section-head small { display: block; color: var(--muted-2); font-size: 6.5px; font-weight: 750; letter-spacing: .1em; text-transform: uppercase; }
.detail-section-head h3 { margin: 2px 0 0; font-size: 11.5px; }
.detail-section-head > span { color: var(--muted); font-size: 8px; }
.detail-collection-chips { display: flex; flex-wrap: wrap; gap: 5px; }
.detail-collection-chips button { --collection-color: var(--accent); min-height: 25px; padding: 0 7px; display: inline-flex; align-items: center; gap: 5px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface-2); color: var(--muted); cursor: pointer; font-size: 7.5px; }
.detail-collection-chips button i { width: 6px; height: 6px; border-radius: 50%; background: var(--collection-color); }
.detail-collection-chips button svg { display: none; width: 10px; height: 10px; }
.detail-collection-chips button.is-selected { color: var(--collection-color); border-color: color-mix(in srgb, var(--collection-color) 44%, var(--line)); background: color-mix(in srgb, var(--collection-color) 7%, white); }
.detail-collection-chips button.is-selected svg { display: block; }
.entity-group { margin-top: 8px; }
.entity-group:first-of-type { margin-top: 0; }
.entity-group > strong { display: block; color: var(--muted); font-size: 7.5px; }
.entity-group > div { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 4px; }
.entity-group span { padding: 4px 6px; border-radius: 6px; background: var(--surface-3); font-size: 7.5px; }
.insight-empty { margin: 0; color: var(--muted); font-size: 8.5px; }
.detail-empty-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; color: var(--muted); }
.detail-empty-row p { margin: 0; font-size: 8.5px; }
.detail-empty-row button { border: 0; background: transparent; color: var(--accent); cursor: pointer; font-size: 8.5px; font-weight: 700; }
.detail-version-list, .detail-activity-list { display: grid; gap: 5px; }
.detail-version-list > div { min-width: 0; display: grid; grid-template-columns: 31px minmax(0,1fr); gap: 8px; align-items: center; }
.detail-version-list b { width: 31px; height: 28px; border-radius: 8px; display: grid; place-items: center; background: var(--surface-3); font-size: 7.5px; }
.detail-version-list strong, .detail-version-list small { display: block; }
.detail-version-list strong { font-size: 8px; }
.detail-version-list small { color: var(--muted); margin-top: 1px; font-size: 7px; }
.detail-activity-list > div { min-width: 0; display: grid; grid-template-columns: 27px minmax(0,1fr); gap: 7px; align-items: center; }
.detail-activity-list .user-avatar { width: 27px; height: 27px; font-size: 7px; }
.detail-activity-list p { min-width: 0; margin: 0; }
.detail-activity-list strong, .detail-activity-list small { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.detail-activity-list strong { font-size: 7.5px; }
.detail-activity-list small { color: var(--muted); margin-top: 2px; font-size: 7px; }

.compare-setup { display: grid; grid-template-columns: minmax(0,1fr) 40px minmax(0,1fr); gap: 10px; align-items: center; }
.compare-file-fixed, .compare-file-select { min-width: 0; min-height: 86px; padding: 13px; border: 1px solid var(--line); border-radius: 15px; background: var(--surface-2); }
.compare-file-fixed { display: grid; grid-template-columns: 38px minmax(0,1fr); gap: 10px; align-items: center; }
.compare-file-fixed > span { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 11px; background: #fff; }
.compare-file-fixed svg { width: 18px; height: 18px; }
.compare-file-fixed small, .compare-file-fixed strong, .compare-file-select small { display: block; }
.compare-file-fixed small, .compare-file-select small { color: var(--muted); margin-bottom: 5px; font-size: 8px; }
.compare-file-fixed strong { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 10px; }
.compare-arrow { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 12px; background: var(--ink); color: #fff; }
.compare-arrow svg { width: 17px; height: 17px; }
.compare-note { margin-top: 10px; padding: 9px 10px; display: flex; align-items: flex-start; gap: 7px; border: 1px solid #dfe0fb; border-radius: 11px; background: #f6f6ff; color: #5556a9; font-size: 8.5px; }
.compare-note svg { width: 13px; height: 13px; flex: 0 0 auto; }
.compare-result-card { margin-top: 14px; padding: 15px; border: 1px solid var(--line); border-radius: 17px; background: #fff; }
.compare-result-head { display: grid; grid-template-columns: minmax(0,1fr) 95px; gap: 16px; align-items: start; }
.compare-result-head small { color: var(--muted-2); font-size: 7px; letter-spacing: .09em; text-transform: uppercase; }
.compare-result-head h3 { margin: 5px 0 0; font-size: 13px; line-height: 1.45; font-weight: 600; }
.similarity-score { width: 92px; height: 72px; display: grid; place-content: center; text-align: center; border-radius: 15px; background: var(--ink); color: #fff; }
.similarity-score strong { font-size: 20px; line-height: 1; }
.similarity-score span { color: #9399a5; margin-top: 3px; font-size: 7px; }
.compare-stats { display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); gap: 6px; margin-top: 13px; }
.compare-stats > div { min-width: 0; padding: 9px; border-radius: 11px; background: var(--surface-2); }
.compare-stats strong, .compare-stats span { display: block; }
.compare-stats strong { font-size: 12px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.compare-stats span { color: var(--muted); margin-top: 2px; font-size: 7px; }
.risk-text.risk-high { color: var(--danger); font-size: 9px; }
.risk-text.risk-medium { color: var(--warning); font-size: 9px; }
.risk-text.risk-low { color: var(--success); font-size: 9px; }
.compare-diff-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 12px; }
.compare-diff-grid > div { min-width: 0; padding: 11px; border: 1px solid var(--line); border-radius: 13px; background: var(--surface-2); }
.compare-diff-grid h4 { margin: 0 0 8px; display: flex; align-items: center; gap: 5px; font-size: 9px; }
.compare-diff-grid h4 svg { width: 12px; height: 12px; }
.compare-diff-grid ul { max-height: 210px; overflow: auto; margin: 0; padding-left: 17px; }
.compare-diff-grid li { margin-bottom: 5px; color: var(--ink-soft); font-size: 8px; line-height: 1.45; }
.compare-diff-grid p { margin: 0; color: var(--muted); font-size: 8px; }

@media (max-width: 1180px) {
    .dashboard-grid { grid-template-columns: minmax(0,1.4fr) minmax(260px,.8fr); }
    .dashboard-collections { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .dashboard-collections .collection-card:nth-child(n+5) { display: none; }
    .document-detail-grid { grid-template-columns: minmax(0,1fr) minmax(330px,.82fr); }
}
@media (max-width: 900px) {
    .briefing-card { grid-template-columns: 1fr; }
    .briefing-score { position: absolute; right: 24px; top: 24px; opacity: .38; }
    .briefing-copy { padding-right: 130px; }
    .dashboard-metrics { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .dashboard-grid { grid-template-columns: 1fr; }
    .dashboard-section--wide { grid-column: auto; }
    .document-detail-grid { grid-template-columns: 1fr; overflow: auto; }
    .document-preview-panel { min-height: 480px; border-right: 0; border-bottom: 1px solid var(--line); }
    .document-intelligence-panel { overflow: visible; }
    .modal.modal-document { height: 94vh; }
}
@media (max-width: 720px) {
    .dashboard-head { align-items: flex-start; flex-direction: column; gap: 13px; }
    .dashboard-head h1 { font-size: 34px; }
    .dashboard-actions { width: 100%; }
    .dashboard-actions > button { flex: 1; justify-content: center; }
    .briefing-card { min-height: 360px; padding: 22px; border-radius: 23px; }
    .briefing-copy { padding-right: 0; }
    .briefing-copy h2 { max-width: 92%; font-size: 27px; }
    .briefing-items { grid-template-columns: 1fr; }
    .briefing-score { display: none; }
    .dashboard-files { grid-template-columns: 1fr; }
    .dashboard-collections { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .collections-intro { align-items: flex-start; flex-direction: column; padding: 21px; }
    .collections-intro > button { width: 100%; justify-content: center; }
    .collections-grid { grid-template-columns: 1fr; }
    .compare-setup { grid-template-columns: 1fr; }
    .compare-arrow { margin: -3px auto; transform: rotate(90deg); }
    .compare-stats { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .compare-diff-grid { grid-template-columns: 1fr; }
    .modal-foot { flex-wrap: wrap; }
    .modal-foot-group { flex: 1 1 auto; }
    .document-preview-panel { min-height: 380px; }
    .document-detail-grid { display: block; }
    .document-intelligence-panel { padding: 10px; }
}
@media (max-width: 430px) {
    .dashboard-metrics { grid-template-columns: 1fr; }
    .dashboard-collections { grid-template-columns: 1fr; }
    .briefing-actions button { width: 100%; justify-content: center; }
    .collection-card--compact { min-height: 118px; }
    .modal-foot-group { width: 100%; }
    .modal-foot-group > * { flex: 1; justify-content: center; }
}

/* LYNQ Space 0.3 — cloud operations */
.storage-widget--button { width: 100%; border: 0; color: inherit; text-align: left; cursor: pointer; }
.upload-center-toggle { position: relative; }
.upload-center-toggle > span { position: absolute; right: -3px; top: -3px; min-width: 15px; height: 15px; padding: 0 4px; display: grid; place-items: center; border: 2px solid #fff; border-radius: 999px; background: var(--accent); color: #fff; font-size: 7px; font-weight: 800; }
.upload-center { position: fixed; right: 20px; bottom: 18px; z-index: 75; width: min(420px, calc(100vw - 28px)); max-height: min(520px, calc(100vh - 90px)); display: none; overflow: hidden; border: 1px solid rgba(13,18,30,.12); border-radius: 20px; background: rgba(255,255,255,.97); box-shadow: 0 24px 80px rgba(12,18,28,.22); backdrop-filter: blur(22px); }
.upload-center.is-open { display: block; animation: uploadCenterIn .22s ease-out; }
@keyframes uploadCenterIn { from { opacity: 0; transform: translateY(12px) scale(.98); } to { opacity: 1; transform: none; } }
.upload-center-head { height: 61px; padding: 0 15px; display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--line); }
.upload-center-head > div { display: flex; align-items: center; gap: 10px; }
.upload-center-head > div > span { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 11px; background: var(--ink); color: #fff; }
.upload-center-head svg { width: 15px; height: 15px; }
.upload-center-head strong, .upload-center-head small { display: block; }
.upload-center-head strong { font-size: 10px; }
.upload-center-head small { margin-top: 2px; color: var(--muted); font-size: 7.5px; }
.upload-center-head > button { width: 28px; height: 28px; display: grid; place-items: center; border: 0; border-radius: 8px; background: var(--surface-3); cursor: pointer; }
.upload-center-list { max-height: 430px; overflow: auto; padding: 8px; }
.upload-job { display: grid; grid-template-columns: 36px minmax(0,1fr) auto; gap: 9px; align-items: center; padding: 10px; border-radius: 13px; }
.upload-job + .upload-job { border-top: 1px solid var(--line); border-radius: 0; }
.upload-job-icon { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 10px; background: var(--surface-3); color: var(--ink-soft); }
.upload-job-icon svg { width: 16px; height: 16px; }
.upload-job-main { min-width: 0; }
.upload-job-main > div { display: grid; grid-template-columns: minmax(0,1fr) auto; column-gap: 8px; row-gap: 2px; align-items: center; }
.upload-job-main strong, .upload-job-main small { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.upload-job-main strong { min-width: 0; font-size: 8.7px; }
.upload-job-main small { grid-column: 1 / -1; margin-top: 0; color: var(--muted); font-size: 7.2px; }
.upload-mode-badge { max-width: 132px; overflow: hidden; padding: 3px 6px; border-radius: 999px; background: rgba(var(--accent-rgb),.1); color: var(--accent-strong); font-size: 6.4px; font-style: normal; font-weight: 800; letter-spacing: .015em; white-space: nowrap; text-overflow: ellipsis; }
.upload-job-main > i { height: 4px; display: block; overflow: hidden; margin-top: 7px; border-radius: 99px; background: #e7e9ee; }
.upload-job-main > i em { height: 100%; display: block; border-radius: inherit; background: var(--accent); transition: width .2s ease; }
.upload-job.completed .upload-job-main > i em { background: var(--success); }
.upload-job.failed .upload-job-main > i em { background: var(--danger); }
.upload-job-main > p { margin: 5px 0 0; color: var(--danger); font-size: 7px; line-height: 1.35; }
.upload-job-actions { display: flex; gap: 3px; }
.upload-job-actions button { width: 27px; height: 27px; display: grid; place-items: center; border: 0; border-radius: 8px; background: var(--surface-3); color: var(--ink-soft); cursor: pointer; }
.upload-job-actions button:hover { background: var(--ink); color: #fff; }
.upload-job-actions svg { width: 12px; height: 12px; }

.storage-page-head { margin-bottom: 17px; }
.storage-hero { position: relative; min-height: 188px; display: grid; grid-template-columns: minmax(0,1fr) 140px; gap: 20px; align-items: center; overflow: hidden; padding: 28px 31px; border-radius: 25px; background: radial-gradient(circle at 85% 20%, rgba(var(--accent-rgb),.34), transparent 34%), linear-gradient(135deg,#111621,#202734); color: #fff; }
.storage-hero::after { content: ''; position: absolute; width: 260px; height: 260px; right: -80px; bottom: -170px; border: 1px solid rgba(255,255,255,.14); border-radius: 50%; box-shadow: 0 0 0 40px rgba(255,255,255,.025), 0 0 0 80px rgba(255,255,255,.018); }
.storage-hero-copy { position: relative; z-index: 1; max-width: 720px; }
.storage-hero-copy > span { color: #9da5b5; font-size: 8px; letter-spacing: .1em; text-transform: uppercase; }
.storage-hero-copy > strong { display: block; margin-top: 9px; font-size: clamp(27px,3vw,43px); line-height: 1; font-weight: 600; letter-spacing: -.035em; }
.storage-hero-copy > strong small { color: #9da5b5; font-size: .42em; font-weight: 500; }
.storage-hero-copy p { max-width: 540px; margin: 12px 0 17px; color: #b4bbc8; font-size: 9px; line-height: 1.55; }
.storage-main-track { height: 7px; overflow: hidden; border-radius: 99px; background: rgba(255,255,255,.12); }
.storage-main-track i { height: 100%; display: block; border-radius: inherit; background: var(--lime); box-shadow: 0 0 20px rgba(198,255,57,.35); }
.storage-gauge { position: relative; z-index: 1; width: 122px; height: 122px; display: grid; place-content: center; text-align: center; border: 1px solid rgba(255,255,255,.16); border-radius: 50%; background: rgba(255,255,255,.05); box-shadow: inset 0 0 0 10px rgba(255,255,255,.025); }
.storage-gauge strong { font-size: 25px; font-weight: 600; }
.storage-gauge span { margin-top: 3px; color: #aab1bd; font-size: 7px; text-transform: uppercase; letter-spacing: .09em; }
.storage-stat-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 9px; margin: 11px 0; }
.storage-stat-grid > * { min-width: 0; min-height: 91px; display: grid; grid-template-columns: 34px minmax(0,1fr); grid-template-rows: auto auto; column-gap: 9px; align-content: center; padding: 14px; border: 1px solid var(--line); border-radius: 15px; background: #fff; text-align: left; }
.storage-stat-grid button { color: inherit; cursor: pointer; }
.storage-stat-grid > * > span { grid-row: 1/3; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; background: var(--surface-3); }
.storage-stat-grid svg { width: 15px; height: 15px; }
.storage-stat-grid strong { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 14px; }
.storage-stat-grid small { color: var(--muted); font-size: 7.5px; }
.storage-layout { display: grid; grid-template-columns: minmax(0,1.35fr) minmax(270px,.65fr); gap: 11px; }
.storage-panel { min-width: 0; padding: 17px; border: 1px solid var(--line); border-radius: 18px; background: #fff; }
.storage-panel--wide { min-height: 260px; }
.storage-panel-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; margin-bottom: 12px; }
.storage-panel-head span { color: var(--muted-2); font-size: 7px; letter-spacing: .1em; text-transform: uppercase; }
.storage-panel-head h2 { margin: 4px 0 0; font-size: 15px; }
.storage-panel-head > button { display: flex; align-items: center; gap: 5px; border: 0; background: transparent; color: var(--muted); font-size: 8px; cursor: pointer; }
.storage-panel-head > button svg { width: 11px; height: 11px; }
.storage-category-list { display: grid; gap: 4px; }
.storage-category-list > button { width: 100%; min-width: 0; display: grid; grid-template-columns: 36px minmax(0,1fr) auto; gap: 10px; align-items: center; padding: 7px; border: 0; border-radius: 11px; background: transparent; color: inherit; text-align: left; cursor: pointer; }
.storage-category-list > button:hover { background: var(--surface-2); }
.storage-category-icon { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 10px; background: var(--surface-3); }
.storage-category-icon svg { width: 15px; height: 15px; }
.storage-category-copy { min-width: 0; }
.storage-category-copy strong, .storage-category-copy small { display: block; }
.storage-category-copy strong { font-size: 8.5px; }
.storage-category-copy small { margin-top: 1px; color: var(--muted); font-size: 7px; }
.storage-category-copy i { height: 3px; display: block; overflow: hidden; margin-top: 6px; border-radius: 99px; background: #e9ebef; }
.storage-category-copy em { height: 100%; display: block; border-radius: inherit; background: var(--accent); }
.storage-category-list > button > b { font-size: 8.5px; white-space: nowrap; }
.share-pulse { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; }
.share-pulse > div { min-height: 72px; display: grid; align-content: center; padding: 11px; border-radius: 12px; background: var(--surface-2); }
.share-pulse strong { font-size: 18px; }
.share-pulse span { margin-top: 3px; color: var(--muted); font-size: 7.5px; }
.duplicate-groups { display: grid; gap: 5px; }
.duplicate-groups > div { display: grid; grid-template-columns: 35px minmax(0,1fr) auto; gap: 9px; align-items: center; padding: 8px; border-radius: 11px; background: var(--surface-2); }
.duplicate-group-icon { width: 35px; height: 35px; display: grid; place-items: center; border-radius: 10px; background: #fff; }
.duplicate-group-icon svg { width: 14px; height: 14px; }
.duplicate-groups strong, .duplicate-groups small { display: block; }
.duplicate-groups strong { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 8.5px; }
.duplicate-groups small { margin-top: 2px; color: var(--muted); font-size: 7px; }
.duplicate-groups > div > b { text-align: right; font-size: 8.5px; }
.duplicate-groups > div > b small { font-weight: 400; }
.largest-file-list { display: grid; gap: 4px; }
.largest-file-list > button { width: 100%; min-width: 0; display: grid; grid-template-columns: 31px minmax(0,1fr) auto; gap: 8px; align-items: center; padding: 6px; border: 0; border-radius: 10px; background: transparent; color: inherit; text-align: left; cursor: pointer; }
.largest-file-list > button:hover { background: var(--surface-2); }
.largest-file-list .row-icon { width: 31px; height: 31px; }
.largest-file-list strong, .largest-file-list small { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.largest-file-list strong { font-size: 8px; }
.largest-file-list small { color: var(--muted); margin-top: 2px; font-size: 7px; }
.largest-file-list b { font-size: 8px; white-space: nowrap; }
.storage-category-mini { display: grid; gap: 8px; }
.storage-category-mini > div > span { display: flex; justify-content: space-between; gap: 10px; }
.storage-category-mini b { font-size: 8px; }
.storage-category-mini small { color: var(--muted); font-size: 7.5px; }
.storage-category-mini i { height: 4px; display: block; overflow: hidden; margin-top: 4px; border-radius: 99px; background: var(--surface-3); }
.storage-category-mini em { height: 100%; display: block; border-radius: inherit; background: var(--accent); }
.duplicate-badge { display: inline-flex; align-items: center; gap: 3px; padding: 4px 6px; border-radius: 7px; background: #eef0ff; color: #5556a9; font-size: 7px; font-weight: 700; }
.duplicate-badge svg { width: 10px; height: 10px; }
.signal-duplicate { color: #5556a9; background: #eef0ff; }
.file-language-pill { padding: 4px 7px; border-radius: 99px; background: var(--surface-3); color: var(--muted); font-size: 7px; font-weight: 700; text-transform: uppercase; }
.file-hash { margin-top: 9px; padding: 8px; border-radius: 9px; background: var(--surface-3); }
.file-hash span { display: block; color: var(--muted); font-size: 6.5px; letter-spacing: .08em; text-transform: uppercase; }
.file-hash code { display: block; overflow: hidden; margin-top: 3px; color: var(--ink-soft); font-size: 6.5px; white-space: nowrap; text-overflow: ellipsis; }
.detail-duplicate-list { display: grid; gap: 4px; }
.detail-duplicate-list button { width: 100%; display: grid; grid-template-columns: 28px minmax(0,1fr) 11px; gap: 7px; align-items: center; padding: 6px; border: 0; border-radius: 9px; background: var(--surface-2); color: inherit; text-align: left; cursor: pointer; }
.detail-duplicate-list button > span { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 8px; background: #fff; }
.detail-duplicate-list svg { width: 11px; height: 11px; }
.detail-duplicate-list strong, .detail-duplicate-list small { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.detail-duplicate-list strong { font-size: 7.8px; }
.detail-duplicate-list small { color: var(--muted); margin-top: 1px; font-size: 6.8px; }
.change-text { font-size: 8px !important; }
.change-high { color: var(--danger); }
.change-medium { color: var(--warning); }
.change-low { color: var(--success); }
.share-analytics-mini { min-width: 48px; text-align: right; }
.share-analytics-mini b, .share-analytics-mini small { display: block; }
.share-analytics-mini b { font-size: 9px; }
.share-analytics-mini small { color: var(--muted); font-size: 6.5px; }
.share-analytics-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 8px; }
.share-analytics-grid > div { min-height: 86px; display: grid; align-content: center; padding: 13px; border-radius: 14px; background: var(--surface-2); }
.share-analytics-grid strong { font-size: 21px; }
.share-analytics-grid span { margin-top: 3px; color: var(--muted); font-size: 7.5px; }
.share-event-section { margin-top: 15px; }
.share-event-list { display: grid; gap: 4px; }
.share-event-list > div { display: grid; grid-template-columns: 31px minmax(0,1fr); gap: 8px; align-items: center; padding: 7px; border-radius: 10px; background: var(--surface-2); }
.share-event-list > div > span { width: 31px; height: 31px; display: grid; place-items: center; border-radius: 9px; background: #fff; }
.share-event-list svg { width: 13px; height: 13px; }
.share-event-list p { min-width: 0; margin: 0; }
.share-event-list strong, .share-event-list small { display: block; }
.share-event-list strong { font-size: 8px; }
.share-event-list small { margin-top: 2px; color: var(--muted); font-size: 7px; }

@media (max-width: 900px) {
    .storage-layout { grid-template-columns: 1fr; }
    .storage-stat-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .storage-hero { grid-template-columns: 1fr 105px; }
    .storage-gauge { width: 100px; height: 100px; }
}
@media (max-width: 720px) {
    .storage-hero { grid-template-columns: 1fr; padding: 23px; }
    .storage-gauge { position: absolute; right: 22px; top: 20px; width: 78px; height: 78px; opacity: .72; }
    .storage-gauge strong { font-size: 17px; }
    .storage-hero-copy { padding-right: 75px; }
    .share-analytics-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .upload-center { right: 8px; bottom: 8px; width: calc(100vw - 16px); }
}
@media (max-width: 430px) {
    .storage-stat-grid { grid-template-columns: 1fr; }
    .storage-hero-copy { padding-right: 0; }
    .storage-gauge { display: none; }
    .storage-category-list > button { grid-template-columns: 33px minmax(0,1fr); }
    .storage-category-list > button > b { grid-column: 2; }
    .share-analytics-mini { display: none; }
}

/* ========================================================================== */
/* LYNQ Space 0.4 — Light Workspace                                           */
/* ========================================================================== */
:root {
    color-scheme: light;
    --ink: #17191f;
    --ink-soft: #3f4450;
    --muted: #737a87;
    --muted-2: #9aa1ad;
    --bg: #f7f8fa;
    --surface: #ffffff;
    --surface-2: #f8f9fb;
    --surface-3: #eef1f5;
    --line: #e5e8ed;
    --line-strong: #d7dbe2;
    --accent-soft: #f0f0ff;
    --lime: var(--accent);
    --lime-ink: #ffffff;
    --sidebar: #ffffff;
    --sidebar-2: #f8f9fb;
    --sidebar-text: var(--ink);
    --sidebar-muted: var(--muted);
    --radius-sm: 10px;
    --radius: 14px;
    --radius-lg: 20px;
    --radius-xl: 26px;
    --shadow-sm: 0 1px 2px rgba(20, 24, 33, .03);
    --shadow: 0 22px 70px rgba(20, 24, 33, .12);
    --sidebar-width: 248px;
    --ai-width: 396px;
}

body {
    background: var(--bg);
    color: var(--ink);
    font-size: 14px;
}

button, input, textarea, select { -webkit-tap-highlight-color: transparent; }
button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible, a:focus-visible {
    outline: 3px solid rgba(var(--accent-rgb), .16);
    outline-offset: 2px;
}

/* Brand */
.brand-mark em {
    background: var(--accent);
    box-shadow: 0 0 0 3px rgba(var(--accent-rgb), .11);
}
.brand-product { color: var(--muted); }
.brand-lockup--boot { color: var(--ink); }
.boot-screen {
    background: radial-gradient(circle at 50% 42%, rgba(var(--accent-rgb), .08), transparent 30%), #fff;
}
.boot-line { background: #edf0f4; }
.boot-line span { background: var(--accent); }

/* Authentication */
.auth-shell.auth-shell--light {
    min-height: 100dvh;
    height: 100vh;
    grid-template-columns: minmax(440px, .82fr) minmax(560px, 1.18fr);
    background: #fff;
}
.auth-shell--light .auth-panel {
    min-width: 0;
    display: block;
    padding: 0;
    background: #fff;
    overflow: auto;
}
.auth-shell--light .auth-panel::before { display: none; }
.auth-panel-inner {
    min-height: 100%;
    width: min(100%, 600px);
    margin: 0 auto;
    padding: clamp(28px, 5vw, 64px);
    display: flex;
    flex-direction: column;
}
.auth-panel-brand {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}
.auth-security {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--muted);
    font-size: 11px;
    white-space: nowrap;
}
.auth-security svg { width: 14px; height: 14px; color: var(--success); }
.auth-shell--light .auth-card {
    width: min(100%, 430px);
    margin: auto 0;
    padding: 54px 0 34px;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
}
.auth-eyebrow {
    margin-bottom: 10px;
    color: var(--accent);
    font-size: 11px;
    font-weight: 750;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.auth-shell--light .auth-card h2 {
    margin: 0 0 12px;
    font-size: clamp(32px, 4vw, 44px);
    line-height: 1.04;
    letter-spacing: -.052em;
    font-weight: 720;
}
.auth-shell--light .auth-card > p {
    max-width: 390px;
    margin: 0 0 28px;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.65;
}
.auth-shell--light .auth-tabs {
    margin-bottom: 22px;
    padding: 3px;
    border: 1px solid var(--line);
    border-radius: 11px;
    background: var(--surface-2);
}
.auth-shell--light .auth-tab {
    min-height: 38px;
    border-radius: 8px;
    font-size: 12px;
}
.auth-shell--light .auth-tab.is-active {
    background: #fff;
    box-shadow: 0 1px 4px rgba(20, 24, 33, .08);
}
.field { gap: 8px; }
.field label { color: var(--ink-soft); font-size: 12px; }
.field-input {
    min-height: 46px;
    border-color: var(--line-strong);
    border-radius: 11px;
    padding: 12px 14px;
    background: #fff;
}
.field-input:hover { border-color: #c8cdd5; }
.field-input:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 4px rgba(var(--accent-rgb), .09);
}
.auth-submit {
    min-height: 48px;
    margin-top: 4px;
    border-radius: 11px;
    background: var(--ink);
    box-shadow: none;
}
.auth-submit > span:first-child { flex: 1; text-align: left; }
.auth-submit svg { width: 16px; height: 16px; }
.auth-submit:hover { background: #2a2d35; transform: none; }
.auth-demo {
    width: 100%;
    min-height: 58px;
    margin-top: 14px;
    padding: 10px 12px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface-2);
    color: var(--ink);
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr) 18px;
    gap: 10px;
    align-items: center;
    text-align: left;
    cursor: pointer;
}
.auth-demo > span:first-child {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: var(--accent-soft);
    color: var(--accent);
}
.auth-demo svg { width: 15px; height: 15px; }
.auth-demo strong, .auth-demo small { display: block; }
.auth-demo strong { font-size: 12px; }
.auth-demo small { margin-top: 2px; color: var(--muted); font-size: 10px; }
.auth-legal { margin-top: 18px; text-align: left; line-height: 1.5; }
.auth-shell--light .auth-story {
    min-width: 0;
    margin: 14px 14px 14px 0;
    padding: clamp(38px, 5vw, 72px);
    border: 1px solid #e2e5ff;
    border-radius: 28px;
    color: var(--ink);
    background:
        radial-gradient(circle at 88% 6%, rgba(var(--accent-rgb), .15), transparent 26%),
        radial-gradient(circle at 8% 86%, rgba(126, 211, 255, .18), transparent 31%),
        linear-gradient(145deg, #f7f7ff 0%, #f2f5ff 54%, #f8fbff 100%);
    display: grid;
    grid-template-rows: auto minmax(260px, 1fr) auto;
    gap: 26px;
}
.auth-shell--light .auth-story::before, .auth-shell--light .auth-graph { display: none; }
.auth-story-copy { position: relative; z-index: 2; max-width: 690px; }
.auth-shell--light .auth-kicker {
    color: var(--muted);
    font-size: 11px;
    letter-spacing: .08em;
}
.auth-shell--light .auth-kicker::before { display: none; }
.auth-kicker > span {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 0 5px rgba(var(--accent-rgb), .09);
}
.auth-shell--light .auth-story h1 {
    max-width: 720px;
    margin: 20px 0 16px;
    color: var(--ink);
    font-size: clamp(44px, 5vw, 72px);
    line-height: .98;
    letter-spacing: -.066em;
    font-weight: 720;
}
.auth-shell--light .auth-story h1 span { color: var(--accent); }
.auth-shell--light .auth-story-copy > p {
    max-width: 620px;
    margin: 0;
    color: var(--muted);
    font-size: 16px;
    line-height: 1.65;
}
.auth-shell--light .auth-benefits {
    max-width: 760px;
    margin-top: 26px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}
.auth-shell--light .auth-benefit {
    min-width: 0;
    padding: 13px;
    border: 1px solid rgba(110, 116, 170, .14);
    border-radius: 13px;
    background: rgba(255, 255, 255, .64);
    display: grid;
    grid-template-columns: 30px minmax(0, 1fr);
    gap: 9px;
    align-items: center;
    backdrop-filter: blur(12px);
}
.auth-shell--light .auth-benefit > svg {
    width: 17px;
    height: 17px;
    color: var(--accent);
}
.auth-shell--light .auth-benefit strong, .auth-shell--light .auth-benefit small { display: block; }
.auth-shell--light .auth-benefit strong { margin: 0; color: var(--ink); font-size: 11px; }
.auth-shell--light .auth-benefit small { margin-top: 2px; color: var(--muted); font-size: 9px; }
.auth-preview {
    position: relative;
    z-index: 1;
    align-self: end;
    width: min(100%, 760px);
    min-height: 300px;
    margin-left: auto;
    border: 1px solid rgba(125, 132, 178, .18);
    border-radius: 20px;
    background: rgba(255, 255, 255, .88);
    box-shadow: 0 30px 80px rgba(63, 70, 130, .15);
    overflow: hidden;
    transform: perspective(1200px) rotateX(1deg) rotateY(-2deg);
}
.auth-preview-bar {
    height: 36px;
    padding: 0 12px;
    display: flex;
    align-items: center;
    gap: 6px;
    border-bottom: 1px solid var(--line);
    background: rgba(250, 251, 253, .96);
}
.auth-preview-bar i { width: 7px; height: 7px; border-radius: 50%; background: #d7dbe3; }
.auth-preview-bar span { margin-left: 7px; color: var(--muted); font-size: 8px; }
.auth-preview-layout { min-height: 264px; display: grid; grid-template-columns: 116px minmax(0, 1fr); }
.auth-preview-nav { padding: 19px 13px; border-right: 1px solid var(--line); display: grid; align-content: start; gap: 13px; }
.auth-preview-nav b { width: 70px; height: 12px; border-radius: 4px; background: var(--accent); opacity: .84; }
.auth-preview-nav span { width: 76px; height: 7px; border-radius: 99px; background: #e9ecf1; }
.auth-preview-main { padding: 18px; }
.auth-preview-search { width: min(100%, 360px); height: 28px; border-radius: 8px; background: #eef1f5; }
.auth-preview-title { width: 180px; height: 17px; margin-top: 24px; border-radius: 5px; background: #22252d; opacity: .88; }
.auth-preview-actions { display: flex; gap: 8px; margin-top: 16px; }
.auth-preview-actions i { width: 90px; height: 42px; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
.auth-preview-actions i:first-child { background: var(--accent-soft); border-color: rgba(var(--accent-rgb), .12); }
.auth-preview-files { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 14px; }
.auth-preview-files span { height: 76px; border: 1px solid var(--line); border-radius: 11px; background: linear-gradient(145deg, #fff, #f6f7f9); }
.auth-story-foot {
    position: relative;
    z-index: 2;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    color: var(--muted);
    font-size: 10px;
}
.auth-story-foot span { display: inline-flex; align-items: center; gap: 6px; }
.auth-story-foot svg { width: 13px; height: 13px; color: var(--success); }

/* Workspace layout */
.workspace-shell,
.workspace-shell.ai-closed {
    height: 100vh;
    display: grid;
    grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
    position: relative;
    overflow: hidden;
    background: var(--bg);
}
.sidebar {
    width: var(--sidebar-width);
    height: 100vh;
    padding: 16px 12px 14px;
    border-right: 1px solid var(--line);
    background: #fff;
    color: var(--ink);
    overflow-y: auto;
    overflow-x: hidden;
    scrollbar-width: thin;
}
.sidebar::after { display: none; }
.sidebar-brand-row {
    min-height: 40px;
    padding: 0 8px 8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}
.sidebar .brand-lockup { padding: 0; color: var(--ink); }
.sidebar .brand-product { color: var(--muted); }
.sidebar-mobile-close {
    display: none;
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 9px;
    background: var(--surface-2);
    color: var(--ink-soft);
    place-items: center;
    cursor: pointer;
}
.sidebar-mobile-close svg { width: 16px; height: 16px; }
.sidebar-create-btn {
    width: 100%;
    min-height: 43px;
    margin: 8px 0 10px;
    padding: 0 13px;
    border: 0;
    border-radius: 11px;
    background: var(--ink);
    color: #fff;
    display: grid;
    grid-template-columns: 18px minmax(0, 1fr) 15px;
    gap: 8px;
    align-items: center;
    text-align: left;
    font-weight: 680;
    font-size: 12px;
    cursor: pointer;
    transition: background .16s ease, transform .16s ease;
}
.sidebar-create-btn:hover { background: #2a2d35; transform: translateY(-1px); }
.sidebar-create-btn svg { width: 16px; height: 16px; }
.sidebar-create-btn svg:last-child { width: 13px; height: 13px; opacity: .65; }
.space-switcher { margin-bottom: 10px; }
.space-switcher-btn {
    min-height: 52px;
    padding: 7px 8px;
    border-color: var(--line);
    border-radius: 11px;
    background: var(--surface-2);
    color: var(--ink);
}
.space-switcher-btn:hover { border-color: var(--line-strong); background: #f4f6f8; }
.space-avatar {
    background: var(--space-accent, var(--accent));
    color: #fff;
    box-shadow: none;
}
.space-avatar--new { background: var(--surface-3); color: var(--ink-soft); }
.space-avatar--new svg { width: 15px; height: 15px; }
.space-switcher-copy strong { color: var(--ink); font-size: 11.5px; }
.space-switcher-copy span { color: var(--muted); font-size: 9.5px; }
.space-switcher-btn > svg { width: 14px; height: 14px; color: var(--muted); }
.space-menu {
    top: calc(100% + 7px);
    left: 0;
    right: auto;
    width: min(310px, calc(100vw - 24px));
    padding: 6px;
    border-color: var(--line);
    border-radius: 13px;
    background: #fff;
    box-shadow: 0 18px 48px rgba(20, 24, 33, .16);
}
.space-menu-item { color: var(--ink); }
.space-menu-item:hover, .space-menu-item.is-active { background: var(--surface-2); }
.space-menu-item strong { color: var(--ink); }
.space-menu-item span { color: var(--muted); }
.space-menu-add { border-color: var(--line); }
.sidebar-section-title {
    padding: 18px 10px 7px;
    color: var(--muted-2);
    font-size: 9px;
    letter-spacing: .1em;
}
.sidebar-nav { gap: 2px; }
.sidebar-nav--primary { margin-top: 2px; }
.nav-btn {
    min-height: 37px;
    padding: 0 10px;
    border-radius: 9px;
    color: var(--ink-soft);
}
.nav-btn:hover { background: var(--surface-2); color: var(--ink); }
.nav-btn.is-active {
    background: var(--accent-soft);
    color: var(--accent);
    font-weight: 680;
}
.nav-btn.is-active::before { display: none; }
.nav-btn svg { width: 16px; height: 16px; }
.nav-btn span { font-size: 11.5px; }
.nav-badge {
    background: var(--surface-3);
    color: var(--muted);
}
.sidebar-divider { display: none; }
.storage-widget {
    margin: 10px 0 8px;
    padding: 11px;
    border-color: var(--line);
    border-radius: 11px;
    background: var(--surface-2);
}
.storage-widget:hover { background: #f3f5f8; }
.storage-widget-head { color: var(--muted); }
.storage-widget-head strong { color: var(--ink); }
.storage-track { background: #e5e8ed; }
.storage-track span { background: var(--accent); }
.storage-widget p { color: var(--muted); }
.sidebar-footer-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5px;
    margin-bottom: 6px;
}
.sidebar-footer-actions button {
    min-width: 0;
    min-height: 34px;
    padding: 0 8px;
    border: 0;
    border-radius: 9px;
    background: transparent;
    color: var(--muted);
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-size: 9px;
}
.sidebar-footer-actions button:hover { background: var(--surface-2); color: var(--ink); }
.sidebar-footer-actions svg { width: 13px; height: 13px; }
.sidebar-footer-actions span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sidebar-footer-actions b { margin-left: auto; font-size: 8px; }
.sidebar-profile {
    min-height: 46px;
    padding: 6px;
    border: 1px solid transparent;
    border-radius: 11px;
}
.sidebar-profile:hover { border-color: var(--line); background: var(--surface-2); }
.user-avatar {
    background: var(--avatar-color, var(--accent));
    color: #fff;
}
.sidebar-profile strong { color: var(--ink); }
.sidebar-profile span { color: var(--muted); }
.sidebar-profile > svg { color: var(--muted); width: 15px; height: 15px; }

/* Main navigation and controls */
.main-column {
    height: 100vh;
    grid-template-rows: 68px minmax(0, 1fr);
    background: var(--bg);
}
.topbar {
    height: 68px;
    padding: 0 22px;
    grid-template-columns: minmax(300px, 720px) auto;
    justify-content: space-between;
    gap: 18px;
    border-bottom-color: var(--line);
    background: rgba(255, 255, 255, .92);
    backdrop-filter: blur(18px);
}
.search-wrap { width: 100%; max-width: 720px; }
.search-wrap > svg { left: 14px; color: var(--muted); }
.global-search {
    height: 42px;
    padding-left: 41px;
    border: 1px solid transparent;
    border-radius: 11px;
    background: #f2f4f7;
    color: var(--ink);
}
.global-search::placeholder { color: #9299a4; }
.global-search:hover { background: #eef1f4; }
.global-search:focus {
    border-color: rgba(var(--accent-rgb), .34);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(var(--accent-rgb), .08);
}
.search-shortcut { color: var(--muted-2); }
.search-shortcut kbd { border-color: #dfe3e8; background: #fff; }
.topbar-actions { gap: 7px; }
.icon-btn {
    width: 38px;
    height: 38px;
    border-color: var(--line);
    border-radius: 10px;
    background: #fff;
    color: var(--ink-soft);
    box-shadow: none;
}
.icon-btn:hover { transform: none; border-color: var(--line-strong); background: var(--surface-2); }
.icon-btn.is-active { border-color: rgba(var(--accent-rgb), .18); background: var(--accent-soft); color: var(--accent); }
.ai-trigger {
    min-height: 38px;
    padding: 0 12px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    color: var(--ink-soft);
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 11.5px;
    font-weight: 650;
    cursor: pointer;
    white-space: nowrap;
}
.ai-trigger:hover { border-color: rgba(var(--accent-rgb), .28); background: var(--accent-soft); color: var(--accent); }
.ai-trigger.is-active { border-color: rgba(var(--accent-rgb), .2); background: var(--accent-soft); color: var(--accent); }
.ai-trigger svg { width: 15px; height: 15px; }
.primary-btn {
    height: 40px;
    border-radius: 10px;
    background: var(--ink);
    box-shadow: none;
    font-size: 11.5px;
}
.primary-btn:hover { background: #2a2d35; transform: none; }
.primary-btn--accent { background: var(--accent); }
.primary-btn--accent:hover { filter: brightness(.94); }
.secondary-btn {
    height: 38px;
    border-color: var(--line);
    border-radius: 10px;
    background: #fff;
    font-size: 11.5px;
}
.secondary-btn:hover { border-color: var(--line-strong); background: var(--surface-2); }
.content-scroll { padding: 26px 28px 52px; }
.content-container { width: min(100%, 1440px); }
.page-head {
    min-height: 52px;
    margin-bottom: 20px;
    align-items: center;
}
.eyebrow {
    margin-bottom: 5px;
    color: var(--muted);
    font-size: 9.5px;
    letter-spacing: .09em;
}
.page-head h1 {
    font-size: clamp(26px, 2.4vw, 36px);
    line-height: 1.08;
    letter-spacing: -.045em;
    font-weight: 720;
}
.page-subtitle { margin-top: 6px; color: var(--muted); font-size: 12px; }

/* Dashboard */
.dashboard-head {
    margin: 2px 0 20px;
    align-items: center;
}
.dashboard-head h1 {
    margin: 4px 0 7px;
    font-size: clamp(34px, 4vw, 48px);
    line-height: 1.02;
    letter-spacing: -.056em;
    font-weight: 720;
}
.dashboard-head p { color: var(--muted); font-size: 13px; }
.dashboard-actions { gap: 7px; }
.dashboard-quick-actions {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 16px;
}
.dashboard-quick-actions > button {
    min-width: 0;
    min-height: 86px;
    padding: 13px;
    border: 1px solid var(--line);
    border-radius: 15px;
    background: #fff;
    color: var(--ink);
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr) 16px;
    gap: 10px;
    align-items: center;
    text-align: left;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}
.dashboard-quick-actions > button:hover {
    border-color: rgba(var(--accent-rgb), .28);
    box-shadow: 0 10px 26px rgba(20, 24, 33, .06);
    transform: translateY(-1px);
}
.dashboard-quick-actions > button > span {
    width: 38px;
    height: 38px;
    border-radius: 11px;
    display: grid;
    place-items: center;
    background: var(--surface-3);
    color: var(--ink-soft);
}
.dashboard-quick-actions > button:nth-child(1) > span { background: var(--accent-soft); color: var(--accent); }
.dashboard-quick-actions > button:nth-child(2) > span { background: #edf8f4; color: #11805d; }
.dashboard-quick-actions > button:nth-child(3) > span { background: #fff5e8; color: #b66512; }
.dashboard-quick-actions > button:nth-child(4) > span { background: #edf5ff; color: #2f71c7; }
.dashboard-quick-actions svg { width: 16px; height: 16px; }
.dashboard-quick-actions > button > svg { color: var(--muted-2); width: 14px; height: 14px; }
.dashboard-quick-actions strong, .dashboard-quick-actions small { display: block; }
.dashboard-quick-actions strong { font-size: 11.5px; }
.dashboard-quick-actions small { margin-top: 3px; color: var(--muted); font-size: 9px; line-height: 1.35; }
.dashboard-grid.dashboard-grid--light {
    display: grid;
    grid-template-columns: minmax(0, 1.48fr) minmax(300px, .72fr);
    gap: 14px;
}
.dashboard-grid--light .dashboard-section {
    min-width: 0;
    padding: 17px;
    border: 1px solid var(--line);
    border-radius: 17px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}
.dashboard-grid--light .dashboard-section--wide { grid-column: 1; }
.dashboard-grid--light .dashboard-storage-card { grid-column: 2; grid-row: 1; }
.dashboard-grid--light .dashboard-briefing-card { grid-column: 2; grid-row: 2; }
.dashboard-grid--light .dashboard-activity-section { grid-column: 1 / -1; }
.dashboard-section-head { margin-bottom: 13px; }
.dashboard-section-head > div > span {
    color: var(--muted-2);
    font-size: 8px;
    letter-spacing: .09em;
}
.dashboard-section-head h2 {
    margin-top: 4px;
    color: var(--ink);
    font-size: 16px;
    line-height: 1.25;
}
.dashboard-section-head > button {
    color: var(--muted);
    font-size: 9px;
}
.dashboard-section-head > button:hover { color: var(--accent); }
.dashboard-files { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.dashboard-file {
    min-height: 56px;
    padding: 7px;
    border: 1px solid transparent;
    border-radius: 11px;
    background: var(--surface-2);
}
.dashboard-file:hover { border-color: var(--line); background: #fff; }
.dashboard-file-icon { width: 37px; height: 37px; border-radius: 10px; }
.dashboard-file-copy strong { font-size: 10px; }
.dashboard-file-copy small { font-size: 8px; }
.dashboard-storage-summary {
    margin-bottom: 16px;
    padding: 13px;
    border-radius: 13px;
    background: var(--surface-2);
}
.dashboard-storage-track { height: 7px; overflow: hidden; border-radius: 99px; background: #e3e6eb; }
.dashboard-storage-track i { display: block; height: 100%; border-radius: inherit; background: var(--accent); }
.dashboard-storage-summary p { margin: 9px 0 0; color: var(--muted); font-size: 9px; }
.dashboard-storage-summary p strong { color: var(--ink); }
.dashboard-briefing-card { background: linear-gradient(145deg, #fff, #fafaff) !important; }
.dashboard-briefing-card .briefing-items { grid-template-columns: 1fr; gap: 6px; }
.dashboard-briefing-card .briefing-item {
    min-height: 44px;
    padding: 8px;
    border: 0;
    border-radius: 10px;
    background: var(--surface-2);
    color: var(--ink-soft);
}
.dashboard-briefing-card .briefing-item > span {
    background: var(--accent-soft);
    color: var(--accent);
}
.dashboard-briefing-card .briefing-item p { color: var(--ink-soft); }
.dashboard-collections { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.collection-card--compact {
    min-height: 128px;
    padding: 12px;
    border-color: var(--line);
    border-radius: 13px;
    background: var(--surface-2);
}
.collection-card--compact:hover { border-color: color-mix(in srgb, var(--collection-color) 30%, var(--line)); background: #fff; }
.dashboard-add-collection {
    min-height: 112px;
    border: 1px dashed var(--line-strong);
    border-radius: 13px;
    background: var(--surface-2);
    color: var(--muted);
    display: grid;
    place-content: center;
    gap: 7px;
    cursor: pointer;
}
.dashboard-add-collection svg { width: 18px; height: 18px; margin: 0 auto; }
.dashboard-activity { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px; }
.dashboard-activity-row {
    padding: 8px;
    border-radius: 11px;
    background: var(--surface-2);
}
.dashboard-empty { color: var(--muted); }

/* Files and folders */
.context-hero {
    min-height: 174px;
    margin-bottom: 12px;
    padding: 24px;
    border: 1px solid #e3e5ff;
    border-radius: 20px;
    background:
        radial-gradient(circle at 95% 0%, rgba(var(--accent-rgb), .11), transparent 28%),
        linear-gradient(145deg, #fff 0%, #fafaff 100%);
    color: var(--ink);
    box-shadow: none;
    grid-template-columns: minmax(0, 1fr) minmax(300px, 420px);
}
.context-hero::before { display: none; }
.hero-copy { position: relative; z-index: 1; }
.hero-label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--accent);
    font-size: 9px;
    font-weight: 750;
    letter-spacing: .04em;
    text-transform: none;
}
.hero-label i { display: none; }
.hero-label svg { width: 13px; height: 13px; }
.hero-copy h2 {
    max-width: 670px;
    margin: 11px 0 8px;
    color: var(--ink);
    font-size: clamp(23px, 2.8vw, 34px);
    line-height: 1.08;
    letter-spacing: -.046em;
}
.hero-copy p { max-width: 680px; margin: 0; color: var(--muted); font-size: 11.5px; line-height: 1.55; }
.hero-actions { margin-top: 17px; gap: 6px; }
.hero-action {
    min-height: 35px;
    padding: 0 11px;
    border-color: var(--line);
    border-radius: 9px;
    background: #fff;
    color: var(--ink-soft);
    font-size: 10px;
}
.hero-action:hover { background: var(--surface-2); border-color: var(--line-strong); }
.hero-action--primary, .hero-action--lime {
    border-color: var(--ink);
    background: var(--ink);
    color: #fff;
}
.hero-action--primary:hover, .hero-action--lime:hover { background: #2a2d35; border-color: #2a2d35; }
.hero-search-example {
    min-width: 0;
    min-height: 88px;
    padding: 14px;
    border: 1px solid rgba(var(--accent-rgb), .14);
    border-radius: 15px;
    background: rgba(255, 255, 255, .82);
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr) 20px;
    gap: 10px;
    align-items: center;
    box-shadow: 0 14px 40px rgba(54, 58, 115, .08);
}
.hero-search-example > span {
    width: 38px;
    height: 38px;
    border-radius: 11px;
    display: grid;
    place-items: center;
    background: var(--accent-soft);
    color: var(--accent);
}
.hero-search-example svg { width: 16px; height: 16px; }
.hero-search-example strong, .hero-search-example small { display: block; }
.hero-search-example strong { font-size: 11px; line-height: 1.35; }
.hero-search-example small { margin-top: 4px; color: var(--muted); font-size: 8.5px; }
.hero-search-example > i { color: var(--muted-2); }
.hero-network { display: none; }
.metric-grid { gap: 8px; margin: 0 0 22px; }
.metric-card {
    min-width: 0;
    min-height: 74px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #fff;
    grid-template-columns: 36px minmax(0, 1fr) 15px;
    gap: 10px;
    color: var(--ink);
    text-align: left;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
}
.metric-card:hover { border-color: rgba(var(--accent-rgb), .25); }
.metric-card > svg { width: 13px; height: 13px; color: var(--muted-2); }
.metric-icon { width: 36px; height: 36px; border-radius: 10px; }
.metric-icon svg { width: 15px; height: 15px; }
.metric-copy strong { font-size: 15px; }
.metric-copy span { font-size: 9px; }
.section-head { margin-bottom: 10px; }
.section-title h2 { font-size: 15px; }
.crumb { font-size: 10.5px; }
.segmented { border-color: var(--line); background: #fff; }
.segmented button.is-active { background: var(--surface-3); }
.items-grid { grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; }
.item-card {
    min-height: 166px;
    padding: 12px;
    border-color: var(--line);
    border-radius: 14px;
    box-shadow: var(--shadow-sm);
}
.item-card:hover {
    transform: translateY(-1px);
    border-color: rgba(var(--accent-rgb), .28);
    box-shadow: 0 10px 26px rgba(20, 24, 33, .06);
}
.item-card.is-selected { box-shadow: 0 0 0 3px rgba(var(--accent-rgb), .08); }
.file-visual { background: #f1f3f6; }
.item-card-name { color: var(--ink); font-size: 11.5px; }
.item-card-meta { color: var(--muted); }
.item-more:hover { background: var(--surface-3); }
.items-list {
    gap: 0;
    padding: 3px;
    border-radius: 14px;
    box-shadow: var(--shadow-sm);
}
.list-header { min-height: 39px; border-bottom: 1px solid var(--line); }
.item-row { min-height: 52px; border-radius: 9px; }
.item-row + .item-row { border-top: 1px solid #f0f2f5; }
.item-row:hover { background: var(--surface-2); }
.empty-state {
    min-height: 320px;
    border-color: var(--line-strong);
    border-radius: 18px;
    background: #fff;
}
.empty-state h3 { font-size: 17px; }
.empty-state p { max-width: 430px; color: var(--muted); }

/* Collections */
.collections-intro {
    min-height: 142px;
    padding: 22px;
    border: 1px solid #e3e5ff;
    border-radius: 18px;
    background: linear-gradient(145deg, #fff, #fafaff);
    color: var(--ink);
}
.collections-intro > div > span {
    background: var(--accent-soft);
    color: var(--accent);
}
.collections-intro h2 { color: var(--ink); font-size: 22px; }
.collections-intro p { color: var(--muted); }
.collections-intro > button {
    border-color: var(--line);
    background: #fff;
    color: var(--ink-soft);
}
.collections-intro > button:hover { border-color: rgba(var(--accent-rgb), .26); color: var(--accent); }
.collections-grid { gap: 10px; }
.collection-card {
    border-color: var(--line);
    border-radius: 15px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}
.collection-card:hover { transform: translateY(-1px); box-shadow: 0 10px 26px rgba(20, 24, 33, .06); }

/* Storage */
.storage-hero {
    min-height: 176px;
    padding: 25px 28px;
    border: 1px solid #e3e5ff;
    border-radius: 20px;
    background:
        radial-gradient(circle at 92% 10%, rgba(var(--accent-rgb), .12), transparent 30%),
        linear-gradient(145deg, #fff, #fafaff);
    color: var(--ink);
}
.storage-hero::after { display: none; }
.storage-hero-copy > span { color: var(--muted); }
.storage-hero-copy > strong { color: var(--ink); }
.storage-hero-copy > strong small { color: var(--muted); }
.storage-hero-copy p { color: var(--muted); font-size: 10px; }
.storage-main-track { background: #e4e7ec; }
.storage-main-track i { background: var(--accent); box-shadow: none; }
.storage-gauge {
    border-color: rgba(var(--accent-rgb), .16);
    background: var(--accent-soft);
    color: var(--accent);
    box-shadow: inset 0 0 0 10px rgba(255, 255, 255, .45);
}
.storage-gauge span { color: var(--muted); }
.storage-stat-grid { gap: 8px; }
.storage-stat-grid > * {
    min-height: 86px;
    border-radius: 14px;
    box-shadow: var(--shadow-sm);
}
.storage-panel {
    padding: 17px;
    border-radius: 16px;
    box-shadow: var(--shadow-sm);
}
.share-pulse > div { background: var(--surface-2); }

/* AI drawer */
.ai-panel {
    position: fixed;
    z-index: 130;
    top: 14px;
    right: 14px;
    bottom: 14px;
    width: min(var(--ai-width), calc(100vw - 28px));
    height: auto;
    display: grid;
    grid-template-rows: 68px minmax(0, 1fr) auto;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 28px 90px rgba(20, 24, 33, .18);
    overflow: hidden;
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
    transition: transform .22s ease, opacity .18s ease;
}
.workspace-shell.ai-closed .ai-panel {
    opacity: 0;
    transform: translateX(calc(100% + 28px));
    pointer-events: none;
}
.ai-head {
    min-height: 68px;
    padding: 0 15px;
    border-bottom-color: var(--line);
    background: #fff;
}
.ai-orb {
    width: 36px;
    height: 36px;
    border-radius: 11px;
    background: var(--accent-soft);
    color: var(--accent);
}
.ai-title-copy strong { color: var(--ink); }
.ai-title-copy span { color: var(--muted); }
.ai-messages { padding: 14px; background: #fbfcfd; }
.ai-welcome {
    padding: 18px;
    border: 1px solid #e3e5ff;
    border-radius: 16px;
    background: linear-gradient(145deg, #fff, #f8f8ff);
    color: var(--ink);
}
.ai-welcome::after { display: none; }
.ai-welcome-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: var(--accent);
    font-size: 8px;
}
.ai-welcome-badge i { display: none; }
.ai-welcome-badge svg { width: 12px; height: 12px; }
.ai-welcome h3 { color: var(--ink); font-size: 21px; }
.ai-welcome p { color: var(--muted); }
.ai-suggestion {
    border-color: var(--line);
    background: #fff;
    color: var(--ink-soft);
}
.ai-suggestion:hover { border-color: rgba(var(--accent-rgb), .22); background: var(--accent-soft); color: var(--accent); }
.chat-message.user .chat-bubble { background: var(--accent); color: #fff; }
.chat-message.assistant .chat-bubble { border-color: var(--line); background: #fff; color: var(--ink-soft); }
.chat-avatar { background: var(--accent-soft); color: var(--accent); }
.chat-source { border-color: var(--line); background: var(--surface-2); color: var(--ink-soft); }
.ai-composer { border-top-color: var(--line); background: #fff; }
.ai-context-pill { color: var(--muted); }
.ai-input-wrap { border-color: var(--line-strong); border-radius: 13px; background: #fff; }
.ai-input-wrap:focus-within { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(var(--accent-rgb), .08); }
.ai-send { background: var(--ink); }
.ai-send:hover { background: #2a2d35; }

/* Menus, dialogs and transient UI */
.context-menu {
    min-width: 205px;
    padding: 6px;
    border-color: var(--line);
    border-radius: 13px;
    background: #fff;
    box-shadow: 0 18px 50px rgba(20, 24, 33, .16);
}
.context-menu button { min-height: 34px; border-radius: 9px; }
.context-menu button:hover { background: var(--surface-2); }
.create-menu { width: 284px; padding: 7px; }
.create-menu-label {
    padding: 7px 9px 6px;
    color: var(--muted-2);
    font-size: 8px;
    font-weight: 750;
    letter-spacing: .09em;
    text-transform: uppercase;
}
.create-menu button {
    min-height: 50px;
    display: grid;
    grid-template-columns: 30px minmax(0, 1fr);
    gap: 10px;
    align-items: center;
}
.create-menu button > svg {
    width: 16px;
    height: 16px;
    justify-self: center;
    color: var(--ink-soft);
}
.create-menu button span { min-width: 0; }
.create-menu button strong, .create-menu button small { display: block; }
.create-menu button strong { color: var(--ink); font-size: 10.5px; }
.create-menu button small { margin-top: 2px; color: var(--muted); font-size: 8px; }
.create-menu hr { border-color: var(--line); }
.modal-backdrop { background: rgba(24, 27, 34, .38); backdrop-filter: blur(4px); }
.modal {
    border-color: var(--line);
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 28px 90px rgba(20, 24, 33, .2);
}
.modal-head { border-bottom-color: var(--line); }
.modal-foot { border-top-color: var(--line); background: #fbfcfd; }
.modal-close { background: var(--surface-2); }
.upload-center {
    right: 16px;
    bottom: 16px;
    border-color: var(--line);
    border-radius: 18px;
    background: rgba(255, 255, 255, .98);
    box-shadow: 0 24px 70px rgba(20, 24, 33, .17);
}
.upload-center-head > div > span { background: var(--accent-soft); color: var(--accent); }
.upload-job-actions button:hover { background: var(--accent-soft); color: var(--accent); }
.toast {
    border-color: var(--line);
    border-radius: 13px;
    background: #fff;
    box-shadow: 0 18px 48px rgba(20, 24, 33, .14);
}

/* Responsive light workspace */
@media (max-width: 1240px) {
    :root { --sidebar-width: 232px; }
    .dashboard-quick-actions { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .dashboard-collections { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .topbar { grid-template-columns: minmax(260px, 620px) auto; }
}

@media (max-width: 1080px) {
    .ai-trigger > span { display: none; }
    .ai-trigger { width: 38px; padding: 0; justify-content: center; }
    .context-hero { grid-template-columns: 1fr; }
    .hero-search-example { max-width: 620px; }
    .dashboard-grid.dashboard-grid--light { grid-template-columns: 1fr; }
    .dashboard-grid--light .dashboard-section,
    .dashboard-grid--light .dashboard-section--wide,
    .dashboard-grid--light .dashboard-storage-card,
    .dashboard-grid--light .dashboard-briefing-card,
    .dashboard-grid--light .dashboard-activity-section { grid-column: 1; grid-row: auto; }
    .dashboard-activity { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
    .auth-shell.auth-shell--light { grid-template-columns: 1fr; height: auto; min-height: 100dvh; }
    .auth-shell--light .auth-story { display: none; }
    .auth-shell--light .auth-panel { min-height: 100dvh; }
    .auth-panel-inner { width: min(100%, 560px); }
    :root { --sidebar-width: 244px; }
    .workspace-shell, .workspace-shell.ai-closed { display: block; }
    .sidebar {
        position: fixed;
        z-index: 160;
        left: 0;
        top: 0;
        width: min(88vw, 284px);
        transform: translateX(-102%);
        transition: transform .2s ease;
        box-shadow: 18px 0 60px rgba(20, 24, 33, .17);
    }
    .workspace-shell.mobile-nav-open .sidebar { transform: translateX(0); }
    .workspace-shell.mobile-nav-open .sidebar-scrim {
        display: block;
        position: fixed;
        inset: 0;
        z-index: 150;
        border: 0;
        background: rgba(22, 25, 32, .34);
        backdrop-filter: blur(2px);
    }
    .sidebar-mobile-close { display: grid; }
    .main-column { height: 100vh; }
    .topbar {
        grid-template-columns: 38px minmax(0, 1fr) auto;
        padding: 0 12px;
        gap: 8px;
    }
    .mobile-menu-btn { display: grid !important; }
    .search-shortcut { display: none; }
    .global-search { padding-right: 12px; }
    .content-scroll { padding: 20px 16px 44px; }
    .storage-layout { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
    body { overflow: hidden; }
    .topbar { height: 64px; }
    .main-column { grid-template-rows: 64px minmax(0, 1fr); }
    .topbar .primary-btn { width: 38px; height: 38px; padding: 0; justify-content: center; }
    .topbar .primary-btn span { display: none; }
    .upload-center-toggle { display: none; }
    .content-scroll { padding: 18px 12px 38px; }
    .page-head { align-items: flex-start; flex-direction: column; gap: 12px; }
    .page-actions { width: 100%; justify-content: flex-start; }
    .page-actions > button { flex: 1; justify-content: center; }
    .dashboard-head { align-items: flex-start; flex-direction: column; gap: 13px; }
    .dashboard-head h1 { font-size: 34px; }
    .dashboard-actions { width: 100%; }
    .dashboard-actions > button { flex: 1; justify-content: center; }
    .dashboard-quick-actions { grid-template-columns: 1fr 1fr; gap: 8px; }
    .dashboard-quick-actions > button { min-height: 82px; grid-template-columns: 34px minmax(0, 1fr); }
    .dashboard-quick-actions > button > svg { display: none; }
    .dashboard-quick-actions > button > span { width: 34px; height: 34px; }
    .dashboard-files { grid-template-columns: 1fr; }
    .dashboard-collections { grid-template-columns: 1fr 1fr; }
    .dashboard-activity { grid-template-columns: 1fr; }
    .context-hero { padding: 20px; border-radius: 17px; }
    .hero-search-example { min-height: 78px; }
    .hero-actions { flex-wrap: wrap; }
    .metric-grid { grid-template-columns: 1fr 1fr; }
    .metric-card { min-height: 68px; }
    .items-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
    .item-card { min-height: 150px; }
    .item-more { opacity: 1; }
    .ai-panel {
        top: 8px;
        right: 8px;
        bottom: 8px;
        width: calc(100vw - 16px);
        border-radius: 18px;
    }
    .storage-hero { grid-template-columns: 1fr; padding: 22px; }
    .storage-gauge { position: absolute; right: 20px; top: 20px; width: 82px; height: 82px; opacity: .76; }
    .storage-hero-copy { padding-right: 75px; }
    .storage-stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 480px) {
    .auth-panel-inner { padding: 22px 20px; }
    .auth-security { display: none; }
    .auth-shell--light .auth-card { padding-top: 48px; }
    .auth-shell--light .auth-card h2 { font-size: 34px; }
    .dashboard-head h1 { font-size: 31px; }
    .dashboard-quick-actions { grid-template-columns: 1fr; }
    .dashboard-quick-actions > button { min-height: 70px; }
    .dashboard-collections { grid-template-columns: 1fr; }
    .items-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .item-card { min-height: 143px; padding: 10px; }
    .file-visual { width: 46px; height: 46px; }
    .metric-grid { grid-template-columns: 1fr; }
    .hero-search-example { grid-template-columns: 34px minmax(0, 1fr); }
    .hero-search-example > i { display: none; }
    .storage-gauge { display: none; }
    .storage-hero-copy { padding-right: 0; }
    .storage-stat-grid { grid-template-columns: 1fr; }
    .create-menu { width: calc(100vw - 24px); }
}

/* Mobile actions keep their meaning; only topbar controls collapse to icons. */
@media (max-width: 720px) {
    .dashboard-actions .ai-trigger {
        width: auto;
        padding: 0 13px;
        gap: 7px;
    }
    .dashboard-actions .ai-trigger > span { display: inline; }
}

/* ========================================================================== */
/* LYNQ Space 0.5 — Everyday File Operations                                  */
/* ========================================================================== */
.files-section {
    position: relative;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}
.files-section > .section-head {
    min-height: 58px;
    margin: 0;
    padding: 10px 14px 10px 16px;
    border-bottom: 1px solid var(--line);
    background: #fff;
}
.files-section .section-title { min-width: 0; }
.files-section .view-tools { min-width: 0; gap: 8px; }
.files-section #items-wrap { min-height: 120px; padding: 5px 8px 9px; }
.files-section .items-list {
    padding: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}
.files-section .items-grid { padding: 6px; }
.files-section .empty-state { margin: 4px; border: 0; box-shadow: none; }

.file-tools { display: flex; align-items: center; gap: 7px; }
.filter-trigger,
.sort-control {
    min-height: 36px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    color: var(--ink-soft);
}
.filter-trigger {
    position: relative;
    padding: 0 10px;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    cursor: pointer;
    font-weight: 650;
    font-size: 11px;
}
.filter-trigger:hover,
.filter-trigger.is-active { border-color: rgba(var(--accent-rgb), .34); background: var(--accent-soft); color: var(--accent); }
.filter-trigger svg { width: 14px; height: 14px; }
.filter-trigger b {
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    background: var(--accent);
    color: #fff;
    font-size: 8px;
}
.sort-control {
    position: relative;
    min-width: 154px;
    padding: 0 29px 0 10px;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: 5px;
}
.sort-control > span { color: var(--muted-2); font-size: 8px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.sort-control select {
    min-width: 0;
    height: 34px;
    padding: 0;
    border: 0;
    outline: 0;
    appearance: none;
    background: transparent;
    color: var(--ink-soft);
    cursor: pointer;
    font-size: 10px;
    font-weight: 650;
}
.sort-control > svg { position: absolute; right: 9px; width: 12px; height: 12px; color: var(--muted); pointer-events: none; }

.active-filters {
    min-height: 45px;
    padding: 8px 16px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    border-bottom: 1px solid var(--line);
    background: #fbfcfe;
}
.active-filters > span { margin-right: 2px; color: var(--muted); font-size: 9px; font-weight: 650; }
.filter-chip,
.filter-reset {
    min-height: 28px;
    border: 0;
    border-radius: 8px;
    cursor: pointer;
    font-size: 9px;
    font-weight: 650;
}
.filter-chip {
    padding: 0 8px 0 9px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--accent-soft);
    color: var(--accent);
}
.filter-chip:hover { box-shadow: inset 0 0 0 1px rgba(var(--accent-rgb), .18); }
.filter-chip svg { width: 10px; height: 10px; }
.filter-reset { padding: 0 8px; background: transparent; color: var(--muted); }
.filter-reset:hover { background: var(--surface-3); color: var(--ink); }

.selection-bar {
    position: sticky;
    top: 8px;
    z-index: 12;
    min-height: 54px;
    margin: 8px 8px 3px;
    padding: 7px 8px 7px 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    border: 1px solid rgba(var(--accent-rgb), .22);
    border-radius: 13px;
    background: rgba(255, 255, 255, .97);
    box-shadow: 0 13px 34px rgba(37, 64, 130, .12);
    backdrop-filter: blur(16px);
}
.selection-summary,
.selection-actions { display: flex; align-items: center; gap: 6px; }
.selection-summary { flex: 0 0 auto; }
.selection-summary > button {
    width: 31px;
    height: 31px;
    display: grid;
    place-items: center;
    border: 0;
    border-radius: 8px;
    background: var(--surface-2);
    color: var(--muted);
    cursor: pointer;
}
.selection-summary > button:hover { background: var(--surface-3); color: var(--ink); }
.selection-summary svg { width: 13px; height: 13px; }
.selection-summary strong {
    min-width: 25px;
    height: 25px;
    padding: 0 6px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    background: var(--accent);
    color: #fff;
    font-size: 10px;
}
.selection-summary span { color: var(--ink-soft); font-size: 10px; font-weight: 650; white-space: nowrap; }
.selection-actions { min-width: 0; justify-content: flex-end; overflow-x: auto; scrollbar-width: none; }
.selection-actions::-webkit-scrollbar { display: none; }
.selection-actions button {
    min-height: 34px;
    padding: 0 10px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex: 0 0 auto;
    border: 1px solid var(--line);
    border-radius: 9px;
    background: #fff;
    color: var(--ink-soft);
    cursor: pointer;
    font-size: 9.5px;
    font-weight: 650;
}
.selection-actions button:hover { border-color: rgba(var(--accent-rgb), .28); background: var(--accent-soft); color: var(--accent); }
.selection-actions button.danger:hover { border-color: #ffd1d6; background: var(--danger-soft); color: var(--danger); }
.selection-actions svg { width: 13px; height: 13px; }

.list-header,
.item-row {
    grid-template-columns: 28px minmax(220px, 1.7fr) minmax(115px, .72fr) 96px 122px 34px;
    gap: 10px;
}
.list-header { padding-left: 10px; padding-right: 8px; }
.item-row { padding-left: 10px; }
.item-row.is-bulk-selected,
.item-card.is-bulk-selected {
    border-color: rgba(var(--accent-rgb), .25);
    background: #f5f8ff;
    box-shadow: inset 3px 0 0 var(--accent);
}
.item-card.is-bulk-selected { box-shadow: inset 0 0 0 2px rgba(var(--accent-rgb), .46), var(--shadow-sm); }
.item-select,
.select-all {
    width: 20px;
    height: 20px;
    padding: 0;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    border: 1px solid var(--line-strong);
    border-radius: 6px;
    background: #fff;
    color: transparent;
    cursor: pointer;
    transition: border-color .15s ease, background .15s ease, color .15s ease, transform .15s ease;
}
.item-select:hover,
.select-all:hover { border-color: var(--accent); }
.item-select.is-selected,
.select-all.is-selected,
.select-all.is-partial { border-color: var(--accent); background: var(--accent); color: #fff; }
.select-all.is-partial svg { opacity: 0; }
.select-all.is-partial::after { content: ""; width: 8px; height: 2px; border-radius: 2px; background: #fff; }
.item-select svg,
.select-all svg { width: 12px; height: 12px; stroke-width: 2.5; }
.item-card > .item-select {
    position: absolute;
    z-index: 3;
    left: 10px;
    top: 10px;
    opacity: 0;
    transform: scale(.86);
}
.item-card:hover > .item-select,
.item-card:focus-within > .item-select,
.item-card.is-bulk-selected > .item-select { opacity: 1; transform: none; }
.grid-select-head {
    min-height: 34px;
    padding: 5px 8px 0;
    display: flex;
    align-items: center;
}
.grid-select-head .select-all { width: auto; min-width: 20px; padding: 0 7px; display: inline-flex; gap: 6px; color: var(--muted); font-size: 9px; font-weight: 650; }
.grid-select-head .select-all.is-selected,
.grid-select-head .select-all.is-partial { color: #fff; }
.grid-select-head .select-all span { white-space: nowrap; }

.filter-form-grid { display: grid; gap: 17px; }
.filter-group { display: grid; gap: 8px; }
.filter-group > span { color: var(--ink-soft); font-size: 10px; font-weight: 750; }
.filter-options { display: flex; flex-wrap: wrap; gap: 7px; }
.filter-option {
    position: relative;
    min-height: 35px;
    padding: 0 11px;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    cursor: pointer;
    color: var(--ink-soft);
    font-size: 9.5px;
    font-weight: 650;
}
.filter-option:hover { border-color: rgba(var(--accent-rgb), .32); }
.filter-option input { position: absolute; opacity: 0; pointer-events: none; }
.filter-option:has(input:checked) { border-color: rgba(var(--accent-rgb), .38); background: var(--accent-soft); color: var(--accent); box-shadow: inset 0 0 0 1px rgba(var(--accent-rgb), .08); }

.move-browser { display: grid; gap: 10px; }
.move-search {
    min-height: 42px;
    padding: 0 12px;
    display: grid;
    grid-template-columns: 17px minmax(0, 1fr);
    gap: 8px;
    align-items: center;
    border: 1px solid var(--line);
    border-radius: 11px;
    background: #fff;
}
.move-search:focus-within { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(var(--accent-rgb), .08); }
.move-search svg { width: 15px; height: 15px; color: var(--muted); }
.move-search input { min-width: 0; border: 0; outline: 0; background: transparent; color: var(--ink); }
.move-destinations {
    max-height: min(440px, 54vh);
    padding: 5px;
    overflow: auto;
    display: grid;
    gap: 3px;
    border: 1px solid var(--line);
    border-radius: 13px;
    background: var(--surface-2);
}
.move-destination {
    min-height: 52px;
    padding: 7px 9px;
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr) 18px;
    gap: 9px;
    align-items: center;
    border: 1px solid transparent;
    border-radius: 10px;
    background: transparent;
    color: var(--ink-soft);
    text-align: left;
    cursor: pointer;
}
.move-destination:hover { background: #fff; border-color: var(--line); }
.move-destination.is-selected { border-color: rgba(var(--accent-rgb), .26); background: #fff; color: var(--accent); box-shadow: var(--shadow-sm); }
.move-destination.is-disabled { opacity: .42; cursor: not-allowed; }
.move-destination > svg { width: 14px; height: 14px; opacity: 0; }
.move-destination.is-selected > svg { opacity: 1; }
.move-destination strong,
.move-destination small { display: block; min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.move-destination strong { font-size: 10.5px; color: var(--ink); }
.move-destination small { margin-top: 2px; color: var(--muted); font-size: 8px; }
.move-folder-icon {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: color-mix(in srgb, var(--folder-color, var(--accent)) 10%, white);
    color: var(--folder-color, var(--accent));
}
.move-folder-icon svg { width: 16px; height: 16px; }
.move-browser-loading { min-height: 260px; }

.hotkeys-list { display: grid; gap: 5px; }
.hotkeys-list > div {
    min-height: 58px;
    padding: 9px 10px;
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
    gap: 14px;
    align-items: center;
    border-bottom: 1px solid var(--line);
}
.hotkeys-list > div:last-child { border-bottom: 0; }
.hotkeys-list > div > span { display: flex; align-items: center; gap: 5px; }
.hotkeys-list kbd {
    min-width: 30px;
    height: 29px;
    padding: 0 7px;
    display: inline-grid;
    place-items: center;
    border: 1px solid var(--line-strong);
    border-bottom-width: 2px;
    border-radius: 7px;
    background: var(--surface-2);
    color: var(--ink-soft);
    font-family: inherit;
    font-size: 9px;
    font-weight: 750;
}
.hotkeys-list p { margin: 0; }
.hotkeys-list strong,
.hotkeys-list small { display: block; }
.hotkeys-list strong { font-size: 10.5px; }
.hotkeys-list small { margin-top: 2px; color: var(--muted); font-size: 8.5px; }

/* Full-window preview stays lightweight while keeping metadata within reach. */
.modal.modal-preview.modal-document {
    position: relative;
    width: min(1460px, calc(100vw - 28px));
    height: calc(100dvh - 28px);
    max-height: none;
    border-radius: 18px;
}
.modal-preview.modal-document .modal-head { min-height: 62px; padding: 12px 15px 10px 18px; }
.modal-preview.modal-document .modal-title { min-width: 0; }
.modal-preview.modal-document .modal-title h2 { max-width: min(780px, 60vw); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 15px; }
.modal-preview.modal-document .modal-title p { font-size: 8.5px; }
.modal-preview.modal-document .modal-body { padding: 0; overflow: hidden; }
.modal-preview.modal-document .modal-foot { min-height: 58px; padding: 9px 14px; }
.modal-preview.modal-document .document-detail-grid { height: 100%; grid-template-columns: minmax(0, 1.42fr) minmax(350px, .58fr); }
.modal-preview.modal-document .document-preview-panel { position: relative; background: #f2f4f7; }
.document-preview-toolbar { min-height: 48px; background: rgba(255,255,255,.9); backdrop-filter: blur(12px); }
.preview-image-stage,
.preview-media-stage,
.preview-audio-stage {
    position: relative;
    width: 100%;
    height: calc(100% - 48px);
    min-height: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: auto;
    padding: 24px;
}
.preview-image-stage { cursor: zoom-in; }
.file-preview-image {
    display: block;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transform-origin: center;
    transition: transform .16s ease;
    border-radius: 4px;
    box-shadow: 0 12px 48px rgba(24, 31, 45, .12);
}
.preview-media-stage video { width: min(100%, 1080px); max-height: 100%; border-radius: 12px; background: #111; box-shadow: 0 20px 60px rgba(14,18,28,.18); }
.preview-audio-stage { flex-direction: column; gap: 15px; text-align: center; }
.preview-audio-stage .file-visual { width: 76px; height: 76px; }
.preview-audio-stage h3 { max-width: 520px; margin: 0; font-size: 14px; }
.preview-audio-stage audio { width: min(520px, 100%); }
.preview-zoom {
    position: absolute;
    z-index: 5;
    left: 50%;
    bottom: 14px;
    transform: translateX(-50%);
    padding: 4px;
    display: flex;
    align-items: center;
    gap: 2px;
    border: 1px solid rgba(25,31,43,.12);
    border-radius: 10px;
    background: rgba(255,255,255,.94);
    box-shadow: 0 10px 30px rgba(20, 24, 33, .13);
    backdrop-filter: blur(12px);
}
.preview-zoom button {
    min-width: 30px;
    height: 30px;
    padding: 0 7px;
    display: grid;
    place-items: center;
    border: 0;
    border-radius: 7px;
    background: transparent;
    color: var(--ink-soft);
    cursor: pointer;
    font-size: 9px;
    font-weight: 700;
}
.preview-zoom button:hover { background: var(--surface-3); }
.preview-zoom svg { width: 14px; height: 14px; }
.preview-navigation {
    position: absolute;
    z-index: 10;
    top: 50%;
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(25,31,43,.12);
    border-radius: 12px;
    background: rgba(255,255,255,.95);
    color: var(--ink-soft);
    box-shadow: 0 12px 34px rgba(20,24,33,.14);
    cursor: pointer;
    backdrop-filter: blur(10px);
}
.preview-navigation:hover:not(:disabled) { color: var(--accent); transform: translateY(-1px); }
.preview-navigation:disabled { opacity: .32; cursor: default; }
.preview-navigation svg { width: 17px; height: 17px; }
.preview-navigation--prev { left: 12px; }
.preview-navigation--next { left: calc(71% - 54px); }
.preview-counter {
    position: absolute;
    z-index: 10;
    top: 75px;
    left: 35.5%;
    transform: translateX(-50%);
    min-width: 50px;
    height: 26px;
    padding: 0 8px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(25,31,43,.1);
    border-radius: 999px;
    background: rgba(255,255,255,.92);
    color: var(--muted);
    font-size: 8.5px;
    font-weight: 700;
    box-shadow: 0 7px 22px rgba(20,24,33,.09);
}

@media (max-width: 1180px) {
    .list-header,
    .item-row { grid-template-columns: 28px minmax(220px, 1.5fr) 94px 118px 34px; }
    .list-header > :nth-child(3),
    .item-row > :nth-child(3) { display: none; }
    .sort-control { min-width: 145px; }
    .preview-navigation--next { left: calc(67% - 52px); }
    .preview-counter { left: 33.5%; }
}

@media (max-width: 900px) {
    .files-section > .section-head { align-items: flex-start; gap: 9px; }
    .files-section .view-tools { width: 100%; justify-content: space-between; }
    .file-tools { min-width: 0; flex: 1; }
    .sort-control { min-width: 0; flex: 1; }
    .selection-bar { align-items: flex-start; flex-direction: column; }
    .selection-actions { width: 100%; justify-content: flex-start; }
    .modal.modal-preview.modal-document { width: calc(100vw - 12px); height: calc(100dvh - 12px); border-radius: 14px; }
    .modal-preview.modal-document .modal-body { overflow: auto; }
    .modal-preview.modal-document .document-detail-grid { display: block; height: auto; overflow: visible; }
    .modal-preview.modal-document .document-preview-panel { min-height: min(62vh, 620px); }
    .modal-preview.modal-document .document-intelligence-panel { overflow: visible; }
    .preview-image-stage,
    .preview-media-stage,
    .preview-audio-stage { height: calc(min(62vh, 620px) - 48px); }
    .preview-navigation--next { left: auto; right: 12px; }
    .preview-counter { left: 50%; }
}

@media (max-width: 720px) {
    .files-section { border-radius: 15px; overflow: visible; }
    .files-section > .section-head { padding: 11px 10px; border-radius: 15px 15px 0 0; }
    .files-section .view-tools { align-items: stretch; flex-wrap: wrap; }
    .file-tools { width: 100%; }
    .filter-trigger { flex: 0 0 auto; }
    .sort-control { flex: 1; }
    .files-section .segmented { margin-left: auto; }
    .active-filters { padding: 8px 10px; }
    .selection-bar { top: 4px; margin: 6px; padding: 7px; }
    .selection-summary span { font-size: 9px; }
    .selection-actions button { min-height: 36px; }
    .files-section #items-wrap { padding: 3px 4px 7px; }
    .list-header { display: none; }
    .item-row {
        grid-template-columns: 28px minmax(0, 1fr) 34px;
        gap: 8px;
        padding: 7px 5px 7px 7px;
    }
    .item-row .row-cell { display: none !important; }
    .item-row .row-actions { grid-column: 3; }
    .item-row .item-select { grid-column: 1; }
    .item-row .row-name { grid-column: 2; }
    .item-card > .item-select { opacity: 1; transform: none; }
    .grid-select-head { padding-left: 5px; }
    .filter-form-grid { gap: 14px; }
    .filter-options { display: grid; grid-template-columns: 1fr 1fr; }
    .filter-option { width: 100%; justify-content: center; }
    .move-destinations { max-height: 48vh; }
    .hotkeys-list > div { grid-template-columns: 92px minmax(0, 1fr); }
    .modal-preview.modal-document .modal-title h2 { max-width: calc(100vw - 110px); font-size: 13px; }
    .modal-preview.modal-document .modal-foot { overflow-x: auto; justify-content: flex-start; flex-wrap: nowrap; }
    .modal-preview.modal-document .modal-foot-group { flex: 0 0 auto; width: auto; }
    .modal-preview.modal-document .modal-foot-group > * { flex: 0 0 auto; }
    .preview-navigation { width: 36px; height: 36px; border-radius: 10px; }
    .preview-navigation--prev { left: 7px; }
    .preview-navigation--next { right: 7px; }
}

@media (max-width: 480px) {
    .filter-trigger span { display: none; }
    .filter-trigger { width: 36px; padding: 0; justify-content: center; }
    .sort-control > span { display: none; }
    .sort-control { grid-template-columns: minmax(0, 1fr); padding-left: 9px; }
    .selection-summary span { display: none; }
    .filter-options { grid-template-columns: 1fr; }
    .hotkeys-list > div { grid-template-columns: 82px minmax(0, 1fr); gap: 9px; padding-left: 4px; padding-right: 4px; }
    .hotkeys-list kbd { min-width: 27px; padding: 0 5px; }
    .preview-image-stage,
    .preview-media-stage,
    .preview-audio-stage { padding: 12px; }
    .preview-counter { top: 70px; }
}

/* v0.5.0 — file pipeline, thumbnails and quarantine states */
.file-visual.image-thumb,
.row-icon.row-thumb {
    overflow: hidden;
    border: 1px solid var(--line);
    background: var(--surface-2);
}
.row-icon.row-thumb { padding: 0; }
.row-icon.row-thumb img,
.file-visual.image-thumb img { width: 100%; height: 100%; display: block; object-fit: cover; }
.file-processing-dot {
    position: absolute;
    right: 5px;
    bottom: 5px;
    width: 8px;
    height: 8px;
    border: 2px solid var(--surface);
    border-radius: 50%;
    background: var(--warning);
    box-shadow: 0 2px 8px rgba(25, 31, 43, .16);
}
.item-card.is-quarantined,
.item-row.is-quarantined { border-color: rgba(219, 58, 74, .34); background: var(--danger-soft); }
.item-card.is-quarantined:hover,
.item-row.is-quarantined:hover { border-color: rgba(219, 58, 74, .52); }
.item-signal.signal-danger { color: var(--danger); background: var(--danger-soft); }
.item-signal.signal-warning { color: #8a5c00; background: #fff7df; }

.pipeline-panel { grid-column: 1 / -1; padding: 0; overflow: hidden; }
.pipeline-panel-head { padding: 18px 20px; border-bottom: 1px solid var(--line); }
.worker-status {
    min-height: 30px;
    padding: 0 10px;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface-2);
    color: var(--muted);
    font-size: 10px;
    font-weight: 720;
}
.worker-status i { width: 7px; height: 7px; border-radius: 50%; background: var(--muted-2); }
.worker-status.is-online { color: var(--success); border-color: rgba(20,137,102,.22); background: rgba(20,137,102,.07); }
.worker-status.is-online i { background: var(--success); box-shadow: 0 0 0 4px rgba(20,137,102,.09); }
.worker-status.is-offline { color: #8a5c00; border-color: rgba(213,138,0,.22); background: #fff9e9; }
.worker-status.is-offline i { background: var(--warning); }
.pipeline-metric-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    border-bottom: 1px solid var(--line);
}
.pipeline-metric-grid > div {
    position: relative;
    min-width: 0;
    padding: 18px 18px 17px 54px;
    border-right: 1px solid var(--line);
}
.pipeline-metric-grid > div:last-child { border-right: 0; }
.pipeline-metric-icon {
    position: absolute;
    left: 17px;
    top: 18px;
    width: 27px;
    height: 27px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    background: var(--accent-soft);
    color: var(--accent);
}
.pipeline-metric-icon svg { width: 14px; height: 14px; }
.pipeline-metric-grid strong,
.pipeline-metric-grid small,
.pipeline-metric-grid em { display: block; min-width: 0; }
.pipeline-metric-grid strong { font-size: 20px; line-height: 1; letter-spacing: -.03em; }
.pipeline-metric-grid small { margin-top: 4px; color: var(--ink-soft); font-size: 9.5px; font-weight: 650; }
.pipeline-metric-grid em { margin-top: 3px; color: var(--muted); font-size: 8.5px; font-style: normal; }
.pipeline-detail-grid { display: grid; grid-template-columns: 1.08fr .92fr; gap: 14px; padding: 14px; }
.pipeline-progress-card,
.pipeline-infra-card { min-width: 0; padding: 16px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface-2); }
.pipeline-card-title { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; gap: 10px; align-items: center; margin-bottom: 15px; }
.pipeline-card-title > span {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: var(--surface);
    border: 1px solid var(--line);
    color: var(--accent);
}
.pipeline-card-title > span svg { width: 16px; height: 16px; }
.pipeline-card-title strong,
.pipeline-card-title small { display: block; }
.pipeline-card-title strong { font-size: 11px; }
.pipeline-card-title small { margin-top: 2px; color: var(--muted); font-size: 8.5px; line-height: 1.35; }
.health-badge,
.capability-list b {
    min-height: 24px;
    padding: 0 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: var(--surface-3);
    color: var(--muted);
    font-size: 8px;
    font-weight: 760;
    white-space: nowrap;
}
.health-badge.is-ok { color: var(--success); background: rgba(20,137,102,.09); }
.health-badge.is-error { color: var(--danger); background: var(--danger-soft); }
.pipeline-progress-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 5px 12px; align-items: center; margin-top: 12px; }
.pipeline-progress-row > span { font-size: 9px; font-weight: 650; }
.pipeline-progress-row > b { color: var(--muted); font-size: 8.5px; font-weight: 650; }
.pipeline-progress-row > i { grid-column: 1 / -1; height: 5px; overflow: hidden; border-radius: 999px; background: #e7e9ee; }
.pipeline-progress-row > i > em { display: block; height: 100%; min-width: 2px; border-radius: inherit; background: var(--accent); }
.pipeline-ok,
.pipeline-warning {
    margin-top: 15px;
    min-height: 34px;
    padding: 8px 10px;
    display: flex;
    align-items: center;
    gap: 8px;
    border-radius: 9px;
    font-size: 8.5px;
    font-weight: 650;
}
.pipeline-ok { color: var(--success); background: rgba(20,137,102,.07); }
.pipeline-warning { color: #8a5c00; background: #fff7df; }
.pipeline-ok svg,
.pipeline-warning svg { width: 14px; height: 14px; flex: 0 0 14px; }
.capability-list { display: grid; gap: 1px; }
.capability-list > div { min-height: 42px; display: grid; grid-template-columns: 9px minmax(0, 1fr) auto; gap: 9px; align-items: center; border-top: 1px solid var(--line); }
.capability-list > div:first-child { border-top: 0; }
.capability-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--muted-2); }
.capability-dot.is-ready { background: var(--success); box-shadow: 0 0 0 3px rgba(20,137,102,.08); }
.capability-list p { min-width: 0; margin: 0; }
.capability-list strong,
.capability-list small { display: block; }
.capability-list strong { font-size: 9px; }
.capability-list small { color: var(--muted); font-size: 8px; }
.capability-list b { min-height: 21px; padding: 0 7px; }
.failed-job-list { margin: 0 14px 14px; border: 1px solid rgba(219,58,74,.18); border-radius: 12px; overflow: hidden; background: var(--danger-soft); }
.failed-job-head { min-height: 34px; padding: 0 12px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid rgba(219,58,74,.12); color: var(--danger); font-size: 8.5px; font-weight: 740; }
.failed-job-list > div:not(.failed-job-head) { min-height: 52px; padding: 8px 10px; display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; gap: 9px; align-items: center; border-top: 1px solid rgba(219,58,74,.1); }
.failed-job-list > div:nth-child(2) { border-top: 0; }
.failed-job-list > div > span { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 8px; background: #fff; color: var(--danger); }
.failed-job-list > div > span svg { width: 14px; height: 14px; }
.failed-job-list p { min-width: 0; margin: 0; }
.failed-job-list strong,
.failed-job-list small { display: block; }
.failed-job-list strong { font-size: 9px; }
.failed-job-list small { margin-top: 2px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; color: var(--muted); font-size: 8px; }
.failed-job-list button { min-height: 28px; padding: 0 9px; border: 1px solid rgba(219,58,74,.22); border-radius: 8px; background: #fff; color: var(--danger); cursor: pointer; font-size: 8px; font-weight: 720; }
.pipeline-setup { margin: 0 14px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-2); }
.pipeline-setup summary { min-height: 40px; padding: 0 12px; display: flex; align-items: center; gap: 8px; cursor: pointer; color: var(--ink-soft); font-size: 9px; font-weight: 700; list-style: none; }
.pipeline-setup summary::-webkit-details-marker { display: none; }
.pipeline-setup summary svg { width: 14px; height: 14px; color: var(--muted); }
.pipeline-setup > div { padding: 0 12px 12px; }
.pipeline-setup p { margin: 0 0 8px; color: var(--muted); font-size: 8.5px; }
.pipeline-setup code { display: block; padding: 10px; overflow-x: auto; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--ink-soft); font-size: 8px; white-space: nowrap; }
.pipeline-setup button { margin-top: 8px; min-height: 30px; padding: 0 10px; display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); border-radius: 8px; background: #fff; cursor: pointer; color: var(--ink-soft); font-size: 8px; font-weight: 700; }
.pipeline-setup button svg { width: 13px; height: 13px; }

.file-pipeline-card { padding: 0; overflow: hidden; }
.file-pipeline-card.is-quarantined { border-color: rgba(219,58,74,.28); background: var(--danger-soft); }
.file-pipeline-card .detail-section-head { padding: 12px 13px; margin: 0; border-bottom: 1px solid var(--line); }
.detail-reprocess { width: 29px; height: 29px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--muted); cursor: pointer; }
.detail-reprocess:hover { color: var(--accent); border-color: rgba(var(--accent-rgb),.3); }
.detail-reprocess:disabled { opacity: .45; cursor: wait; }
.detail-reprocess svg { width: 14px; height: 14px; }
.file-pipeline-rows { display: grid; }
.file-pipeline-rows > div { min-height: 49px; padding: 8px 11px; display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; gap: 8px; align-items: center; border-top: 1px solid var(--line); }
.file-pipeline-rows > div:first-child { border-top: 0; }
.pipeline-row-icon { width: 30px; height: 30px; display: grid; place-items: center; border-radius: 9px; background: var(--surface-2); color: var(--accent); }
.pipeline-row-icon svg { width: 14px; height: 14px; }
.file-pipeline-rows p { min-width: 0; margin: 0; }
.file-pipeline-rows strong,
.file-pipeline-rows small { display: block; }
.file-pipeline-rows strong { font-size: 9px; }
.file-pipeline-rows small { margin-top: 2px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; color: var(--muted); font-size: 7.7px; }
.pipeline-state { min-height: 23px; padding: 0 7px; display: inline-flex; align-items: center; border-radius: 999px; background: var(--surface-3); color: var(--muted); font-size: 7.5px; font-weight: 740; white-space: nowrap; }
.pipeline-state.is-ready { color: var(--success); background: rgba(20,137,102,.08); }
.pipeline-state.is-pending { color: #765800; background: #fff7df; }
.pipeline-state.is-warning { color: #8a5c00; background: #fff2d2; }
.pipeline-state.is-danger { color: var(--danger); background: #fff; }
.file-quarantine-notice { margin: 0 11px 11px; padding: 8px 9px; display: flex; align-items: center; gap: 7px; border-radius: 8px; background: #fff; color: var(--danger); font-size: 8px; font-weight: 650; }
.file-quarantine-notice svg { width: 13px; height: 13px; flex: 0 0 13px; }

@media (max-width: 1040px) {
    .pipeline-metric-grid { grid-template-columns: 1fr 1fr; }
    .pipeline-metric-grid > div:nth-child(2) { border-right: 0; }
    .pipeline-metric-grid > div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
    .pipeline-detail-grid { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
    .pipeline-panel-head { align-items: flex-start; gap: 10px; }
    .pipeline-metric-grid { grid-template-columns: 1fr; }
    .pipeline-metric-grid > div { border-right: 0; border-bottom: 1px solid var(--line); }
    .pipeline-metric-grid > div:last-child { border-bottom: 0; }
    .pipeline-detail-grid { padding: 8px; gap: 8px; }
    .pipeline-progress-card,
    .pipeline-infra-card { padding: 12px; }
    .failed-job-list,
    .pipeline-setup { margin-left: 8px; margin-right: 8px; }
    .failed-job-list > div:not(.failed-job-head) { grid-template-columns: 26px minmax(0, 1fr); }
    .failed-job-list button { grid-column: 2; justify-self: start; }
    .file-pipeline-rows > div { grid-template-columns: 28px minmax(0, 1fr); }
    .file-pipeline-rows .pipeline-state { grid-column: 2; justify-self: start; }
}

.storage-check-btn {
    width: 100%;
    min-height: 36px;
    margin-top: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    color: var(--ink-soft);
    cursor: pointer;
    font-size: 10px;
    font-weight: 700;
    transition: border-color .15s ease, color .15s ease, background .15s ease;
}
.storage-check-btn:hover { border-color: rgba(var(--accent-rgb), .30); background: var(--accent-soft); color: var(--accent); }
.storage-check-btn:disabled { opacity: .58; cursor: wait; }
.storage-check-btn svg { width: 14px; height: 14px; }
.storage-check-btn.is-loading svg { animation: pipelineSpin .85s linear infinite; }
@keyframes pipelineSpin { to { transform: rotate(360deg); } }

/* v0.5.0 — safe preview states */
.file-quarantine-preview { background: linear-gradient(180deg, #fff, var(--danger-soft)); }
.file-quarantine-preview .file-danger { color: var(--danger); background: #fff; border: 1px solid rgba(219,58,74,.22); }
.preview-open-disabled { width: 32px; height: 32px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 8px; background: var(--surface-3); color: var(--muted); cursor: not-allowed; }
.preview-open-disabled svg { width: 15px; height: 15px; }
.primary-btn.is-danger-disabled { background: var(--danger-soft); color: var(--danger); border-color: rgba(219,58,74,.18); opacity: 1; cursor: not-allowed; }

.context-menu-empty {
  max-width: 220px;
  padding: 12px 14px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

/* v0.5.0 — role-aware member management */
.members-readonly-note {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 0 0 16px;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface-2);
    color: var(--muted);
    font-size: 12px;
    line-height: 1.45;
}
.members-readonly-note svg { width: 16px; height: 16px; flex: 0 0 auto; color: var(--accent); }
.member-role-label {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 10px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface-2);
    color: var(--ink-soft);
    font-size: 11px;
    font-weight: 650;
    white-space: nowrap;
}

/* v0.5.0 — read-only detail states */
.detail-collection-chips > span {
    min-height: 30px;
    padding: 0 10px;
    border: 1px solid var(--line);
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--muted);
    background: var(--surface-2);
    font-size: 11px;
}
.detail-collection-chips > span > i { width: 7px; height: 7px; border-radius: 50%; background: var(--collection-color, var(--accent)); }
.detail-collection-chips > span.is-selected { color: var(--ink-soft); border-color: color-mix(in srgb, var(--collection-color, var(--accent)) 34%, var(--line)); }
.detail-collection-chips > span svg { width: 12px; height: 12px; color: var(--collection-color, var(--accent)); }
.version-readonly { color: var(--muted); font-size: 10px; font-weight: 650; }

/* ========================================================================== */
/* v0.7.0 — Universal Reader & Developer Mode                                */
/* ========================================================================== */

/* Universal Reader --------------------------------------------------------- */
.modal-preview.modal-document .document-preview-panel {
    grid-template-rows: auto minmax(0, 1fr);
    background: #f5f6f8;
}

.universal-reader-toolbar {
    position: relative;
    z-index: 8;
    min-width: 0;
    min-height: 58px;
    padding: 8px 10px;
    display: grid;
    grid-template-columns: minmax(150px, .8fr) minmax(260px, 1.2fr) auto;
    align-items: center;
    gap: 9px;
    border-bottom: 1px solid var(--line);
    background: rgba(255,255,255,.96);
    backdrop-filter: blur(14px);
}
.universal-reader-identity {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 9px;
}
.universal-reader-identity > span {
    width: 34px;
    height: 34px;
    flex: 0 0 34px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(var(--accent-rgb), .13);
    border-radius: 10px;
    color: var(--accent);
    background: var(--accent-soft);
}
.universal-reader-identity > span svg { width: 16px; height: 16px; }
.universal-reader-identity > div { min-width: 0; }
.universal-reader-identity small,
.universal-reader-identity strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.universal-reader-identity small { color: var(--muted); font-size: 8px; font-weight: 750; letter-spacing: .08em; text-transform: uppercase; }
.universal-reader-identity strong { margin-top: 2px; color: var(--ink-soft); font-size: 10px; }
.reader-status {
    flex: 0 0 auto;
    min-height: 23px;
    padding: 0 8px;
    display: inline-flex;
    align-items: center;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface-2);
    color: var(--muted);
    font-size: 8px;
    font-weight: 760;
}
.reader-status-ready { border-color: rgba(20,137,102,.18); background: #eef9f5; color: var(--success); }
.reader-status-error { border-color: rgba(213,138,0,.2); background: #fff8e9; color: #9b6500; }
.reader-status-pending,
.reader-status-processing { border-color: rgba(var(--accent-rgb),.16); background: var(--accent-soft); color: var(--accent); }
.universal-reader-tabs {
    min-width: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    padding: 3px;
    border: 1px solid var(--line);
    border-radius: 11px;
    background: var(--surface-2);
    overflow-x: auto;
    scrollbar-width: none;
}
.universal-reader-tabs::-webkit-scrollbar { display: none; }
.universal-reader-tabs button {
    min-width: 0;
    height: 31px;
    padding: 0 9px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    flex: 0 0 auto;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: var(--muted);
    cursor: pointer;
    font-size: 9px;
    font-weight: 690;
    white-space: nowrap;
}
.universal-reader-tabs button:hover { color: var(--ink-soft); background: rgba(255,255,255,.72); }
.universal-reader-tabs button.is-active { color: var(--ink); background: #fff; box-shadow: 0 1px 4px rgba(16,18,23,.08); }
.universal-reader-tabs svg { width: 13px; height: 13px; }
.universal-reader-tools { display: flex; align-items: center; justify-content: flex-end; gap: 4px; }
.universal-reader-tools button,
.universal-reader-tools a {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 9px;
    background: #fff;
    color: var(--muted);
    cursor: pointer;
}
.universal-reader-tools button:hover,
.universal-reader-tools a:hover { border-color: var(--line-strong); color: var(--accent); background: var(--accent-soft); }
.universal-reader-tools svg { width: 14px; height: 14px; }

.universal-reader-stage {
    min-width: 0;
    min-height: 0;
    height: 100%;
    overflow: auto;
    background:
        radial-gradient(circle at 50% -15%, rgba(var(--accent-rgb), .055), transparent 34%),
        #f5f6f8;
}
.universal-reader-pdf { width: 100%; height: 100%; min-height: 420px; border: 0; background: #fff; }
.reader-loading {
    min-height: 100%;
    display: grid;
    place-content: center;
    justify-items: center;
    gap: 8px;
    padding: 32px;
    text-align: center;
    color: var(--muted);
}
.reader-loading > span {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(var(--accent-rgb), .15);
    border-radius: 13px;
    color: var(--accent);
    background: var(--accent-soft);
}
.reader-loading > span svg { width: 18px; height: 18px; animation: reader-spin 1.05s linear infinite; }
.reader-loading strong { color: var(--ink-soft); font-size: 11px; }
.reader-loading small { font-size: 9px; }
@keyframes reader-spin { to { transform: rotate(360deg); } }

.reader-code-view,
.reader-archive-view,
.reader-hex-view,
.reader-metadata-view {
    width: min(100%, 1120px);
    min-height: calc(100% - 32px);
    margin: 16px auto;
    border: 1px solid var(--line);
    border-radius: 15px;
    background: #fff;
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}
.reader-code-view { display: grid; grid-template-rows: auto minmax(0,1fr) auto; }
.reader-code-view > header,
.reader-code-view > footer {
    min-height: 42px;
    padding: 0 13px;
    display: flex;
    align-items: center;
    gap: 8px;
    border-bottom: 1px solid var(--line);
    background: #fbfcfd;
    color: var(--muted);
    font-size: 8.5px;
}
.reader-code-view > header span:first-child { margin-right: auto; color: var(--ink-soft); font-weight: 700; }
.reader-code-view > header svg { width: 13px; height: 13px; color: var(--accent); }
.reader-code-view > footer { min-height: 38px; border-top: 1px solid var(--line); border-bottom: 0; }
.reader-code-view > footer svg { width: 13px; height: 13px; color: var(--warning); }
.reader-code-scroll {
    min-height: 300px;
    max-height: calc(100dvh - 245px);
    display: grid;
    grid-template-columns: auto minmax(0,1fr);
    overflow: auto;
    background: #fcfcfb;
}
.reader-code-scroll pre { margin: 0; font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace; font-size: 11px; line-height: 1.72; tab-size: 4; }
.reader-code-lines {
    position: sticky;
    left: 0;
    z-index: 2;
    min-width: 52px;
    padding: 15px 12px;
    border-right: 1px solid var(--line);
    background: #f6f7f8;
    color: #a0a5af;
    text-align: right;
    user-select: none;
}
.reader-code-content { min-width: max-content; padding: 15px 18px; color: #242833; white-space: pre; }

.reader-archive-view > header,
.reader-hex-view > header,
.reader-metadata-view > header {
    min-height: 68px;
    padding: 13px 15px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border-bottom: 1px solid var(--line);
    background: #fbfcfd;
}
.reader-archive-view > header > div,
.reader-hex-view > header > div,
.reader-metadata-view > header { justify-content: flex-start; }
.reader-archive-view > header > div,
.reader-hex-view > header > div { display: flex; align-items: center; gap: 11px; min-width: 0; }
.reader-archive-view > header svg,
.reader-hex-view > header svg,
.reader-metadata-view > header > svg {
    width: 36px;
    height: 36px;
    padding: 9px;
    flex: 0 0 36px;
    border-radius: 11px;
    color: var(--accent);
    background: var(--accent-soft);
}
.reader-archive-view header p,
.reader-hex-view header p,
.reader-metadata-view header div { min-width: 0; margin: 0; }
.reader-archive-view header strong,
.reader-hex-view header strong,
.reader-metadata-view header strong,
.reader-archive-view header small,
.reader-hex-view header small,
.reader-metadata-view header small { display: block; }
.reader-archive-view header strong,
.reader-hex-view header strong,
.reader-metadata-view header strong { font-size: 11px; }
.reader-archive-view header small,
.reader-hex-view header small,
.reader-metadata-view header small { margin-top: 3px; color: var(--muted); font-size: 8.5px; }
.reader-archive-warning {
    min-height: 28px;
    padding: 0 9px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    border: 1px solid rgba(213,138,0,.18);
    border-radius: 999px;
    background: #fff8e9;
    color: #966000;
    font-size: 8px;
}
.reader-archive-warning svg { width: 12px !important; height: 12px !important; padding: 0 !important; background: transparent !important; }
.reader-inline-note {
    margin: 12px 13px 0;
    padding: 10px 11px;
    display: flex;
    align-items: flex-start;
    gap: 7px;
    border: 1px solid rgba(var(--accent-rgb),.13);
    border-radius: 10px;
    background: var(--accent-soft);
    color: #4546ad;
    font-size: 8.5px;
}
.reader-inline-note svg { width: 13px; height: 13px; flex: 0 0 auto; }
.reader-inline-note--warning { border-color: rgba(213,138,0,.18); background: #fff8e9; color: #966000; }
.reader-archive-list { padding: 7px; display: grid; gap: 2px; }
.reader-archive-list > div {
    min-height: 49px;
    padding: 7px 9px;
    display: grid;
    grid-template-columns: 31px minmax(0,1fr) auto;
    align-items: center;
    gap: 9px;
    border-radius: 10px;
}
.reader-archive-list > div:hover { background: var(--surface-2); }
.reader-archive-list > div > span { width: 31px; height: 31px; display: grid; place-items: center; border-radius: 9px; color: var(--accent); background: var(--accent-soft); }
.reader-archive-list svg { width: 14px; height: 14px; }
.reader-archive-list p { min-width: 0; margin: 0; }
.reader-archive-list strong,
.reader-archive-list small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.reader-archive-list strong { font-size: 9.5px; }
.reader-archive-list small { margin-top: 2px; color: var(--muted); font-size: 8px; }
.reader-archive-list code { color: var(--muted); font-size: 8px; }
.reader-archive-view > footer { padding: 10px 13px; display: flex; align-items: center; gap: 7px; border-top: 1px solid var(--line); color: var(--muted); font-size: 8px; }
.reader-archive-view > footer svg { width: 12px; height: 12px; }
.reader-empty { min-height: 240px !important; grid-template-columns: 1fr !important; place-items: center; align-content: center; text-align: center; }
.reader-empty > span { width: 44px !important; height: 44px !important; }
.reader-empty p { max-width: 380px; color: var(--muted); font-size: 9px; }

.reader-hex-view > header > code {
    max-width: 46%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    padding: 6px 8px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    color: var(--muted);
    font-size: 8px;
}
.reader-hex-table { min-width: 720px; overflow: auto; font-family: "SFMono-Regular", Consolas, monospace; font-size: 9.5px; }
.reader-hex-head,
.reader-hex-table > div:not(.reader-hex-head) {
    min-height: 32px;
    padding: 0 13px;
    display: grid;
    grid-template-columns: 82px minmax(420px,1fr) minmax(150px,.45fr);
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid #edf0f2;
}
.reader-hex-head { position: sticky; top: 0; z-index: 2; background: #f6f7f8; color: var(--muted); font-size: 7.5px; font-weight: 760; letter-spacing: .08em; }
.reader-hex-table > div:not(.reader-hex-head):hover { background: #fafbfc; }
.reader-hex-table > div > span { color: #8b91a0; }
.reader-hex-table code { color: #293043; word-spacing: 3px; }
.reader-hex-table samp { color: #656b78; overflow: hidden; white-space: nowrap; }
.reader-hex-view details,
.reader-metadata-view details { margin: 12px; border: 1px solid var(--line); border-radius: 11px; background: var(--surface-2); overflow: hidden; }
.reader-hex-view summary,
.reader-metadata-view summary { padding: 10px 11px; cursor: pointer; color: var(--ink-soft); font-size: 8.5px; font-weight: 700; }
.reader-hex-view details pre,
.reader-metadata-view details pre { margin: 0; padding: 12px; max-height: 280px; overflow: auto; border-top: 1px solid var(--line); background: #fff; color: #323744; font-family: "SFMono-Regular", Consolas, monospace; font-size: 9px; line-height: 1.55; }

.reader-metadata-grid { padding: 12px; display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 7px; }
.reader-metadata-grid > div { min-width: 0; min-height: 57px; padding: 9px 10px; border: 1px solid var(--line); border-radius: 10px; background: #fbfcfd; }
.reader-metadata-grid span,
.reader-metadata-grid strong { display: block; }
.reader-metadata-grid span { color: var(--muted); font-size: 7.5px; text-transform: uppercase; letter-spacing: .06em; }
.reader-metadata-grid strong { margin-top: 5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 9.5px; }

/* Developer projects ------------------------------------------------------- */
.developer-loading { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 10px; }
.developer-loading .skeleton-card { min-height: 190px; border-radius: 18px; border: 1px solid var(--line); background: linear-gradient(90deg,#fff,#f5f6f8,#fff); background-size: 220% 100%; animation: developer-skeleton 1.4s linear infinite; }
@keyframes developer-skeleton { to { background-position: -220% 0; } }
.developer-page-head { margin-bottom: 14px; }
.developer-intro {
    position: relative;
    margin-bottom: 12px;
    padding: 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: #fff;
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}
.developer-intro::after { content: "</>"; position: absolute; right: 270px; top: -34px; color: rgba(var(--accent-rgb),.045); font: 800 118px/1 "SFMono-Regular", Consolas, monospace; pointer-events: none; }
.developer-intro-copy { position: relative; z-index: 1; min-width: 0; display: flex; align-items: flex-start; gap: 13px; }
.developer-intro-icon { width: 44px; height: 44px; flex: 0 0 44px; display: grid; place-items: center; border: 1px solid rgba(var(--accent-rgb),.15); border-radius: 13px; background: var(--accent-soft); color: var(--accent); }
.developer-intro-icon svg { width: 20px; height: 20px; }
.developer-intro-copy small { color: var(--accent); font-size: 8px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.developer-intro-copy h2 { margin: 4px 0 5px; font-size: 17px; letter-spacing: -.035em; }
.developer-intro-copy p { max-width: 750px; margin: 0; color: var(--muted); font-size: 9.5px; line-height: 1.55; }
.developer-runner-badge { position: relative; z-index: 1; min-width: 220px; max-width: 290px; padding: 10px 11px; display: flex; align-items: center; gap: 9px; border: 1px solid var(--line); border-radius: 13px; background: var(--surface-2); }
.developer-runner-badge > svg { width: 17px; height: 17px; flex: 0 0 auto; }
.developer-runner-badge span,
.developer-runner-badge strong,
.developer-runner-badge small { min-width: 0; display: block; }
.developer-runner-badge strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 9px; }
.developer-runner-badge small { margin-top: 2px; color: var(--muted); font-size: 7.8px; }
.developer-runner-badge.is-safe { border-color: rgba(20,137,102,.18); background: #eef9f5; color: var(--success); }
.developer-runner-badge.is-warning { border-color: rgba(213,138,0,.2); background: #fff8e9; color: #966000; }
.developer-runner-badge.is-neutral { color: var(--muted); }
.developer-metrics { margin-bottom: 12px; display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 8px; }
.developer-metrics > div { min-height: 76px; padding: 12px; display: grid; grid-template-columns: 34px auto 1fr; grid-template-rows: auto auto; align-items: center; column-gap: 10px; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.developer-metrics > div > span { grid-row: 1/3; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; color: var(--accent); background: var(--accent-soft); }
.developer-metrics svg { width: 15px; height: 15px; }
.developer-metrics strong { align-self: end; font-size: 18px; line-height: 1; letter-spacing: -.03em; }
.developer-metrics small { align-self: start; color: var(--muted); font-size: 8px; }
.developer-projects-section { padding: 14px; border: 1px solid var(--line); border-radius: 18px; background: #fff; box-shadow: var(--shadow-sm); }
.developer-projects-section .section-head { padding: 0 1px 11px; }
.developer-project-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(280px,1fr)); gap: 9px; }
.developer-project-card { min-width: 0; min-height: 150px; padding: 14px; display: grid; grid-template-columns: 41px minmax(0,1fr) 18px; align-items: start; gap: 11px; border: 1px solid var(--line); border-radius: 15px; background: #fbfcfd; color: inherit; text-align: left; cursor: pointer; transition: border-color .16s, background .16s, transform .16s, box-shadow .16s; }
.developer-project-card:hover { transform: translateY(-2px); border-color: rgba(var(--accent-rgb),.24); background: #fff; box-shadow: 0 12px 28px rgba(16,18,23,.07); }
.developer-project-card > svg { width: 15px; height: 15px; align-self: center; color: var(--muted-2); }
.developer-project-icon { width: 41px; height: 41px; display: grid; place-items: center; border: 1px solid rgba(var(--accent-rgb),.13); border-radius: 12px; background: var(--accent-soft); color: var(--accent); }
.developer-project-icon svg { width: 18px; height: 18px; }
.developer-project-copy { min-width: 0; display: flex; flex-direction: column; height: 100%; }
.developer-project-top { display: flex; align-items: center; justify-content: space-between; gap: 7px; }
.developer-project-top em { color: var(--accent); font-size: 7.5px; font-style: normal; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.developer-project-copy > strong { margin-top: 7px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; }
.developer-project-copy > small { min-height: 29px; margin-top: 4px; color: var(--muted); font-size: 8.5px; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.developer-project-meta { margin-top: auto; padding-top: 10px; display: flex; flex-wrap: wrap; gap: 9px; color: var(--muted); font-size: 7.5px; }
.developer-project-meta i { display: inline-flex; align-items: center; gap: 4px; font-style: normal; }
.developer-project-meta svg { width: 11px; height: 11px; }
.developer-build-state { min-height: 23px; padding: 0 7px; display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 999px; background: #fff; color: var(--muted); font-size: 7px; font-weight: 760; white-space: nowrap; }
.developer-build-state.is-completed { border-color: rgba(20,137,102,.16); background: #eef9f5; color: var(--success); }
.developer-build-state.is-running { border-color: rgba(var(--accent-rgb),.18); background: var(--accent-soft); color: var(--accent); }
.developer-build-state.is-queued { border-color: rgba(213,138,0,.18); background: #fff8e9; color: #966000; }
.developer-build-state.is-failed { border-color: rgba(219,58,74,.18); background: var(--danger-soft); color: var(--danger); }
.developer-build-state.is-cancelled { background: var(--surface-3); color: var(--muted); }
.developer-empty-project { min-height: 270px; display: grid; place-content: center; justify-items: center; text-align: center; }
.developer-empty-project > span { width: 52px; height: 52px; display: grid; place-items: center; border-radius: 16px; color: var(--accent); background: var(--accent-soft); }
.developer-empty-project svg { width: 22px; height: 22px; }
.developer-empty-project h3 { margin: 13px 0 5px; font-size: 14px; }
.developer-empty-project p { max-width: 430px; margin: 0 0 15px; color: var(--muted); font-size: 9px; }

/* Developer IDE ------------------------------------------------------------ */
.developer-ide-page { min-height: calc(100dvh - 118px); display: grid; grid-template-rows: auto minmax(0,1fr); gap: 10px; }
.developer-ide-head { min-width: 0; min-height: 70px; padding: 9px 10px; display: flex; align-items: center; justify-content: space-between; gap: 14px; border: 1px solid var(--line); border-radius: 16px; background: #fff; box-shadow: var(--shadow-sm); }
.developer-project-heading { min-width: 0; display: flex; align-items: center; gap: 10px; }
.developer-project-heading > div { min-width: 0; }
.developer-project-heading small { display: block; color: var(--accent); font-size: 7.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.developer-project-heading h1 { margin: 2px 0 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 15px; letter-spacing: -.025em; }
.developer-project-heading p { max-width: 520px; margin: 2px 0 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); font-size: 8px; }
.developer-project-avatar { width: 39px; height: 39px; flex: 0 0 39px; display: grid; place-items: center; border: 1px solid rgba(var(--accent-rgb),.14); border-radius: 11px; background: var(--accent-soft); color: var(--accent); }
.developer-project-avatar svg { width: 17px; height: 17px; }
.developer-build-controls { min-width: 0; display: flex; align-items: center; justify-content: flex-end; gap: 7px; }
.developer-build-controls select { width: 170px; height: 37px; padding: 0 30px 0 10px; font-size: 9px; }
.developer-build-btn { height: 37px; }
.developer-runner-mini { min-height: 29px; padding: 0 8px; display: inline-flex; align-items: center; gap: 5px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface-2); color: var(--muted); font-size: 7.5px; font-weight: 700; white-space: nowrap; }
.developer-runner-mini svg { width: 12px; height: 12px; }
.developer-runner-mini.is-safe { color: var(--success); background: #eef9f5; border-color: rgba(20,137,102,.16); }
.developer-runner-mini.is-warning { color: #966000; background: #fff8e9; border-color: rgba(213,138,0,.18); }
.developer-ide-shell { min-width: 0; min-height: 580px; height: calc(100dvh - 198px); display: grid; grid-template-columns: 236px minmax(420px,1fr) 330px; border: 1px solid var(--line); border-radius: 16px; background: #fff; box-shadow: var(--shadow-sm); overflow: hidden; }
.developer-explorer,
.developer-build-panel { min-width: 0; min-height: 0; display: grid; grid-template-rows: auto minmax(0,1fr) auto; background: #fbfcfd; }
.developer-explorer { border-right: 1px solid var(--line); }
.developer-build-panel { border-left: 1px solid var(--line); }
.developer-panel-head { min-height: 48px; padding: 8px 10px; display: flex; align-items: center; justify-content: space-between; gap: 8px; border-bottom: 1px solid var(--line); background: #fff; }
.developer-panel-head small,
.developer-panel-head strong { display: block; }
.developer-panel-head small { color: var(--muted); font-size: 7px; font-weight: 760; letter-spacing: .1em; }
.developer-panel-head strong { max-width: 175px; margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 9px; }
.developer-panel-head button { width: 29px; height: 29px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 8px; background: var(--surface-2); color: var(--muted); cursor: pointer; }
.developer-panel-head button:hover { color: var(--accent); background: var(--accent-soft); border-color: rgba(var(--accent-rgb),.16); }
.developer-panel-head svg { width: 13px; height: 13px; }
.developer-tree { min-height: 0; padding: 6px; overflow: auto; }
.developer-tree-row { --tree-depth: 0; width: 100%; min-height: 31px; padding: 0 7px 0 calc(7px + var(--tree-depth) * 13px); display: grid; grid-template-columns: 13px 16px minmax(0,1fr) auto; align-items: center; gap: 5px; border: 0; border-radius: 8px; background: transparent; color: var(--ink-soft); text-align: left; font-size: 8.5px; }
button.developer-tree-row { cursor: pointer; }
.developer-tree-row:hover { background: #f1f3f5; }
.developer-tree-row.is-active { color: var(--accent); background: var(--accent-soft); }
.developer-tree-row.is-folder { color: var(--muted); }
.developer-tree-row.is-readonly { opacity: .72; }
.developer-tree-row svg { width: 13px; height: 13px; }
.developer-tree-row strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 580; }
.developer-tree-row em { color: var(--muted-2); font-size: 6.5px; font-style: normal; text-transform: uppercase; }
.developer-tree-row em svg { width: 11px; height: 11px; }
.developer-tree-empty { min-height: 180px; display: grid; place-content: center; justify-items: center; text-align: center; color: var(--muted); }
.developer-tree-empty span { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 11px; background: var(--surface-3); }
.developer-tree-empty svg { width: 16px; height: 16px; }
.developer-tree-empty p { max-width: 150px; margin: 8px 0 0; font-size: 8px; }
.developer-explorer-foot { min-height: 36px; padding: 0 10px; display: flex; align-items: center; justify-content: space-between; gap: 8px; border-top: 1px solid var(--line); color: var(--muted); background: #fff; font-size: 7px; }
.developer-explorer-foot span { display: inline-flex; align-items: center; gap: 4px; }
.developer-explorer-foot svg { width: 11px; height: 11px; }

.developer-editor-panel { min-width: 0; min-height: 0; display: grid; grid-template-rows: auto minmax(0,1fr) auto; background: #fff; }
.developer-editor-head { min-height: 48px; padding: 6px 8px 6px 11px; display: flex; align-items: center; justify-content: space-between; gap: 9px; border-bottom: 1px solid var(--line); background: #fff; }
.developer-file-tab { min-width: 0; min-height: 31px; display: flex; align-items: center; gap: 7px; }
.developer-file-tab > span { color: var(--accent); }
.developer-file-tab svg { width: 14px; height: 14px; }
.developer-file-tab strong { max-width: 440px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 8.5px; font-weight: 650; }
.developer-file-tab i { width: 6px; height: 6px; flex: 0 0 6px; border-radius: 50%; background: var(--warning); }
.developer-editor-actions { display: flex; align-items: center; gap: 4px; }
.developer-editor-actions button { min-height: 30px; padding: 0 8px; display: inline-flex; align-items: center; gap: 5px; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--muted); cursor: pointer; font-size: 7.5px; font-weight: 670; }
.developer-editor-actions button:hover { color: var(--ink); background: var(--surface-2); }
.developer-editor-actions button.developer-save-btn { color: #fff; border-color: var(--ink); background: var(--ink); }
.developer-editor-actions button.developer-save-btn.is-dirty { border-color: var(--accent); background: var(--accent); }
.developer-editor-actions svg { width: 12px; height: 12px; }
.developer-editor-wrap { min-width: 0; min-height: 0; display: grid; grid-template-columns: auto minmax(0,1fr); overflow: hidden; background: #fcfcfb; }
.developer-line-numbers,
.developer-code-editor { margin: 0; padding-top: 15px; padding-bottom: 30px; border: 0; outline: 0; resize: none; white-space: pre; overflow: auto; font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace; font-size: 11px; line-height: 1.68; tab-size: 2; }
.developer-line-numbers { width: 54px; padding-left: 8px; padding-right: 11px; border-right: 1px solid var(--line); background: #f5f6f7; color: #a1a6b0; text-align: right; user-select: none; overflow: hidden; }
.developer-code-editor { width: 100%; height: 100%; min-height: 0; padding-left: 16px; padding-right: 24px; background: #fcfcfb; color: #242833; caret-color: var(--accent); }
.developer-code-editor:focus { background: #fff; }
.developer-editor-status { min-height: 31px; padding: 0 10px; display: flex; align-items: center; justify-content: flex-end; gap: 11px; border-top: 1px solid var(--line); background: #fbfcfd; color: var(--muted); font-size: 7px; }
.developer-editor-status span:first-child { margin-right: auto; color: var(--accent); font-weight: 760; text-transform: uppercase; }
.developer-welcome { min-height: 100%; padding: 35px; display: grid; place-content: center; justify-items: center; text-align: center; background: radial-gradient(circle at 50% 35%, rgba(var(--accent-rgb),.06), transparent 30%), #fff; }
.developer-welcome-mark { width: 58px; height: 58px; display: grid; place-items: center; border: 1px solid rgba(var(--accent-rgb),.15); border-radius: 18px; background: var(--accent-soft); color: var(--accent); }
.developer-welcome-mark svg { width: 25px; height: 25px; }
.developer-welcome > small { margin-top: 13px; color: var(--accent); font-size: 7.5px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.developer-welcome h2 { margin: 4px 0 5px; font-size: 19px; letter-spacing: -.035em; }
.developer-welcome > p { max-width: 490px; margin: 0; color: var(--muted); font-size: 9px; }
.developer-welcome-cards { width: min(100%,680px); margin: 18px 0 14px; display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 7px; }
.developer-welcome-cards > div { min-height: 112px; padding: 12px; display: flex; flex-direction: column; align-items: flex-start; border: 1px solid var(--line); border-radius: 12px; background: #fff; text-align: left; }
.developer-welcome-cards svg { width: 17px; height: 17px; color: var(--accent); }
.developer-welcome-cards strong { margin-top: 9px; font-size: 9px; }
.developer-welcome-cards span { margin-top: 3px; color: var(--muted); font-size: 7.5px; line-height: 1.4; }

.developer-build-panel { grid-template-rows: auto minmax(0,1fr); overflow: hidden; }
.developer-build-current { min-height: 0; padding: 10px; overflow: auto; border-bottom: 1px solid var(--line); background: #fff; }
.developer-build-current-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.developer-build-current-head time { color: var(--muted); font-size: 7px; }
.developer-build-current > strong,
.developer-build-current > small { display: block; }
.developer-build-current > strong { margin-top: 9px; font-size: 10px; }
.developer-build-current > small { margin-top: 2px; color: var(--muted); font-size: 7px; }
.developer-build-current > pre { min-height: 176px; max-height: 300px; margin: 10px 0; padding: 11px; overflow: auto; border: 1px solid var(--line); border-radius: 10px; background: #f7f8f9; color: #303541; font-family: "SFMono-Regular", Consolas, monospace; font-size: 8px; line-height: 1.55; white-space: pre-wrap; word-break: break-word; }
.developer-build-error { margin-bottom: 9px; padding: 8px 9px; display: flex; align-items: flex-start; gap: 6px; border: 1px solid rgba(219,58,74,.16); border-radius: 9px; background: var(--danger-soft); color: var(--danger); font-size: 7.5px; }
.developer-build-error svg { width: 12px; height: 12px; flex: 0 0 auto; }
.developer-build-current-actions { display: flex; align-items: center; gap: 6px; }
.developer-build-current-actions .primary-btn,
.developer-build-current-actions .secondary-btn { height: 33px; font-size: 8px; }
.developer-artifact-meta { margin-top: 8px; display: flex; justify-content: space-between; gap: 8px; color: var(--muted); font-size: 7px; }
.developer-artifact-meta code { max-width: 145px; overflow: hidden; text-overflow: ellipsis; }
.developer-build-history { min-height: 145px; max-height: 42%; padding: 7px; overflow: auto; background: #fbfcfd; }
.developer-build-history-head { min-height: 28px; padding: 0 4px; display: flex; align-items: center; justify-content: space-between; color: var(--muted); font-size: 7.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; }
.developer-build-history-head b { min-width: 20px; height: 20px; padding: 0 5px; display: grid; place-items: center; border-radius: 999px; background: var(--surface-3); font-size: 7px; }
.developer-build-history button { width: 100%; min-height: 48px; padding: 7px; display: grid; grid-template-columns: 8px minmax(0,1fr) 14px; align-items: center; gap: 8px; border: 0; border-radius: 9px; background: transparent; color: inherit; text-align: left; cursor: pointer; }
.developer-build-history button:hover,
.developer-build-history button.is-active { background: #fff; box-shadow: inset 0 0 0 1px var(--line); }
.developer-build-history button > span:nth-child(2) { min-width: 0; }
.developer-build-history strong,
.developer-build-history small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.developer-build-history strong { font-size: 8px; }
.developer-build-history small { margin-top: 2px; color: var(--muted); font-size: 7px; }
.developer-build-history svg { width: 12px; height: 12px; color: var(--muted); }
.developer-build-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--muted-2); }
.developer-build-dot.is-completed { background: var(--success); }
.developer-build-dot.is-running { background: var(--accent); box-shadow: 0 0 0 4px rgba(var(--accent-rgb),.11); }
.developer-build-dot.is-queued { background: var(--warning); }
.developer-build-dot.is-failed { background: var(--danger); }
.developer-build-empty { min-height: 260px; display: grid; place-content: center; justify-items: center; padding: 20px; text-align: center; color: var(--muted); background: #fff; }
.developer-build-empty > span { width: 43px; height: 43px; display: grid; place-items: center; border-radius: 13px; background: var(--surface-3); }
.developer-build-empty svg { width: 18px; height: 18px; }
.developer-build-empty h3 { margin: 10px 0 4px; color: var(--ink-soft); font-size: 11px; }
.developer-build-empty p { max-width: 190px; margin: 0; font-size: 8px; }

.developer-profile-picker { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 7px; }
.developer-profile-option { position: relative; min-width: 0; cursor: pointer; }
.developer-profile-option > input { position: absolute; opacity: 0; pointer-events: none; }
.developer-profile-option > span { min-height: 118px; padding: 11px; display: flex; flex-direction: column; align-items: flex-start; border: 1px solid var(--line); border-radius: 12px; background: #fff; transition: border-color .15s, background .15s, box-shadow .15s; }
.developer-profile-option:hover > span { border-color: var(--line-strong); background: #fbfcfd; }
.developer-profile-option > input:checked + span { border-color: var(--accent); background: var(--accent-soft); box-shadow: 0 0 0 3px rgba(var(--accent-rgb),.08); }
.developer-profile-option svg { width: 18px; height: 18px; color: var(--accent); }
.developer-profile-option b { margin-top: 9px; font-size: 9px; }
.developer-profile-option small { min-height: 28px; margin-top: 3px; color: var(--muted); font-size: 7.5px; line-height: 1.35; }
.developer-profile-option em { margin-top: auto; color: var(--success); font-size: 7px; font-style: normal; font-weight: 720; }
.developer-profile-option.is-disabled { cursor: not-allowed; opacity: .55; }
.developer-profile-option.is-disabled em { color: var(--danger); }
.developer-new-file-content { font-family: "SFMono-Regular", Consolas, monospace; font-size: 10px; line-height: 1.55; }
.developer-preview-notice { margin-bottom: 10px; padding: 10px 11px; display: flex; align-items: center; gap: 7px; border: 1px solid rgba(20,137,102,.16); border-radius: 10px; background: #eef9f5; color: var(--success); font-size: 8.5px; }
.developer-preview-notice svg { width: 14px; height: 14px; }
.developer-live-preview { width: 100%; min-height: 620px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }

@media (max-width: 1280px) {
    .universal-reader-toolbar { grid-template-columns: minmax(135px,.65fr) minmax(220px,1fr) auto; }
    .universal-reader-identity .reader-status { display: none; }
    .developer-ide-shell { grid-template-columns: 210px minmax(380px,1fr) 290px; }
    .developer-runner-mini { display: none; }
}

@media (max-width: 1080px) {
    .developer-ide-page { min-height: auto; }
    .developer-ide-shell { height: auto; min-height: 680px; grid-template-columns: 210px minmax(0,1fr); grid-template-rows: minmax(500px,68vh) auto; overflow: visible; }
    .developer-build-panel { grid-column: 1 / -1; min-height: 380px; border-left: 0; border-top: 1px solid var(--line); grid-template-columns: minmax(0,1fr) 320px; grid-template-rows: auto minmax(0,1fr); }
    .developer-build-panel > .developer-panel-head { grid-column: 1 / -1; }
    .developer-build-current,
    .developer-build-empty { border-bottom: 0; border-right: 1px solid var(--line); }
    .developer-build-history { max-height: none; }
    .developer-build-current > pre { max-height: 230px; }
    .developer-profile-picker { grid-template-columns: repeat(2,minmax(0,1fr)); }
}

@media (max-width: 900px) {
    .universal-reader-toolbar { grid-template-columns: minmax(0,1fr) auto; }
    .universal-reader-tabs { grid-column: 1 / -1; grid-row: 2; justify-content: flex-start; order: 3; }
    .universal-reader-stage { min-height: 420px; }
    .reader-code-view,
    .reader-archive-view,
    .reader-hex-view,
    .reader-metadata-view { min-height: 390px; margin: 10px; width: calc(100% - 20px); }
    .reader-code-scroll { max-height: 52vh; }
    .developer-intro { align-items: flex-start; flex-direction: column; }
    .developer-intro::after { right: -15px; }
    .developer-runner-badge { width: 100%; max-width: none; }
    .developer-project-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .developer-ide-head { align-items: flex-start; flex-direction: column; }
    .developer-build-controls { width: 100%; justify-content: flex-start; }
    .developer-build-controls select { flex: 1; width: auto; }
    .developer-ide-shell { min-height: 720px; grid-template-columns: 188px minmax(0,1fr); }
    .developer-file-tab strong { max-width: 250px; }
}

@media (max-width: 720px) {
    .universal-reader-toolbar { min-height: 54px; padding: 7px; }
    .universal-reader-identity > span { width: 31px; height: 31px; flex-basis: 31px; }
    .universal-reader-identity small { display: none; }
    .universal-reader-identity strong { max-width: 180px; }
    .universal-reader-tools button,
    .universal-reader-tools a { width: 31px; height: 31px; }
    .universal-reader-tabs button { height: 29px; padding: 0 8px; }
    .reader-code-view,
    .reader-archive-view,
    .reader-hex-view,
    .reader-metadata-view { margin: 6px; width: calc(100% - 12px); border-radius: 12px; }
    .reader-code-scroll pre { font-size: 10px; }
    .reader-code-lines { min-width: 43px; padding-left: 8px; padding-right: 8px; }
    .reader-code-content { padding-left: 12px; padding-right: 12px; }
    .reader-metadata-grid { grid-template-columns: 1fr; }
    .reader-archive-list > div { grid-template-columns: 29px minmax(0,1fr); }
    .reader-archive-list code { display: none; }
    .reader-hex-view { overflow-x: auto; }

    .developer-loading,
    .developer-metrics { grid-template-columns: 1fr; }
    .developer-intro { padding: 14px; border-radius: 15px; }
    .developer-intro-copy { gap: 10px; }
    .developer-intro-icon { width: 39px; height: 39px; flex-basis: 39px; }
    .developer-projects-section { padding: 9px; border-radius: 15px; }
    .developer-project-grid { grid-template-columns: 1fr; }
    .developer-project-card { min-height: 132px; }
    .developer-ide-page { display: block; }
    .developer-ide-head { margin-bottom: 8px; padding: 8px; border-radius: 13px; }
    .developer-project-heading p { max-width: calc(100vw - 130px); }
    .developer-build-controls { flex-wrap: wrap; }
    .developer-build-controls select { min-width: 170px; }
    .developer-build-btn { flex: 0 0 auto; }
    .developer-ide-shell { min-height: 0; height: auto; display: block; border-radius: 13px; overflow: visible; }
    .developer-explorer { max-height: 260px; border-right: 0; border-bottom: 1px solid var(--line); }
    .developer-tree { max-height: 190px; }
    .developer-editor-panel { min-height: 540px; }
    .developer-editor-head { align-items: flex-start; flex-direction: column; }
    .developer-editor-actions { width: 100%; overflow-x: auto; padding-bottom: 2px; }
    .developer-editor-actions button { flex: 0 0 auto; }
    .developer-file-tab strong { max-width: calc(100vw - 100px); }
    .developer-editor-wrap { min-height: 450px; }
    .developer-code-editor,
    .developer-line-numbers { font-size: 10px; }
    .developer-line-numbers { width: 44px; padding-right: 8px; }
    .developer-code-editor { padding-left: 11px; }
    .developer-editor-status { overflow-x: auto; justify-content: flex-start; white-space: nowrap; }
    .developer-build-panel { min-height: 520px; display: grid; grid-template-columns: 1fr; grid-template-rows: auto auto auto; border-left: 0; border-top: 1px solid var(--line); }
    .developer-build-current,
    .developer-build-empty { min-height: 300px; border-right: 0; border-bottom: 1px solid var(--line); }
    .developer-build-history { min-height: 180px; }
    .developer-welcome { padding: 24px 14px; }
    .developer-welcome-cards { grid-template-columns: 1fr; }
    .developer-welcome-cards > div { min-height: 86px; }
    .developer-profile-picker { grid-template-columns: 1fr; }
    .developer-profile-option > span { min-height: 94px; }
    .developer-live-preview { min-height: 68vh; }
}

@media (max-width: 430px) {
    .universal-reader-identity strong { max-width: 128px; }
    .universal-reader-tabs button span { display: none; }
    .universal-reader-tabs button { width: 34px; padding: 0; }
    .reader-archive-view > header,
    .reader-hex-view > header,
    .reader-metadata-view > header { padding: 10px; }
    .reader-hex-view > header > code { display: none; }
    .developer-project-heading .icon-btn { width: 33px; height: 33px; }
    .developer-project-avatar { display: none; }
    .developer-build-controls select { width: 100%; flex-basis: calc(100% - 105px); }
    .developer-editor-actions button { font-size: 0; width: 32px; justify-content: center; padding: 0; }
    .developer-editor-actions button svg { width: 13px; height: 13px; }
}

/* v0.7.0 — usability pass: readable Reader and Developer typography */
.universal-reader-identity small { font-size: 10px; }
.universal-reader-identity strong { font-size: 12px; }
.reader-status { min-height: 26px; font-size: 10px; }
.universal-reader-tabs button { height: 34px; padding-inline: 11px; font-size: 11px; }
.reader-loading strong { font-size: 13px; }
.reader-loading small { font-size: 11px; }
.reader-code-view > header,
.reader-code-view > footer { min-height: 44px; font-size: 11px; }
.reader-code-scroll pre { font-size: 12px; line-height: 1.68; }
.reader-archive-view header strong,
.reader-hex-view header strong,
.reader-metadata-view header strong { font-size: 13px; }
.reader-archive-view header small,
.reader-hex-view header small,
.reader-metadata-view header small { font-size: 11px; }
.reader-archive-warning,
.reader-inline-note,
.reader-archive-view > footer { font-size: 10.5px; }
.reader-archive-list strong { font-size: 12px; }
.reader-archive-list small,
.reader-archive-list code { font-size: 10px; }
.reader-empty p { font-size: 11px; }
.reader-hex-view > header > code { font-size: 10px; }
.reader-hex-table { font-size: 11px; }
.reader-hex-head { font-size: 9px; }
.reader-hex-view summary,
.reader-metadata-view summary { font-size: 11px; }
.reader-hex-view details pre,
.reader-metadata-view details pre { font-size: 11px; }
.reader-metadata-grid span { font-size: 9px; }
.reader-metadata-grid strong { font-size: 11px; }

.developer-intro-copy small { font-size: 10px; }
.developer-intro-copy h2 { font-size: 20px; }
.developer-intro-copy p { font-size: 12px; line-height: 1.6; }
.developer-runner-badge strong { font-size: 11px; }
.developer-runner-badge small { font-size: 9.5px; }
.developer-metrics small { font-size: 10px; }
.developer-project-card strong { font-size: 13px; }
.developer-project-card small { font-size: 10.5px; line-height: 1.45; }
.developer-project-top em,
.developer-project-meta,
.developer-build-state { font-size: 9.5px; }
.developer-empty-project p { font-size: 11px; }
.developer-project-heading small { font-size: 9px; }
.developer-project-heading h1 { font-size: 20px; }
.developer-project-heading p { font-size: 10.5px; }
.developer-runner-mini { font-size: 9.5px; }
.developer-panel-head small { font-size: 9px; }
.developer-panel-head strong { font-size: 11px; }
.developer-tree-row strong { font-size: 11px; }
.developer-tree-row em { font-size: 9px; }
.developer-explorer-foot { font-size: 9px; }
.developer-file-tab strong { font-size: 11px; }
.developer-editor-actions button { min-height: 32px; padding-inline: 10px; font-size: 10px; }
.developer-line-numbers,
.developer-code-editor { font-size: 12px; line-height: 1.68; }
.developer-editor-status { min-height: 34px; font-size: 9.5px; }
.developer-welcome > small { font-size: 9px; }
.developer-welcome h2 { font-size: 22px; }
.developer-welcome > p { font-size: 11.5px; line-height: 1.55; }
.developer-welcome-cards strong { font-size: 11px; }
.developer-welcome-cards span { font-size: 10px; }
.developer-build-current-head time { font-size: 9px; }
.developer-build-current > strong { font-size: 12px; }
.developer-build-current > small { font-size: 9.5px; }
.developer-build-current > pre { font-size: 10.5px; line-height: 1.6; }
.developer-build-error { font-size: 10px; }
.developer-build-current-actions .primary-btn,
.developer-build-current-actions .secondary-btn { font-size: 10px; }
.developer-artifact-meta { font-size: 9px; }
.developer-build-history-head { font-size: 9px; }
.developer-build-history strong { font-size: 10.5px; }
.developer-build-history small { font-size: 9px; }
.developer-build-empty p { font-size: 10.5px; }
.developer-profile-option b { font-size: 11px; }
.developer-profile-option small { font-size: 10px; line-height: 1.45; }
.developer-profile-option em { font-size: 9px; }
.developer-preview-notice { font-size: 10.5px; }

.developer-project-folder-note {
    min-height: 54px;
    padding: 10px 12px;
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr) 18px;
    align-items: center;
    gap: 10px;
    border: 1px solid rgba(var(--accent-rgb), .18);
    border-radius: 13px;
    background: var(--accent-soft);
    color: var(--accent);
}
.developer-project-folder-note > svg:first-child {
    width: 34px;
    height: 34px;
    padding: 8px;
    border-radius: 10px;
    background: #fff;
}
.developer-project-folder-note > svg:last-child { width: 15px; height: 15px; opacity: .7; }
.developer-project-folder-note span,
.developer-project-folder-note small,
.developer-project-folder-note strong { min-width: 0; display: block; }
.developer-project-folder-note small { color: #6265b7; font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.developer-project-folder-note strong { margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink); font-size: 12px; }

@media (max-width: 720px) {
    .universal-reader-tabs button { font-size: 10px; }
    .reader-code-scroll pre,
    .developer-line-numbers,
    .developer-code-editor { font-size: 11px; }
    .developer-intro-copy p,
    .developer-project-card small,
    .developer-welcome > p { font-size: 11px; }
    .developer-editor-actions button { font-size: 10px; }
}

/* Universal Reader: structured adapters (databases, fonts, CAD/3D, e-mail and datasets). */
.reader-structure-view {
    min-height: 100%;
    padding: 24px;
    background: #f6f8fc;
    color: #172033;
}
.reader-structure-view > header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    max-width: 1120px;
    margin: 0 auto 16px;
    padding: 18px 20px;
    border: 1px solid #e2e7f0;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 8px 26px rgba(26, 42, 78, .05);
}
.reader-structure-view > header > div {
    display: flex;
    align-items: center;
    gap: 13px;
    min-width: 0;
}
.reader-structure-view > header > div > span,
.reader-structure-title > span {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    border-radius: 12px;
    background: #eef3ff;
    color: #3563e9;
}
.reader-structure-view > header svg,
.reader-structure-title svg { width: 21px; height: 21px; }
.reader-structure-view > header p,
.reader-structure-title > div { min-width: 0; margin: 0; }
.reader-structure-view > header strong,
.reader-structure-title strong { display: block; font-size: 14px; line-height: 1.35; }
.reader-structure-view > header small,
.reader-structure-title small {
    display: block;
    margin-top: 3px;
    color: #7b8498;
    font-size: 11px;
    line-height: 1.35;
}
.reader-structure-view > header > b {
    flex: 0 0 auto;
    padding: 7px 10px;
    border: 1px solid #dfe6f2;
    border-radius: 999px;
    background: #f8faff;
    color: #5c6680;
    font-size: 11px;
    font-weight: 700;
}
.reader-structure-sections {
    display: grid;
    gap: 12px;
    max-width: 1120px;
    margin: 0 auto;
}
.reader-structure-sections > section {
    overflow: hidden;
    border: 1px solid #e2e7f0;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 6px 20px rgba(26, 42, 78, .04);
}
.reader-structure-title {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 18px;
    border-bottom: 1px solid #edf0f6;
}
.reader-structure-title > span { width: 36px; height: 36px; border-radius: 10px; }
.reader-structure-title svg { width: 18px; height: 18px; }
.reader-structure-object,
.reader-structure-list {
    display: grid;
    gap: 0;
    padding: 4px 18px 14px;
}
.reader-structure-object > div,
.reader-structure-list > div {
    display: grid;
    grid-template-columns: minmax(130px, 220px) minmax(0, 1fr);
    align-items: start;
    gap: 18px;
    padding: 10px 0;
    border-bottom: 1px solid #eff2f7;
}
.reader-structure-list > div { grid-template-columns: 46px minmax(0, 1fr); }
.reader-structure-object > div:last-child,
.reader-structure-list > div:last-child { border-bottom: 0; }
.reader-structure-object small,
.reader-structure-list small {
    color: #788297;
    font-size: 11px;
    line-height: 1.5;
    text-transform: none;
}
.reader-structure-object code,
.reader-structure-list code {
    overflow-wrap: anywhere;
    white-space: pre-wrap;
    color: #263249;
    font: 12px/1.55 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.reader-structure-object > div > .reader-structure-object,
.reader-structure-object > div > .reader-structure-list,
.reader-structure-list > div > .reader-structure-object,
.reader-structure-list > div > .reader-structure-list {
    padding: 0;
    border-left: 2px solid #edf2ff;
    padding-left: 14px;
}
.reader-structure-list footer {
    padding: 9px 0 3px 64px;
    color: #8a93a5;
    font-size: 11px;
}
.reader-structure-view .reader-empty {
    min-height: 260px;
    border: 1px dashed #d8dfeb;
    border-radius: 16px;
    background: #fff;
}

@media (max-width: 760px) {
    .reader-structure-view { padding: 14px; }
    .reader-structure-view > header { align-items: flex-start; padding: 15px; }
    .reader-structure-view > header > b { display: none; }
    .reader-structure-title { padding: 14px; }
    .reader-structure-object,
    .reader-structure-list { padding: 2px 14px 12px; }
    .reader-structure-object > div,
    .reader-structure-list > div {
        grid-template-columns: 1fr;
        gap: 4px;
        padding: 9px 0;
    }
    .reader-structure-list footer { padding-left: 0; }
}


/* v0.7.0 mobile Developer actions: keep labels readable without clipping. */
@media (max-width: 430px) {
    .developer-editor-head { padding: 8px; }
    .developer-editor-actions {
        width: 100%;
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 6px;
        overflow: visible;
        padding-bottom: 0;
    }
    .developer-editor-actions button {
        width: 100%;
        min-width: 0;
        padding: 0 8px;
        justify-content: center;
        font-size: 10px;
    }
}

/* v0.7.0 mobile Universal Reader: readable tabs and complete actions. */
@media (max-width: 430px) {
    .universal-reader-toolbar {
        grid-template-columns: minmax(0, 1fr) auto;
        gap: 6px;
    }
    .universal-reader-identity { overflow: hidden; }
    .universal-reader-identity strong { max-width: none; }
    .universal-reader-tabs {
        width: 100%;
        justify-content: flex-start;
        overflow-x: auto;
        scroll-snap-type: x proximity;
    }
    .universal-reader-tabs button {
        width: auto;
        min-width: max-content;
        padding: 0 9px;
        flex: 0 0 auto;
        font-size: 9.5px;
        scroll-snap-align: start;
    }
    .modal-preview.modal-document .modal-foot {
        display: grid;
        grid-template-columns: 1fr;
        gap: 7px;
        overflow: visible;
        padding: 8px;
    }
    .modal-preview.modal-document .modal-foot-group {
        width: 100%;
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
        gap: 6px;
    }
    .modal-preview.modal-document .modal-foot-group > * {
        width: 100%;
        min-width: 0;
        justify-content: center;
    }
}

@media (max-width: 430px) {
    .modal-preview.modal-document .preview-counter { display: none; }
}

/* v0.8.0 · Universal Reader data tables */
.reader-table-view {
    min-height: 100%;
    display: grid;
    grid-template-rows: auto minmax(280px, 1fr) auto;
    background: #f8fafc;
}
.reader-table-view > header {
    min-height: 66px;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    border-bottom: 1px solid var(--line);
    background: #fff;
}
.reader-table-view > header > div { display: flex; align-items: center; gap: 10px; min-width: 0; }
.reader-table-view > header > div > span {
    width: 34px; height: 34px; flex: 0 0 34px; display: grid; place-items: center;
    border-radius: 10px; color: #2759d7; background: #edf3ff;
}
.reader-table-view > header svg { width: 16px; height: 16px; }
.reader-table-view > header p { min-width: 0; margin: 0; }
.reader-table-view > header strong,
.reader-table-view > header small { display: block; }
.reader-table-view > header strong { color: var(--ink); font-size: 13px; }
.reader-table-view > header small { margin-top: 3px; color: var(--muted); font-size: 11px; }
.reader-table-view > header > span { color: var(--muted); font-size: 11px; white-space: nowrap; }
.reader-table-scroll { min-width: 0; overflow: auto; background: #fff; }
.reader-table-scroll table { width: max-content; min-width: 100%; border-collapse: separate; border-spacing: 0; font-size: 11px; }
.reader-table-scroll th,
.reader-table-scroll td {
    min-width: 130px; max-width: 360px; padding: 10px 12px; border-right: 1px solid #edf0f5; border-bottom: 1px solid #edf0f5;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: left; vertical-align: top;
}
.reader-table-scroll th {
    position: sticky; top: 0; z-index: 2; color: #44506a; background: #f5f7fb;
    font-size: 10px; font-weight: 750; letter-spacing: .02em;
}
.reader-table-scroll tbody tr:hover td { background: #f8fbff; }
.reader-table-scroll td { color: #243049; }
.reader-table-empty { color: #a0a8b7; }
.reader-table-view > footer {
    min-height: 56px; padding: 9px 12px 9px 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px;
    border-top: 1px solid var(--line); background: #fff; color: var(--muted); font-size: 10px;
}
.reader-table-view > footer > span { display: flex; align-items: center; gap: 7px; }
.reader-table-view > footer > span svg { width: 14px; height: 14px; }
.reader-table-view > footer > div { display: flex; gap: 7px; }
.reader-table-view > footer button { min-height: 34px; padding-inline: 11px; }

/* v0.8.0 · Developer Studio */
.developer-studio-v2 .developer-ide-head { min-height: 76px; }
.developer-head-action { min-height: 35px; padding-inline: 10px; white-space: nowrap; }
.developer-panel-actions { display: flex; align-items: center; gap: 3px; }
.developer-panel-actions button,
.developer-tree-more {
    width: 28px; height: 28px; padding: 0; display: grid; place-items: center; border: 0; border-radius: 8px;
    color: var(--muted); background: transparent; cursor: pointer;
}
.developer-panel-actions button:hover,
.developer-tree-more:hover { color: var(--accent); background: var(--accent-soft); }
.developer-panel-actions svg,
.developer-tree-more svg { width: 14px; height: 14px; }
.developer-studio-v2 .developer-tree-row {
    width: 100%; min-height: 33px; padding: 0 4px 0 calc(4px + var(--tree-depth) * 13px);
    display: flex; align-items: center; gap: 2px; border-radius: 8px;
}
.developer-studio-v2 .developer-tree-row.is-active { background: var(--accent-soft); }
.developer-tree-main {
    min-width: 0; min-height: 31px; flex: 1 1 auto; padding: 0 4px; display: grid;
    grid-template-columns: 13px 16px minmax(0, 1fr) auto; align-items: center; gap: 5px;
    border: 0; border-radius: 7px; color: inherit; background: transparent; text-align: left;
}
button.developer-tree-main { cursor: pointer; }
.developer-tree-main svg { width: 13px; height: 13px; }
.developer-tree-main strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; font-weight: 600; }
.developer-tree-main em { color: var(--muted-2); font-size: 8px; font-style: normal; text-transform: uppercase; }
.developer-tree-more { flex: 0 0 26px; opacity: 0; }
.developer-tree-row:hover .developer-tree-more,
.developer-tree-more:focus-visible { opacity: 1; }
.developer-editor-panel { position: relative; }
.developer-editor-panel.has-tabs { grid-template-rows: auto auto minmax(0,1fr) auto; }

.developer-editor-tabs {
    min-height: 37px; display: flex; align-items: stretch; overflow-x: auto; overflow-y: hidden;
    border-bottom: 1px solid var(--line); background: #f7f8fa; scrollbar-width: thin;
}
.developer-editor-tab { min-width: 132px; max-width: 220px; display: flex; align-items: stretch; border-right: 1px solid var(--line); color: var(--muted); }
.developer-editor-tab.is-active { color: var(--ink); background: #fff; box-shadow: inset 0 2px 0 var(--accent); }
.developer-editor-tab > button:first-child {
    min-width: 0; flex: 1; padding: 0 6px 0 10px; display: flex; align-items: center; gap: 7px;
    border: 0; background: transparent; color: inherit; cursor: pointer;
}
.developer-editor-tab > button:first-child svg { width: 13px; height: 13px; flex: 0 0 13px; }
.developer-editor-tab > button:first-child span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 10px; }
.developer-editor-tab > button:first-child i { width: 6px; height: 6px; flex: 0 0 6px; border-radius: 50%; background: #f1a33c; }
.developer-editor-tab > button:last-child { width: 26px; flex: 0 0 26px; padding: 0; border: 0; color: var(--muted); background: transparent; cursor: pointer; opacity: .45; }
.developer-editor-tab > button:last-child:hover { color: var(--ink); opacity: 1; }
.developer-editor-tab > button:last-child svg { width: 12px; height: 12px; }
.developer-welcome-actions { display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; }
.developer-context-menu { min-width: 210px; }
.developer-search-dialog { display: grid; grid-template-rows: auto minmax(320px, 58vh); gap: 10px; }
.developer-search-input { position: relative; }
.developer-search-input > svg { position: absolute; left: 13px; top: 50%; width: 17px; height: 17px; color: var(--muted); transform: translateY(-50%); pointer-events: none; }
.developer-search-input input { min-height: 48px; padding-left: 42px; font-size: 14px; }
.developer-search-results { min-height: 0; overflow: auto; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.developer-search-meta { padding: 9px 12px; border-bottom: 1px solid var(--line); color: var(--muted); background: #f8fafc; font-size: 10px; }
.developer-search-results > button {
    width: 100%; min-height: 54px; padding: 9px 12px; display: grid; grid-template-columns: 28px minmax(0, 1fr) auto;
    align-items: center; gap: 9px; border: 0; border-bottom: 1px solid #edf0f5; color: var(--ink-soft); background: #fff; text-align: left; cursor: pointer;
}
.developer-search-results > button:hover { background: #f5f8ff; }
.developer-search-results > button > span { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 8px; color: var(--accent); background: var(--accent-soft); }
.developer-search-results > button svg { width: 14px; height: 14px; }
.developer-search-results p { min-width: 0; margin: 0; }
.developer-search-results strong,
.developer-search-results small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.developer-search-results strong { font-size: 11px; }
.developer-search-results small { margin-top: 3px; color: var(--muted); font: 10px/1.4 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.developer-search-results em { color: var(--muted); font-size: 9px; font-style: normal; }
.developer-history-dialog { min-height: 520px; display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 12px; }
.developer-version-list { min-height: 0; overflow: auto; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.developer-version-list article { padding: 10px; display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 7px 9px; border-bottom: 1px solid #edf0f5; }
.developer-version-list article.is-current { background: #f3f7ff; }
.developer-version-list article > span { width: 34px; height: 28px; display: grid; place-items: center; border-radius: 8px; color: var(--accent); background: var(--accent-soft); font-size: 10px; font-weight: 800; }
.developer-version-list article div { min-width: 0; }
.developer-version-list article strong,
.developer-version-list article small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.developer-version-list article strong { font-size: 10px; }
.developer-version-list article small { margin-top: 3px; color: var(--muted); font-size: 9px; }
.developer-version-list article code { grid-column: 2; color: var(--muted); font-size: 8px; }
.developer-version-list article em { grid-column: 1 / -1; color: #2e7d58; font-size: 9px; font-style: normal; font-weight: 700; }
.developer-version-list article button { grid-column: 1 / -1; min-height: 30px; border: 1px solid var(--line); border-radius: 8px; color: var(--ink-soft); background: #fff; font-size: 9px; cursor: pointer; }
.developer-version-list article button svg { width: 12px; height: 12px; }
.developer-diff-section { min-width: 0; min-height: 0; display: grid; grid-template-rows: auto minmax(0, 1fr); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: #fff; }
.developer-diff-section > header { padding: 9px 10px; display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; border-bottom: 1px solid var(--line); background: #f8fafc; }
.developer-diff-section > header > div { display: flex; gap: 8px; }
.developer-diff-section label { display: grid; gap: 4px; color: var(--muted); font-size: 8px; font-weight: 700; text-transform: uppercase; }
.developer-diff-section select { min-width: 92px; min-height: 32px; padding: 4px 26px 4px 8px; font-size: 10px; }
.developer-diff-section > header > span { color: var(--muted); font: 10px ui-monospace, monospace; }
.developer-diff-view { min-height: 0; overflow: auto; background: #fbfcfe; }
.developer-diff-view > div[class^="is-"] { min-height: 24px; display: grid; grid-template-columns: 44px 44px minmax(0, 1fr); border-bottom: 1px solid #f0f2f5; }
.developer-diff-view > div[class^="is-"] > span { padding: 4px 6px; color: #9aa3b3; border-right: 1px solid #edf0f5; background: #f6f8fb; text-align: right; font: 9px/1.6 ui-monospace, monospace; }
.developer-diff-view code { padding: 4px 10px; overflow-wrap: anywhere; white-space: pre-wrap; color: #283249; font: 10px/1.6 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.developer-diff-view .is-add code { background: #eaf8ef; }
.developer-diff-view .is-remove code { background: #fff0f0; }
.developer-diff-view .is-add > span { background: #e1f5e8; }
.developer-diff-view .is-remove > span { background: #ffe8e8; }
.developer-diff-view footer { padding: 10px; color: var(--muted); font-size: 9px; }
.developer-preview-notice { margin-bottom: 10px; padding: 10px 12px; display: flex; align-items: center; gap: 8px; border: 1px solid #dbe5fb; border-radius: 11px; color: #40506f; background: #f3f7ff; font-size: 10px; }
.developer-preview-notice svg { width: 15px; height: 15px; color: var(--accent); }
.developer-live-preview.developer-project-preview,
.developer-live-preview.developer-build-preview { width: 100%; min-height: 60vh; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.developer-manifest-dialog { display: grid; gap: 10px; }
.developer-manifest-dialog > header { padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: #f8fafc; }
.developer-manifest-dialog > header > div { display: flex; align-items: center; gap: 10px; }
.developer-manifest-dialog > header span { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; color: var(--accent); background: var(--accent-soft); }
.developer-manifest-dialog > header p { margin: 0; }
.developer-manifest-dialog > header strong,
.developer-manifest-dialog > header small { display: block; }
.developer-manifest-dialog > header small { margin-top: 3px; color: var(--muted); font-size: 10px; }
.developer-manifest-list { max-height: 46vh; overflow: auto; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.developer-manifest-list > div { min-height: 46px; padding: 8px 10px; display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; align-items: center; gap: 9px; border-bottom: 1px solid #edf0f5; }
.developer-manifest-list > div > span { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 8px; color: var(--accent); background: var(--accent-soft); }
.developer-manifest-list svg { width: 14px; height: 14px; }
.developer-manifest-list p { min-width: 0; margin: 0; }
.developer-manifest-list strong,
.developer-manifest-list small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.developer-manifest-list strong { font-size: 10px; }
.developer-manifest-list small { margin-top: 2px; color: var(--muted); font-size: 9px; }
.developer-manifest-list code { color: var(--muted); font-size: 8px; }
.developer-build-current-actions { flex-wrap: wrap; }
.developer-build-current-actions .secondary-btn { min-height: 32px; padding-inline: 8px; }

@media (max-width: 1180px) {
    .developer-head-action { font-size: 0; width: 36px; padding: 0; justify-content: center; }
    .developer-head-action svg { width: 15px; height: 15px; }
    .developer-history-dialog { grid-template-columns: 220px minmax(0, 1fr); }
}

@media (max-width: 760px) {
    .reader-table-view { grid-template-rows: auto minmax(340px, 1fr) auto; }
    .reader-table-view > footer { align-items: flex-start; flex-direction: column; }
    .reader-table-view > footer > div { width: 100%; }
    .reader-table-view > footer button { flex: 1; }
    .developer-head-action { width: auto; padding-inline: 9px; font-size: 10px; }
    .developer-editor-tabs { min-height: 39px; }
    .developer-editor-tab { min-width: 124px; }
    .developer-history-dialog { min-height: 0; grid-template-columns: 1fr; }
    .developer-version-list { max-height: 210px; }
    .developer-diff-section { min-height: 440px; }
    .developer-search-dialog { grid-template-rows: auto minmax(300px, 62vh); }
}

@media (max-width: 430px) {
    .developer-studio-v2 .developer-build-controls { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); width: 100%; }
    .developer-studio-v2 .developer-build-controls > select { grid-column: 1 / -1; width: 100%; }
    .developer-studio-v2 .developer-build-controls .developer-build-btn { width: 100%; }
    .developer-studio-v2 .developer-runner-mini { min-width: 0; justify-content: center; }
    .developer-head-action { width: 100%; justify-content: center; }
    .developer-tree-more { opacity: 1; }
    .developer-editor-actions { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .developer-history-dialog { gap: 8px; }
    .developer-diff-section > header { align-items: stretch; flex-direction: column; }
    .developer-diff-section > header > div { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .developer-diff-section select { min-width: 0; width: 100%; }
    .developer-diff-view > div[class^="is-"] { grid-template-columns: 32px 32px minmax(0, 1fr); }
    .developer-live-preview.developer-project-preview,
    .developer-live-preview.developer-build-preview { min-height: 54vh; }
    .developer-manifest-list > div { grid-template-columns: 26px minmax(0, 1fr); }
    .developer-manifest-list code { grid-column: 2; }
    .reader-table-view > header { align-items: flex-start; }
    .reader-table-scroll th,
    .reader-table-scroll td { min-width: 112px; padding: 9px; }
}

/* v1.0.0 RC1 · LYNQ Desktop and Sync Core */
.sync-page { display: grid; gap: 22px; padding-bottom: 32px; }
.sync-page-head { align-items: flex-start; }
.sync-page-head .page-subtitle { max-width: 760px; }
.sync-hero {
    min-height: 230px; padding: 28px 34px; display: grid; grid-template-columns: minmax(240px, 36%) minmax(0, 1fr);
    align-items: center; gap: 38px; overflow: hidden; border: 1px solid #dce4f1; border-radius: 24px;
    background: linear-gradient(135deg, #f8fbff 0%, #ffffff 55%, #eef4ff 100%); box-shadow: 0 18px 46px rgba(35, 65, 122, .06);
}
.sync-hero > div:last-child > small { color: var(--accent); font-size: 10px; font-weight: 850; letter-spacing: .16em; }
.sync-hero h2 { margin: 8px 0 10px; color: var(--ink); font-size: clamp(25px, 3vw, 39px); line-height: 1.04; letter-spacing: -.035em; }
.sync-hero p { max-width: 720px; margin: 0; color: var(--muted); font-size: 13px; line-height: 1.65; }
.sync-hero-visual { position: relative; min-height: 172px; display: grid; place-items: center; }
.sync-hero-visual::before { content: ''; position: absolute; width: 158px; height: 158px; border: 1px dashed #b9c9e9; border-radius: 50%; }
.sync-hero-visual::after { content: ''; position: absolute; width: 226px; height: 112px; border: 1px solid #dbe5f7; border-radius: 50%; transform: rotate(-12deg); }
.sync-cloud { position: relative; z-index: 3; width: 84px; height: 84px; display: grid; place-items: center; border: 1px solid #d5e1f7; border-radius: 25px; color: #fff; background: linear-gradient(145deg, #416fe9, #2854cb); box-shadow: 0 20px 38px rgba(53,99,233,.25); }
.sync-cloud svg { width: 39px; height: 39px; stroke-width: 1.6; }
.sync-orbit { position: absolute; z-index: 4; width: 49px; height: 49px; display: grid; place-items: center; border: 1px solid #dce5f4; border-radius: 15px; color: var(--accent); background: #fff; box-shadow: 0 10px 25px rgba(41,67,116,.12); }
.sync-orbit svg { width: 22px; height: 22px; }
.sync-orbit-a { left: 8%; top: 22%; }
.sync-orbit-b { right: 7%; bottom: 16%; }
.sync-hero-visual i, .sync-hero-visual b { position: absolute; z-index: 2; height: 2px; width: 72px; background: linear-gradient(90deg, transparent, #8ca7df, transparent); }
.sync-hero-visual i { left: 24%; top: 39%; transform: rotate(18deg); }
.sync-hero-visual b { right: 22%; bottom: 34%; transform: rotate(18deg); }
.sync-hero-points { margin-top: 20px; display: flex; flex-wrap: wrap; gap: 8px; }
.sync-hero-points span { min-height: 31px; padding: 0 10px; display: inline-flex; align-items: center; gap: 6px; border: 1px solid #dde6f5; border-radius: 999px; color: #45536b; background: rgba(255,255,255,.82); font-size: 10px; font-weight: 750; }
.sync-hero-points svg { width: 13px; height: 13px; color: var(--accent); }
.sync-release-hash { margin-top: 12px; display: grid; grid-template-columns: auto minmax(0,1fr); align-items: center; gap: 8px; }
.sync-release-hash span { color: var(--muted); font-size: 8px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.sync-release-hash code { min-width: 0; padding: 7px 9px; overflow: hidden; border: 1px solid #e0e7f2; border-radius: 9px; color: #65728a; background: rgba(255,255,255,.75); font-size: 7px; text-overflow: ellipsis; white-space: nowrap; }
.sync-metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.sync-metrics article { min-height: 92px; padding: 17px; display: flex; align-items: center; gap: 13px; border: 1px solid var(--line); border-radius: 17px; background: #fff; }
.sync-metrics article > span { width: 42px; height: 42px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 13px; color: var(--accent); background: var(--accent-soft); }
.sync-metrics article > span svg { width: 19px; height: 19px; }
.sync-metrics article.has-alert > span { color: #bd5a23; background: #fff2e8; }
.sync-metrics strong, .sync-metrics small { display: block; }
.sync-metrics strong { color: var(--ink); font-size: 20px; letter-spacing: -.025em; }
.sync-metrics small { margin-top: 3px; color: var(--muted); font-size: 9px; }
.sync-layout { display: grid; grid-template-columns: minmax(0, 1fr) 310px; gap: 18px; align-items: start; }
.sync-section { min-width: 0; padding: 18px; border: 1px solid var(--line); border-radius: 20px; background: #fff; }
.sync-section .section-head { margin-bottom: 14px; }
.sync-section .section-head > p { margin: 0; color: var(--muted); font-size: 10px; }
.sync-device-list { display: grid; gap: 8px; }
.sync-device { min-height: 80px; padding: 13px 12px; display: grid; grid-template-columns: 48px minmax(0, 1fr) auto auto; align-items: center; gap: 12px; border: 1px solid #e3e8f0; border-radius: 15px; background: #fff; transition: border-color .18s, box-shadow .18s, transform .18s; }
.sync-device:hover { border-color: #c8d6ee; box-shadow: 0 9px 22px rgba(33,60,106,.06); transform: translateY(-1px); }
.sync-device.is-revoked { opacity: .58; background: #fafbfc; }
.sync-device-icon { position: relative; width: 45px; height: 45px; display: grid; place-items: center; border-radius: 13px; color: #53617a; background: #f1f4f9; }
.sync-device-icon svg { width: 21px; height: 21px; }
.sync-device-icon i { position: absolute; right: 1px; bottom: 1px; width: 10px; height: 10px; border: 2px solid #fff; border-radius: 50%; background: #aab2c0; }
.sync-device-icon i.is-online { background: #2fa46f; box-shadow: 0 0 0 3px rgba(47,164,111,.1); }
.sync-device-copy { min-width: 0; }
.sync-device-copy > div { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.sync-device-copy strong { max-width: 360px; overflow: hidden; color: var(--ink); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.sync-device-copy p, .sync-device-copy small { margin: 0; }
.sync-device-copy p { margin-top: 4px; color: #505c70; font-size: 10px; }
.sync-device-copy small { display: block; margin-top: 4px; overflow: hidden; color: var(--muted); font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.sync-device-status { padding: 3px 7px; border-radius: 999px; color: #6c7584; background: #f0f2f5; font-size: 8px; font-weight: 800; }
.sync-device-status.is-online { color: #207950; background: #e9f7f0; }
.sync-device-status.is-revoked { color: #974f4f; background: #faeaea; }
.sync-device-meta { display: grid; justify-items: end; gap: 5px; }
.sync-device-meta span { display: inline-flex; align-items: center; gap: 4px; color: var(--muted); font-size: 8px; font-weight: 750; }
.sync-device-meta span.has-alert { color: #b65a27; }
.sync-device-meta svg { width: 11px; height: 11px; }
.sync-device-meta code { color: #8a93a2; font-size: 7px; }
.sync-device-actions { display: flex; gap: 4px; }
.sync-device-actions .mini-btn.danger { color: #ad4b4b; }
.sync-guide { padding: 20px; border: 1px solid #d9e3f4; border-radius: 20px; background: linear-gradient(180deg, #f7faff, #fff); }
.sync-guide-head { display: flex; align-items: center; gap: 10px; }
.sync-guide-head > span { width: 39px; height: 39px; display: grid; place-items: center; border-radius: 12px; color: var(--accent); background: var(--accent-soft); }
.sync-guide-head svg { width: 18px; height: 18px; }
.sync-guide-head small, .sync-guide-head strong { display: block; }
.sync-guide-head small { color: var(--accent); font-size: 7px; font-weight: 850; letter-spacing: .12em; }
.sync-guide-head strong { margin-top: 3px; color: var(--ink); font-size: 14px; }
.sync-guide ol { margin: 20px 0; padding: 0; display: grid; gap: 14px; list-style: none; }
.sync-guide li { display: grid; grid-template-columns: 29px minmax(0, 1fr); gap: 10px; }
.sync-guide li > span { width: 29px; height: 29px; display: grid; place-items: center; border: 1px solid #d4e0f3; border-radius: 9px; color: var(--accent); background: #fff; font-size: 9px; font-weight: 850; }
.sync-guide li strong, .sync-guide li p { display: block; margin: 0; }
.sync-guide li strong { color: var(--ink-soft); font-size: 10px; }
.sync-guide li p { margin-top: 3px; color: var(--muted); font-size: 9px; line-height: 1.5; }
.sync-guide > code { display: block; padding: 10px; overflow: hidden; border: 1px solid #e1e7f0; border-radius: 10px; color: #5e6980; background: #fff; font-size: 8px; text-overflow: ellipsis; white-space: nowrap; }
.sync-empty { min-height: 250px; padding: 35px; display: grid; place-items: center; align-content: center; text-align: center; }
.sync-empty > span { width: 57px; height: 57px; display: grid; place-items: center; border-radius: 18px; color: var(--accent); background: var(--accent-soft); }
.sync-empty > span svg { width: 26px; height: 26px; }
.sync-empty h3 { margin: 13px 0 6px; color: var(--ink); font-size: 16px; }
.sync-empty p { max-width: 420px; margin: 0 0 17px; color: var(--muted); font-size: 10px; line-height: 1.55; }
.sync-empty-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.sync-cli-details { margin-top: 14px; border-top: 1px solid #e7ebf2; }
.sync-cli-details summary { padding: 12px 0 2px; color: #526078; font-size: 9px; font-weight: 800; cursor: pointer; }
.sync-cli-details[open] summary { color: var(--accent); }
.sync-conflicts { display: grid; gap: 10px; }
.sync-conflict-list { display: grid; gap: 8px; }
.sync-conflict { padding: 13px; display: grid; grid-template-columns: 39px minmax(0, 1fr) auto; align-items: center; gap: 12px; border: 1px solid #f0dccf; border-radius: 14px; background: #fffbf8; }
.sync-conflict > span { width: 39px; height: 39px; display: grid; place-items: center; border-radius: 12px; color: #b95a25; background: #fff0e6; }
.sync-conflict > span svg { width: 18px; height: 18px; }
.sync-conflict > div:nth-child(2) { min-width: 0; }
.sync-conflict > div:nth-child(2) > div { display: flex; align-items: center; flex-wrap: wrap; gap: 7px; }
.sync-conflict strong { overflow: hidden; color: var(--ink); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.sync-conflict b { padding: 3px 7px; border-radius: 999px; color: #965029; background: #ffe9dc; font-size: 7px; }
.sync-conflict p, .sync-conflict small { display: block; margin: 0; color: var(--muted); font-size: 8px; }
.sync-conflict p { margin-top: 4px; }
.sync-conflict small { margin-top: 3px; }
.sync-conflict-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 5px; }
.sync-conflict-actions button { min-height: 29px; padding: 0 9px; border: 1px solid #e4d3c9; border-radius: 8px; color: #755947; background: #fff; font-size: 8px; font-weight: 750; cursor: pointer; }
.sync-conflict-actions button.is-primary { border-color: #bfcdef; color: var(--accent); background: #f1f5ff; }
.sync-conflict-clear { min-height: 104px; display: flex; align-items: center; justify-content: center; gap: 12px; border: 1px dashed #cfe1d8; border-radius: 14px; color: #2a8057; background: #f7fcf9; }
.sync-conflict-clear > svg { width: 25px; height: 25px; }
.sync-conflict-clear strong, .sync-conflict-clear span { display: block; }
.sync-conflict-clear strong { font-size: 11px; }
.sync-conflict-clear span { margin-top: 3px; color: #658174; font-size: 9px; }
.sync-loading { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 14px; }
.sync-mode-note { padding: 12px; display: flex; gap: 9px; border: 1px solid #dce6f7; border-radius: 13px; color: #53617a; background: #f7faff; }
.sync-mode-note > svg { width: 16px; height: 16px; flex: 0 0 auto; color: var(--accent); }
.sync-mode-note strong, .sync-mode-note p { display: block; margin: 0; }
.sync-mode-note strong { font-size: 10px; }
.sync-mode-note p { margin-top: 4px; color: var(--muted); font-size: 9px; line-height: 1.5; }
.sync-token-success { padding: 15px; display: flex; align-items: center; gap: 12px; border: 1px solid #cae5d7; border-radius: 14px; background: #f4fbf7; }
.sync-token-success > span { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 13px; color: #24815a; background: #e2f5eb; }
.sync-token-success svg { width: 20px; height: 20px; }
.sync-token-success small, .sync-token-success strong, .sync-token-success p { display: block; margin: 0; }
.sync-token-success small { color: #24815a; font-size: 7px; font-weight: 850; letter-spacing: .12em; }
.sync-token-success strong { margin-top: 3px; color: var(--ink); font-size: 13px; }
.sync-token-success p { margin-top: 3px; color: var(--muted); font-size: 9px; }
.sync-secret { margin-top: 12px; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 7px; }
.sync-secret label { grid-column: 1 / -1; color: var(--muted); font-size: 8px; font-weight: 750; text-transform: uppercase; }
.sync-secret code { min-height: 44px; padding: 10px; overflow-wrap: anywhere; border: 1px solid #dfe5ef; border-radius: 10px; color: #34445e; background: #f8fafc; font-size: 9px; line-height: 1.5; }
.sync-secret button { min-width: 95px; border: 1px solid #d7e0ee; border-radius: 10px; color: var(--accent); background: #fff; font-size: 9px; font-weight: 750; cursor: pointer; }
.sync-secret button svg { width: 13px; height: 13px; }
.sync-install-steps { margin-top: 14px; display: grid; gap: 8px; }
.sync-install-steps p { margin: 0; display: flex; align-items: flex-start; gap: 8px; color: #596579; font-size: 9px; line-height: 1.5; }
.sync-install-steps p > span { width: 20px; height: 20px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 7px; color: var(--accent); background: var(--accent-soft); font-size: 8px; font-weight: 850; }
.sync-install-steps code { padding: 2px 4px; border-radius: 4px; background: #f1f4f8; font-size: 8px; }
.nav-badge.is-alert { color: #a95729; background: #fff0e6; }

@media (max-width: 1100px) {
    .sync-layout { grid-template-columns: 1fr; }
    .sync-guide { display: grid; grid-template-columns: auto minmax(0,1fr); gap: 16px; }
    .sync-guide ol { margin: 0; grid-template-columns: repeat(3, minmax(0,1fr)); }
    .sync-guide > code { grid-column: 1 / -1; }
}

@media (max-width: 820px) {
    .sync-hero { grid-template-columns: 1fr; padding: 24px; }
    .sync-hero-visual { min-height: 140px; order: 2; }
    .sync-metrics { grid-template-columns: repeat(2, minmax(0,1fr)); }
    .sync-device { grid-template-columns: 44px minmax(0,1fr) auto; }
    .sync-device-meta { display: none; }
    .sync-conflict { grid-template-columns: 36px minmax(0,1fr); }
    .sync-conflict-actions { grid-column: 2; justify-content: flex-start; }
    .sync-guide { display: block; }
    .sync-guide ol { margin: 18px 0; grid-template-columns: 1fr; }
}

@media (max-width: 520px) {
    .sync-page { gap: 14px; }
    .sync-page-head .page-actions { width: 100%; display: grid; grid-template-columns: 1fr; }
    .sync-page-head .page-actions > * { width: 100%; justify-content: center; }
    .sync-hero { padding: 20px; border-radius: 18px; }
    .sync-hero-visual { min-height: 122px; }
    .sync-cloud { width: 68px; height: 68px; border-radius: 21px; }
    .sync-cloud svg { width: 31px; height: 31px; }
    .sync-orbit { width: 42px; height: 42px; }
    .sync-metrics { grid-template-columns: 1fr 1fr; gap: 8px; }
    .sync-metrics article { min-height: 78px; padding: 12px; }
    .sync-metrics article > span { width: 35px; height: 35px; }
    .sync-metrics strong { font-size: 16px; }
    .sync-section { padding: 13px; border-radius: 16px; }
    .sync-device { grid-template-columns: 39px minmax(0,1fr) auto; padding: 11px 9px; gap: 9px; }
    .sync-device-icon { width: 39px; height: 39px; }
    .sync-device-copy small { white-space: normal; }
    .sync-device-actions { display: grid; }
    .sync-conflict-actions button { flex: 1; }
    .sync-secret { grid-template-columns: 1fr; }
    .sync-secret button { min-height: 39px; }
}

/* v1.0.0-rc1 · LYNQ Space Desktop */
.sync-desktop-hero { grid-template-columns: minmax(330px, 42%) minmax(0, 1fr); }
.sync-desktop-preview { min-width: 0; padding: 10px 0; }
.sync-window { width: min(100%, 480px); margin: 0 auto; overflow: hidden; border: 1px solid #cfd9e9; border-radius: 18px; background: #fff; box-shadow: 0 22px 55px rgba(37,59,98,.15); transform: perspective(900px) rotateY(4deg) rotateX(1deg); }
.sync-window-bar { height: 38px; padding: 0 12px; display: flex; align-items: center; gap: 6px; border-bottom: 1px solid #e7ebf2; background: #f8fafc; }
.sync-window-bar i { width: 8px; height: 8px; border-radius: 50%; background: #d7dde7; }
.sync-window-bar i:first-child { background: #f28c86; }
.sync-window-bar i:nth-child(2) { background: #f1c36c; }
.sync-window-bar i:nth-child(3) { background: #68c48c; }
.sync-window-bar span { margin-left: auto; margin-right: auto; color: #778399; font-size: 8px; font-weight: 750; }
.sync-window-body { min-height: 172px; display: grid; grid-template-columns: 88px minmax(0,1fr); }
.sync-window-body > aside { padding: 17px 12px; display: grid; align-content: start; gap: 12px; border-right: 1px solid #edf0f5; background: #fafbfd; }
.sync-window-body > aside b { color: #20324e; font-size: 10px; letter-spacing: .08em; }
.sync-window-body > aside span { height: 7px; border-radius: 999px; background: #e5eaf2; }
.sync-window-body > aside span:nth-child(2) { width: 58px; background: #dbe6fd; }
.sync-window-body > aside span:nth-child(3) { width: 48px; }
.sync-window-body > aside span:nth-child(4) { width: 62px; }
.sync-window-body > main { padding: 20px; background: #fff; }
.sync-window-status { min-height: 54px; padding: 12px; display: flex; align-items: center; gap: 10px; border: 1px solid #d9eade; border-radius: 12px; color: #238058; background: #f6fcf8; }
.sync-window-status svg { width: 20px; height: 20px; }
.sync-window-status strong { color: #264737; font-size: 10px; }
.sync-window-cards { margin-top: 13px; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; }
.sync-window-cards i { height: 37px; border: 1px solid #e7ebf2; border-radius: 9px; background: linear-gradient(100deg,#f8fafc,#eef3fa); }
.sync-desktop-actions { margin-top: 20px; display: flex; flex-wrap: wrap; gap: 9px; }
.sync-desktop-actions .primary-btn, .sync-desktop-actions .secondary-btn { min-height: 40px; }
.sync-guide-download { min-height: 40px; padding: 0 12px; display: flex; align-items: center; justify-content: center; gap: 7px; border: 1px solid #cbd9f4; border-radius: 11px; color: var(--accent); background: #fff; font-size: 9px; font-weight: 800; text-decoration: none; }
.sync-guide-download:hover { border-color: #aebfe5; background: #f7faff; }
.sync-guide-download svg { width: 14px; height: 14px; }
.sync-guide-endpoint { margin-top: 10px; display: flex; align-items: center; gap: 6px; overflow: hidden; color: #7c8799; font-size: 8px; text-overflow: ellipsis; white-space: nowrap; }
.sync-guide-endpoint svg { width: 11px; height: 11px; flex: 0 0 auto; }
.sync-device.needs-update { border-color: #ead7ad; background: #fffdf8; }
.sync-device-copy em { display: block; margin-top: 5px; overflow: hidden; color: #b04747; font-size: 8px; font-style: normal; text-overflow: ellipsis; white-space: nowrap; }
.sync-update-badge { padding: 3px 7px; border-radius: 999px; color: #9c671b; background: #fff2d9; font-size: 7px; font-weight: 850; }
.sync-update-badge.is-blocked { color: #a54141; background: #fde9e9; }
.sync-runs { gap: 0; }
.sync-run-list { display: grid; gap: 7px; }
.sync-run { min-height: 72px; padding: 12px; display: grid; grid-template-columns: 39px minmax(0,1fr) auto; align-items: center; gap: 11px; border: 1px solid #e4e9f1; border-radius: 14px; background: #fff; }
.sync-run.is-error { border-color: #f0d1d1; background: #fffafa; }
.sync-run.is-paused { border-color: #ebdfc5; background: #fffdf8; }
.sync-run-icon { width: 39px; height: 39px; display: grid; place-items: center; border-radius: 12px; color: #25805a; background: #eaf7f0; }
.sync-run.is-error .sync-run-icon { color: #b94747; background: #fdeaea; }
.sync-run.is-paused .sync-run-icon { color: #9a6b21; background: #fff2dc; }
.sync-run-icon svg { width: 18px; height: 18px; }
.sync-run > div { min-width: 0; }
.sync-run > div > div { display: flex; align-items: center; flex-wrap: wrap; gap: 7px; }
.sync-run strong { color: var(--ink); font-size: 10px; }
.sync-run b { padding: 3px 7px; border-radius: 999px; color: #247553; background: #eaf7f0; font-size: 7px; }
.sync-run.is-error b { color: #a94545; background: #fdeaea; }
.sync-run.is-paused b { color: #8e631e; background: #fff2dc; }
.sync-run p, .sync-run small { display: block; margin: 0; overflow: hidden; color: var(--muted); font-size: 8px; text-overflow: ellipsis; white-space: nowrap; }
.sync-run p { margin-top: 5px; }
.sync-run small { margin-top: 3px; color: #ad4646; }
.sync-run > aside { display: grid; justify-items: end; gap: 2px; }
.sync-run > aside strong { font-size: 9px; }
.sync-run > aside span, .sync-run > aside small { color: var(--muted); font-size: 7px; }
.sync-cli-details { margin-top: 13px; border: 1px solid #e1e6ef; border-radius: 12px; background: #fafbfd; }
.sync-cli-details summary { min-height: 42px; padding: 0 12px; display: flex; align-items: center; gap: 7px; color: #53617a; font-size: 9px; font-weight: 750; cursor: pointer; }
.sync-cli-details summary svg { width: 14px; height: 14px; }
.sync-cli-details[open] { padding-bottom: 12px; }
.sync-cli-details .sync-secret { margin: 0 12px; }
.sync-desktop-steps strong { color: #47566d; font-size: 9px; }
@media (max-width: 900px) {
    .sync-desktop-hero { grid-template-columns: 1fr; }
    .sync-desktop-preview { order: 2; }
    .sync-window { transform: none; }
}
@media (max-width: 620px) {
    .sync-window-body { grid-template-columns: 66px minmax(0,1fr); }
    .sync-window-body > main { padding: 14px; }
    .sync-desktop-actions { display: grid; grid-template-columns: 1fr; }
    .sync-desktop-actions > * { width: 100%; justify-content: center; }
    .sync-run { grid-template-columns: 35px minmax(0,1fr); }
    .sync-run > aside { grid-column: 2; display: flex; justify-content: flex-start; gap: 8px; }
}


/* v0.9.0 · Code Intelligence */
.developer-side-tabs { min-height: 43px; display: grid; grid-template-columns: 1fr 1fr; gap: 3px; padding: 5px; border-bottom: 1px solid #e6ebf2; background: #f8fafc; }
.developer-side-tabs button { min-width: 0; min-height: 33px; padding: 0 8px; display: flex; align-items: center; justify-content: center; gap: 6px; border: 0; border-radius: 8px; color: #708096; background: transparent; font-size: 8px; font-weight: 800; cursor: pointer; }
.developer-side-tabs button svg { width: 13px; height: 13px; }
.developer-side-tabs button.is-active { color: var(--accent); background: #fff; box-shadow: 0 1px 4px rgba(32,50,78,.08); }
.developer-side-tabs button b { min-width: 17px; height: 17px; padding: 0 4px; display: grid; place-items: center; border-radius: 999px; color: #fff; background: #d94f4f; font-size: 7px; }
.developer-side-tabs button i { width: 6px; height: 6px; border-radius: 50%; background: #3b72e8; box-shadow: 0 0 0 3px #e9efff; }
.developer-side-content { min-height: 0; display: flex; flex: 1; flex-direction: column; overflow: hidden; }
.developer-side-content > .developer-panel-head { flex: 0 0 auto; }
.developer-problems-head button svg { width: 13px; height: 13px; }
.developer-problems-summary { padding: 10px; display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 6px; border-bottom: 1px solid #edf0f5; }
.developer-problems-summary > div { min-height: 50px; padding: 8px; display: flex; flex-direction: column; justify-content: center; border: 1px solid #e5eaf2; border-radius: 10px; background: #fafbfd; }
.developer-problems-summary strong { color: #26364f; font-size: 15px; line-height: 1; }
.developer-problems-summary small { margin-top: 4px; color: var(--muted); font-size: 7px; }
.developer-problems-summary .is-error { border-color: #f3d5d5; background: #fff8f8; }
.developer-problems-summary .is-error strong { color: #c43d3d; }
.developer-problems-summary .is-warning { border-color: #f3dfbd; background: #fffbf3; }
.developer-problems-summary .is-warning strong { color: #aa6a18; }
.developer-diagnostics-run { margin: 10px 10px 4px; min-height: 34px; justify-content: center; }
.developer-diagnostics-run svg { width: 13px; height: 13px; }
.developer-problems-list { min-height: 0; padding: 6px 8px 10px; display: flex; flex: 1; flex-direction: column; gap: 3px; overflow: auto; }
.developer-problem-row { width: 100%; padding: 8px; display: grid; grid-template-columns: 22px minmax(0,1fr); gap: 7px; border: 0; border-radius: 8px; text-align: left; background: transparent; cursor: pointer; }
.developer-problem-row:hover { background: #f5f7fb; }
.developer-problem-row > span:first-child { width: 22px; height: 22px; display: grid; place-items: center; border-radius: 7px; }
.developer-problem-row > span:first-child svg { width: 12px; height: 12px; }
.developer-problem-row strong, .developer-problem-row small { display: block; }
.developer-problem-row strong { overflow: hidden; color: #3b4657; font-size: 8px; line-height: 1.35; text-overflow: ellipsis; white-space: normal; }
.developer-problem-row small { margin-top: 3px; overflow: hidden; color: #8a95a7; font-size: 7px; line-height: 1.35; text-overflow: ellipsis; white-space: nowrap; }
.developer-problem-row.is-error > span:first-child { color: #c83e3e; background: #fff0f0; }
.developer-problem-row.is-warning > span:first-child { color: #a66a18; background: #fff6e7; }
.developer-problem-row.is-info > span:first-child, .developer-problem-row.is-hint > span:first-child { color: #3f6fc9; background: #edf3ff; }
.developer-problems-clean > span { color: #2b8a5d; background: #eaf8f1; }
.developer-problems-foot { padding: 8px 10px; display: flex; align-items: center; justify-content: space-between; gap: 8px; border-top: 1px solid #edf0f5; color: #7d899a; background: #fafbfd; font-size: 7px; }
.developer-problems-foot span { display: flex; align-items: center; gap: 5px; }
.developer-problems-foot svg { width: 11px; height: 11px; color: #3a70d5; }
.developer-tree-diagnostic { min-width: 15px; height: 15px; margin-left: auto; padding: 0 4px; display: inline-grid; place-items: center; flex: 0 0 auto; border-radius: 999px; font-size: 7px; font-style: normal; }
.developer-tree-diagnostic.is-error { color: #fff; background: #d74b4b; }
.developer-tree-diagnostic.is-warning { color: #fff; background: #c78324; }
.developer-tree-diagnostic.is-pending { width: 8px; min-width: 8px; height: 8px; padding: 0; background: #4d78d6; box-shadow: 0 0 0 3px #eaf0ff; animation: developer-pulse 1.4s ease-in-out infinite; }
@keyframes developer-pulse { 50% { opacity: .35; transform: scale(.8); } }
.developer-editor-diagnostic { min-height: 20px; padding: 0 6px; display: inline-flex; align-items: center; gap: 4px; border: 0; border-radius: 6px; font: inherit; font-size: 7px; }
button.developer-editor-diagnostic { cursor: pointer; }
.developer-editor-diagnostic svg { width: 10px; height: 10px; }
.developer-editor-diagnostic.is-error { color: #b43b3b; background: #fff0f0; }
.developer-editor-diagnostic.is-warning { color: #966018; background: #fff6e6; }
.developer-editor-diagnostic.is-clean { color: #267853; background: #eaf8f1; }
.developer-editor-diagnostic.is-pending { color: #3b68bd; background: #edf3ff; }
.developer-editor-diagnostic.is-pending svg, .is-spinning svg { animation: spin .9s linear infinite; }
.developer-editor-diagnostic.is-muted { color: #8490a1; background: #f2f4f7; }

@media (max-width: 920px) {
    .developer-side-tabs { position: sticky; top: 0; z-index: 2; }
    .developer-problems-list { max-height: 340px; }
}

@media (max-width: 520px) {
    .developer-problems-summary { grid-template-columns: repeat(3,minmax(0,1fr)); padding: 8px; }
    .developer-problems-summary > div { min-height: 45px; padding: 7px; }
    .developer-problems-summary strong { font-size: 13px; }
    .developer-problem-row { padding: 9px 7px; }
    .developer-problems-foot { align-items: flex-start; flex-direction: column; }
}

/* v1.0.0-rc2 · Account security, recovery and onboarding */
.field-label-row { display:flex; align-items:center; justify-content:space-between; gap:12px; }
.field-label-row label { margin:0; }
.field-link, .auth-back { padding:0; border:0; color:var(--accent); background:transparent; font:inherit; font-size:9px; font-weight:800; cursor:pointer; }
.auth-back { margin:0 0 18px; display:inline-flex; align-items:center; gap:6px; color:#68758a; }
.auth-back svg { width:13px; height:13px; }
.password-hint { margin-top:6px; display:block; color:#8791a2; font-size:8px; line-height:1.5; }
.auth-token-status { min-height:42px; padding:11px 12px; display:flex; align-items:center; gap:8px; border:1px solid #dfe5ed; border-radius:11px; color:#657287; background:#f8fafc; font-size:9px; font-weight:700; }
.auth-token-status svg { width:15px; height:15px; flex:0 0 auto; }
.auth-token-status.is-valid { border-color:#cce8db; color:#267555; background:#f1faf6; }
.auth-token-status.is-invalid { border-color:#f0d1d1; color:#ae4141; background:#fff7f7; }
.auth-success-symbol, .two-factor-symbol { width:52px; height:52px; margin:0 0 18px; display:grid; place-items:center; border-radius:16px; color:var(--accent); background:#edf3ff; }
.auth-success-symbol svg, .two-factor-symbol svg { width:23px; height:23px; }
.auth-card--two-factor strong { color:#3f4a5c; }
.two-factor-input { letter-spacing:.08em; font-variant-numeric:tabular-nums; }
.auth-reset-demo-link, .auth-full-button { width:100%; margin-top:14px; justify-content:center; text-decoration:none; }

.account-center-loading { min-height:430px; display:grid; place-content:center; justify-items:center; gap:14px; color:var(--muted); }
.account-center { min-height:570px; display:grid; grid-template-columns:230px minmax(0,1fr); margin:-20px; }
.account-center-nav { min-width:0; padding:18px 12px; display:flex; flex-direction:column; gap:5px; border-right:1px solid #e8ecf2; background:#f8fafc; }
.account-identity { min-height:68px; margin:0 4px 14px; padding:8px; display:flex; align-items:center; gap:10px; border-bottom:1px solid #e5eaf1; }
.account-identity .user-avatar { width:39px; height:39px; flex:0 0 auto; }
.account-identity span:last-child { min-width:0; }
.account-identity strong, .account-identity small { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.account-identity strong { color:var(--ink); font-size:10px; }
.account-identity small { margin-top:3px; color:var(--muted); font-size:8px; }
.account-center-nav > button { width:100%; min-height:48px; padding:8px 10px; display:grid; grid-template-columns:19px minmax(0,1fr) auto; align-items:center; gap:9px; border:0; border-radius:11px; color:#66758b; text-align:left; background:transparent; cursor:pointer; }
.account-center-nav > button:hover { background:#eef2f7; }
.account-center-nav > button.is-active { color:#284f9f; background:#eaf1ff; }
.account-center-nav > button > svg { width:17px; height:17px; }
.account-center-nav > button span { min-width:0; }
.account-center-nav > button strong, .account-center-nav > button small { display:block; }
.account-center-nav > button strong { color:inherit; font-size:9px; }
.account-center-nav > button small { margin-top:2px; color:#8995a6; font-size:7px; }
.account-nav-dot { width:7px; height:7px; border-radius:50%; background:#d1d7e0; }
.account-nav-dot.is-safe { background:#2a9a69; box-shadow:0 0 0 3px #e2f5ed; }
.account-center-nav-spacer { flex:1; }
.account-center-nav .account-logout-nav { color:#a34242; }
.account-center-content { min-width:0; padding:26px 28px 30px; overflow:auto; background:#fff; }
.account-panel { display:none; }
.account-panel.is-active { display:block; animation:account-panel-in .18s ease-out; }
@keyframes account-panel-in { from { opacity:.3; transform:translateY(3px); } to { opacity:1; transform:none; } }
.account-panel-head { min-height:67px; margin-bottom:22px; display:flex; align-items:flex-start; justify-content:space-between; gap:18px; }
.account-panel-head h3 { margin:3px 0 5px; color:var(--ink); font-size:24px; letter-spacing:-.035em; }
.account-panel-head p { max-width:560px; margin:0; color:var(--muted); font-size:9px; line-height:1.55; }
.account-plan, .security-score { min-height:30px; padding:0 10px; display:inline-flex; align-items:center; gap:6px; border:1px solid #dfe5ed; border-radius:999px; color:#657287; background:#fafbfd; font-size:8px; font-weight:800; white-space:nowrap; }
.security-score svg { width:13px; height:13px; }
.security-score.is-strong { border-color:#cce8db; color:#267555; background:#eff9f4; }
.account-form { width:min(520px,100%); }
.account-form-submit { width:max-content; margin-top:4px; }
.security-grid { display:grid; grid-template-columns:1fr 1fr; gap:14px; }
.security-card { min-width:0; padding:18px; border:1px solid #e2e7ee; border-radius:16px; background:#fff; box-shadow:0 4px 15px rgba(33,48,74,.035); }
.security-card-head { display:flex; align-items:center; gap:11px; margin-bottom:16px; }
.security-card-head > span:last-child { min-width:0; }
.security-card-head strong, .security-card-head small { display:block; }
.security-card-head strong { color:#344157; font-size:10px; }
.security-card-head small { margin-top:3px; color:var(--muted); font-size:8px; line-height:1.4; }
.security-card-icon { width:38px; height:38px; display:grid; place-items:center; flex:0 0 auto; border-radius:12px; color:#5270a8; background:#edf2fa; }
.security-card-icon.is-safe { color:#25805a; background:#e9f7f0; }
.security-card-icon svg { width:18px; height:18px; }
.compact-form { gap:10px; }
.compact-form .field { gap:5px; }
.compact-form .field-input { min-height:39px; }
.security-card-copy { margin:0 0 16px; color:#727f91; font-size:9px; line-height:1.6; }
.security-status-row { min-height:42px; padding:10px 11px; display:flex; align-items:center; gap:7px; border:1px solid #d8eadf; border-radius:11px; background:#f3faf6; }
.security-status-row strong { color:#297759; font-size:9px; }
.security-status-row small { margin-left:auto; color:#769184; font-size:7px; }
.security-details { margin-top:10px; border:1px solid #e3e7ed; border-radius:11px; overflow:hidden; }
.security-details summary { min-height:39px; padding:0 11px; display:flex; align-items:center; color:#53647d; background:#fafbfd; font-size:8px; font-weight:800; cursor:pointer; }
.security-details[open] { padding-bottom:12px; }
.security-details form { padding:11px 11px 0; }
.security-details--danger summary { color:#a64b4b; background:#fffafa; }
.two-factor-setup { margin-top:15px; padding-top:15px; display:grid; gap:11px; border-top:1px solid #e7ebf1; }
.two-factor-setup-step { display:flex; align-items:flex-start; gap:9px; }
.two-factor-setup-step > b { width:24px; height:24px; display:grid; place-items:center; flex:0 0 auto; border-radius:8px; color:#fff; background:var(--accent); font-size:8px; }
.two-factor-setup-step strong, .two-factor-setup-step small { display:block; }
.two-factor-setup-step strong { color:#3c485a; font-size:9px; }
.two-factor-setup-step small { margin-top:3px; color:var(--muted); font-size:8px; line-height:1.45; }
.two-factor-uri { min-height:39px; padding:0 10px; display:flex; align-items:center; justify-content:center; gap:7px; border:1px solid #cdd9f0; border-radius:10px; color:var(--accent); text-decoration:none; font-size:8px; font-weight:850; background:#f8faff; }
.two-factor-uri svg { width:14px; height:14px; }
.two-factor-secret { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:7px; }
.two-factor-secret code { min-width:0; padding:10px; overflow-wrap:anywhere; border:1px dashed #cbd5e4; border-radius:10px; color:#3a4a63; background:#f8fafc; font-size:9px; letter-spacing:.08em; }
.session-list, .security-event-list { display:grid; gap:8px; }
.session-row { min-height:78px; padding:13px; display:grid; grid-template-columns:42px minmax(0,1fr) auto; align-items:center; gap:12px; border:1px solid #e3e8ef; border-radius:14px; background:#fff; }
.session-row.is-current { border-color:#cddbf7; background:#f8faff; }
.session-row.is-revoked { opacity:.62; background:#fafafa; }
.session-device-icon { width:42px; height:42px; display:grid; place-items:center; border-radius:13px; color:#4d699d; background:#edf2fa; }
.session-device-icon svg { width:19px; height:19px; }
.session-row > div { min-width:0; }
.session-row-title { display:flex; align-items:center; flex-wrap:wrap; gap:7px; }
.session-row-title strong { color:#344054; font-size:9px; }
.session-row-title b { padding:3px 7px; border-radius:999px; color:#315da9; background:#e8efff; font-size:7px; }
.session-row-title b.is-muted { color:#737c8a; background:#eceff3; }
.session-row p, .session-row small { margin:0; display:block; overflow:hidden; color:var(--muted); text-overflow:ellipsis; white-space:nowrap; }
.session-row p { margin-top:5px; font-size:8px; }
.session-row small { margin-top:3px; font-size:7px; }
.danger-text-btn { min-height:32px; padding:0 9px; border:1px solid #efcece; border-radius:9px; color:#ab4242; background:#fffafa; font-size:8px; font-weight:800; cursor:pointer; }
.security-event-row { min-height:57px; padding:11px 12px; display:grid; grid-template-columns:34px minmax(0,1fr); align-items:center; gap:10px; border:1px solid #e4e8ef; border-radius:12px; }
.security-event-row > span { width:34px; height:34px; display:grid; place-items:center; border-radius:10px; color:#62738d; background:#f0f3f7; }
.security-event-row > span svg { width:16px; height:16px; }
.security-event-row strong, .security-event-row small { display:block; }
.security-event-row strong { color:#3b4759; font-size:9px; }
.security-event-row small { margin-top:3px; color:var(--muted); font-size:7px; }
.security-event-row.is-secure > span { color:#277a57; background:#eaf7f0; }
.security-event-row.is-danger > span { color:#b64343; background:#fcecec; }
.compact-empty { min-height:220px; }
.recovery-warning { padding:14px; display:flex; align-items:flex-start; gap:11px; border:1px solid #f0d6a5; border-radius:13px; color:#755318; background:#fff9ed; }
.recovery-warning > svg { width:20px; height:20px; flex:0 0 auto; }
.recovery-warning strong { display:block; font-size:10px; }
.recovery-warning p { margin:4px 0 0; font-size:8px; line-height:1.5; }
.recovery-code-grid { margin-top:14px; display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; }
.recovery-code-grid code { min-height:40px; padding:0 10px; display:flex; align-items:center; justify-content:center; border:1px solid #dfe4ec; border-radius:10px; color:#334155; background:#f8fafc; font-size:10px; font-weight:800; letter-spacing:.08em; }

.onboarding-hero { padding:20px; display:flex; align-items:center; gap:17px; border:1px solid #dbe5f7; border-radius:17px; background:linear-gradient(135deg,#f7faff,#edf4ff); }
.onboarding-hero-mark { width:56px; height:56px; position:relative; display:block; flex:0 0 auto; border-radius:17px; background:#fff; box-shadow:0 9px 28px rgba(43,82,150,.14); }
.onboarding-hero-mark i,.onboarding-hero-mark b,.onboarding-hero-mark em { position:absolute; display:block; border-radius:999px; background:var(--accent); }
.onboarding-hero-mark i { width:23px; height:9px; left:12px; top:14px; transform:rotate(35deg); }
.onboarding-hero-mark b { width:28px; height:9px; right:8px; top:25px; transform:rotate(-35deg); }
.onboarding-hero-mark em { width:20px; height:9px; left:15px; bottom:11px; transform:rotate(35deg); }
.onboarding-hero h3 { margin:3px 0 5px; color:var(--ink); font-size:22px; letter-spacing:-.035em; }
.onboarding-hero p { margin:0; color:#6f7c90; font-size:9px; line-height:1.55; }
.onboarding-actions { margin-top:14px; display:grid; grid-template-columns:1fr 1fr; gap:9px; }
.onboarding-actions > button { min-height:91px; padding:14px; display:grid; grid-template-columns:35px minmax(0,1fr) 16px; align-items:center; gap:11px; border:1px solid #e0e5ed; border-radius:14px; color:#52627a; text-align:left; background:#fff; cursor:pointer; transition:.16s; }
.onboarding-actions > button:hover { border-color:#bfcdec; transform:translateY(-1px); box-shadow:0 8px 22px rgba(33,55,91,.07); }
.onboarding-actions > button > svg:first-child { width:35px; height:35px; padding:8px; border-radius:11px; color:var(--accent); background:#edf3ff; }
.onboarding-actions > button > svg:last-child { width:15px; height:15px; }
.onboarding-actions strong, .onboarding-actions small { display:block; }
.onboarding-actions strong { color:#334155; font-size:9px; }
.onboarding-actions small { margin-top:4px; color:#7d899b; font-size:8px; line-height:1.45; }
.onboarding-safety { margin-top:10px; padding:12px 13px; display:grid; grid-template-columns:32px minmax(0,1fr) auto; align-items:center; gap:10px; border:1px solid #d8eadf; border-radius:13px; background:#f4fbf7; }
.onboarding-safety > svg { width:32px; height:32px; padding:7px; border-radius:10px; color:#267b58; background:#e3f5eb; }
.onboarding-safety strong, .onboarding-safety small { display:block; }
.onboarding-safety strong { color:#32634f; font-size:9px; }
.onboarding-safety small { margin-top:3px; color:#72897d; font-size:8px; }
.onboarding-safety button { border:0; color:#287655; background:transparent; font-size:8px; font-weight:850; cursor:pointer; }
.onboarding-footnote { margin-right:auto; color:var(--muted); font-size:8px; }

@media (max-width: 780px) {
    .account-center { min-height:0; grid-template-columns:1fr; margin:-16px; }
    .account-center-nav { padding:10px; display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); border-right:0; border-bottom:1px solid #e8ecf2; overflow-x:auto; }
    .account-identity, .account-center-nav-spacer, .account-center-nav .account-logout-nav { display:none; }
    .account-center-nav > button { min-width:78px; min-height:48px; padding:7px; display:flex; flex-direction:column; justify-content:center; gap:4px; text-align:center; }
    .account-center-nav > button > svg { width:15px; height:15px; }
    .account-center-nav > button small, .account-nav-dot { display:none; }
    .account-center-content { padding:20px 16px 24px; }
    .security-grid { grid-template-columns:1fr; }
    .account-panel-head { align-items:flex-start; flex-direction:column; }
    .session-row { grid-template-columns:38px minmax(0,1fr); }
    .session-row > button { grid-column:2; width:max-content; }
    .recovery-code-grid, .onboarding-actions { grid-template-columns:1fr; }
    .onboarding-safety { grid-template-columns:30px minmax(0,1fr); }
    .onboarding-safety button { grid-column:2; width:max-content; padding:0; }
}

@media (max-width: 480px) {
    .auth-card { padding-left:21px; padding-right:21px; }
    .account-center-nav { grid-template-columns:repeat(4,82px); }
    .account-panel-head h3 { font-size:21px; }
    .security-card { padding:14px; }
    .two-factor-secret { grid-template-columns:1fr; }
    .recovery-code-grid code { font-size:9px; }
    .onboarding-hero { align-items:flex-start; padding:16px; }
    .onboarding-hero-mark { width:48px; height:48px; }
}

/* v1.0.0-rc3 · Passkeys and verified email */
.auth-choice { margin:14px 0 10px; display:flex; align-items:center; gap:10px; color:#98a2b3; font-size:8px; font-weight:800; text-transform:uppercase; letter-spacing:.08em; }
.auth-choice::before,.auth-choice::after { height:1px; flex:1; content:""; background:#e5e9f0; }
.auth-passkey { width:100%; min-height:58px; padding:10px 12px; display:grid; grid-template-columns:35px minmax(0,1fr) 15px; align-items:center; gap:10px; border:1px solid #cfdaf0; border-radius:13px; color:#34568f; text-align:left; background:#f8faff; cursor:pointer; transition:.16s ease; }
.auth-passkey:hover { border-color:#9db3dc; background:#f1f6ff; transform:translateY(-1px); box-shadow:0 7px 20px rgba(52,86,143,.08); }
.auth-passkey:disabled { opacity:.62; cursor:wait; transform:none; }
.auth-passkey > svg:first-child { width:35px; height:35px; padding:8px; border-radius:11px; color:#315da9; background:#e6efff; }
.auth-passkey > svg:last-child { width:15px; height:15px; }
.auth-passkey strong,.auth-passkey small { display:block; }
.auth-passkey strong { color:#30496f; font-size:9px; }
.auth-passkey small { margin-top:3px; color:#78879c; font-size:7px; line-height:1.35; }
.account-email-card { width:min(720px,100%); min-height:76px; margin-top:22px; padding:13px; display:grid; grid-template-columns:42px minmax(0,1fr) auto; align-items:center; gap:12px; border:1px solid #efd8b1; border-radius:14px; background:#fffaf1; }
.account-email-card.is-verified { border-color:#cde6da; background:#f3faf6; }
.account-email-icon { width:42px; height:42px; display:grid; place-items:center; border-radius:13px; color:#9b681f; background:#fff0d5; }
.account-email-card.is-verified .account-email-icon { color:#247656; background:#e2f4ea; }
.account-email-icon svg { width:19px; height:19px; }
.account-email-title { display:flex; align-items:center; flex-wrap:wrap; gap:7px; }
.account-email-title strong { color:#344054; font-size:9px; }
.account-email-title b { padding:3px 7px; border-radius:999px; color:#98651d; background:#ffebc8; font-size:7px; }
.account-email-card.is-verified .account-email-title b { color:#287557; background:#daf0e4; }
.account-email-card p { margin:5px 0 0; color:#7c8797; font-size:8px; }
.email-change-pending { width:min(720px,100%); margin-top:10px; padding:12px 13px; display:grid; grid-template-columns:30px minmax(0,1fr) auto; align-items:center; gap:10px; border:1px solid #d8e1f2; border-radius:13px; color:#4f6590; background:#f5f8ff; }
.email-change-pending > svg { width:30px; height:30px; padding:7px; border-radius:10px; background:#e6edfb; }
.email-change-pending strong,.email-change-pending p { display:block; }
.email-change-pending strong { color:#3a4d71; font-size:9px; }
.email-change-pending p { margin:4px 0 0; color:#78869c; font-size:8px; }
.email-change-details { width:min(720px,100%); margin-top:10px; border:1px solid #e1e6ee; border-radius:13px; overflow:hidden; }
.email-change-details > summary { min-height:45px; padding:0 13px; display:flex; align-items:center; gap:8px; color:#52627a; background:#fafbfd; font-size:9px; font-weight:850; cursor:pointer; }
.email-change-details > summary svg { width:14px; height:14px; }
.email-change-details[open] { padding-bottom:14px; }
.email-change-details form { width:min(520px,100%); padding:14px 14px 0; }
.form-note { margin:0; color:#8490a1; font-size:7px; line-height:1.55; }
.security-card--passkeys { grid-column:1 / -1; }
.passkey-list { display:grid; gap:7px; }
.passkey-row { min-height:62px; padding:9px; display:grid; grid-template-columns:36px minmax(0,1fr) auto; align-items:center; gap:10px; border:1px solid #e4e9f0; border-radius:12px; background:#fbfcfe; }
.passkey-row-icon { width:36px; height:36px; display:grid; place-items:center; border-radius:11px; color:#315fae; background:#e9f1ff; }
.passkey-row-icon svg { width:17px; height:17px; }
.passkey-row strong,.passkey-row p,.passkey-row small { display:block; }
.passkey-row strong { color:#344054; font-size:9px; }
.passkey-row p { margin:3px 0 0; color:#68778e; font-size:8px; }
.passkey-row small { margin-top:3px; color:#929baa; font-size:7px; }
.passkey-row-actions { display:flex; gap:5px; }
.passkey-row-actions .icon-btn { width:30px; height:30px; }
.passkey-row-actions .icon-btn.is-danger { color:#ad4949; }
.passkey-empty,.passkey-unavailable { min-height:62px; padding:11px; display:flex; align-items:center; gap:10px; border:1px dashed #d9e0ea; border-radius:12px; color:#78869a; background:#fafbfd; }
.passkey-empty > svg,.passkey-unavailable > svg { width:30px; height:30px; padding:7px; flex:0 0 auto; border-radius:10px; color:#4e6d9f; background:#edf2fa; }
.passkey-empty strong,.passkey-empty p,.passkey-unavailable strong,.passkey-unavailable small { display:block; }
.passkey-empty strong,.passkey-unavailable strong { color:#45546b; font-size:9px; }
.passkey-empty p,.passkey-unavailable small { margin:3px 0 0; color:#8490a2; font-size:8px; line-height:1.4; }
.passkey-add-details { margin-top:9px; }
@media (max-width:780px) {
    .account-email-card { grid-template-columns:38px minmax(0,1fr); }
    .account-email-card > button { grid-column:2; width:max-content; }
    .email-change-pending { grid-template-columns:28px minmax(0,1fr); }
    .email-change-pending > button { grid-column:2; width:max-content; }
    .passkey-row { grid-template-columns:34px minmax(0,1fr); }
    .passkey-row-actions { grid-column:2; }
}
@media (max-width:480px) {
    .auth-passkey { grid-template-columns:32px minmax(0,1fr) 14px; }
    .auth-passkey > svg:first-child { width:32px; height:32px; }
    .account-email-title { align-items:flex-start; flex-direction:column; }
}
