:root {
    --bg-dark: #121212;
    --bg-surface: #1e1e1e;
    --bg-surface-hover: #2c2c2c;
    --accent-yellow: #ffb300;
    --accent-yellow-glow: rgba(255, 179, 0, 0.4);
    --accent-red: #d32f2f;
    --text-main: #ffffff;
    --text-muted: #aaaaaa;
    --border-color: #333333;
    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Roboto', sans-serif;
    --transition-speed: 0.3s;
    --header-height: 88px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 180px;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-dark);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
}

/* Typography */
h1 span {
    color: var(--accent-yellow);
}

/* Buttons */
button {
    font-family: var(--font-heading);
    font-weight: 700;
    cursor: pointer;
    border: none;
    border-radius: 8px;
    padding: 10px 20px;
    transition: all var(--transition-speed);
    text-transform: uppercase;
    font-size: 0.9rem;
}

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

.btn-primary:hover:not(:disabled) {
    background-color: #ffca28;
    transform: translateY(-2px);
}

.btn-primary:disabled {
    background-color: var(--border-color);
    color: var(--text-muted);
    cursor: not-allowed;
}

.btn-secondary {
    background-color: transparent;
    color: var(--text-main);
    border: 2px solid var(--accent-yellow);
}

.btn-secondary:hover {
    background-color: rgba(255, 179, 0, 0.1);
    transform: translateY(-2px);
}

.btn-icon {
    background: transparent;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
}

.btn-icon:hover {
    background-color: var(--bg-surface);
}

.w-100 { width: 100%; }
.mt-2 { margin-top: 1rem; }
.hidden { display: none !important; }

.page-shell { padding: 32px 5%; }
.card { background: var(--bg-surface); border: 1px solid var(--border-color); border-radius: 16px; padding: 24px; box-shadow: 0 10px 30px rgba(0,0,0,0.35); }
.profile-card { max-width: 980px; margin: 0 auto; }
.profile-tabs { display: flex; gap: 8px; margin: 16px 0 12px; }
.profile-tab { background: var(--bg-surface-hover); color: var(--text-main); border: 1px solid var(--border-color); padding: 8px 12px; text-transform: none; font-size: 0.95rem; }
.profile-tab.active { background: var(--accent-yellow); color: #000; }
.profile-pane { display: block; }
.profile-list { list-style: none; display: grid; gap: 10px; }
.gift-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.gift-card { background: var(--bg-surface-hover); border: 1px solid var(--border-color); border-radius: 14px; padding: 12px; display: grid; gap: 8px; }
.gift-thumb { width: 100%; height: 120px; object-fit: cover; border-radius: 10px; }

.voucher-card { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.voucher-card .voucher-expiry { font-size: 0.8rem; color: var(--text-muted); }
.voucher-card.voucher-selected { border-color: var(--accent-yellow); }

.order-history-list { display: flex; flex-direction: column; gap: 10px; max-height: 320px; overflow-y: auto; }
.order-history-card { background: var(--bg-surface-hover); border: 1px solid var(--border-color); border-radius: 12px; padding: 10px 14px; }
.order-history-card-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; }
.order-history-card-main { display: flex; flex-direction: column; gap: 2px; }
.order-history-card-date { font-size: 0.8rem; color: var(--text-muted); }
.order-history-card-status { font-size: 0.85rem; font-weight: 700; }
.order-history-card-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.order-history-items { margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--border-color); display: flex; flex-direction: column; gap: 6px; }
.order-history-items.hidden { display: none; }
.order-history-item-row { display: flex; justify-content: space-between; gap: 10px; font-size: 0.88rem; }

.wheel-wrap {
    position: relative;
    width: clamp(220px, 70vw, 300px);
    aspect-ratio: 1 / 1;
    margin: 24px auto 16px;
}

.wheel-pointer {
    position: absolute;
    top: -4px;
    left: 50%;
    width: 0;
    height: 0;
    transform: translateX(-50%);
    border-left: 14px solid transparent;
    border-right: 14px solid transparent;
    border-top: 24px solid var(--accent-yellow);
    filter: drop-shadow(0 2px 3px rgba(0,0,0,0.6));
    z-index: 2;
}

.wheel-circle {
    position: relative;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: var(--bg-dark);
    border: 6px solid var(--accent-yellow);
    box-shadow: 0 0 0 3px rgba(0,0,0,0.4), 0 10px 25px rgba(0,0,0,0.45);
    transition: transform 4.2s cubic-bezier(0.17, 0.67, 0.32, 1.02);
    overflow: hidden;
}

