:root {
    --bg: #f3f1ef;
    --panel: rgba(255,255,255,0.95);
    --text: #1c1a1a;
    --muted: #6b6661;
    --accent: #8f0808;
    --accent-dark: #520404;
    --line: #e6dfd7;
    --shadow: 0 18px 45px rgba(0,0,0,0.08);
    --radius: 24px;
}
* { box-sizing: border-box; }
body {
    margin: 0;
    font-family: Georgia, "Times New Roman", serif;
    background:
        radial-gradient(circle at top right, rgba(143,8,8,0.08), transparent 28%),
        linear-gradient(180deg, #f7f5f2 0%, #ebe7e2 100%);
    color: var(--text);
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { cursor: pointer; }
.page-shell { display: grid; grid-template-columns: 280px 1fr; min-height: 100vh; }
.sidebar {
    background: linear-gradient(180deg, #161515 0%, #070707 100%);
    color: #fff;
    padding: 28px 22px;
    position: sticky;
    top: 0;
    height: 100vh;
    display: flex;
    flex-direction: column;
    gap: 26px;
}
.sidebar-brand {
    font-size: 2rem;
    font-style: italic;
    letter-spacing: 0.02em;
}
.sidebar nav { display: flex; flex-direction: column; gap: 12px; }
.sidebar a {
    padding: 14px 16px;
    border-radius: 16px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.05);
    transition: 0.25s ease;
}
.sidebar a:hover { background: rgba(143,8,8,0.9); transform: translateX(2px); }
.sidebar-foot {
    margin-top: auto;
    color: rgba(255,255,255,0.65);
    font-size: 0.95rem;
}
.content { padding: 0 28px 28px; }
.top-banner {
    width: 100%;
    background: #e6e6e6;
    border-radius: 0 0 var(--radius) var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    margin-bottom: 28px;
}
.top-banner img {
    width: 100%;
    height: 340px;
    object-fit: contain;
    padding: 22px;
}
.card {
    background: var(--panel);
    border-radius: var(--radius);
    padding: 28px;
    box-shadow: var(--shadow);
    margin-bottom: 22px;
    border: 1px solid rgba(255,255,255,0.7);
    backdrop-filter: blur(12px);
}
.hero-card { padding: 40px; }
.landing-card {
    display: grid;
    grid-template-columns: 1.4fr 0.8fr;
    gap: 26px;
    align-items: center;
}
.hero-panel {
    padding: 28px;
    border-radius: 22px;
    background: linear-gradient(135deg, #f9f4f2, #f1ece7);
    border: 1px solid var(--line);
}
.eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.2em;
    font-size: 0.82rem;
    color: var(--accent);
}
h1, h2, h3 { margin-top: 0; }
p { line-height: 1.6; }
.form-card form,
.admin-form { display: grid; gap: 16px; }
.two-col-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.full-span { grid-column: 1 / -1; }
.narrow-card { max-width: 680px; }
label, fieldset {
    display: grid;
    gap: 8px;
    color: var(--muted);
    font-size: 0.97rem;
}
input, select, button {
    font: inherit;
    padding: 14px 16px;
    border-radius: 16px;
    border: 1px solid #d8d1c9;
    background: #fff;
}
input:focus, select:focus {
    outline: none;
    border-color: rgba(143,8,8,0.5);
    box-shadow: 0 0 0 3px rgba(143,8,8,0.08);
}
fieldset { border: 1px solid var(--line); border-radius: 18px; padding: 18px; }
.checkbox-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
}
.brand-grid { grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); }
.choice-card {
    display: flex;
    gap: 10px;
    align-items: center;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: #fcfbfa;
}
.featured-choice {
    background: linear-gradient(135deg, #fff8f8, #f8efef);
    border-color: rgba(143,8,8,0.25);
}
.checkbox-inline {
    display: flex;
    align-items: center;
    gap: 10px;
}
.btn {
    display: inline-block;
    width: fit-content;
    background: linear-gradient(135deg, var(--accent), var(--accent-dark));
    color: #fff;
    border: none;
    cursor: pointer;
    box-shadow: 0 10px 24px rgba(125,12,12,0.22);
}
.btn:hover { filter: brightness(1.05); }
.btn-secondary { background: #1d1d1d; box-shadow: none; }
.btn-small { padding: 10px 14px; border-radius: 12px; font-size: 0.92rem; }
.danger { background: linear-gradient(135deg, #a71818, #620707); }
.cta-row { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 8px; }
.flash-message {
    margin-bottom: 18px;
    padding: 14px 18px;
    border-left: 5px solid var(--accent);
    background: #fff9f9;
    border-radius: 14px;
    box-shadow: var(--shadow);
}
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-top: 22px;
}
.stat-box {
    padding: 18px;
    border-radius: 18px;
    background: linear-gradient(135deg, #faf7f5, #f3ede9);
    border: 1px solid var(--line);
}
.stat-box span {
    display: block;
    color: var(--muted);
    margin-bottom: 8px;
}
.stat-box strong {
    font-size: 2rem;
}
.admin-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 16px;
}
.mini-card {
    padding: 18px;
    border-radius: 18px;
    border: 1px solid var(--line);
    background: #fcfbfa;
}
.search-card h3 { margin-bottom: 12px; }
.plain-list {
    margin: 0;
    padding-left: 18px;
    display: grid;
    gap: 8px;
}
.table-wrap { overflow-x: auto; }
.admin-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 720px;
}
.admin-table th,
.admin-table td {
    text-align: left;
    padding: 14px 12px;
    border-bottom: 1px solid var(--line);
    vertical-align: top;
}
.admin-table th { color: var(--muted); font-weight: normal; }
.action-row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.pill-row { display: flex; gap: 10px; flex-wrap: wrap; }
.pill {
    padding: 8px 12px;
    border-radius: 999px;
    background: #f5efea;
    border: 1px solid var(--line);
    color: var(--muted);
}
.split-card {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    align-items: center;
}
.site-footer {
    text-align: center;
    color: var(--muted);
    padding: 18px 0 6px;
}
@media (max-width: 1100px) {
    .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .landing-card { grid-template-columns: 1fr; }
}
@media (max-width: 960px) {
    .page-shell { grid-template-columns: 1fr; }
    .sidebar { position: relative; height: auto; }
    .top-banner img { height: 220px; }
    .two-col-form { grid-template-columns: 1fr; }
    .full-span { grid-column: auto; }
    .split-card { flex-direction: column; align-items: flex-start; }
}
