:root {
    --bg: #fbf1e3;
    --bg-strong: #f0dfc7;
    --surface: rgba(255, 251, 245, 0.86);
    --surface-strong: rgba(255, 248, 240, 0.76);
    --ink: #241915;
    --ink-soft: #6a5a4f;
    --line: rgba(180, 83, 9, 0.14);
    --line-strong: rgba(180, 83, 9, 0.22);
    --accent: #d97706;
    --accent-strong: #b45309;
    --glow: rgba(217, 119, 6, 0.2);
    --shadow: 0 24px 60px rgba(95, 55, 17, 0.14);
    --radius-xl: 30px;
    --radius-lg: 22px;
    --radius-md: 18px;
    --display-font: Georgia, "Times New Roman", serif;
    --body-font: "Trebuchet MS", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    color: var(--ink);
    font-family: var(--body-font);
    background:
        radial-gradient(circle at top left, var(--glow), transparent 28%),
        linear-gradient(180deg, var(--bg), var(--bg-strong));
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background-image:
        linear-gradient(rgba(36, 25, 21, 0.022) 1px, transparent 1px),
        linear-gradient(90deg, rgba(36, 25, 21, 0.022) 1px, transparent 1px);
    background-size: 34px 34px;
    mask-image: linear-gradient(180deg, rgba(0,0,0,.36), transparent 88%);
}

a { color: inherit; }

.brand-shell {
    max-width: 1240px;
    margin: 0 auto;
    padding: 26px 18px 96px;
    position: relative;
}

.brand-topbar {
    position: sticky;
    top: 14px;
    z-index: 30;
    margin-bottom: 18px;
}

.topbar-card,
.brand-card,
.brand-panel,
.brand-metric,
.brand-tile,
.brand-form-card,
.brand-list-card {
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
    backdrop-filter: blur(14px);
}

.topbar-card {
    border-radius: 999px;
    padding: 14px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.brand-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--ink);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.brand-mark {
    width: 34px;
    height: 34px;
    display: inline-grid;
    place-items: center;
    border-radius: 50%;
    color: #fffaf4;
    background: linear-gradient(135deg, var(--accent), var(--accent-strong));
    box-shadow: 0 14px 30px var(--glow);
}

.topbar-nav,
.topbar-actions,
.brand-actions,
.inline-pills {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.topbar-nav a,
.topbar-nav button,
.brand-link-lite {
    color: var(--ink-soft);
    text-decoration: none;
    font-size: 14px;
    font-weight: 700;
}

.topbar-nav a:hover,
.brand-link-lite:hover {
    color: var(--ink);
}

.brand-btn {
    min-height: 46px;
    padding: 0 18px;
    border-radius: 999px;
    border: 1px solid transparent;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    transition: transform .18s ease, filter .18s ease, background-color .18s ease;
}

.brand-btn:hover {
    transform: translateY(-1px);
}

.brand-btn-primary {
    color: #fffaf4;
    background: linear-gradient(135deg, var(--accent), var(--accent-strong));
    box-shadow: 0 14px 28px var(--glow);
}

.brand-btn-secondary {
    color: var(--ink);
    background: rgba(255,255,255,.48);
    border-color: var(--line);
}

.brand-btn-ghost {
    color: var(--ink-soft);
    background: transparent;
    border-color: var(--line);
}

.brand-main {
    display: grid;
    gap: 18px;
}

.brand-grid-2,
.brand-grid-3,
.brand-grid-4,
.brand-form-grid,
.brand-list-grid {
    display: grid;
    gap: 18px;
}

.brand-grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.brand-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.brand-grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.brand-form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.brand-list-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.brand-card,
.brand-panel,
.brand-form-card,
.brand-list-card {
    border-radius: var(--radius-xl);
    padding: 28px;
}

.brand-metric,
.brand-tile {
    border-radius: var(--radius-lg);
    padding: 18px;
}

.brand-card {
    background:
        radial-gradient(circle at top right, var(--glow), transparent 26%),
        linear-gradient(180deg, rgba(255,255,255,.68), rgba(255,255,255,.26));
}

.eyebrow,
.section-kicker,
.micro-label,
.status-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .1em;
    text-transform: uppercase;
}

.eyebrow,
.section-kicker,
.micro-label {
    color: var(--accent-strong);
}

.status-chip {
    min-height: 36px;
    padding: 0 12px;
    border-radius: 999px;
    color: #fffaf4;
    background: linear-gradient(135deg, var(--accent), var(--accent-strong));
}

.brand-pill {
    min-height: 38px;
    padding: 0 14px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: rgba(255,255,255,.48);
    display: inline-flex;
    align-items: center;
    color: var(--ink);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
}