.wheel-svg {
    display: block;
    width: 100%;
    height: 100%;
}

.wheel-svg text {
    font-family: var(--font-heading), sans-serif;
    pointer-events: none;
    paint-order: stroke;
}

.wheel-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 14px;
    justify-content: center;
    margin-bottom: 10px;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.wheel-legend span.swatch {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    margin-right: 6px;
}

.wheel-result {
    text-align: center;
    font-weight: 700;
    color: var(--accent-yellow);
    font-size: 1.05rem;
}

/* Glow effect for special buttons */
.glow {
    box-shadow: 0 0 15px var(--accent-yellow-glow);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { box-shadow: 0 0 15px var(--accent-yellow-glow); }
    50% { box-shadow: 0 0 25px rgba(255, 179, 0, 0.7); }
    100% { box-shadow: 0 0 15px var(--accent-yellow-glow); }
}

/* Header */
.main-header {
    display: grid;
    grid-template-columns: auto 1fr auto auto;
    justify-content: space-between;
    align-items: center;
    padding: 20px 5%;
    background-color: var(--bg-surface);
    border-bottom: 2px solid var(--accent-yellow);
    position: sticky;
    top: 0;
    z-index: 150;
}

.logo h1 {
    font-size: 1.8rem;
}

.tagline {
    font-size: 0.8rem;
    color: var(--text-muted);
    letter-spacing: 1px;
    text-transform: uppercase;
}

.header-actions {
    display: flex;
    gap: 15px;
    align-items: center;
}

.lang-switcher {
    position: relative;
    grid-column: 3;
}

.header-actions {
    grid-column: 4;
}

.lang-toggle {
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 6px 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    line-height: 0;
}

.lang-toggle:hover {
    border-color: var(--accent-yellow);
}

.lang-flag svg {
    display: block;
    border-radius: 2px;
}

.lang-dropdown {
    display: none;
    flex-direction: column;
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.5);
    min-width: 140px;
    overflow: hidden;
    z-index: 60;
}

.lang-dropdown.open {
    display: flex;
}

.lang-option {
    display: flex;
    align-items: center;
    gap: 10px;
    background: none;
    border: none;
    color: var(--text-main);
    padding: 10px 14px;
    font-size: 0.9rem;
    cursor: pointer;
    text-align: left;
}

.lang-option:hover {
    background: var(--bg-surface-hover);
}

.lang-option.active {
    color: var(--accent-yellow);
    font-weight: 700;
}

/* Google Translate widget takarása - csak a saját nyelvváltó gombunkat mutatjuk, a Google saját
   fordító sávját/kiemeléseit/tooltipjeit teljesen elrejtjük, hogy ne törje el a layoutot.
   A Google a saját UI elemeit mind ".skiptranslate" class-szal jelöli - ezt is elrejtjük
   általánosan, plusz extra védésként off-screen is toljuk, ha a display:none valamiért mégsem
   érvényesülne (pl. a Google JS-e egy inline !important stílust ír felül rajta). */
.goog-te-banner-frame,
.goog-te-banner-frame.skiptranslate,
iframe.goog-te-banner-frame,
iframe.skiptranslate,
body > iframe.skiptranslate,
.skiptranslate > iframe,
#goog-gt-tt,
.goog-tooltip.skiptranslate,
.goog-te-balloon-frame {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    width: 0 !important;
    position: absolute !important;
    top: -9999px !important;
    left: -9999px !important;
}

body {
    top: 0px !important;
    position: static !important;
}

.goog-text-highlight {
    background: none !important;
    box-shadow: none !important;
}

.mobile-menu-panel {
    display: none;
}

/* Mobile Menu Button - Hidden on Desktop */
.btn-mobile-menu {
    display: none;
    background: none;
    border: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 5px;
}

.btn-mobile-menu span {
    width: 25px;
    height: 3px;
    background-color: var(--accent-yellow);
    border-radius: 2px;
    transition: all 0.3s;
}

.btn-mobile-menu.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.btn-mobile-menu.active span:nth-child(2) {
    opacity: 0;
}

.btn-mobile-menu.active span:nth-child(3) {
    transform: rotate(-45deg) translate(8px, -8px);
}

.badge {
    background-color: var(--accent-red);
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: bold;
}

/* Menu Grid */
.menu-container {
    padding: 40px 5%;
}

.menu-category-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 15px 5% 10px;
    position: sticky;
    top: var(--header-height);
    z-index: 100;
    background: rgba(18, 18, 18, 0.98);
    backdrop-filter: blur(8px);
    border-bottom: 2px solid var(--accent-yellow);
}

