:root {
    --bg: #f2f0e8;
    --surface: #ffffff;
    --surface-2: #fbfaf5;
    --surface-3: #f4f2ea;
    --border: #e5e2d6;
    --border-strong: #d8d4c4;
    --ink: #16201a;
    --ink-2: #5a645d;
    --ink-3: #8c948c;
    --green-950: #101e16;
    --green-900: #15271c;
    --green-800: #1c3527;
    --green-700: #244732;
    --green-500: #3e7a55;
    --green-soft: #e4ede6;
    --green-ink: #2c5b3f;
    --gold: #c6a15b;
    --gold-600: #b68f45;
    --gold-soft: #f0e3c4;
    --gold-ink: #7a6126;
    --tg: #229ed9;
    --tg-soft: #e1f1fa;
    --discord: #5865f2;
    --discord-soft: #e8eafd;
    --sell: #c24a3e;
    --sell-soft: #f8e6e3;
    --radius: 16px;
    --radius-sm: 11px;
    --radius-lg: 22px;
    --shadow-sm: 0 1px 2px rgba(20, 30, 22, .05), 0 1px 1px rgba(20, 30, 22, .04);
    --shadow: 0 4px 18px -6px rgba(20, 30, 22, .12), 0 2px 6px -3px rgba(20, 30, 22, .08);
    --shadow-lg: 0 24px 60px -20px rgba(16, 30, 22, .28);
    --sans: "SamsungOne", "Samsung Sharp Sans", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
    --display: "Samsung Sharp Sans", "SamsungOne", "Inter", var(--sans);
    --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
    --sidebar-w: 248px;
}

* {
    box-sizing: border-box;
}

