:root {
    --bg: #f7f7f5;
    --surface: #ffffff;
    --text: #1d1d1f;
    --muted: #5f6368;
    --border: #e2e2de;
    --accent: #c0392b;
    --accent-soft: #fbecea;
    --ok: #1e7e34;
    --ok-soft: #e7f4ea;
    --warn: #8a5a00;
    --warn-soft: #fdf3dc;
    --error: #b3261e;
    --error-soft: #fce8e6;
    --code-bg: #f1f1ee;
    --radius: 10px;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg: #151517;
        --surface: #1f1f22;
        --text: #ececec;
        --muted: #a1a1aa;
        --border: #34343a;
        --accent: #ff6b5b;
        --accent-soft: #3a1f1c;
        --ok: #7bd389;
        --ok-soft: #1b3122;
        --warn: #f2c96d;
        --warn-soft: #3a2f16;
        --error: #ff8a80;
        --error-soft: #3b1d1b;
        --code-bg: #2a2a2e;
    }
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

code, pre, textarea.mono {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.9em;
}

code { background: var(--code-bg); padding: 0.1em 0.35em; border-radius: 4px; }

pre {
    background: var(--code-bg);
    padding: 0.9rem 1rem;
    border-radius: var(--radius);
    overflow-x: auto;
    white-space: pre-wrap;
    word-break: break-word;
}

.container { max-width: 1080px; margin: 0 auto; padding: 0 16px; }

.site-header {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 10;
}

.site-header .container {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 1.5rem;
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
}

.brand { font-weight: 700; font-size: 1.15rem; color: var(--text); }
.brand span { color: var(--accent); }

.nav { display: flex; flex-wrap: wrap; gap: 0.25rem 0.5rem; font-size: 0.95rem; }
.nav a { color: var(--muted); }
.nav a.active, .nav a:hover { color: var(--text); text-decoration: none; }
.nav { align-items: center; }
.nav .nav-contact { display: inline-block; color: #fff; background: var(--accent); font-weight: 600; font-size: inherit; line-height: inherit; padding: 0.3rem 0.8rem; border-radius: 6px; }
.nav .nav-contact:hover { color: #fff; filter: brightness(1.1); }

/* One menu per group, opened on hover or keyboard focus, no JavaScript. */
.nav-group { position: relative; }
.nav-group-title {
    background: transparent;
    color: var(--muted);
    font-weight: 500;
    padding: 0.3rem 0.6rem;
    border-radius: 6px;
}
.nav-group-title::after { content: " \25BE"; font-size: 0.75em; }
.nav-group.active .nav-group-title { color: var(--text); font-weight: 600; }
.nav-group:hover .nav-group-title, .nav-group:focus-within .nav-group-title { background: var(--code-bg); color: var(--text); }
.nav-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 11rem;
    padding: 0.4rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
    z-index: 20;
}
.nav-group:hover .nav-menu, .nav-group:focus-within .nav-menu { display: block; }
.nav-menu a { display: block; padding: 0.35rem 0.6rem; border-radius: 6px; white-space: nowrap; }
.nav-menu a:hover, .nav-menu a.active { background: var(--code-bg); }

main { padding: 1.5rem 0 3rem; }

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    padding: 0;
    margin: 0 0 1rem;
    font-size: 0.9rem;
    color: var(--muted);
}

.breadcrumb-item + .breadcrumb-item::before { content: "/"; padding: 0 0.5rem; color: var(--border); }
.breadcrumb-item.active { color: var(--text); }

h1 { font-size: 1.9rem; line-height: 1.2; margin: 0 0 0.5rem; }
h2 { font-size: 1.3rem; margin: 0 0 0.75rem; }
h3 { font-size: 1.05rem; margin: 0 0 0.5rem; }

.lead { color: var(--muted); font-size: 1.05rem; margin: 0 0 1.5rem; max-width: 70ch; }