.menu-category-nav-btn {
    background: rgba(255, 179, 0, 0.08);
    border: 1px solid rgba(255, 179, 0, 0.4);
    color: var(--text-main);
    padding: 8px 14px;
    border-radius: 999px;
    font-size: 0.78rem;
    text-transform: none;
    font-weight: 700;
}

.menu-category-nav-btn:hover {
    background: rgba(255, 179, 0, 0.18);
    transform: translateY(-1px);
}

.category-section {
    margin-bottom: 50px;
}

.category-title {
    font-size: 2rem;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--border-color);
    padding-bottom: 10px;
}

.category-subtitle {
    margin-top: -14px;
    margin-bottom: 20px;
    color: var(--text-muted);
    font-size: 0.95rem;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
}

.product-card {
    background-color: var(--bg-surface);
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 100%;
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: transform var(--transition-speed), box-shadow var(--transition-speed);
}

.product-card-clickable {
    cursor: pointer;
}

.product-card-clickable:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.35);
}

.product-image {
    width: 100%;
    aspect-ratio: 4 / 3;
    background-color: #333;
    background-image: url('https://images.unsplash.com/photo-1550547660-d9450f859349?ixlib=rb-1.2.1&auto=format&fit=crop&w=800&q=80'); /* Placeholder burger */
    background-size: cover;
    background-position: center;
    flex-shrink: 0;
}

/* Different placeholders based on category (done via js or fallback) */

.product-info {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
}

.product-name {
    font-size: 1.2rem;
    margin-bottom: 10px;
}

.product-desc {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 15px;
    flex: 1 1 auto;
}

.product-price {
    font-weight: bold;
    color: var(--accent-yellow);
    font-size: 1.2rem;
    margin-top: auto;
    margin-bottom: 15px;
}

.add-to-cart-btn {
    margin-top: 0;
}

/* Cart Panel */
.cart-panel {
    position: fixed;
    top: 0;
    right: -400px;
    width: 400px;
    height: 100vh;
    height: 100dvh; /* mobil címsáv miatt a 100vh levágná a lábléc gombot */
    background-color: var(--bg-surface);
    box-shadow: -5px 0 15px rgba(0,0,0,0.5);
    transition: right 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    z-index: 1000;
    display: flex;
    flex-direction: column;
}

.cart-panel.open {
    right: 0;
}

/* Scroll to Top Button */
.btn-scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-yellow), #ffca28);
    color: #000;
    font-size: 1.5rem;
    font-weight: bold;
    border: none;
    cursor: pointer;
    z-index: 999;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(255, 179, 0, 0.4);
    transition: all var(--transition-speed);
}

.btn-scroll-to-top.visible {
    display: flex;
}

.btn-scroll-to-top:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(255, 179, 0, 0.6);
}

.btn-scroll-to-top:active {
    transform: translateY(-1px);
}

/* Lebegő gomb, ami visszahozza a rendelés-követő modalt, ha a felhasználó véletlenül bezárta */
.btn-resume-tracking {
    position: fixed;
    bottom: 30px;
    left: 30px;
    padding: 12px 18px;
    border-radius: 30px;
    background: linear-gradient(135deg, var(--accent-yellow), #ffca28);
    color: #000;
    font-weight: 700;
    font-size: 0.9rem;
    border: none;
    cursor: pointer;
    z-index: 999;
    box-shadow: 0 4px 14px rgba(255, 179, 0, 0.45);
    transition: all var(--transition-speed);
    animation: resumeTrackPulse 2s ease-in-out infinite;
}

.btn-resume-tracking.hidden {
    display: none;
}

.password-field {
    position: relative;
}

.password-field input {
    width: 100%;
    padding-right: 44px;
}

.password-toggle {
    position: absolute;
    top: 50%;
    right: 8px;
    transform: translateY(-50%);
    border: 0;
    background: transparent;
    cursor: pointer;
    font-size: 1rem;
    line-height: 1;
    padding: 6px;
}

.btn-text-action {
    display: inline-block;
    margin-top: 10px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--accent-yellow);
    font: inherit;
    cursor: pointer;
    text-decoration: underline;
}

.btn-text-action:hover {
    color: var(--accent-yellow-hover);
}

.btn-resume-tracking:hover {
    transform: translateY(-3px);
}

@keyframes resumeTrackPulse {
    0%, 100% { box-shadow: 0 4px 14px rgba(255, 179, 0, 0.45); }
    50% { box-shadow: 0 4px 22px rgba(255, 179, 0, 0.8); }
}

