:root {
    --ink: #19202a;
    --muted: #667085;
    --line: #e6e9ef;
    --paper: #ffffff;
    --soft: #f6f8fb;
    --primary: #0f766e;
    --primary-strong: #115e59;
    --accent: #eab308;
    --danger: #b42318;
}

* { box-sizing: border-box; }
body {
    margin: 0;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
    color: var(--ink);
    background: var(--soft);
}
a { color: inherit; text-decoration: none; }
h1, h2, h3, p { margin-top: 0; }
h1 { font-size: clamp(2rem, 4vw, 4.4rem); line-height: 1.02; max-width: 880px; }
h2 { font-size: 1.45rem; }
input, select, textarea {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: .82rem .9rem;
    font: inherit;
    background: #fff;
}
label { display: grid; gap: .35rem; color: var(--muted); font-size: .9rem; }
table { width: 100%; border-collapse: collapse; background: #fff; }
th, td { padding: .9rem; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
th { color: var(--muted); font-size: .78rem; text-transform: uppercase; }
small { color: var(--muted); }

.topbar {
    position: sticky;
    top: 0;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem min(5vw, 72px);
    background: rgba(255,255,255,.92);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(12px);
}
.brand { display: inline-flex; align-items: center; gap: .65rem; font-weight: 800; }
.brand span {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: 8px;
    color: #fff;
    background: var(--primary);
}
.topbar nav { display: flex; align-items: center; gap: 1rem; color: var(--muted); }
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: .72rem 1rem;
    border: 0;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 800;
    line-height: 1;
}
.btn.primary { color: #fff; background: var(--primary); }
.btn.primary:hover { background: var(--primary-strong); }
.btn.secondary { color: #12312e; background: #ccfbf1; }
.btn.ghost { color: var(--primary); background: #eefaf8; }
.btn.small { min-height: 34px; padding: .55rem .8rem; color: #fff; background: var(--ink); }
.btn.icon { width: 38px; min-height: 38px; padding: 0; color: #fff; background: var(--primary); }
.hero {
    min-height: 72vh;
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) 360px;
    gap: 2rem;
    align-items: center;
    padding: min(9vw, 110px) min(5vw, 72px);
    background:
        linear-gradient(120deg, rgba(15,118,110,.92), rgba(25,32,42,.72)),
        url("../img/print-pattern.svg");
    color: #fff;
}
.hero p { max-width: 670px; color: rgba(255,255,255,.84); font-size: 1.1rem; }
.hero-board {
    display: grid;
    gap: .8rem;
    padding: 1.2rem;
    border: 1px solid rgba(255,255,255,.28);
    border-radius: 8px;
    background: rgba(255,255,255,.12);
}
.hero-board span {
    padding: .75rem;
    border-radius: 8px;
    background: rgba(255,255,255,.12);
}
.eyebrow {
    display: inline-block;
    margin-bottom: .55rem;
    color: var(--accent);
    font-weight: 900;
    letter-spacing: 0;
    text-transform: uppercase;
    font-size: .75rem;
}
.page { padding: 4rem min(5vw, 72px); }
.section-title { display: flex; align-items: end; justify-content: space-between; gap: 1rem; margin-bottom: 1.4rem; }
.product-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1rem; }
.product-card, .metric, .panel, .auth-panel {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--paper);
    box-shadow: 0 14px 36px rgba(24, 32, 42, .06);
}
.product-card { display: grid; gap: .75rem; padding: 1rem; }
.product-card p { color: var(--muted); min-height: 58px; }
.product-art {
    display: grid;
    place-items: center;
    height: 148px;
    border-radius: 8px;
    color: #0f3b36;
    background: linear-gradient(135deg, #ccfbf1, #fde68a);
    font-size: 2.3rem;
    font-weight: 900;
}
.tag { width: fit-content; padding: .25rem .5rem; border-radius: 999px; color: var(--primary); background: #ecfdf5; font-size: .76rem; font-weight: 800; }
.footer { padding: 2rem min(5vw, 72px); color: var(--muted); background: #fff; border-top: 1px solid var(--line); }

.auth { min-height: 100vh; display: grid; place-items: center; padding: 2rem; background: linear-gradient(135deg, #f6f8fb, #dff7f2); }
.installer { width: min(100%, 860px); }
.auth-panel { width: min(100%, 720px); padding: 1.4rem; }
.auth-panel h1 { font-size: 2rem; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.wide { grid-column: 1 / -1; }
.check { display: flex; align-items: center; gap: .55rem; }
.check input { width: auto; }
.notice { margin: 0 0 1rem; padding: .85rem 1rem; border-radius: 8px; font-weight: 700; }
.notice.success { color: #065f46; background: #d1fae5; }
.notice.danger { color: var(--danger); background: #fee4e2; }

.dashboard { display: grid; grid-template-columns: 248px minmax(0, 1fr); min-height: 100vh; }
.sidebar {
    position: sticky;
    top: 0;
    height: 100vh;
    display: flex;
    flex-direction: column;
    gap: .35rem;
    padding: 1rem;
    color: #dbeafe;
    background: #19202a;
}
.sidebar a { padding: .75rem; border-radius: 8px; }
.sidebar a:hover { background: rgba(255,255,255,.08); }
.workspace { padding: 1.2rem; overflow: hidden; }
.workspace-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; }
.workspace-head h1 { font-size: 2rem; margin-bottom: 0; }
.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; margin-bottom: 1rem; }
.metric { padding: 1rem; }
.metric span { color: var(--muted); }
.metric strong { display: block; margin-top: .4rem; font-size: 1.7rem; }
.panel { padding: 1rem; margin-bottom: 1rem; }
.table-wrap { overflow-x: auto; margin-top: 1rem; border: 1px solid var(--line); border-radius: 8px; }
.quote-box { display: flex; align-items: center; justify-content: space-between; padding: 1rem; border-radius: 8px; background: #fef3c7; }
.quote-box strong { font-size: 1.5rem; }
.pix-panel { background: #ecfdf5; }
.logline { padding: .65rem 0; border-bottom: 1px solid var(--line); color: var(--muted); }

@media (max-width: 860px) {
    .hero, .dashboard { grid-template-columns: 1fr; }
    .sidebar { position: static; height: auto; }
    .metric-grid, .form-grid { grid-template-columns: 1fr; }
    .topbar { align-items: flex-start; flex-direction: column; }
    .topbar nav { flex-wrap: wrap; }
    .workspace-head, .section-title { align-items: flex-start; flex-direction: column; }
}
