/* Shared foundation and common components. */
:root {
    --bg: #f6f4ef;
    --surface: #ffffff;
    --surface-muted: #f3f0e8;
    --text: #1f2522;
    --muted: #6f766f;
    --line: #ded8cc;
    --brand: #24745a;
    --brand-dark: #174a3b;
    --accent: #b24b3a;
    --danger: #b42318;
    --page-max: 1180px;
    --venue-max: 1180px;
    --shadow: 0 18px 50px rgba(31, 37, 34, .08);
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: Inter, Arial, Helvetica, sans-serif;
    line-height: 1.5;
}

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

a:hover {
    text-decoration: underline;
}

main,
.site-header,
.site-footer {
    width: min(100% - 40px, var(--page-max));
    margin: 0 auto;
}

main {
    padding: 26px 0 44px;
}

.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 22px 0;
}

.site-footer {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 24px;
    padding: 28px 0 36px;
    border-top: 1px solid var(--line);
}

.footer-brand,
.brand {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    color: var(--brand-dark);
    font-size: 24px;
    font-weight: 900;
}

.brand-icon {
    flex: 0 0 auto;
    width: 32px;
    height: 32px;
    border-radius: 8px;
}

.site-footer p {
    margin: 6px 0 0;
    color: var(--muted);
}

.footer-nav,
.nav {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    align-items: center;
    justify-content: flex-end;
}

.footer-copy {
    grid-column: 1 / -1;
    font-size: 13px;
}

.language-mini {
    display: inline-flex;
    gap: 6px;
}

.language-mini a {
    font-weight: 800;
}

.inline-form {
    display: inline;
}

.button,
button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 10px 16px;
    border: 1px solid var(--brand);
    border-radius: 8px;
    background: var(--brand);
    color: #fff;
    cursor: pointer;
    font: inherit;
    font-weight: 800;
}

.button:hover,
button:hover {
    text-decoration: none;
}

.button-secondary {
    border-color: var(--line);
    background: var(--surface);
    color: var(--brand-dark);
}

.button-small {
    min-height: 34px;
    padding: 7px 10px;
    font-size: 13px;
}

.link-button {
    min-height: auto;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--brand);
    font-weight: 800;
}

.link-button:hover {
    text-decoration: underline;
}

.link-button.danger {
    color: var(--danger);
}

.hero,
.restaurant-hero,
.auth-shell {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, 420px);
    gap: 28px;
    align-items: center;
    padding: 42px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: var(--shadow);
}

.auth-shell-small {
    max-width: 620px;
    margin: 0 auto;
    grid-template-columns: 1fr;
}

.hero h1,
.restaurant-hero h1,
.auth-shell h1,
.section-head h1 {
    margin: 0;
    font-size: clamp(32px, 4vw, 56px);
    line-height: 1.06;
    letter-spacing: 0;
}

.auth-shell h1,
.section-head h1 {
    font-size: clamp(28px, 3vw, 44px);
}

.hero p,
.restaurant-hero p,
.auth-shell p,
.section-head p {
    color: var(--muted);
}

.eyebrow,
.meta {
    margin: 0;
    color: var(--accent);
    font-size: 13px;
    font-weight: 900;
    text-transform: uppercase;
}

.search-panel,
.form-card,
.contact-panel {
    display: grid;
    gap: 16px;
    padding: 22px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: var(--shadow);
}

.restaurant-cover {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: 8px;
    background: var(--surface-muted);
}

.form-card {
    box-shadow: none;
}

.form-card h2,
.menu-preview h2 {
    margin: 0;
    font-size: 24px;
}

label {
    display: grid;
    gap: 6px;
    color: var(--text);
    font-weight: 800;
}

input,
select,
textarea {
    width: 100%;
    min-height: 42px;
    padding: 10px 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    font: inherit;
}

.phone-control {
    position: relative;
    display: block;
}

.phone-control input {
    min-width: 0;
    padding-left: 58px;
}

.phone-flag {
    position: absolute;
    top: 50%;
    left: 10px;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 28px;
    border-right: 1px solid var(--line);
    font-size: 20px;
    line-height: 1;
    transform: translateY(-50%);
    pointer-events: none;
}

textarea {
    resize: vertical;
}

input[type="checkbox"],
input[type="radio"] {
    width: auto;
    min-height: auto;
    padding: 0;
    accent-color: var(--brand);
}

.section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 22px;
}

.section-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-end;
}

.restaurant-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.restaurant-card {
    display: grid;
    gap: 12px;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
}

.restaurant-card h3,
.restaurant-card p {
    margin: 0;
}

.card-footer,
.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.card-footer {
    justify-content: space-between;
}

.tag-row span,
.status {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    padding: 3px 8px;
    border-radius: 999px;
    background: var(--surface-muted);
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}

.notice {
    margin-bottom: 16px;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
}

.notice-success {
    border-color: rgba(36, 116, 90, .3);
    background: rgba(36, 116, 90, .08);
}

.notice-warning {
    border-color: rgba(178, 75, 58, .3);
    background: rgba(178, 75, 58, .08);
}

.notice-with-action {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.notice-with-action > div {
    display: grid;
    gap: 3px;
}

.notice-with-action span {
    color: var(--muted);
    font-size: 13px;
}

.notice-with-action form {
    flex: 0 0 auto;
}

.notice-error,
.field-error {
    color: var(--danger);
}

.field-error {
    margin: 0;
    font-size: 13px;
}

.empty-state {
    padding: 28px;
    border: 1px dashed var(--line);
    border-radius: 8px;
    background: var(--surface);
    text-align: center;
}

.empty-state.inline {
    padding: 18px;
    text-align: left;
}

.simple-page {
    display: grid;
    gap: 18px;
    max-width: 760px;
}

.simple-page h1 {
    margin: 0;
    font-size: clamp(34px, 4vw, 56px);
    line-height: 1.06;
}

.restaurant-link-list {
    display: grid;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.restaurant-link-list a {
    display: block;
    padding: 14px 0;
    border-bottom: 1px solid var(--line);
    color: var(--brand-dark);
    font-size: 20px;
    font-weight: 700;
}

.setup-command {
    display: block;
    margin-top: 18px;
    padding: 14px;
    overflow-x: auto;
    border-radius: 8px;
    background: #1f2522;
    color: #fff;
    text-align: left;
}

@media (max-width: 900px) {
    .hero,
    .restaurant-hero,
    .auth-shell,
    .auth-shell-small {
        grid-template-columns: 1fr;
    }

    .section-head {
        align-items: flex-start;
        flex-direction: column;
    }
}

@media (max-width: 620px) {
    main,
    .site-header,
    .site-footer {
        width: min(100% - 22px, var(--page-max));
    }

    .site-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .site-footer {
        grid-template-columns: 1fr;
        align-items: flex-start;
    }

    .footer-nav,
    .nav {
        justify-content: flex-start;
    }

    .hero,
    .restaurant-hero,
    .auth-shell {
        padding: 24px;
    }

}