@media (max-width: 500px) {
    .btn-scroll-to-top {
        bottom: 84px;
        right: 16px;
    }

    .btn-resume-tracking {
        left: 12px;
        right: 12px;
        bottom: 16px;
        text-align: center;
    }
}

@media (max-width: 500px) {
    .cart-panel {
        width: 100%;
        right: -100%;
    }

    .menu-category-nav {
        position: static !important;
        background: var(--bg-surface);
        padding: 12px 5%;
        border-bottom: 2px solid var(--accent-yellow);
        gap: 8px;
    }

    .menu-category-nav-btn {
        font-size: 0.7rem;
        padding: 6px 10px;
    }
}

.cart-header {
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cart-items {
    flex-grow: 1;
    min-height: 0; /* flex gyerek e nélkül a tartalom magasságára nő, kitolva a lábléc gombot a képernyőről */
    overflow-y: auto;
    padding: 20px;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 15px;
    margin-bottom: 15px;
    border-bottom: 1px solid var(--border-color);
}

.cart-item-details {
    flex-grow: 1;
}

.cart-item-name {
    font-weight: bold;
}

.cart-item-modifier {
    font-size: 0.8rem;
    color: var(--accent-yellow);
}

.cart-item-price {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.cart-item-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.cart-item-btn {
    background: var(--bg-dark);
    border: 1px solid var(--border-color);
    color: white;
    width: 25px;
    height: 25px;
    border-radius: 4px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    font-weight: bold;
}

.cart-item-btn:hover {
    background: var(--border-color);
}

.cart-footer {
    padding: 20px;
    border-top: 1px solid var(--border-color);
    background-color: var(--bg-surface);
    flex-shrink: 0;
}

.cart-total {
    display: flex;
    justify-content: space-between;
    font-size: 1.2rem;
    font-weight: bold;
    margin-bottom: 20px;
}

.cart-total-original {
    opacity: 0.55;
    font-size: 0.85em;
    font-weight: 400;
    margin-right: 6px;
}

.cart-total-discounted {
    color: var(--accent-green, #2e7d32);
}

/* Footer */
.site-footer {
    border-top: 2px solid var(--accent-yellow);
    background-color: var(--bg-surface);
    padding: 28px 5% 24px;
    margin-top: 40px;
}

.footer-content {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    text-align: center;
}

.footer-brand strong {
    font-family: var(--font-heading);
    color: var(--accent-yellow);
    font-size: 1.05rem;
}

.footer-brand p {
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-top: 2px;
}

.footer-hours {
    text-align: center;
}

.footer-hours strong {
    display: block;
    color: var(--accent-yellow);
    font-family: var(--font-heading);
    margin-bottom: 8px;
}

.footer-hours-list {
    list-style: none;
    display: grid;
    gap: 3px;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.footer-hours-list li {
    display: flex;
    justify-content: center;
    gap: 12px;
    min-width: 180px;
}

.footer-hours-list li span:first-child {
    width: 90px;
    text-align: right;
}

.footer-hours-list li span:last-child {
    width: 90px;
    text-align: left;
}

.footer-hours-today {
    color: var(--text-main);
    font-weight: 700;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px 18px;
}

.footer-link-btn {
    background: none;
    border: none;
    color: var(--text-main);
    text-decoration: underline;
    text-underline-offset: 3px;
    cursor: pointer;
    font-size: 0.85rem;
    text-transform: none;
    font-weight: 500;
    padding: 4px;
}

.footer-link-btn:hover {
    color: var(--accent-yellow);
}

.footer-link-btn.inline-link {
    display: inline;
    padding: 0;
}

.footer-copy {
    color: var(--text-muted);
    font-size: 0.78rem;
}

/* Cookie beleegyező sáv */
.cookie-banner {
    position: fixed;
    left: 16px;
    right: 16px;
    bottom: 16px;
    max-width: 720px;
    margin: 0 auto;
    background-color: var(--bg-surface);
    border: 1px solid var(--accent-yellow);
    border-radius: 14px;
    padding: 16px;
    box-shadow: 0 12px 30px rgba(0,0,0,0.5);
    z-index: 10030;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    justify-content: space-between;
    box-sizing: border-box;
}

.cookie-banner p {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.88rem;
    flex: 1 1 260px;
}

.cookie-banner-link {
    background: none;
    border: none;
    color: var(--accent-yellow);
    text-decoration: underline;
    cursor: pointer;
    font-size: 0.88rem;
    padding: 0;
    margin-left: 4px;
}

.cookie-banner-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    flex: 1 1 auto;
    justify-content: flex-end;
}

.cookie-banner-actions button {
    flex: 1 1 auto;
    min-width: 120px;
    padding: 10px 14px;
    font-size: 0.85rem;
    text-align: center;
    white-space: normal;
    word-break: break-word;
}

@media (max-width: 480px) {
    .cookie-banner {
        left: 10px;
        right: 10px;
        bottom: 10px;
        padding: 12px;
        gap: 10px;
    }
    .cookie-banner-actions {
        width: 100%;
        flex-direction: column;
    }
    .cookie-banner-actions button {
        width: 100%;
    }
}

/* Jogi dokumentum modalok */
.legal-content {
    overflow-y: auto;
    padding-right: 4px;
}

.legal-content h3 {
    margin-top: 22px;
}

.legal-content h3:first-child {
    margin-top: 0;
}

.legal-content p {
    line-height: 1.6;
}

.legal-list {
    list-style: none;
    display: grid;
    gap: 6px;
    margin-bottom: 20px;
    color: var(--text-muted);
    line-height: 1.6;
}

.legal-note {
    font-size: 0.85rem;
    font-style: italic;
    opacity: 0.8;
}

.cookie-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
    font-size: 0.88rem;
}

.cookie-table th,
.cookie-table td {
    border: 1px solid var(--border-color);
    padding: 8px 10px;
    text-align: left;
    color: var(--text-muted);
}

.cookie-table th {
    color: var(--text-main);
    background-color: var(--bg-surface-hover);
}

/* Modals */
body.modal-open {
    overflow: hidden;
    overscroll-behavior: none;
}

.modal-overlay {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0,0,0,0.82);
    backdrop-filter: blur(5px);
    z-index: 10040;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity var(--transition-speed), visibility var(--transition-speed);
}

.modal-overlay.active {
    display: flex !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
}

.modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.95);
    background-color: var(--bg-surface);
    padding: 30px;
    border-radius: 12px;
    z-index: 10050;
    display: flex;
    flex-direction: column;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity var(--transition-speed), transform var(--transition-speed), visibility var(--transition-speed);
    width: min(92vw, 520px);
    max-width: 520px;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    overflow-x: hidden;
    overflow-wrap: break-word;
    word-break: break-word;
    box-shadow: 0 12px 40px rgba(0,0,0,0.6);
    box-sizing: border-box;
}