html,
body {
    min-height: 100%;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font-family: var(--sans);
    font-size: 15px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

a {
    color: var(--green-ink);
    text-decoration: none;
}

button,
input,
select,
textarea {
    font: inherit;
}

div,
section,
article,
p,
span,
a,
small,
strong,
label,
legend,
th,
td {
    font-family: var(--sans);
}

button {
    border: 0;
}

::selection {
    background: var(--gold-soft);
}

.app {
    display: flex;
    min-height: 100vh;
}

.menu-toggle,
.menu-backdrop,
.hamburger {
    display: none;
}

.sidebar {
    width: var(--sidebar-w);
    flex: 0 0 var(--sidebar-w);
    position: sticky;
    top: 0;
    height: 100vh;
    display: flex;
    flex-direction: column;
    padding: 22px 16px 16px;
    border-right: 1px solid rgba(0, 0, 0, .2);
    background: linear-gradient(180deg, var(--green-950), var(--green-900));
    color: #d7e0d9;
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 4px 8px 22px;
    color: inherit;
}

.brand-mark {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    border-radius: 12px;
    background: linear-gradient(150deg, var(--gold), #9c7b33);
    color: #241b06;
    box-shadow: 0 6px 16px -6px rgba(198, 161, 91, .7);
    font-family: var(--display);
    font-size: 22px;
    font-weight: 800;
}

.brand-name,
.brand-sub {
    display: block;
}

.brand-name {
    color: #fff;
    font-family: var(--display);
    font-size: 16px;
    font-weight: 800;
    line-height: 1.1;
}

.brand-sub {
    color: #8fa396;
    font-size: 11.5px;
    letter-spacing: .3px;
}

.nav {
    display: flex;
    flex-direction: column;
    gap: 3px;
    margin-top: 6px;
}

.nav-label {
    padding: 14px 12px 6px;
    color: #6e8378;
    font-family: var(--sans);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .16em;
    text-transform: uppercase;
}

.nav-item {
    position: relative;
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 9px 12px;
    border-radius: 11px;
    color: #b9c6bc;
    font-size: 14.5px;
    font-weight: 500;
    transition: .15s;
}

.nav-badge {
    min-width: 22px;
    height: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-left: auto;
    padding: 0 7px;
    border-radius: 999px;
    background: var(--gold);
    color: #201704;
    font-size: 12px;
    font-weight: 800;
    line-height: 1;
}

.nav-icon {
    width: 18px;
    height: 18px;
    color: #d4ddd6;
    flex: 0 0 auto;
}

.nav-icon svg,
.icon-btn svg {
    width: 18px;
    height: 18px;
    display: block;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.nav-item:hover {
    background: rgba(255, 255, 255, .06);
    color: #eaf0eb;
}

.nav-item.active {
    background: rgba(198, 161, 91, .16);
    color: #fff;
}

.nav-item.active::before {
    content: "";
    position: absolute;
    left: -16px;
    top: 8px;
    bottom: 8px;
    width: 3px;
    border-radius: 0 3px 3px 0;
    background: var(--gold);
}

.nav-item.active .nav-icon {
    color: var(--gold-soft);
}

.bot-status {
    margin-top: auto;
    padding: 13px 14px;
    border: 1px solid rgba(255, 255, 255, .07);
    border-radius: 14px;
    background: rgba(255, 255, 255, .04);
}

.bot-status h4 {
    margin: 0 0 10px;
    color: #7e927f;
    font-family: var(--sans);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
}

.bot-row {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 5px 0;
    color: #c2cec4;
    font-size: 12.5px;
}

.bot-row .dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #2c8a5b;
    box-shadow: 0 0 0 3px rgba(44, 138, 91, .22);
}

.bot-row .ms {
    margin-left: auto;
    color: #7e927f;
    font-family: var(--sans);
    font-size: 11px;
}

.bot-platform {
    width: 14px;
    height: 14px;
    display: block;
    fill: currentColor;
}

.bot-platform.tg {
    color: var(--tg);
}

.bot-platform.dc {
    color: var(--discord);
}

.sidebar-footer {
    display: grid;
    gap: 8px;
    margin-top: 14px;
    padding: 0 8px;
    font-size: 13px;
}

.sidebar-footer a {
    color: #c8d0c5;
}

.main {
    min-width: 0;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.topbar {
    position: sticky;
    top: 0;
    z-index: 30;
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 14px 32px;
    border-bottom: 1px solid var(--border);
    background: rgba(242, 240, 232, .82);
    backdrop-filter: blur(12px);
}

.hamburger {
    width: 38px;
    height: 38px;
    place-items: center;
    gap: 4px;
    border: 1px solid var(--border);
    border-radius: 11px;
    background: var(--surface);
    color: var(--ink);
    cursor: pointer;
}

.hamburger span {
    width: 17px;
    height: 2px;
    display: block;
    border-radius: 999px;
    background: currentColor;
}

.crumb {
    color: var(--ink-3);
    font-family: var(--sans);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    white-space: nowrap;
}

.crumb b {
    color: var(--ink-2);
    font-weight: 500;
}

.topbar-spacer {
    flex: 1;
}

.icon-btn,
.avatar {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: 11px;
}

.icon-btn {
    position: relative;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--ink-2);
    transition: .15s;
}

.icon-btn:hover {
    border-color: var(--border-strong);
    color: var(--ink);
}

.icon-btn .ind {
    position: absolute;
    top: 8px;
    right: 9px;
    width: 7px;
    height: 7px;
    border: 2px solid var(--surface);
    border-radius: 50%;
    background: var(--gold);
}

.avatar {
    background: var(--green-700);
    color: #eaf0eb;
    font-family: var(--display);
    font-size: 14px;
    font-weight: 600;
}

.shell {
    width: 100%;
    max-width: 1400px;
    padding: 28px 32px 56px;
}

.page-head {
    position: relative;
    display: flex;
    align-items: flex-end;
    gap: 24px;
    margin-bottom: 22px;
    padding: 30px 32px;
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, .2);
    border-radius: var(--radius-lg);
    background:
        radial-gradient(60% 90% at 96% 120%, rgba(198, 161, 91, .22), transparent 60%),
        radial-gradient(120% 140% at 88% 0%, #2c5b3f 0%, #193024 46%, #101e16 100%);
    color: #fff;
}

.page-head::before {
    content: "";
    position: absolute;
    inset: 0;
    opacity: .05;
    background-image:
        linear-gradient(rgba(255, 255, 255, .7) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, .7) 1px, transparent 1px);
    background-size: 40px 40px;
    pointer-events: none;
}

.page-head.compact {
    align-items: center;
    min-height: 112px;
    background: var(--surface);
    color: var(--ink);
    box-shadow: var(--shadow-sm);
}

.page-head.compact::before {
    display: none;
}

.page-head > * {
    position: relative;
}

.page-head > .actions,
.page-head > .button {
    margin-left: auto;
}

.page-head h1,
.login-panel h1 {
    margin: 0;
    font-family: var(--display);
    font-size: 40px;
    font-weight: 800;
    line-height: 1.02;
    letter-spacing: 0;
}

.page-head.compact h1 {
    font-size: 28px;
}

.page-head p,
.muted {
    max-width: 650px;
    margin: 12px 0 0;
    color: #b7c8bd;
    font-size: 14.5px;
}

.page-head.compact p {
    margin-top: 2px;
    color: var(--ink-2);
}

.hero-pills {
    position: relative;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 20px;
}

.live-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 30px;
    padding: 6px 13px 6px 11px;
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 30px;
    background: rgba(255, 255, 255, .07);
    color: #d8e4db;
    font-size: 12.5px;
    font-weight: 600;
}

