/* ===== Speisekarte: speisekarte, en/menu.html, ka/menu.html ===== */

/* Ersatzschrift mit den Maßen von Urbanist: solange die Webschrift lädt, brechen Navigation und Zeilen genauso um */
@font-face {
    font-family: 'Urbanist Fallback';
    font-weight: 400;
    src: local('Arial'), local('Helvetica'), local('Liberation Sans');
    size-adjust: 97.2%;
    ascent-override: 97.7%;
    descent-override: 25.7%;
    line-gap-override: 0%;
}

@font-face {
    font-family: 'Urbanist Fallback';
    font-weight: 700;
    src: local('Arial Bold'), local('Helvetica Bold'), local('Liberation Sans Bold');
    size-adjust: 93%;
    ascent-override: 102.2%;
    descent-override: 26.9%;
    line-gap-override: 0%;
}

.menu-page-body {
    font-family: 'Urbanist', 'Urbanist Fallback', sans-serif;
}

html[lang="ka"] .menu-page-body {
    font-family: 'Noto Sans Georgian', 'Urbanist', 'Urbanist Fallback', sans-serif;
}

/*
 * Sprungnavigation: dieselben Dateien, aber ohne nachträglichen Schriftwechsel. Sonst rutschen Einträge beim
 * Laden in eine andere Zeile, und die ganze Karte springt. Kommt die Schrift zu spät, bleibt die Ersatzschrift
 * für diesen Aufruf; beim nächsten Aufruf liegt die Datei im Cache.
 */
@font-face {
    font-family: 'Menu Nav';
    font-weight: 400 700;
    font-display: optional;
    src: url('fonts/urbanist-latin.woff2') format('woff2');
}

@font-face {
    font-family: 'Menu Nav Georgian';
    font-weight: 400 700;
    font-display: optional;
    src: url('fonts/noto-sans-georgian.woff2') format('woff2');
}

.menu-page {
    --menu-gutter: 40px;
    --menu-header-h: 116px;
    --menu-nav-h: 0px;
    --menu-line: rgba(239, 163, 123, 0.14);
    padding-left: var(--menu-gutter);
    padding-right: var(--menu-gutter);
}

/* Dichte Textzeilen scheinen sonst durch die leicht transparente Kopfzeile */
.menu-page-body .header,
.menu-page-body .header.header-scrolled {
    background-color: var(--green);
}

/* Reservierung */
.menu-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    margin-top: 24px;
    padding: 12px 32px;
    background: var(--gold);
    color: var(--green-dark);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    transition: background 0.3s, transform 0.2s;
}

.menu-cta:hover {
    background: var(--gold-light);
    transform: translateY(-2px);
}

.menu-cta:focus-visible,
.menu-nav-link:focus-visible,
.menu-page-more a:focus-visible {
    outline: 2px solid var(--gold-light);
    outline-offset: 2px;
}

/* Hinweis auf die Gruppenmenüs unter der Reservierung */
.menu-page-more {
    margin-top: 14px;
    color: var(--text-muted);
    font-size: 0.9375rem;
}

.menu-page-more a {
    color: var(--gold-light);
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* Sprungnavigation */
.menu-nav {
    max-width: 1180px;
    margin: 0 auto 56px;
    border-top: 1px solid var(--menu-line);
    border-bottom: 1px solid var(--menu-line);
}

.menu-nav-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0 4px;
    padding: 8px 0;
    list-style: none;
}

.menu-nav-link {
    display: inline-flex;
    align-items: center;
    min-height: 36px;
    padding: 0 12px;
    color: var(--text-muted);
    font-family: 'Menu Nav', 'Urbanist Fallback', sans-serif;
    font-size: 0.875rem;
    white-space: nowrap;
    transition: color 0.2s;
}

html[lang="ka"] .menu-nav-link {
    font-family: 'Menu Nav Georgian', 'Urbanist Fallback', sans-serif;
}

.menu-nav-link:hover {
    color: var(--gold);
}

/* Abschnitte */
.menu-sections {
    max-width: 720px;
    margin: 0 auto;
}

.menu-section {
    margin-bottom: 48px;
    break-inside: avoid;
    scroll-margin-top: calc(var(--menu-header-h) + var(--menu-nav-h) + 16px);
}