.modal.active {
    display: flex !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    transform: translate(-50%, -50%) scale(1) !important;
}

.modal-wide {
    width: min(96vw, 1100px);
    max-width: 1100px;
    padding: 24px;
    box-sizing: border-box;
}

.modal h2, .modal h3 {
    margin-bottom: 15px;
    color: var(--accent-yellow);
}

.modal p {
    margin-bottom: 20px;
    color: var(--text-muted);
}

.modal-actions {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
}

.modal-close {
    align-self: flex-end;
    background: transparent;
    border: 0;
    color: var(--text-main);
    font-size: 1.7rem;
    cursor: pointer;
}

.product-detail-layout {
    display: grid;
    grid-template-columns: 1fr 1.1fr;
    gap: 24px;
    align-items: stretch;
    min-width: 0;
}

.product-detail-image {
    aspect-ratio: 4 / 3;
    align-self: start;
    border-radius: 18px;
    background-size: cover;
    background-position: center;
    border: 1px solid rgba(255,255,255,0.08);
    min-width: 0;
}

.product-detail-content {
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-width: 0;
    overflow-wrap: break-word;
    word-break: break-word;
}

.product-detail-price {
    color: var(--accent-yellow);
    font-weight: 700;
    font-size: 1.05rem;
}

.product-detail-options {
    display: grid;
    gap: 10px;
}

.product-detail-options label {
    display: grid;
    gap: 6px;
    color: var(--text-main);
    font-size: 0.95rem;
}

.product-detail-options select,
.product-detail-options input,
.product-detail-content textarea {
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 10px 12px;
    background: #161616;
    color: var(--text-main);
    font: inherit;
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
}

.product-detail-options select option,
.product-detail-options select optgroup {
    background: #161616;
    color: var(--text-main);
}

.product-note-label {
    color: var(--text-main);
    font-weight: 600;
}

@media (max-width: 900px) {
    .product-detail-layout {
        grid-template-columns: 1fr;
    }
}

