:root {
    --bg: #f6efe2;
    --panel: #fffaf2;
    --text: #2d211a;
    --muted: #705e52;
    --line: #e2d2bf;
    --accent: #b44f2e;
    --accent-dark: #8f3e24;
    --danger: #a63a3a;
    --success-bg: #e5f6eb;
    --success-text: #205c36;
    --error-bg: #ffe9e9;
    --error-text: #822a2a;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    color: var(--text);
    font-family: "Trebuchet MS", "Segoe UI", sans-serif;
    line-height: 1.45;
    background: radial-gradient(circle at 10% 0%, #fff7ea 0%, var(--bg) 35%, #ecd7bc 100%);
}

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

a:hover {
    text-decoration: underline;
}

.container {
    width: min(1100px, calc(100% - 2rem));
    margin: 0 auto;
}

.site-header {
    background: #2d211a;
    border-bottom: 4px solid #b67f59;
    position: sticky;
    top: 0;
    z-index: 10;
}

.nav-wrap {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    min-height: 72px;
}

.brand {
    color: #fff3e0;
    font-size: 1.3rem;
    font-weight: 700;
    letter-spacing: 0.4px;
}

.menu {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    flex-wrap: wrap;
}

.menu a,
.link-button {
    color: #fff3e0;
    padding: 0.25rem 0.4rem;
}

.link-button {
    border: 0;
    background: transparent;
    font: inherit;
    cursor: pointer;
}

main.container {
    padding: 1.25rem 0 2rem;
}

.page-title {
    margin: 0.3rem 0 1rem;
}

.panel {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 1rem;
    margin-bottom: 1rem;
    box-shadow: 0 8px 20px rgba(45, 33, 26, 0.08);
}

.panel h2 {
    margin-top: 0;
}

.hero h2 {
    margin: 0.2rem 0;
}

.hero-subtitle {
    margin: 0;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    font-size: 0.85rem;
}

.narrow {
    width: min(520px, 100%);
}

.form-grid {
    display: grid;
    gap: 0.8rem;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.form-grid label {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    font-weight: 600;
}

.form-grid input,
.form-grid select,
.form-grid textarea {
    border: 1px solid #c8b39e;
    border-radius: 10px;
    padding: 0.58rem 0.65rem;
    font: inherit;
    color: var(--text);
    background: #fffdf8;
}

.checkbox {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.checkbox input {
    width: 1rem;
    height: 1rem;
}

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

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

.button-row.compact {
    gap: 0.35rem;
}

.btn-primary,
.btn-secondary,
.btn-danger {
    border: 0;
    border-radius: 10px;
    padding: 0.55rem 0.9rem;
    cursor: pointer;
    font: inherit;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 36px;
}

.btn-primary {
    background: var(--accent);
    color: #fff;
}

.btn-primary:hover {
    background: var(--accent-dark);
    text-decoration: none;
}

.btn-secondary {
    background: #ede1d3;
    color: #382a21;
}

.btn-secondary:hover {
    background: #dfcfba;
    text-decoration: none;
}

.btn-danger {
    background: var(--danger);
    color: #fff;
}

.btn-danger:hover {
    background: #822b2b;
    text-decoration: none;
}

.small {
    font-size: 0.85rem;
    padding: 0.4rem 0.7rem;
}

.flash {
    border-radius: 10px;
    padding: 0.72rem 0.9rem;
    margin-bottom: 0.85rem;
}

.flash-success {
    background: var(--success-bg);
    color: var(--success-text);
    border: 1px solid #b8dfc7;
}

.flash-error {
    background: var(--error-bg);
    color: var(--error-text);
    border: 1px solid #f0b9b9;
}

.table-grid {
    display: grid;
    gap: 0.8rem;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.table-card {
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 0.85rem;
    background: #fffefb;
}

.booking-list {
    display: grid;
    gap: 0.75rem;
}

.booking-card {
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 0.8rem;
    display: flex;
    justify-content: space-between;
    gap: 0.8rem;
    align-items: center;
    background: #fffdf8;
}

.status {
    display: inline-block;
    padding: 0.2rem 0.45rem;
    border-radius: 999px;
    font-size: 0.82rem;
}

.status-pending {
    background: #fff0c7;
    color: #72530a;
}

.status-confirmed {
    background: #dff5df;
    color: #1f5a34;
}

.status-cancelled {
    background: #f8dede;
    color: #7d2f2f;
}

.stats-grid {
    display: grid;
    gap: 0.75rem;
    grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
}

.stat-card {
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 0.75rem;
    text-align: center;
    background: #fffdf8;
}

.stat-card h2 {
    margin: 0;
    font-size: 1.6rem;
}

.stat-card p {
    margin: 0.2rem 0 0;
    color: var(--muted);
}

.section-heading {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.8rem;
    margin-bottom: 0.8rem;
}

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

table {
    width: 100%;
    border-collapse: collapse;
    min-width: 760px;
}

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

th {
    background: #f2e5d4;
}

.inline-form {
    display: inline;
}

.site-footer {
    border-top: 1px solid var(--line);
    margin-top: 1.2rem;
    padding: 0.85rem 0;
    color: var(--muted);
}

@media (max-width: 680px) {
    .booking-card {
        flex-direction: column;
        align-items: flex-start;
    }

    .nav-wrap {
        align-items: flex-start;
        flex-direction: column;
        padding: 0.5rem 0;
    }
}