.uses { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0 0 1.5rem; }
.tag {
    display: inline-block;
    padding: 0.1rem 0.55rem;
    border: 1px solid var(--border);
    border-radius: 999px;
    font-size: 0.8rem;
    color: var(--muted);
    background: var(--surface);
}

.grid { display: grid; gap: 1rem; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }

.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem;
    box-shadow: var(--shadow);
    min-width: 0;
}

.card + .card { margin-top: 1rem; }
.grid > .card + .card { margin-top: 0; }

.package h3 { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 0.98rem; }
.package p { margin: 0 0 0.75rem; color: var(--muted); font-size: 0.95rem; }
.package .links { display: flex; gap: 1rem; font-size: 0.9rem; }

.group-title { margin: 2rem 0 0.75rem; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); }

form .field { margin-bottom: 1rem; }
label { display: block; font-weight: 600; font-size: 0.92rem; margin-bottom: 0.3rem; }
.hint { display: block; font-weight: 400; color: var(--muted); font-size: 0.85rem; margin-top: 0.25rem; }

input[type="text"], input[type="email"], input[type="number"], input[type="date"], select, textarea {
    width: 100%;
    padding: 0.55rem 0.7rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--bg);
    color: var(--text);
    font: inherit;
}

textarea { min-height: 7rem; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.invalid { border-color: var(--error) !important; }

.checkbox { display: flex; gap: 0.5rem; align-items: center; font-weight: 400; }
.checkbox input { width: auto; }

.row { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 0 1rem; }

button, .button {
    display: inline-block;
    padding: 0.55rem 1.1rem;
    border: 0;
    border-radius: 8px;
    background: var(--accent);
    color: #fff;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
}

.button.secondary { background: transparent; color: var(--accent); border: 1px solid var(--accent); }
button:hover, .button:hover { filter: brightness(1.05); text-decoration: none; }

.error-text { color: var(--error); font-size: 0.88rem; margin-top: 0.25rem; }

.alert { padding: 0.8rem 1rem; border-radius: var(--radius); margin-bottom: 1rem; font-size: 0.95rem; }
.alert-ok { background: var(--ok-soft); color: var(--ok); }
.alert-warn { background: var(--warn-soft); color: var(--warn); }
.alert-error { background: var(--error-soft); color: var(--error); }

.demo-banner { background: var(--warn-soft); color: var(--warn); font-size: 0.9rem; padding: 0.5rem 0; text-align: center; }

table { width: 100%; border-collapse: collapse; font-size: 0.93rem; }
th, td { text-align: left; padding: 0.5rem 0.6rem; border-bottom: 1px solid var(--border); vertical-align: top; }
th { color: var(--muted); font-weight: 600; font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.04em; }
.table-wrap { overflow-x: auto; }

dl.facts { display: grid; grid-template-columns: max-content 1fr; gap: 0.35rem 1rem; margin: 0; }
dl.facts dt { color: var(--muted); }
dl.facts dd { margin: 0; word-break: break-word; }

.code-preview { display: flex; justify-content: center; background: #fff; border-radius: var(--radius); padding: 1rem; margin-bottom: 1rem; }
.code-preview svg { max-width: 100%; height: auto; }

.status { font-weight: 600; }
.status.ok { color: var(--ok); }
.status.off { color: var(--muted); }

.rendered { border: 1px dashed var(--border); border-radius: var(--radius); padding: 0.75rem 1rem; }

/* Column sort icons of laravel-column-sortable (Font Awesome class names, drawn without the font). */
th a { color: inherit; }
i.fa { font-style: normal; color: var(--muted); }
i.fa-sort::before { content: "\2195"; }
i[class*="-asc"]::before { content: "\2191"; color: var(--accent); }
i[class*="-desc"]::before { content: "\2193"; color: var(--accent); }

.chart svg { width: 100%; height: auto; display: block; }
.chart .bar { fill: var(--accent); }
.chart .axis { fill: var(--muted); font-size: 11px; }
.chart .value { fill: var(--text); font-size: 11px; }

.matrix td, .matrix th { text-align: center; }
.matrix td:first-child, .matrix th:first-child { text-align: left; }
.allowed { color: var(--ok); font-weight: 600; }
.denied { color: var(--muted); }

.avatars { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; }
.avatars figure { margin: 0; text-align: center; font-size: 0.8rem; color: var(--muted); }


.site-footer { border-top: 1px solid var(--border); padding: 1.5rem 0 2.5rem; color: var(--muted); font-size: 0.88rem; }
.site-footer p { margin: 0.25rem 0; }

@media (max-width: 600px) {
    h1 { font-size: 1.5rem; }
    .card { padding: 1rem; }
}

.pagination { display: flex; flex-wrap: wrap; gap: 0.25rem; margin-top: 1rem; }
.pagination a, .pagination span { padding: 0.25rem 0.6rem; border: 1px solid var(--border); border-radius: 6px; font-size: 0.9rem; }
.pagination span { color: var(--muted); }
.pagination a.active { background: var(--accent); color: #fff; border-color: var(--accent); }

.cta { padding: 2.5rem 0 1.5rem; }
.cta-box { background: linear-gradient(135deg, #c0392b 0%, #8e2419 100%); color: #fff; border-radius: 14px; box-shadow: 0 14px 34px rgba(142, 36, 25, 0.35); padding: 2.25rem 2.5rem; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.5rem 2.5rem; }
.cta-photo { flex: 0 0 auto; width: 112px; height: 112px; border-radius: 50%; object-fit: cover; border: 3px solid #fff; box-shadow: 0 6px 18px rgba(0, 0, 0, 0.3); }
.cta-text { flex: 1 1 380px; max-width: 46rem; }
.cta-box .cta-badge { display: inline-flex; align-items: center; gap: 0.5rem; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: #fff; background: rgba(255, 255, 255, 0.16); border-radius: 999px; padding: 0.3rem 0.8rem; margin: 0 0 0.9rem; }
.cta-box .cta-badge::before { content: ""; width: 0.55rem; height: 0.55rem; border-radius: 50%; background: #7dffa8; box-shadow: 0 0 0 4px rgba(125, 255, 168, 0.25); }
.cta-box h2 { margin: 0 0 0.6rem; font-size: clamp(1.6rem, 3.2vw, 2.2rem); line-height: 1.15; color: #fff; }
.cta-box .cta-text > p { margin: 0 0 0.75rem; color: rgba(255, 255, 255, 0.92); font-size: 1.05rem; }
.cta-offers { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.45rem; font-size: 1.02rem; }
.cta-offers li { position: relative; padding-left: 1.6rem; color: #fff; }
.cta-offers li::before { content: "\2713"; position: absolute; left: 0; font-weight: 700; color: #7dffa8; }
.cta-actions { display: flex; flex-direction: column; gap: 0.6rem; align-items: stretch; min-width: 14rem; }
.cta-actions .button { background: #fff; color: #8e2419; border: 1px solid #fff; font-weight: 700; font-size: 1.1rem; padding: 0.85rem 1.6rem; text-align: center; }
.cta-actions .button:hover { background: #ffe9e5; text-decoration: none; }
.cta-actions .button.secondary { background: transparent; color: #fff; border-color: rgba(255, 255, 255, 0.6); font-weight: 600; font-size: 1rem; }
.cta-actions .button.secondary:hover { background: rgba(255, 255, 255, 0.12); }
.cta-note { margin: 0; font-size: 0.85rem; color: rgba(255, 255, 255, 0.8); text-align: center; }
@media (max-width: 600px) {
    .cta-box { padding: 1.5rem 1.25rem; }
    .cta-photo { width: 84px; height: 84px; }
    .cta-actions { width: 100%; }
}