/* Slot Machine Redesign */
.restaurant-status-banner {
    width: calc(100% - 10%);
    margin: 0 auto 20px;
    padding: 15px 20px;
    border-radius: 10px;
    background-color: rgba(255, 179, 0, 0.12);
    color: var(--text-main);
    border: 1px solid rgba(255,179,0,0.25);
    text-align: center;
    font-weight: 700;
}

.restaurant-status-banner.closed-status {
    background-color: rgba(211, 47, 47, 0.12);
    border-color: rgba(211,47,47,0.25);
}

.pickup-info-banner,
.pickup-callout {
    width: calc(100% - 10%);
    margin: 0 auto 16px;
    padding: 14px 18px;
    border-radius: 12px;
    background-color: rgba(255, 179, 0, 0.09);
    border: 1px solid rgba(255, 179, 0, 0.45);
    color: var(--text-main);
    line-height: 1.5;
    font-size: 0.96rem;
}

.pickup-info-banner strong,
.pickup-callout strong {
    color: var(--accent-yellow);
}

.pickup-link {
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: opacity 0.2s ease;
}

.pickup-link:hover {
    opacity: 0.9;
}

.wolt-link {
    color: #1a73e8;
    font-weight: 900;
}

.foodora-link {
    color: #ff4fa3;
    font-weight: 900;
}

.map-link {
    color: var(--text-main);
    font-weight: 700;
}

.pickup-info-banner span,
.pickup-callout span {
    display: block;
    margin-top: 6px;
    font-weight: 700;
}

.time-option-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.time-option-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    text-align: center;
    padding: 14px 10px;
    border-radius: 12px;
    background-color: var(--bg-dark);
    border: 1px solid var(--border-color);
    cursor: pointer;
    transition: border-color 0.2s ease, background-color 0.2s ease, transform 0.15s ease;
}

.time-option-card:hover {
    transform: translateY(-1px);
}

.time-option-card input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.time-option-card:has(input:checked) {
    border-color: var(--accent-yellow);
    background-color: rgba(255, 179, 0, 0.12);
}

.time-option-icon {
    font-size: 1.4rem;
    line-height: 1;
}

.time-option-text {
    font-weight: 700;
    font-size: 0.92rem;
}

.scheduled-time-panel {
    background-color: rgba(255, 179, 0, 0.06);
    border: 1px solid rgba(255, 179, 0, 0.25);
    border-radius: 12px;
    padding: 14px 16px;
    margin-top: 12px;
}

.scheduled-time-title {
    display: flex;
    align-items: center;
    gap: 8px;
}

.checkout-time-grid {
    display: grid;
    grid-template-columns: 1.1fr 0.8fr 0.8fr;
    gap: 10px;
    margin-bottom: 10px;
}

.checkout-time-grid select {
    appearance: none;
    background-color: var(--bg-dark);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 12px;
    color: var(--text-main);
}

.busy-warning {
    background-color: rgba(255, 179, 0, 0.14);
    border: 1px solid rgba(255,179,0,0.25);
    color: var(--text-main);
    padding: 12px;
    border-radius: 8px;
    font-size: 0.95rem;
}

.restaurant-busy-message {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(255,179,0,0.35);
    color: var(--accent-yellow);
    font-size: 1rem;
    line-height: 1.5;
}

.orders-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    gap: 15px;
}

.orders-controls h2 {
    margin-bottom: 6px;
}

.admin-order-subtitle {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.btn-busy-mode {
    min-width: 190px;
}

.slot-machine-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 15px;
    margin-bottom: 20px;
    width: 100%;
}

@media (max-width: 980px) {
    .slot-machine-grid {
        grid-template-columns: 1fr;
    }

    .modal-wide {
        padding: 16px;
    }
}

.slot-column-container {
    min-width: 0;

    background-color: var(--bg-dark);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    padding: 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.slot-image-window {
    width: 100%;
    height: 120px;
    background-color: #000;
    border-radius: 8px;
    overflow: hidden;
    position: relative;
    border: 1px solid var(--border-color);
}

.slot-image-spinner {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
}

.spinning-image {
    animation: imageSpin 0.15s infinite alternate ease-in-out;
}

@keyframes imageSpin {
    0% { transform: translateY(-15px) scale(1.05); filter: blur(2px); opacity: 0.8; }
    100% { transform: translateY(15px) scale(1.05); filter: blur(2px); opacity: 0.8; }
}

.slot-image-item {
    width: 100%;
    height: 120px;
    background-size: cover;
    background-position: center;
    flex-shrink: 0;
}

.slot-result-name {
    font-weight: bold;
    text-align: center;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
}

.btn-slot-respin {
    font-size: 0.8rem;
    padding: 6px;
}

/* Forms */
.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: var(--text-muted);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px;
    background-color: var(--bg-dark);
    border: 1px solid var(--border-color);
    color: var(--text-main);
    border-radius: 6px;
    font-family: var(--font-body);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-yellow);
}