h1, h2, h3 {
    margin: 0;
    color: var(--ink);
    font-family: var(--display-font);
    font-weight: 700;
    letter-spacing: -.03em;
}

h1 { font-size: clamp(40px, 6vw, 72px); line-height: .96; }
h2 { font-size: clamp(28px, 3.2vw, 40px); line-height: 1.04; }
h3 { font-size: 22px; line-height: 1.12; }

p {
    margin: 0;
    color: var(--ink-soft);
    line-height: 1.66;
}

.lead {
    margin-top: 16px;
    font-size: 18px;
}

.copy-box {
    margin-top: 18px;
    padding: 18px 20px;
    border-radius: var(--radius-md);
    border: 1px solid rgba(255,255,255,.36);
    background: var(--surface-strong);
    color: var(--ink);
}

.brand-metric strong,
.brand-panel strong,
.brand-tile strong {
    display: block;
    margin-bottom: 8px;
    color: var(--ink-soft);
    font-size: 11px;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.brand-value {
    display: block;
    margin-bottom: 6px;
    color: var(--ink);
    font-family: var(--display-font);
    font-size: 34px;
    line-height: 1;
}

.brand-list {
    margin: 16px 0 0;
    padding-left: 18px;
    display: grid;
    gap: 10px;
}

.brand-list li {
    color: var(--ink);
    line-height: 1.58;
}

.brand-form {
    display: grid;
    gap: 16px;
    margin-top: 20px;
}

.brand-field {
    display: grid;
    gap: 8px;
}

.brand-field label {
    font-weight: 700;
    color: var(--ink);
}

.brand-input,
.brand-select,
.brand-textarea {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: rgba(255,255,255,.58);
    color: var(--ink);
    padding: 13px 14px;
    font: inherit;
}

.brand-textarea {
    min-height: 120px;
    resize: vertical;
}

.flash-box,
.error-box,
.success-box {
    padding: 14px 16px;
    border-radius: 18px;
    border: 1px solid var(--line);
    background: rgba(255, 245, 231, 0.88);
    color: var(--ink);
}

.error-box {
    border-color: rgba(180, 83, 9, 0.24);
    background: rgba(255, 240, 228, 0.9);
}

.success-box {
    border-color: rgba(180, 83, 9, 0.26);
    background: rgba(255, 247, 236, 0.92);
}

.registry-card {
    padding: 18px;
    border-radius: var(--radius-md);
    border: 1px solid var(--line);
    background: var(--surface-strong);
    display: grid;
    gap: 12px;
}

.registry-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.registry-status {
    min-height: 34px;
    padding: 0 12px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: #fffaf4;
    background: linear-gradient(135deg, #ea580c, #c2410c);
}

.registry-status.review {
    background: linear-gradient(135deg, #d97706, #b45309);
}

.registry-status.green {
    background: linear-gradient(135deg, #f59e0b, #d97706);
}

.registry-meta {
    display: grid;
    gap: 8px;
}

.registry-meta span {
    color: var(--ink-soft);
    line-height: 1.56;
}

.empty-state {
    padding: 20px;
    border-radius: var(--radius-md);
    border: 1px dashed var(--line-strong);
    background: rgba(255,255,255,.48);
}

.mobile-actions {
    position: fixed;
    left: 14px;
    right: 14px;
    bottom: 14px;
    z-index: 30;
    display: none;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    padding: 12px;
    border-radius: 22px;
    border: 1px solid var(--line);
    background: rgba(255,251,245,.94);
    box-shadow: 0 18px 44px rgba(52,31,18,.14);
    backdrop-filter: blur(16px);
}

@media (max-width: 1100px) {
    .brand-grid-3,
    .brand-grid-4,
    .brand-form-grid,
    .brand-list-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .brand-grid-2 {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 760px) {
    .brand-shell {
        padding: 18px 14px 112px;
    }

    .brand-topbar {
        position: static;
    }

    .topbar-card {
        border-radius: 24px;
        align-items: flex-start;
        flex-direction: column;
    }

    .topbar-nav {
        width: 100%;
    }

    .topbar-actions {
        display: none;
    }

    .brand-card,
    .brand-panel,
    .brand-form-card,
    .brand-list-card {
        padding: 22px;
        border-radius: 24px;
    }

    .brand-grid-3,
    .brand-grid-4,
    .brand-form-grid,
    .brand-list-grid {
        grid-template-columns: 1fr;
    }

    h1 { font-size: 46px; }
    h2 { font-size: 30px; }

    .mobile-actions {
        display: grid;
    }
}