.live-pill .dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #5fd18c;
    box-shadow: 0 0 0 3px rgba(95, 209, 140, .25);
}

.live-pill svg {
    width: 15px;
    height: 15px;
    display: block;
    fill: currentColor;
}

.live-pill.tg {
    color: #aee2f8;
}

.live-pill.dc {
    color: #cdd1ff;
}

.eyebrow {
    margin: 0 0 12px;
    color: var(--gold);
    font-family: var(--sans);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .2em;
    text-transform: uppercase;
}

.actions,
.form-actions,
.row-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.button {
    min-height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 0 16px;
    border: 1px solid transparent;
    border-radius: 11px;
    cursor: pointer;
    font-size: 13.5px;
    font-weight: 700;
    white-space: nowrap;
    transition: .15s;
}

.button.primary {
    background: var(--gold);
    color: #231a05;
    box-shadow: 0 6px 16px -8px rgba(198, 161, 91, .9);
}

.button.primary:hover {
    background: var(--gold-600);
}

.button.ghost {
    border-color: var(--border);
    background: var(--surface);
    color: var(--ink);
}

.button.ghost:hover {
    border-color: var(--border-strong);
    background: var(--surface-2);
}

.page-head:not(.compact) .button.ghost {
    border-color: rgba(255, 255, 255, .18);
    background: rgba(255, 255, 255, .1);
    color: #fff;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 14px;
    margin-bottom: 22px;
}

.stat,
.panel,
.table-wrap,
.catalog-item,
.notice-row,
.form-grid,
.login-panel,
.request-card,
.preview {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow-sm);
}

.stat {
    min-height: 118px;
    padding: 16px 17px;
    transition: .18s;
    position: relative;
    overflow: hidden;
}

.stat:hover {
    transform: translateY(-2px);
    border-color: var(--border-strong);
    box-shadow: var(--shadow);
}

.stat-top {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
}

.stat-ico {
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    border-radius: 9px;
    background: var(--surface-3);
    color: var(--ink-2);
}

.stat-ico svg,
.platform svg,
.platform-chip svg,
.channel-logo svg {
    width: 16px;
    height: 16px;
    display: block;
    fill: currentColor;
}

.stat-ico svg {
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.stat-ico.tg {
    background: var(--tg-soft);
    color: var(--tg);
}

.stat-ico.dc {
    background: var(--discord-soft);
    color: var(--discord);
}

.stat-ico.tg svg,
.stat-ico.dc svg {
    fill: currentColor;
    stroke: none;
}

.stat-ico.gold {
    background: var(--gold-soft);
    color: var(--gold-ink);
}

.stat-ico.green {
    background: var(--green-soft);
    color: var(--green-ink);
}

.stat-label,
table small,
.catalog-item small,
.notice-row small,
.mini-row small {
    display: block;
    color: var(--ink-3);
    font-size: 12px;
}

.stat strong {
    display: block;
    margin-top: 14px;
    font-family: var(--display);
    font-size: 30px;
    font-weight: 800;
    letter-spacing: 0;
    line-height: 1;
}

.split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
    margin-bottom: 18px;
}

.panel {
    padding: 20px;
}

.panel-head,
.catalog-title,
.request-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.panel h2,
.catalog-title h2 {
    margin: 0;
    font-family: var(--display);
    font-size: 16px;
    font-weight: 800;
}

.product-list,
.mini-table,
.notification-strip,
.catalog,
.notice-list,
.request-list {
    display: grid;
    gap: 12px;
    margin-top: 18px;
}

.product-row,
.mini-row,
.notice,
.catalog-item,
.notice-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 15px 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--surface);
    transition: .15s;
}

.dashboard-product {
    align-items: flex-start;
    gap: 12px;
}