.radio-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.radio-group label {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.error-text {
    color: #ffb3b3;
    margin-top: 6px;
    font-size: 0.85rem;
    min-height: 1.1em;
}

/* Upsell Grid */
.upsell-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 20px;
}

.upsell-item {
    background-color: var(--bg-dark);
    padding: 10px;
    border-radius: 8px;
    text-align: center;
    border: 1px solid var(--border-color);
    cursor: pointer;
    transition: border-color var(--transition-speed);
}

.upsell-item:hover {
    border-color: var(--accent-yellow);
}

.upsell-item h4 {
    font-size: 0.9rem;
    margin-bottom: 5px;
}

.upsell-item .price {
    color: var(--accent-yellow);
    font-size: 0.9rem;
    font-weight: bold;
}

/* Order Tracking Modal */
.modal-tracking {
    max-width: 400px;
    text-align: center;
    padding: 40px 30px;
    border-top: 3px solid var(--accent-yellow);
}

.tracking-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    margin-bottom: 30px;
}

.tracking-icon {
    font-size: 3rem;
    animation: pulse 2s infinite;
}

.tracking-timer-container {
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Circular countdown timer */
.timer-circle {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 4px solid var(--accent-yellow);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    font-weight: bold;
    font-family: var(--font-heading);
    color: var(--accent-yellow);
    box-shadow: 0 0 20px var(--accent-yellow-glow);
    animation: timerPulse 1s ease-in-out infinite alternate;
}

@keyframes timerPulse {
    from { box-shadow: 0 0 10px var(--accent-yellow-glow); }
    to { box-shadow: 0 0 30px rgba(255, 179, 0, 0.8); }
}

/* Pulse loader while waiting */
.loader-pulse {
    color: var(--text-muted);
    font-size: 1.1rem;
    animation: fadeInOut 1.5s infinite;
}

@keyframes fadeInOut {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 1; }
}

/* ==================== MOBILE OPTIMIZATION ==================== */