.menu-section:last-child {
    margin-bottom: 0;
}

.menu-section-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--gold-subtle);
}

.menu-section-title {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.75rem;
    font-weight: 500;
    line-height: 1.2;
    color: var(--white);
}

html[lang="ka"] .menu-section-title {
    font-family: 'Noto Serif Georgian', 'Cormorant Garamond', serif;
    font-size: 1.375rem;
}

.menu-section-unit {
    flex-shrink: 0;
    color: var(--text-muted);
    font-size: 0.8125rem;
}

.menu-section-note {
    margin-top: 8px;
    color: var(--text-muted);
    font-size: 0.875rem;
    line-height: 1.5;
}

/* Positionen */
.menu-items {
    list-style: none;
}

.menu-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: baseline;
    gap: 20px;
    padding: 10px 0;
    border-bottom: 1px solid var(--menu-line);
    line-height: 1.45;
}

.menu-item:last-child {
    border-bottom: none;
}

.menu-item-name {
    margin-right: 8px;
    font-weight: 500;
}

.menu-item-geo {
    margin-right: 8px;
    color: var(--text-subtle);
    font-size: 0.8125rem;
}

/* Als Block: «0,2 l» oder «5 Stück» wandert geschlossen in die nächste Zeile, längere Angaben brechen in sich um */
.menu-item-unit {
    display: inline-block;
    color: var(--text-muted);
    font-size: 0.8125rem;
}

.menu-item-prices {
    display: flex;
    justify-content: flex-end;
    gap: 16px;
    white-space: nowrap;
}

.menu-price-label {
    display: inline-block;
    min-width: 2.8em;
    color: var(--text-muted);
    font-size: 0.8125rem;
    text-align: right;
}

.menu-price-value {
    display: inline-block;
    color: var(--gold);
    font-weight: 600;
    text-align: right;
}

.menu-price-label + .menu-price-value {
    min-width: 3.4em;
}

/* Hinweis */
.menu-allergens {
    max-width: 680px;
    margin: 48px auto 0;
    padding-top: 24px;
    border-top: 1px solid var(--menu-line);
    color: var(--text-muted);
    font-size: 0.875rem;
    line-height: 1.6;
    text-align: center;
}

/* Georgische Großbuchstaben (Mtavruli) nur dort, wo die Seite sie ausdrücklich setzt */
html[lang="ka"] .menu-cta {
    letter-spacing: 0.05em;
    text-transform: none;
}

/* Breite Bildschirme: zwei Spalten wie auf der gedruckten Karte */
@media (min-width: 1100px) {
    .menu-sections {
        max-width: 1180px;
        columns: 2;
        column-gap: 72px;
    }
}

/* Telefon und schmales Tablet: Navigation als eigene Leiste, die nur in sich selbst scrollt */
@media (max-width: 768px) {
    .menu-page {
        --menu-gutter: 20px;
        --menu-header-h: 99px;
        --menu-nav-h: 46px;
    }

    .menu-nav {
        position: sticky;
        top: var(--menu-header-h);
        z-index: 10;
        margin: 0 calc(var(--menu-gutter) * -1) 36px;
        border-top: none;
        background: var(--green);
        box-shadow: 0 -32px 0 var(--green);
    }

    .menu-nav-list {
        flex-wrap: nowrap;
        justify-content: flex-start;
        gap: 0;
        padding: 0 calc(var(--menu-gutter) - 12px);
        overflow-x: auto;
        overscroll-behavior-x: contain;
        scrollbar-width: none;
    }

    .menu-nav-list::-webkit-scrollbar {
        display: none;
    }

    .menu-nav-link {
        min-height: 44px;
        font-size: 0.8125rem;
    }

    .menu-nav-link:focus-visible {
        outline-offset: -2px;
    }

    .menu-section {
        margin-bottom: 36px;
    }

    .menu-section-title {
        font-size: 1.5rem;
    }

    html[lang="ka"] .menu-section-title {
        font-size: 1.25rem;
    }
}

@media (max-width: 480px) {
    .menu-page {
        --menu-header-h: 95px;
    }

    .menu-item {
        gap: 12px;
    }

    .menu-item-prices {
        flex-direction: column;
        align-items: flex-end;
        gap: 0;
    }
}
