:root {
    --coffee: #4a2b1f;
    --coffee-dark: #241713;
    --caramel: #b98247;
    --cream: #fbf4e8;
    --paper: #fffaf2;
    --sage: #5b7561;
    --ink: #221b17;
    --muted: #73665d;
    --line: #e8dac9;
    --shadow: 0 20px 50px rgba(36, 23, 19, 0.16);
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    color: var(--ink);
    background: var(--paper);
    line-height: 1.6;
}

a {
    color: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 10;
    background: rgba(255, 250, 242, 0.96);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(12px);
}

.topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    max-width: 1180px;
    margin: 0 auto;
    padding: 0.8rem 1rem;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
}

.brand-mark {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 8px;
    color: white;
    background: var(--coffee);
    font-weight: 700;
}

.brand strong,
.brand small {
    display: block;
}

.brand small,
.login-state,
.eyebrow {
    color: var(--muted);
    font-size: 0.88rem;
}

.login-state {
    margin: 0;
    text-align: right;
}

.main-nav {
    display: flex;
    justify-content: center;
    gap: 0.35rem;
    padding: 0 1rem 0.8rem;
    overflow-x: auto;
}

.main-nav a {
    padding: 0.55rem 0.9rem;
    border-radius: 6px;
    text-decoration: none;
    white-space: nowrap;
}

.main-nav a:hover,
.main-nav a.active {
    color: white;
    background: var(--coffee);
}

.hero {
    min-height: 68vh;
    display: flex;
    align-items: center;
    background:
        linear-gradient(90deg, rgba(36, 23, 19, 0.76), rgba(36, 23, 19, 0.28)),
        url("https://images.unsplash.com/photo-1511920170033-f8396924c348?auto=format&fit=crop&w=1800&q=85") center/cover;
    color: white;
}

.hero-content {
    width: min(1180px, 100%);
    margin: 0 auto;
    padding: 6rem 1rem;
}

.hero h1 {
    margin: 0;
    font-size: clamp(2.8rem, 8vw, 5.8rem);
    line-height: 1;
}

.lead {
    max-width: 650px;
    font-size: 1.2rem;
}

.hero .eyebrow {
    color: #f5d6b3;
}

.hero-actions,
.form-actions {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.button,
button {
    border: 0;
    border-radius: 6px;
    padding: 0.75rem 1rem;
    font: inherit;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}

.button.primary,
button.primary {
    color: white;
    background: var(--sage);
}

.button.ghost {
    color: white;
    outline: 1px solid rgba(255, 255, 255, 0.6);
}

.button.secondary,
button.secondary {
    color: var(--coffee-dark);
    background: #ead9c1;
}

.button.danger,
button.danger {
    color: white;
    background: #9d3e30;
}

.section {
    max-width: 1180px;
    margin: 0 auto;
    padding: 3rem 1rem;
}

.section.compact {
    max-width: 780px;
}

.promo-grid,
.card-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}

.promo-grid article,
.card,
.form-panel,
.table-panel {
    background: white;
    border: 1px solid var(--line);
    border-radius: 8px;
    box-shadow: var(--shadow);
}

.promo-grid article,
.card {
    padding: 1.25rem;
}

.metric {
    display: inline-block;
    color: var(--sage);
    font-size: 2rem;
    font-weight: 800;
}

.split {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.5rem;
    align-items: start;
}

video,
.video-frame,
.map,
.gallery-img {
    width: 100%;
    border-radius: 8px;
    border: 1px solid var(--line);
    background: #1b1210;
}

.video-frame {
    aspect-ratio: 16 / 9;
    overflow: hidden;
}

.video-frame iframe,
.map {
    width: 100%;
    height: 100%;
    border: 0;
}

.map {
    min-height: 340px;
}

.gallery-img {
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

.form-panel {
    padding: 1.25rem;
}

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

.field {
    display: grid;
    gap: 0.35rem;
}

.field.full {
    grid-column: 1 / -1;
}

label {
    font-weight: 700;
}

input,
textarea,
select {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 0.7rem 0.8rem;
    font: inherit;
    background: #fffdf8;
}

textarea {
    min-height: 140px;
    resize: vertical;
}

.form-errors,
.error-list {
    color: #8e2f24;
    font-weight: 700;
}

.flash {
    max-width: 1180px;
    margin: 1rem auto 0;
    padding: 0.8rem 1rem;
    border-radius: 6px;
}

.flash-success {
    background: #e5f1e7;
}

.flash-warning,
.flash-error {
    background: #f6e1dc;
}

.table-panel {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

th,
td {
    padding: 0.75rem;
    border-bottom: 1px solid var(--line);
    text-align: left;
    vertical-align: top;
}

th {
    background: var(--cream);
}

.actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

@media (max-width: 800px) {
    .topbar {
        align-items: flex-start;
        flex-direction: column;
    }

    .login-state {
        text-align: left;
    }

    .main-nav {
        justify-content: flex-start;
    }

    .promo-grid,
    .card-grid,
    .split,
    .form-grid {
        grid-template-columns: 1fr;
    }

    .hero {
        min-height: 58vh;
    }
}