@media (max-width: 768px) {
    .main-header {
        display: grid;
        grid-template-columns: 1fr auto auto auto;
        gap: 10px;
        padding: 12px 3%;
        align-items: center;
    }

    .logo {
        grid-column: 1;
        min-width: 0;
    }

    .logo h1 {
        font-size: 1.2rem;
    }

    .tagline {
        font-size: 0.6rem;
    }

    .btn-mobile-menu {
        display: flex;
        grid-column: 3;
        justify-self: end;
        padding: 8px;
    }

    .header-actions {
        display: flex !important;
        position: static;
        grid-column: 4;
        justify-content: flex-end;
        background: transparent;
        border: none;
        gap: 8px;
        padding: 0;
        z-index: auto;
        flex-wrap: nowrap;
    }

    /* A logó és a hamburger menü gomb közé kerül, ne a zsúfolt header-actions sorba. */
    .lang-switcher {
        grid-column: 2;
        justify-self: end;
        position: relative;
    }

    .lang-dropdown {
        right: 0;
        left: auto;
    }

    .mobile-menu-panel {
        display: none;
        grid-column: 1 / -1;
        flex-direction: column;
        gap: 8px;
        background: var(--bg-surface);
        border: 1px solid var(--border-color);
        border-radius: 12px;
        padding: 12px;
        margin-top: 4px;
        box-shadow: 0 14px 28px rgba(0,0,0,0.16);
    }

    .mobile-menu-panel.active {
        display: flex !important;
    }

    .header-actions.active {
        display: flex !important;
    }

    .header-actions > * {
        flex-shrink: 0;
    }

    #btn-slot-machine {
        order: 1;
        min-width: 0;
        white-space: nowrap;
        padding: 10px 12px;
        font-size: 0.75rem;
        font-weight: 700;
        background: linear-gradient(135deg, var(--accent-yellow), #f9c74f);
        color: var(--text-dark);
        box-shadow: 0 8px 20px rgba(255, 189, 56, 0.28);
    }

    #btn-cart-toggle {
        order: 2;
        padding: 10px 12px;
        font-size: 0.75rem;
    }

    #btn-login, #btn-profile {
        display: none;
    }

    .header-actions button {
        width: auto;
        padding: 10px 12px;
        font-size: 0.75rem;
    }

    .menu-container {
        padding: 20px 3%;
    }

    .category-section {
        margin-bottom: 30px;
    }

    .category-title {
        font-size: 1.4rem;
    }

    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
        gap: 12px;
    }

    .product-card {
        border-radius: 8px;
    }

    .product-info {
        padding: 12px;
    }

    .product-name {
        font-size: 1rem;
    }

    .product-price {
        font-size: 1rem;
        margin-top: auto;
        margin-bottom: 12px;
    }

    .product-desc {
        font-size: 0.8rem;
        margin-bottom: 10px;
        flex: 1 1 auto;
    }

    .btn-primary, .btn-secondary, .btn-icon {
        padding: 10px 15px;
        font-size: 0.85rem;
    }

    /* Modal optimizations for mobile */
    .modal {
        width: 95vw !important;
        max-width: 95vw !important;
        margin: auto;
        padding: 16px;
        border-radius: 12px;
    }

    .modal-wide {
        width: 95vw !important;
        max-width: 95vw !important;
    }

    h3 {
        font-size: 1.3rem;
    }

    /* Form optimization */
    .form-group {
        margin-bottom: 15px;
    }

    .form-group input, .form-group select, .form-group textarea {
        font-size: 16px; /* Prevents zoom on iOS */
        padding: 12px;
        width: 100%;
    }

    .modal-actions {
        flex-direction: column;
        gap: 10px;
    }

    .modal-actions button {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .main-header {
        grid-template-columns: 1fr auto auto;
        gap: 8px;
        padding: 10px 3%;
    }

    .logo {
        text-align: left;
        width: auto;
        grid-column: 1;
    }

    .logo h1 {
        font-size: 1rem;
    }

    .tagline {
        font-size: 0.55rem;
    }

    .lang-switcher {
        grid-column: 2;
    }

    .btn-mobile-menu {
        grid-column: 3;
    }

    .header-actions {
        grid-column: 1 / -1;
        justify-content: center;
        gap: 6px;
    }

    #btn-slot-machine,
    #btn-cart-toggle {
        padding: 9px 10px;
        font-size: 0.7rem;
    }

    .menu-container {
        padding: 10px 2%;
    }

    .product-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    .product-card {
        border-radius: 6px;
    }

    .product-info {
        padding: 8px;
    }

    .product-name {
        font-size: 0.9rem;
        margin-bottom: 5px;
    }

    .product-price {
        font-size: 0.9rem;
        margin-top: auto;
        margin-bottom: 8px;
    }

    .product-desc {
        font-size: 0.75rem;
        margin-bottom: 6px;
        flex: 1 1 auto;
    }

    .add-to-cart-btn {
        padding: 8px 10px;
        font-size: 0.8rem;
    }

    /* Cart Panel - Full screen on tiny mobile */
    .cart-panel {
        width: 100%;
        right: -100%;
    }

    .cart-header {
        padding: 15px;
    }

    .cart-header h2 {
        font-size: 1.1rem;
    }

    .cart-items {
        padding: 15px;
    }

    .cart-item {
        padding-bottom: 12px;
        margin-bottom: 12px;
    }

    .cart-item-name {
        font-size: 0.9rem;
    }

    .cart-item-modifier {
        font-size: 0.7rem;
    }

    .cart-footer {
        padding: 15px;
    }

    .cart-total {
        font-size: 0.9rem;
        margin-bottom: 10px;
    }

    /* Modals */
    .modal {
        width: 92vw !important;
        padding: 12px;
    }

    .modal h2, .modal h3 {
        font-size: 1.1rem;
        margin-bottom: 10px;
    }

    .modal p {
        font-size: 0.9rem;
    }

    .form-group label {
        font-size: 0.9rem;
    }

    .form-group input, .form-group select, .form-group textarea {
        font-size: 16px;
        padding: 10px;
    }

    .btn-primary, .btn-secondary, .btn-icon {
        padding: 10px 12px;
        font-size: 0.8rem;
    }

    .badge {
        font-size: 0.7rem;
        padding: 1px 6px;
    }

    /* Slot machine */
    .slot-machine-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .slot-image-window {
        height: 120px;
    }

    .slot-result-name {
        font-size: 0.9rem;
        margin: 8px 0;
    }

    /* Checkout form */
    .checkout-time-grid {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .checkout-time-grid select {
        padding: 10px;
    }

    /* Timer circle - smaller on tiny screens */
    .timer-circle {
        width: 80px;
        height: 80px;
        font-size: 1.5rem;
    }
}