.dashboard-product-main {
    min-width: 0;
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr);
    align-items: start;
    gap: 12px;
    flex: 1;
}

.dashboard-product-main strong,
.dashboard-notice strong {
    display: block;
    min-width: 0;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.dashboard-product-main p {
    overflow-wrap: anywhere;
    word-break: break-word;
}

.catalog-item {
    align-items: flex-start;
}

.catalog-main {
    min-width: 0;
    flex: 1;
}

.catalog-main .catalog-title {
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 8px;
}

.catalog-meta {
    line-height: 1.35;
}

.channel-note {
    width: fit-content;
    margin-top: 8px;
    padding: 5px 8px;
    border-radius: 8px;
    background: var(--sell-soft);
    color: var(--sell);
    line-height: 1.25;
}

.channel-edit {
    flex: 0 0 auto;
}

.mini-row {
    justify-content: flex-start;
}

.mini-row > span:nth-child(2) {
    min-width: 0;
    flex: 1;
}

.row-ava {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    border-radius: 11px;
    background: linear-gradient(150deg, var(--green-700), var(--green-900));
    color: #fff;
    font-family: var(--display);
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0;
    text-transform: uppercase;
}

.product-ava {
    background: var(--green-soft);
    color: var(--green-ink);
}

.cell-user {
    display: flex;
    align-items: center;
    gap: 11px;
}

.cell-user > span:last-child {
    min-width: 0;
}

.product-row:hover,
.mini-row:hover,
.notice:hover,
.catalog-item:hover,
.notice-row:hover,
.request-card:hover {
    border-color: var(--border-strong);
    box-shadow: var(--shadow);
}

.product-row p,
.notice p,
.catalog-item p,
.notice-row p,
.preview p {
    margin: 6px 0 0;
    color: var(--ink-2);
}

.notification-strip {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    align-items: stretch;
}

.notice {
    align-items: flex-start;
    min-height: 150px;
}

.dashboard-notice {
    min-width: 0;
    display: grid;
    align-content: start;
    justify-content: stretch;
    gap: 8px;
}

.dashboard-notice .status {
    width: fit-content;
}

.dashboard-notice p {
    margin: 0;
    max-width: 100%;
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.pill,
.status,
.platform {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    padding: 2px 9px;
    border-radius: 30px;
    background: var(--surface-3);
    color: var(--ink-2);
    font-family: var(--sans);
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.platform,
.platform-chip {
    gap: 6px;
}

.platform.telegram,
.platform-chip.telegram {
    border-color: transparent;
    background: var(--tg-soft);
    color: var(--tg);
}

.platform.discord,
.platform-chip.discord {
    border-color: transparent;
    background: var(--discord-soft);
    color: var(--discord);
}

.platform-chip {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    padding: 2px 8px;
    border-radius: 30px;
    font-family: var(--sans);
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    vertical-align: middle;
}

.channel-logo {
    width: 48px;
    height: 48px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    border-radius: 13px;
    color: #fff;
}

.channel-logo.telegram {
    background: linear-gradient(150deg, #3db5e8, #1e8fcb);
}

.channel-logo.discord {
    background: linear-gradient(150deg, #7984f5, #4e5ae0);
}

.channel-logo svg {
    width: 26px;
    height: 26px;
}

.status.active,
.status.sent,
.status.answered {
    background: var(--green-soft);
    color: var(--green-ink);
}

.status.lead,
.status.draft,
.status.open {
    background: var(--gold-soft);
    color: var(--gold-ink);
}

.status.trial,
.status.scheduled {
    background: var(--tg-soft);
    color: var(--tg);
}

.status.paused,
.status.cancelled {
    background: var(--sell-soft);
    color: var(--sell);
}

.filters {
    display: grid;
    grid-template-columns: minmax(240px, 1fr) 180px 180px auto;
    gap: 10px;
    margin: 18px 0;
}

input,
select,
textarea,
fieldset {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: 11px;
    background: var(--surface-2);
    color: var(--ink);
    outline: none;
}

input,
select {
    min-height: 42px;
    padding: 0 12px;
}

textarea {
    min-height: 130px;
    padding: 12px;
    resize: vertical;
}

fieldset {
    margin: 0;
    padding: 14px;
}

legend {
    padding: 0 6px;
    color: var(--ink-3);
    font-family: var(--sans);
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
}

input:focus,
select:focus,
textarea:focus {
    border-color: var(--gold);
    background: var(--surface);
    box-shadow: 0 0 0 3px rgba(198, 161, 91, .15);
}

.table-wrap {
    overflow: auto;
}

table {
    width: 100%;
    min-width: 820px;
    border-collapse: collapse;
    font-size: 14px;
}

th,
td {
    padding: 14px 18px;
    border-bottom: 1px solid var(--border);
    text-align: left;
    vertical-align: middle;
}

th {
    background: var(--surface-2);
    color: var(--ink-3);
    font-family: var(--sans);
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    white-space: nowrap;
}

tbody tr:hover {
    background: var(--surface-2);
}

tr:last-child td {
    border-bottom: 0;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    margin-top: 18px;
    padding: 22px;
}

label {
    display: grid;
    gap: 8px;
    color: var(--ink-3);
    font-family: var(--sans);
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
}

label small {
    color: var(--ink-2);
    font-family: var(--sans);
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0;
    text-transform: none;
}

.wide,
.preview {
    grid-column: 1 / -1;
}

.checkline {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 42px;
    color: var(--ink);
    font-family: var(--sans);
    font-size: 13.5px;
    font-weight: 600;
    letter-spacing: 0;
    text-transform: none;
}

.checkline input {
    width: 18px;
    min-height: 18px;
    accent-color: var(--green-700);
}

.check-group {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.form-actions {
    grid-column: 1 / -1;
}

.preview {
    padding: 16px;
    background: var(--surface-3);
}

.preview strong {
    font-family: var(--display);
    font-size: 15px;
}

.image-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.image-grid figure {
    margin: 0;
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--surface);
}

.image-grid img {
    width: 100%;
    aspect-ratio: 4 / 3;
    display: block;
    object-fit: cover;
}

.image-grid figcaption {
    padding: 8px;
    color: var(--ink-2);
    font-size: 12px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.flash-stack {
    display: grid;
    gap: 10px;
    margin-bottom: 14px;
}

.flash {
    padding: 13px 17px;
    border-radius: 13px;
    background: var(--green-900);
    color: #eaf3ec;
    box-shadow: var(--shadow-lg);
    font-size: 13.5px;
    font-weight: 600;
}

.flash.error {
    background: var(--sell-soft);
    color: var(--sell);
    box-shadow: none;
}

.request-card {
    display: grid;
    gap: 14px;
    padding: 18px;
    transition: .15s;
}

.scrollable-requests {
    max-height: calc(100vh - 260px);
    min-height: 260px;
    overflow-y: auto;
    padding-right: 4px;
}

.request-head small,
.reply-box small {
    display: block;
    margin-top: 4px;
    color: var(--ink-3);
}

.request-message {
    margin: 0;
    color: var(--ink);
    white-space: pre-wrap;
}

.reply-box {
    padding: 14px;
    border-radius: var(--radius-sm);
    background: var(--green-soft);
}

.reply-box p {
    margin: 6px 0 0;
    color: var(--ink);
    white-space: pre-wrap;
}

.attachment-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

.attachment-list strong {
    width: 100%;
    font-size: 13px;
}

.attachment-list a {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 10px;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: var(--surface);
    font-size: 13px;
    font-weight: 700;
}

.pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 16px;
}

.pagination span {
    color: var(--ink-3);
    font-size: 13px;
    font-weight: 700;
}

.button.disabled {
    pointer-events: none;
    opacity: .45;
}

.reply-form {
    display: grid;
    gap: 10px;
}

.empty,
.empty-cell {
    color: var(--ink-3);
}

.login-panel {
    width: min(480px, 100%);
    margin: 12vh auto 0;
    padding: 28px;
}

.login-panel h1 {
    color: var(--ink);
}

.login-form {
    display: grid;
    gap: 16px;
}

.login-form button {
    width: 100%;
}

.auth-page {
    min-height: 100vh;
    background:
        linear-gradient(180deg, rgba(246, 247, 244, .94), rgba(235, 239, 232, .98)),
        url("https://images.unsplash.com/photo-1642790551116-18e150f248e1?auto=format&fit=crop&w=1600&q=80") center/cover fixed;
    color: var(--ink);
}

.auth-shell {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 24px;
}

.auth-panel {
    width: min(420px, 100%);
    display: grid;
    gap: 18px;
    padding: 30px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: rgba(255, 255, 255, .92);
    box-shadow: var(--shadow-lg);
}

.auth-panel h1 {
    margin: 0;
    font-family: var(--display);
    font-size: 34px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0;
}

.auth-panel .flash-stack {
    margin: 0;
}

*::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

*::-webkit-scrollbar-thumb {
    border: 3px solid transparent;
    border-radius: 10px;
    background: var(--border-strong);
    background-clip: content-box;
}

*::-webkit-scrollbar-thumb:hover {
    background: var(--ink-3);
    background-clip: content-box;
}

.public-page {
    min-height: 100vh;
    background:
        linear-gradient(180deg, rgba(16, 30, 22, .88), rgba(16, 30, 22, .7)),
        url("https://images.unsplash.com/photo-1611974789855-9c2a0a7236a3?auto=format&fit=crop&w=1800&q=80") center/cover fixed;
    color: #eef4ef;
}

.public-shell {
    width: min(1120px, calc(100% - 36px));
    margin: 0 auto;
    padding: 58px 0;
}

.public-shell.narrow {
    width: min(720px, calc(100% - 36px));
}

.public-hero {
    max-width: 760px;
    padding: 42px 0 30px;
}

.public-hero h1 {
    margin: 0;
    color: #fff;
    font-family: var(--display);
    font-size: clamp(38px, 7vw, 74px);
    font-weight: 800;
    line-height: .98;
}

.public-hero p {
    max-width: 620px;
    margin: 18px 0 0;
    color: #d9e4dc;
    font-size: 17px;
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 16px;
}

.pricing-card,
.access-panel {
    display: grid;
    gap: 18px;
    padding: 22px;
    border: 1px solid rgba(255, 255, 255, .14);
    border-radius: var(--radius);
    background: rgba(255, 255, 255, .94);
    color: var(--ink);
    box-shadow: var(--shadow-lg);
}

.pricing-card h2,
.access-panel h2 {
    margin: 12px 0 0;
    font-family: var(--display);
    font-size: 24px;
}

.pricing-card p,
.access-panel p {
    color: var(--ink-2);
}

.pricing-card strong {
    font-size: 22px;
}

.pricing-card form {
    display: grid;
    gap: 12px;
}

.pricing-card button:disabled {
    cursor: not-allowed;
    opacity: .55;
}

.access-panel code {
    display: block;
    overflow-x: auto;
    padding: 14px;
    border-radius: 11px;
    background: var(--green-950);
    color: #e8f4ea;
    font-size: 14px;
}

.verify-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.verify-grid > div {
    display: grid;
    gap: 8px;
}

.verify-grid strong {
    font-size: 13px;
}

.public-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

@media (max-width: 1040px) {
    .app {
        display: block;
    }

    .sidebar {
        position: fixed;
        top: 0;
        bottom: 0;
        left: 0;
        z-index: 80;
        width: min(320px, calc(100vw - 52px));
        height: 100vh;
        min-height: 100vh;
        padding: 22px 16px 16px;
        transform: translateX(-105%);
        transition: transform .22s ease;
    }

    .nav {
        display: flex;
        flex-direction: column;
        gap: 3px;
        margin-top: 6px;
        overflow: visible;
    }

    .hamburger {
        display: grid;
    }

    .menu-toggle:checked ~ .sidebar {
        transform: translateX(0);
    }

    .menu-toggle:checked ~ .menu-backdrop {
        display: block;
        position: fixed;
        inset: 0;
        z-index: 70;
        background: rgba(8, 14, 10, .48);
        backdrop-filter: blur(2px);
    }

    .nav-label {
        display: none;
    }

    .nav-item {
        white-space: normal;
    }

    .topbar {
        padding: 12px 18px;
    }

    .shell {
        padding: 18px;
    }

    .split {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 760px) {
    .page-head,
    .page-head.compact {
        align-items: flex-start;
        flex-direction: column;
        padding: 22px;
    }

    .page-head h1 {
        font-size: 30px;
    }

    .stats-grid,
    .notification-strip,
    .filters,
    .form-grid,
    .check-group,
    .image-grid {
        grid-template-columns: 1fr;
    }

    .product-row,
    .mini-row,
    .notice,
    .catalog-item,
    .notice-row,
    .request-head {
        align-items: flex-start;
        flex-direction: column;
    }

    .public-shell {
        padding: 34px 0;
    }

    .verify-grid {
        grid-template-columns: 1fr;
    }
}
