:root {
    --ink: #14261f;
    --forest: #0d3b2e;
    --forest-2: #165241;
    --sage: #e8efe6;
    --sage-2: #f0f5ee;
    --cream: #f7f4ec;
    --paper: #fffdf8;
    --gold: #c8a96a;
    --gold-soft: #efe3c8;
    --line: #dde5dd;
    --muted: #6b7a72;
    --danger: #a33a2b;
    --danger-soft: #f8e7e2;
    --warn: #8a6a1f;
    --warn-soft: #fbf2dc;
    --ok: #2e6b4f;
    --ok-soft: #e3f1e8;
    --shadow: 0 18px 45px rgba(16, 48, 37, .08);
    --radius: 16px;
    --sans: "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, Arial, sans-serif;
    --serif: Georgia, "Times New Roman", serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    background: var(--cream);
    color: var(--ink);
    font-family: var(--sans);
    font-size: 15px;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
}
a { color: var(--forest-2); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--forest); }
img { max-width: 100%; display: block; }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 600; line-height: 1.18; color: var(--ink); margin: 0 0 .5rem; }
h1 { font-size: clamp(1.9rem, 3vw, 2.7rem); letter-spacing: -.03em; }
h2 { font-size: clamp(1.35rem, 2vw, 1.8rem); letter-spacing: -.02em; }
h3 { font-size: 1.15rem; }
p { margin: 0 0 .8rem; }
small, .small { font-size: .82rem; }
.muted { color: var(--muted); }
.tiny { font-size: .74rem; }
.mono { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: .86em; }
.skip-link { position: absolute; left: -999px; top: 8px; background: var(--forest); color: #fff; padding: 10px 16px; z-index: 9999; border-radius: 8px; }
.skip-link:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

/* shell */
.app-shell { display: grid; grid-template-columns: 262px minmax(0, 1fr); min-height: 100vh; }
.sidebar {
    background: radial-gradient(circle at 20% 0%, #17503f 0%, var(--forest) 45%, #082a20 100%);
    color: #e9f1ea;
    padding: 26px 18px;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
}
.brand { display: flex; gap: 10px; align-items: center; color: #fff; text-decoration: none; margin-bottom: 6px; }
.brand:hover { color: #fff; }
.brand-mark {
    width: 40px; height: 40px; display: grid; place-items: center; border-radius: 12px;
    background: var(--gold); color: #14261f; font-family: var(--serif); font-weight: 700; font-size: 1.35rem;
}
.brand-name { font-family: var(--serif); font-size: 1.35rem; letter-spacing: .06em; line-height: 1; }
.brand-sub { display: block; font-family: var(--sans); font-size: .66rem; letter-spacing: .12em; text-transform: uppercase; color: #a9c2b5; margin-top: 4px; }
.sidebar-context { border-top: 1px solid rgba(255,255,255,.12); border-bottom: 1px solid rgba(255,255,255,.12); padding: 14px 2px; margin: 20px 0 16px; }
.sidebar-context .label { color: #9db8aa; font-size: .68rem; text-transform: uppercase; letter-spacing: .12em; }
.sidebar-context .value { color: #fff; font-size: .9rem; margin-top: 2px; }
.sidebar nav { display: grid; gap: 3px; }
.nav-link {
    display: flex; align-items: center; gap: 11px; padding: 10px 12px; border-radius: 10px;
    color: #c8d9cf; text-decoration: none; font-size: .88rem; transition: background .15s, color .15s;
}
.nav-link .ico { width: 19px; text-align: center; opacity: .85; }
.nav-link:hover { background: rgba(255,255,255,.08); color: #fff; }
.nav-link.active { background: rgba(200,169,106,.18); color: #fff; box-shadow: inset 3px 0 0 var(--gold); }
.nav-section { color: #8fa99c; text-transform: uppercase; font-size: .64rem; letter-spacing: .15em; padding: 16px 12px 5px; }
.sidebar-foot { margin-top: 26px; font-size: .7rem; color: #8fa99c; line-height: 1.5; }
.sidebar-foot .dot { color: #75b08d; }
.main-wrap { display: flex; flex-direction: column; min-width: 0; }
.topbar {
    display: flex; align-items: center; justify-content: space-between; gap: 18px;
    padding: 16px 34px; background: rgba(247,244,236,.88); backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 40;
}
.topbar .crumb { color: var(--muted); font-size: .78rem; letter-spacing: .04em; }
.topbar .crumb strong { color: var(--ink); font-weight: 600; }
.topbar-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.main { padding: 30px 34px 60px; max-width: 1440px; width: 100%; margin: 0 auto; flex: 1; }
.app-footer { padding: 16px 34px 26px; color: #8a968f; font-size: .72rem; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

/* page headers */
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; margin-bottom: 22px; flex-wrap: wrap; }
.page-head p { max-width: 720px; color: var(--muted); margin: 4px 0 0; }
.eyebrow { text-transform: uppercase; letter-spacing: .16em; font-size: .68rem; color: var(--forest-2); font-weight: 700; margin-bottom: 6px; }
.section-title { display: flex; align-items: center; gap: 10px; margin: 28px 0 12px; }
.section-title h2, .section-title h3 { margin: 0; }

/* cards & grids */
.card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; box-shadow: 0 6px 20px rgba(16,48,37,.035); }
.card.flush { padding: 0; overflow: hidden; }
.card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 14px; }
.card-head h3 { margin: 0; }
.grid { display: grid; gap: 18px; }
.grid.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid.side { grid-template-columns: minmax(0, 1fr) 340px; align-items: start; }
.stack { display: grid; gap: 12px; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.spacer { flex: 1; }
.divider { height: 1px; background: var(--line); margin: 16px 0; }

/* hero */
.hero { background: linear-gradient(120deg, #0d3b2e 0%, #165241 58%, #2e6b55 100%); color: #fff; border-radius: 22px; padding: 34px; position: relative; overflow: hidden; }
.hero:after { content: ""; position: absolute; width: 360px; height: 360px; border-radius: 50%; right: -100px; top: -160px; background: rgba(200,169,106,.15); }
.hero h1, .hero h2 { color: #fff; }
.hero p { color: #d7e4db; max-width: 720px; }
.hero .eyebrow { color: var(--gold); }
.hero-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; position: relative; z-index: 1; }
.hero-stats { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 1px; background: rgba(255,255,255,.12); border-radius: 14px; overflow: hidden; margin-top: 26px; position: relative; z-index: 1; }
.hero-stat { background: rgba(8,42,32,.35); padding: 14px 16px; }
.hero-stat .v { font-size: 1.35rem; font-weight: 700; color: #fff; }
.hero-stat .k { color: #b9cec2; font-size: .72rem; text-transform: uppercase; letter-spacing: .1em; }

/* buttons */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 7px;
    border: 1px solid transparent; border-radius: 10px; padding: 10px 16px;
    background: var(--forest); color: #fff; font-family: var(--sans); font-weight: 600; font-size: .86rem;
    cursor: pointer; text-decoration: none; transition: transform .12s, background .12s, box-shadow .12s;
    line-height: 1.2;
}
.btn:hover { background: var(--forest-2); color: #fff; transform: translateY(-1px); }
.btn:disabled, .btn.disabled { opacity: .5; cursor: not-allowed; transform: none; }
.btn.gold { background: var(--gold); color: #1b2a22; }
.btn.gold:hover { background: #d8bc80; color: #1b2a22; }
.btn.ghost { background: transparent; border-color: #b9c8be; color: var(--forest); }
.btn.ghost:hover { background: var(--sage); color: var(--forest); }
.btn.light { background: #fff; border-color: var(--line); color: var(--ink); }
.btn.light:hover { background: var(--sage-2); color: var(--ink); }
.btn.danger { background: var(--danger); }
.btn.danger:hover { background: #8b2f22; }
.btn.sm { padding: 7px 11px; font-size: .78rem; border-radius: 8px; }
.btn.lg { padding: 14px 22px; font-size: .95rem; border-radius: 12px; }
.btn.block { width: 100%; }
.btn-link { border: 0; background: none; color: var(--forest-2); text-decoration: underline; cursor: pointer; padding: 0; font: inherit; }

/* badges */
.badge { display: inline-flex; align-items: center; gap: 5px; border-radius: 999px; padding: 3px 9px; font-size: .72rem; font-weight: 700; letter-spacing: .02em; background: var(--sage); color: var(--forest); white-space: nowrap; }
.badge.ok { background: var(--ok-soft); color: var(--ok); }
.badge.warn { background: var(--warn-soft); color: var(--warn); }
.badge.danger { background: var(--danger-soft); color: var(--danger); }
.badge.gold { background: var(--gold-soft); color: #6b5321; }
.badge.muted { background: #eef1ee; color: #65736b; }
.badge.outline { background: transparent; border: 1px solid var(--line); color: var(--muted); }
.pill-row { display: flex; gap: 6px; flex-wrap: wrap; }

/* forms */
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.form-grid .full { grid-column: 1 / -1; }
.form-grid.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.field label, .label { display: block; font-size: .78rem; font-weight: 700; color: #3d4d44; margin-bottom: 5px; letter-spacing: .01em; }
.field .hint { color: var(--muted); font-size: .74rem; margin-top: 4px; }
input:not([type]), input[type=text], input[type=email], input[type=password], input[type=number], input[type=date], input[type=time], input[type=search], select, textarea {
    width: 100%; border: 1px solid #cfd9d1; background: #fff; color: var(--ink);
    border-radius: 9px; padding: 10px 12px; font-family: var(--sans); font-size: .88rem; min-height: 42px;
    transition: border .12s, box-shadow .12s;
}
input:focus, select:focus, textarea:focus { border-color: var(--forest-2); box-shadow: 0 0 0 3px rgba(22,82,65,.12); outline: none; }
textarea { min-height: 100px; resize: vertical; }
input[type=checkbox], input[type=radio] { width: 16px; height: 16px; accent-color: var(--forest); vertical-align: -2px; }
.checkline { display: flex; gap: 9px; align-items: flex-start; font-size: .86rem; color: #3d4d44; }
.checkline input { margin-top: 3px; }
.invalid { border-color: var(--danger) !important; }
.error-text { color: var(--danger); font-size: .77rem; margin-top: 4px; }
fieldset { border: 1px solid var(--line); border-radius: 12px; padding: 18px; margin: 0 0 18px; }
legend { font-weight: 700; font-size: .85rem; color: var(--forest); padding: 0 6px; }
.help-btn { width: 19px; height: 19px; border-radius: 50%; border: 1px solid #a8bcaf; background: #fff; color: var(--forest); font-size: .72rem; font-weight: 700; cursor: pointer; display: inline-grid; place-items: center; padding: 0; vertical-align: 1px; }
.help-btn:hover { background: var(--sage); }
.help-dialog { border: 0; border-radius: 16px; padding: 0; max-width: 560px; width: calc(100% - 32px); box-shadow: var(--shadow); }
.help-dialog::backdrop { background: rgba(8,30,23,.45); backdrop-filter: blur(2px); }
.help-dialog-inner { padding: 24px; }
.help-dialog h3 { margin-bottom: 6px; }
.help-dialog .summary { color: var(--forest-2); font-weight: 600; }
.help-dialog .detail { white-space: pre-line; color: #44534b; margin-top: 12px; border-top: 1px solid var(--line); padding-top: 12px; }

/* tables */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
table.data { width: 100%; border-collapse: collapse; font-size: .84rem; }
table.data th { text-align: left; background: #f3f6f1; color: #58675e; font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; padding: 11px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
table.data td { padding: 11px 12px; border-bottom: 1px solid #eef1ed; vertical-align: top; }
table.data tr:last-child td { border-bottom: 0; }
table.data tr:hover td { background: #fbfcf9; }
table.data .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
table.data .actions { display: flex; gap: 6px; flex-wrap: wrap; }

/* proposal cards */
.proposal-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 18px; }
.proposal-card { background: var(--paper); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; display: flex; flex-direction: column; position: relative; }
.proposal-card .img { height: 150px; background: var(--sage); overflow: hidden; }
.proposal-card .img img { width: 100%; height: 100%; object-fit: cover; }
.proposal-card .body { padding: 18px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.proposal-card h3 { margin: 0; }
.proposal-card .tagline { color: var(--muted); font-size: .82rem; }
.proposal-card .price { font-size: 1.45rem; font-weight: 700; color: var(--forest); font-variant-numeric: tabular-nums; }
.proposal-card .price small { font-size: .72rem; color: var(--muted); font-weight: 400; }
.proposal-card .foot { margin-top: auto; display: flex; gap: 8px; align-items: center; padding-top: 10px; }
.proposal-card.selected { border-color: var(--gold); box-shadow: 0 0 0 3px var(--gold-soft); }
.proposal-card .ribbon { position: absolute; top: 12px; left: 12px; }

/* workspace */
.mode-bar { display: flex; gap: 5px; flex-wrap: wrap; background: #ecefe8; padding: 4px; border-radius: 11px; }
.mode-link { padding: 7px 11px; border-radius: 8px; text-decoration: none; color: #5d6b63; font-size: .78rem; font-weight: 600; }
.mode-link:hover { background: #fff; color: var(--forest); }
.mode-link.active { background: var(--forest); color: #fff; }
.workspace { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 22px; align-items: start; }
.day-card { background: var(--paper); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; margin-bottom: 16px; }
.day-card-head { display: flex; gap: 14px; padding: 14px 18px; background: #f4f7f1; border-bottom: 1px solid var(--line); align-items: flex-start; }
.day-num { background: var(--forest); color: #fff; width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; font-family: var(--serif); font-size: 1.05rem; flex: 0 0 auto; }
.day-card-head h3 { margin: 0; font-size: 1.15rem; }
.day-card-body { padding: 14px 18px 18px; }
.day-img { height: 120px; width: 100%; object-fit: cover; border-radius: 10px; margin-bottom: 10px; }
.block-row { display: flex; gap: 10px; align-items: flex-start; padding: 10px 0; border-top: 1px solid #eef1ed; }
.block-row:first-child { border-top: 0; }
.block-time { flex: 0 0 86px; font-size: .72rem; color: var(--muted); font-variant-numeric: tabular-nums; padding-top: 2px; }
.block-main { flex: 1; min-width: 0; }
.block-main .title { font-weight: 600; }
.block-tools { display: flex; gap: 4px; flex-wrap: wrap; }
.icon-btn { border: 1px solid var(--line); background: #fff; border-radius: 7px; padding: 4px 7px; font-size: .72rem; cursor: pointer; color: #4d5d54; }
.icon-btn:hover { background: var(--sage); }
.day-foot { display: flex; justify-content: space-between; gap: 10px; padding-top: 10px; border-top: 1px solid var(--line); font-size: .78rem; color: var(--muted); flex-wrap: wrap; }
.sidebar-card { background: var(--paper); border: 1px solid var(--line); border-radius: 16px; padding: 18px; margin-bottom: 16px; }
.sidebar-card h3 { font-size: 1rem; }
.price-big { font-size: 2rem; font-weight: 700; color: var(--forest); font-family: var(--serif); font-variant-numeric: tabular-nums; }
.price-sub { color: var(--muted); font-size: .78rem; }
.kv { display: flex; justify-content: space-between; gap: 10px; padding: 6px 0; border-bottom: 1px dashed #e6ebe5; font-size: .82rem; }
.kv:last-child { border-bottom: 0; }
.kv .k { color: var(--muted); }
.kv .v { font-weight: 600; text-align: right; }
.alert { border-radius: 11px; padding: 11px 14px; font-size: .84rem; border: 1px solid; margin-bottom: 12px; }
.alert.info { background: #eef5f1; border-color: #cfe2d6; color: #2c5b46; }
.alert.warn { background: var(--warn-soft); border-color: #ead8ae; color: #6b5528; }
.alert.danger { background: var(--danger-soft); border-color: #ecc8c0; color: #7d2a1f; }
.alert.ok { background: var(--ok-soft); border-color: #c4e0d0; color: var(--ok); }

/* guided / visual / board / professional / conversational */
.guided-steps { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; margin-bottom: 20px; }
.guided-step { background: #eef2ea; border-radius: 10px; padding: 10px 12px; font-size: .75rem; color: #5c6b62; }
.guided-step strong { display: block; color: var(--forest); font-size: .8rem; margin-bottom: 2px; }
.guided-step.done { background: var(--ok-soft); color: var(--ok); }
.visual-hero { display: grid; grid-template-columns: 1.3fr 1fr; gap: 18px; margin-bottom: 18px; }
.visual-hero .img { border-radius: 18px; overflow: hidden; min-height: 280px; background: var(--sage); }
.visual-hero .img img { width: 100%; height: 100%; object-fit: cover; }
.board { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(250px, 1fr); gap: 12px; overflow-x: auto; padding-bottom: 8px; }
.board-col { background: #f1f4ee; border-radius: 14px; padding: 12px; min-height: 220px; }
.board-col h4 { margin: 0 0 8px; font-size: .85rem; color: var(--forest); }
.board-item { background: #fff; border: 1px solid var(--line); border-radius: 9px; padding: 9px; margin-bottom: 7px; font-size: .78rem; }
.pro-table { font-size: .8rem; }
.pro-table td { padding: 8px 9px; }
.pro-table .money { font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; }
.chat { display: grid; gap: 12px; }
.chat-msg { max-width: 82%; padding: 12px 15px; border-radius: 14px; font-size: .88rem; }
.chat-msg.assistant { background: var(--sage-2); border: 1px solid var(--line); border-bottom-left-radius: 4px; }
.chat-msg.user { background: var(--forest); color: #fff; margin-left: auto; border-bottom-right-radius: 4px; }
.chat-msg .who { font-size: .66rem; text-transform: uppercase; letter-spacing: .1em; opacity: .7; margin-bottom: 3px; }

/* install / auth */
.guest-shell { min-height: 100vh; display: grid; grid-template-columns: 1.05fr .95fr; background: var(--cream); }
.guest-aside { background: radial-gradient(circle at 20% 10%, #1f5e4a, #0d3b2e 55%, #082a20); color: #fff; padding: 54px; display: flex; flex-direction: column; justify-content: space-between; }
.guest-aside h1 { color: #fff; font-size: clamp(2rem, 4vw, 3.2rem); }
.guest-aside p { color: #cfe0d6; max-width: 480px; }
.guest-main { display: grid; place-items: center; padding: 40px 24px; }
.auth-card { width: 100%; max-width: 430px; background: var(--paper); border: 1px solid var(--line); border-radius: 20px; padding: 34px; box-shadow: var(--shadow); }
.install-card { width: 100%; max-width: 860px; }
.checklist { display: grid; gap: 8px; }
.check { display: flex; gap: 10px; align-items: flex-start; padding: 9px 11px; border: 1px solid var(--line); border-radius: 9px; background: #fff; font-size: .84rem; }
.check .state { width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; font-size: .7rem; font-weight: 700; flex: 0 0 auto; }
.check .state.ok { background: var(--ok-soft); color: var(--ok); }
.check .state.fail { background: var(--danger-soft); color: var(--danger); }

/* catalog */
.catalog-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }
.catalog-card { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 14px; }
.catalog-card h4 { margin: 0 0 4px; }
.catalog-card .meta { color: var(--muted); font-size: .78rem; }
.thumb { width: 100%; height: 110px; object-fit: cover; border-radius: 8px; margin-bottom: 8px; background: var(--sage); }
.stat { background: var(--paper); border: 1px solid var(--line); border-radius: 13px; padding: 16px; }
.stat .v { font-size: 1.7rem; font-weight: 700; color: var(--forest); font-family: var(--serif); }
.stat .k { font-size: .74rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }

/* public proposal */
.public-shell { background: #f2f1eb; min-height: 100vh; padding: 26px 14px 60px; }
.public-doc { max-width: 920px; margin: 0 auto; background: #fff; border-radius: 8px; box-shadow: 0 20px 60px rgba(20,38,31,.12); overflow: hidden; }
.public-head { background: var(--forest); color: #fff; padding: 30px 38px; }
.public-head h1 { color: #fff; }
.public-body { padding: 30px 38px 42px; }
.public-day { border-top: 1px solid var(--line); padding: 18px 0; }
.public-day h3 { margin: 2px 0; }
.public-day .day-label { color: var(--muted); font-size: .72rem; text-transform: uppercase; letter-spacing: .1em; }
.public-price { background: var(--sage-2); border: 1px solid var(--line); border-radius: 12px; padding: 20px; margin-top: 22px; }
.public-price .amount { font-size: 2rem; font-weight: 700; color: var(--forest); font-family: var(--serif); }
.public-actions { display: flex; gap: 10px; flex-wrap: wrap; margin: 16px 0; }
@media print {
    .public-shell { background: #fff; padding: 0; }
    .public-doc { box-shadow: none; max-width: none; }
    .no-print { display: none !important; }
}

/* misc */
.empty { text-align: center; padding: 40px 20px; color: var(--muted); }
.empty h3 { color: var(--ink); }
.progress { height: 8px; background: #e8ede7; border-radius: 999px; overflow: hidden; }
.progress span { display: block; height: 100%; background: var(--forest); border-radius: 999px; }
.timeline { border-left: 2px solid var(--line); margin-left: 8px; padding-left: 16px; }
.timeline-item { position: relative; padding-bottom: 14px; }
.timeline-item:before { content: ""; position: absolute; left: -23px; top: 5px; width: 9px; height: 9px; border-radius: 50%; background: var(--gold); border: 2px solid #fff; box-shadow: 0 0 0 1px var(--line); }
.trace-step { background: #fbfcf9; border: 1px solid var(--line); border-radius: 9px; padding: 10px 12px; margin-bottom: 8px; font-size: .8rem; }
.trace-line { display: grid; grid-template-columns: 1fr auto auto; gap: 8px; padding: 7px 0; border-bottom: 1px dashed #e6ebe5; font-size: .8rem; }
.flash-stack { position: fixed; right: 20px; top: 80px; z-index: 100; display: grid; gap: 8px; max-width: 420px; }
.flash { background: #fff; border: 1px solid var(--line); border-left: 4px solid var(--ok); border-radius: 9px; padding: 11px 14px; box-shadow: var(--shadow); font-size: .84rem; }
.flash.error { border-left-color: var(--danger); }
.flash.warning { border-left-color: var(--warn); }
.modal-form { max-width: 720px; }

@media (max-width: 1100px) {
    .grid.side, .workspace { grid-template-columns: 1fr; }
    .visual-hero { grid-template-columns: 1fr; }
    .hero-stats { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 900px) {
    .app-shell { grid-template-columns: 1fr; }
    .sidebar { position: static; height: auto; padding: 16px; }
    .sidebar nav { grid-template-columns: repeat(2, minmax(0,1fr)); }
    .sidebar-foot, .sidebar-context { display: none; }
    .nav-section { grid-column: 1 / -1; padding: 10px 6px 2px; }
    .main { padding: 22px 18px 46px; }
    .topbar { padding: 12px 18px; }
    .guest-shell { grid-template-columns: 1fr; }
    .guest-aside { padding: 32px; min-height: 240px; }
    .form-grid, .form-grid.cols-3 { grid-template-columns: 1fr; }
    .grid.cols-2, .grid.cols-3, .grid.cols-4 { grid-template-columns: 1fr; }
    .guided-steps { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
    .page-head { align-items: flex-start; }
    .hero { padding: 24px; }
    .card { padding: 16px; }
    .sidebar nav { grid-template-columns: 1fr; }
    .topbar-actions .btn span.long { display: none; }
}
