/* === ИТАЛ Пицца — стили === */
:root {
    --bg: #1a1510;
    --bg-card: #252019;
    --text: #f5ebe0;
    --accent: #e07c3c;
}

/* Ссылка «Перейти к содержимому» — видна только при фокусе с клавиатуры */
.skip-link {
    position: absolute;
    left: 0.5rem;
    top: 0.5rem;
    padding: 0.6rem 1rem;
    background: var(--accent);
    color: #1a1510;
    font-weight: 600;
    text-decoration: none;
    border-radius: 6px;
    z-index: 1000;
    transform: translateY(-120%);
    transition: transform 0.2s;
}
.skip-link:focus {
    transform: translateY(0);
    outline: 2px solid var(--text);
    outline-offset: 2px;
}

/* Фокус для клавиатурной навигации */
a:focus-visible,
button:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

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

body {
    font-family: 'Source Sans 3', sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    overflow-x: hidden;
}

.header {
    position: relative;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.5rem 1.5rem;
    gap: 0.75rem;
}

.header-brand {
    text-align: left;
}

.logo {
    font-family: 'Playfair Display', serif;
    font-size: clamp(1.8rem, 5vw, 2.5rem);
    font-weight: 700;
    text-decoration: none;
    letter-spacing: 0.02em;
}
/* Цвета флага Италии в названии: зелёный, белый, красный */
.logo-ita { color: #009246; }
.logo-lpi { color: #FFFFFF; text-shadow: 0 0 1px rgba(0,0,0,0.3); }
.logo-cca { color: #CE2B37; }

.tagline {
    font-size: 0.95rem;
    color: rgba(245, 235, 224, 0.7);
    margin-top: 0.25rem;
}

.header-meta {
    font-size: 0.85rem;
    color: rgba(245, 235, 224, 0.6);
    margin-top: 0.1rem;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-left: auto;
}

.header-worktime {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    font-size: 0.8rem;
    color: rgba(245, 235, 224, 0.7);
}

.header-worktime-label {
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.7rem;
    opacity: 0.7;
}

.header-worktime-value {
    font-weight: 600;
}

.header-phone {
    display: inline-block;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text);
    text-decoration: none;
    letter-spacing: 0.02em;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    transition: background 0.2s, color 0.2s;
    white-space: nowrap;
    margin-left: auto;
}
.header-phone:hover {
    color: var(--accent);
    background: rgba(224, 124, 60, 0.15);
}
.header-phone:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}
@media (max-width: 480px) {
    .header-phone {
        font-size: 1.2rem;
        padding: 0.65rem 1rem;
        min-height: 44px;
        line-height: 1.3;
        box-sizing: border-box;
    }
}

.main {
    display: flex;
    justify-content: flex-start;
    align-items: stretch;
    min-height: calc(100vh - 140px);
    padding: 2rem 1rem;
    padding-top: 5vh;
    gap: 2rem;
}

.sidebar {
    flex-shrink: 0;
    width: 220px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    padding: 1rem 0;
    border: 1px solid rgba(255, 255, 255, 0.08);
    align-self: flex-start;
    position: relative;
    z-index: 20;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.sidebar-link {
    display: block;
    padding: 0.65rem 1rem;
    margin: 0 0.5rem;
    font-size: 0.95rem;
    font-weight: 500;
    color: rgba(245, 235, 224, 0.6);
    text-decoration: none;
    border-radius: 8px;
    transition: background 0.2s, color 0.2s;
}

.sidebar-link:hover {
    color: var(--text);
    background: rgba(255, 255, 255, 0.06);
}

.sidebar-link.active {
    background: rgba(224, 124, 60, 0.25);
    color: var(--text);
}

/* === Сетка пицц (главная) === */
.pizza-grid-wrapper {
    flex: 1;
    min-width: 0;
    padding: 0 1rem;
}

.pizza-grid-heading {
    font-family: 'Playfair Display', serif;
    font-size: 1.6rem;
    margin-bottom: 1.25rem;
    color: var(--text);
}

.pizza-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.25rem;
}

.pizza-grid-card {
    display: flex;
    flex-direction: column;
    background: var(--bg-card);
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    padding: 1rem;
    color: var(--text);
    transition: transform 0.2s, box-shadow 0.2s;
}

.pizza-grid-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}

.pizza-grid-card-link {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: var(--text);
    flex: 1;
}

.pizza-grid-card-btn {
    display: block;
    width: 100%;
    padding: 0.6rem;
    border: none;
    border-radius: 8px;
    background: var(--accent);
    color: #fff;
    font-size: 0.9rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s;
    margin-top: 0.6rem;
}

.pizza-grid-card-btn:hover:not(:disabled) {
    background: #c9551f;
    transform: scale(1.02);
}

.pizza-grid-card-btn:disabled {
    background: #555;
    cursor: not-allowed;
    opacity: 0.7;
}

.pizza-grid-card-btn-added {
    background: #27ae60;
    pointer-events: none;
}

.pizza-grid-slice-btn {
    display: block;
    width: 100%;
    margin-top: 0.4rem;
    padding: 0.5rem 0.6rem;
    border: 1px solid rgba(224, 124, 60, 0.55);
    border-radius: 8px;
    background: transparent;
    color: var(--accent);
    font-size: 0.85rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.2s;
}

.pizza-grid-slice-btn:hover {
    background: rgba(224, 124, 60, 0.12);
}

.pizza-grid-slice-btn-primary {
    background: var(--accent);
    color: #1a1510;
    border-color: var(--accent);
}

.pizza-grid-slice-btn-primary:hover {
    background: #c9551f;
    color: #1a1510;
}

.ready-intro {
    margin: -0.5rem 0 1.25rem;
    color: rgba(245, 235, 224, 0.72);
    font-size: 0.98rem;
    line-height: 1.45;
    max-width: 36rem;
}

.ready-empty {
    margin: 1.5rem 0 2rem;
    padding: 1.25rem 1rem;
    color: rgba(245, 235, 224, 0.75);
    line-height: 1.55;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
}

.ready-empty a {
    color: var(--accent);
    font-weight: 600;
}

.ready-teaser {
    display: block;
    margin: 0 0 1rem;
    padding: 0.75rem 1rem;
    border-radius: 10px;
    background: rgba(224, 124, 60, 0.14);
    border: 1px solid rgba(224, 124, 60, 0.4);
    color: var(--accent);
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s;
}

.ready-teaser:hover {
    background: rgba(224, 124, 60, 0.22);
}

.pizza-grid-card-ready {
    position: relative;
}

.ready-badge {
    display: inline-block;
    margin-bottom: 0.55rem;
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    background: rgba(39, 174, 96, 0.2);
    color: #7ddea8;
    font-size: 0.75rem;
    font-weight: 600;
}

.pizza-grid-ready-whole {
    display: block;
    margin-top: 0.55rem;
    text-align: center;
    font-size: 0.85rem;
    color: rgba(245, 235, 224, 0.65);
    text-decoration: none;
}

.pizza-grid-ready-whole:hover {
    color: var(--accent);
}

.pizza-grid-card-out {
    opacity: 0.55;
    position: relative;
}

.product-card-out {
    opacity: 0.55;
    position: relative;
}

.product-card-out-label {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #c0392b;
    color: #fff;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 4px;
    z-index: 5;
}

.product-card-add:disabled {
    background: #555;
    cursor: not-allowed;
    opacity: 0.7;
}

.pizza-grid-card-image {
    width: 100%;
    aspect-ratio: 1;
    border-radius: 50%;
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
    background-color: transparent;
    margin-bottom: 0.75rem;
}

.pizza-grid-card-name {
    font-family: 'Playfair Display', serif;
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 0.35rem;
}

.pizza-grid-card-ingredients {
    font-size: 0.82rem;
    color: rgba(245, 235, 224, 0.6);
    line-height: 1.4;
    margin-bottom: 0.5rem;
    flex: 1;
}

.pizza-grid-card-price {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 0.6rem;
}


.footer {
    text-align: center;
    padding: 1rem;
    font-size: 0.9rem;
    color: rgba(245, 235, 224, 0.5);
}

.footer.footer-rich {
    text-align: left;
    padding: 2rem 1.5rem 1.25rem;
    margin-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.15), rgba(0, 0, 0, 0.35));
}

.footer-inner {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.1fr 1.2fr 1.2fr;
    gap: 1.5rem;
    align-items: start;
}

.footer-logo {
    font-family: 'Playfair Display', serif;
    font-size: 1.25rem;
    color: var(--text);
    margin: 0 0 0.35rem;
}

.footer-tag {
    margin: 0;
    color: rgba(245, 235, 224, 0.65);
    font-size: 0.95rem;
    line-height: 1.4;
}

.footer-contacts p {
    margin: 0 0 0.55rem;
    color: rgba(245, 235, 224, 0.8);
    font-size: 0.95rem;
    line-height: 1.45;
}

.footer-label {
    display: inline-block;
    min-width: 4.5rem;
    color: rgba(245, 235, 224, 0.45);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-right: 0.35rem;
}

.footer-maps {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-top: 0.75rem !important;
}

.footer-map-link {
    display: inline-block;
    padding: 0.4rem 0.75rem;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.04);
    color: rgba(245, 235, 224, 0.85) !important;
    font-size: 0.85rem;
}

.footer-map-link:hover {
    border-color: var(--accent);
    color: var(--accent) !important;
}

.footer-map-wrap {
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    min-height: 180px;
    background: rgba(0, 0, 0, 0.25);
}

.footer-map {
    display: block;
    width: 100%;
    height: 180px;
    border: 0;
}

.footer-copy {
    max-width: 1100px;
    margin: 1.25rem auto 0;
    text-align: center;
    font-size: 0.8rem;
    color: rgba(245, 235, 224, 0.35);
}

@media (max-width: 900px) {
    .footer-inner {
        grid-template-columns: 1fr;
    }

    .footer-map {
        height: 200px;
    }
}

.info-section {
    padding: 2rem 1.5rem 3rem;
    background: radial-gradient(circle at top, rgba(224, 124, 60, 0.12), transparent 55%);
}

.info-columns {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem;
}

.info-block {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 1.25rem 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.info-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.2rem;
    margin-bottom: 0.75rem;
    color: var(--text);
}

.info-list {
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 0.95rem;
    color: rgba(245, 235, 224, 0.8);
}

.info-list li + li {
    margin-top: 0.25rem;
}

.payment-icons {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.75rem;
}

.payment-icon {
    padding: 0.25rem 0.6rem;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.payment-icon-visa {
    background: linear-gradient(135deg, #1a1f71, #0043ce);
}

.payment-icon-mc {
    background: linear-gradient(135deg, #ff5f00, #eb001b);
}

.payment-icon-mir {
    background: linear-gradient(135deg, #00b488, #007b62);
}


/* === Страница пиццы и заказа === */
.main-pizza-page {
    align-items: flex-start;
    padding: 2rem 1rem 4rem;
}

.main-pizza-page .pizza-detail {
    flex: 1;
}

.pizza-detail {
    max-width: 640px;
    margin: 0 auto;
    width: 100%;
    position: relative;
}

.pizza-detail-hero {
    display: grid;
    grid-template-columns: 140px 1fr;
    gap: 1.5rem;
    align-items: start;
    margin-bottom: 2.5rem;
}

.pizza-detail-image {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
    background-color: transparent;
    box-shadow: none;
    border: none;
}

.pizza-detail-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.75rem;
    color: var(--accent);
    margin-bottom: 0.5rem;
}

.pizza-detail-desc {
    color: rgba(245, 235, 224, 0.9);
    line-height: 1.5;
    margin-bottom: 0.75rem;
}

.pizza-detail-ingredients {
    font-size: 0.9rem;
    color: rgba(245, 235, 224, 0.7);
    margin-bottom: 0.5rem;
}

.pizza-detail-weight {
    font-size: 0.9rem;
    color: rgba(245, 235, 224, 0.6);
    margin-bottom: 0.3rem;
}

.pizza-detail-price {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 0.75rem;
}

.pizza-detail-cart-btn {
    display: inline-block;
    padding: 0.7rem 2rem;
    border: none;
    border-radius: 8px;
    background: var(--accent);
    color: #fff;
    font-size: 1rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s;
}

.pizza-detail-cart-btn:hover {
    background: #c9551f;
    transform: scale(1.03);
}

.pizza-detail-cart-btn-added {
    background: #27ae60;
    pointer-events: none;
}

.pizza-detail-cart-btn:disabled {
    background: #555;
    cursor: not-allowed;
    opacity: 0.7;
}

.pizza-detail-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-top: 0.25rem;
}

.pizza-detail-slice-btn {
    display: inline-block;
    padding: 0.7rem 1.25rem;
    border: 1px solid var(--accent);
    border-radius: 8px;
    background: transparent;
    color: var(--accent);
    font-size: 1rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s;
}

.pizza-detail-slice-btn:hover {
    background: rgba(224, 124, 60, 0.12);
    transform: scale(1.03);
}

.pizza-detail-slice-btn-added {
    background: rgba(39, 174, 96, 0.2);
    border-color: #27ae60;
    color: #27ae60;
    pointer-events: none;
}

.pizza-detail-slices-info {
    margin-top: 0.5rem;
    font-size: 0.88rem;
    color: rgba(245, 235, 224, 0.7);
}

.pizza-nav-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    color: var(--text);
    font-size: 1.4rem;
    cursor: pointer;
    transition: background 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pizza-nav-arrow:hover {
    background: rgba(224, 124, 60, 0.35);
}

.pizza-nav-prev {
    left: -10px;
}

.pizza-nav-next {
    right: -10px;
}

.order-section {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 1.5rem;
    border: 1px solid rgba(212, 165, 116, 0.2);
}

.order-section h2 {
    font-family: 'Playfair Display', serif;
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: var(--text);
}

.order-type-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.25rem;
}

.order-type-tabs .tab {
    flex: 1;
    padding: 0.65rem 1rem;
    font-family: inherit;
    font-size: 0.95rem;
    font-weight: 500;
    color: rgba(245, 235, 224, 0.8);
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
}

.order-type-tabs .tab:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text);
}

.order-type-tabs .tab.active {
    background: var(--accent);
    color: #1a1510;
    border-color: var(--accent);
}

.order-form .form-group {
    margin-bottom: 1rem;
}

.order-form label {
    display: block;
    font-size: 0.85rem;
    color: rgba(245, 235, 224, 0.8);
    margin-bottom: 0.35rem;
}

.form-required {
    color: #ffb3a2;
}

.form-hint {
    font-size: 0.8rem;
    color: rgba(245, 235, 224, 0.55);
    margin-top: 0.25rem;
}

.schedule-mode {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 18px;
    margin-bottom: 0.5rem;
}
.schedule-mode-option {
    display: inline-flex !important;
    align-items: center;
    gap: 0.45rem;
    margin: 0 !important;
    width: auto !important;
    max-width: 100%;
    cursor: pointer;
    font-size: 0.95rem !important;
    color: var(--text) !important;
    white-space: nowrap;
}
.order-form .schedule-mode-option input[type="radio"] {
    width: 18px !important;
    height: 18px !important;
    min-width: 18px;
    max-width: 18px;
    padding: 0 !important;
    margin: 0;
    flex-shrink: 0;
    accent-color: var(--accent);
    background: transparent;
    border: none;
    border-radius: 0;
    box-shadow: none;
    cursor: pointer;
}
.schedule-fields {
    margin-top: 0.35rem;
}
.schedule-fields[hidden] {
    display: none !important;
}
.date-select-row {
    display: grid;
    grid-template-columns: 0.7fr 1.4fr 0.9fr;
    gap: 8px;
    margin-bottom: 8px;
}
.order-form .date-select,
.order-form .time-select {
    width: 100%;
    padding: 0.65rem 0.7rem;
    font-family: inherit;
    font-size: 1rem;
    color: #f5ebe0;
    background: #2a231c;
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 8px;
    appearance: auto;
    color-scheme: dark;
}
.order-form .date-select option,
.order-form .time-select option {
    color: #1a1510;
    background: #f5ebe0;
}
.order-form .date-select:focus,
.order-form .time-select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 1px rgba(224, 124, 60, 0.45);
    background: #322a22;
}
.form-group-error .date-select,
.form-group-error .time-select {
    border-color: #ff8a80;
    box-shadow: 0 0 0 1px rgba(255, 138, 128, 0.4);
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    cursor: pointer;
    font-size: 0.95rem;
    color: #f5ebe0;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--accent);
    cursor: pointer;
    flex-shrink: 0;
}

.address-input-wrapper {
    position: relative;
}

.address-suggestions {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 100;
    background: #1e1a15;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-top: none;
    border-radius: 0 0 8px 8px;
    list-style: none;
    padding: 0;
    margin: 0;
    max-height: 200px;
    overflow-y: auto;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.address-suggestion-item {
    padding: 0.6rem 0.75rem;
    font-size: 0.9rem;
    color: #f5ebe0;
    cursor: pointer;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    transition: background 0.15s;
}

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

.address-suggestion-item:hover {
    background: rgba(224, 124, 60, 0.15);
}

.delivery-cost-info {
    margin-top: 0.5rem;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 500;
}

.delivery-cost-loading {
    color: #aaa;
    background: rgba(255, 255, 255, 0.05);
}

.delivery-cost-ok {
    color: #27ae60;
    background: rgba(39, 174, 96, 0.1);
}

.delivery-cost-error {
    color: #e74c3c;
    background: rgba(231, 76, 60, 0.1);
}

.order-total-summary {
    margin-top: 1rem;
    padding: 0.75rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.order-total-row {
    display: flex;
    justify-content: space-between;
    padding: 0.3rem 0;
    font-size: 0.9rem;
    color: rgba(245, 235, 224, 0.8);
}

.order-total-final {
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    margin-top: 0.3rem;
    padding-top: 0.5rem;
    font-size: 1.05rem;
    font-weight: 700;
    color: #f5ebe0;
}

.form-error {
    font-size: 0.8rem;
    color: #ffb3a2;
    margin-top: 0.25rem;
}

.form-group-error input,
.form-group-error textarea {
    border-color: #ff8a80;
    box-shadow: 0 0 0 1px rgba(255, 138, 128, 0.4);
}

.checkout-subtitle {
    text-align: center;
    font-size: 0.95rem;
    color: rgba(245, 235, 224, 0.75);
    margin-top: -0.5rem;
    margin-bottom: 1.5rem;
}

.order-form input,
.order-form textarea {
    width: 100%;
    padding: 0.65rem 0.9rem;
    font-family: inherit;
    font-size: 1rem;
    color: var(--text);
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
}

.order-form input::placeholder,
.order-form textarea::placeholder {
    color: rgba(245, 235, 224, 0.4);
}

.order-form textarea {
    resize: vertical;
    min-height: 60px;
}

.btn-submit {
    width: 100%;
    margin-top: 0.5rem;
    padding: 0.9rem;
    font-family: inherit;
    font-size: 1rem;
    font-weight: 600;
    color: #1a1510;
    background: var(--accent);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
}

.btn-submit:hover {
    background: #e89a5a;
}

.btn-submit:active {
    transform: scale(0.98);
}

.footer a {
    color: rgba(245, 235, 224, 0.6);
    text-decoration: none;
}

.footer a:hover {
    color: var(--accent);
}

/* === Страница категории и карточки товаров === */
.main-category {
    align-items: flex-start;
}

.main-category .sidebar {
    position: sticky;
    top: 1rem;
}

.category-content {
    flex: 1;
    max-width: 1200px;
    padding: 0 0.5rem;
}

.category-title {
    font-family: 'Playfair Display', serif;
    font-size: clamp(1.75rem, 4vw, 2.25rem);
    font-weight: 700;
    color: var(--text);
    margin-bottom: 1.5rem;
}

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

.product-card {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, 0.08);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    position: relative;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.product-card:hover {
    border-color: rgba(224, 124, 60, 0.3);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}

.product-card-image {
    width: 100%;
    aspect-ratio: 1;
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
}

.product-card-info {
    position: absolute;
    top: 0.7rem;
    right: 0.7rem;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.5);
    background: rgba(0, 0, 0, 0.5);
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: background 0.15s, border-color 0.15s, transform 0.1s;
}

.product-card-info:hover {
    background: rgba(0, 0, 0, 0.7);
    border-color: var(--accent);
}

.product-card-info:active {
    transform: scale(0.94);
}

.product-card-name {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text);
    margin: 0.75rem 1rem 0.25rem;
    line-height: 1.3;
}

.product-card-desc {
    font-size: 0.85rem;
    color: rgba(245, 235, 224, 0.7);
    line-height: 1.4;
    margin: 0 1rem;
    flex: 1;
}

.product-card-price {
    font-size: 1.25rem;
    font-weight: 700;
    color: #f4d35e;
    margin: 0.65rem 1rem 0.1rem;
}

.product-card-weight {
    font-size: 0.85rem;
    color: rgba(245, 235, 224, 0.7);
    margin: 0 1rem 0.9rem;
}

.product-card-add {
    position: absolute;
    bottom: 1rem;
    right: 1rem;
    min-width: 72px;
    height: 40px;
    padding: 0 0.9rem;
    border: none;
    border-radius: 999px;
    background: #c45c4a;
    color: #fff;
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    line-height: 1;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, transform 0.1s, box-shadow 0.2s;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
}

.product-card-add:hover {
    background: #a84a3a;
}

.product-card-add:active {
    transform: scale(0.96);
}

.product-info-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.65);
    z-index: 120;
    padding: 1rem;
}

.product-info-modal-visible {
    display: flex;
}

/* Combo modal */
.combo-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.65);
    z-index: 130;
    padding: 1rem;
}

.combo-modal-visible {
    display: flex;
}

.combo-modal-dialog {
    max-width: 440px;
    width: 100%;
    max-height: min(90vh, 720px);
    display: flex;
    flex-direction: column;
    background: var(--bg-card);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 1.5rem;
    position: relative;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.6);
    overflow: hidden;
}

.combo-modal-close {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.4);
    background: transparent;
    color: rgba(245, 235, 224, 0.9);
    cursor: pointer;
    font-size: 1rem;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.combo-modal-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.3rem;
    margin: 0 2rem 1rem 0;
    color: var(--text);
    flex-shrink: 0;
}

.combo-modal-choices {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    flex: 1 1 auto;
    min-height: 0;
    padding-right: 0.25rem;
}

.combo-modal-choices::-webkit-scrollbar {
    width: 8px;
}

.combo-modal-choices::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.25);
    border-radius: 4px;
}

.combo-modal-choices::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
}

.combo-choice-group {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.combo-choice-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: rgba(245, 235, 224, 0.7);
}

.combo-choice-select {
    padding: 0.55rem 0.75rem;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    background: #1a1510;
    color: #f5ebe0;
    font-size: 0.95rem;
    font-family: inherit;
    cursor: pointer;
    appearance: auto;
}

.combo-choice-select option {
    background: #252019;
    color: #f5ebe0;
    padding: 0.4rem;
}

.combo-choice-select optgroup {
    background: #1a1510;
    color: #e07c3c;
    font-weight: 600;
}

.combo-choice-select:focus {
    outline: 2px solid var(--accent);
    outline-offset: 1px;
}

.combo-modal-submit {
    display: block;
    width: 100%;
    padding: 0.7rem;
    border: none;
    border-radius: 8px;
    background: var(--accent);
    color: #fff;
    font-size: 1rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.2s;
    flex-shrink: 0;
}

.combo-modal-submit:hover {
    background: #c9551f;
}

.product-info-dialog {
    max-width: 420px;
    width: 100%;
    background: var(--bg-card);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 1.25rem 1.5rem 1.25rem;
    position: relative;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.6);
}

.product-info-close {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.4);
    background: transparent;
    color: rgba(245, 235, 224, 0.9);
    cursor: pointer;
    font-size: 1rem;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-info-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.3rem;
    margin-bottom: 0.4rem;
}

.product-info-desc {
    font-size: 0.95rem;
    color: rgba(245, 235, 224, 0.8);
    margin-bottom: 0.4rem;
}

.product-info-weight {
    font-size: 0.85rem;
    color: rgba(245, 235, 224, 0.65);
    margin-bottom: 0.4rem;
}

.product-info-bju {
    font-size: 0.85rem;
    color: rgba(245, 235, 224, 0.9);
    margin-top: 0.4rem;
}

.product-info-portion {
    margin-bottom: 0.4rem;
    color: rgba(245, 235, 224, 0.8);
}

.product-bju-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.82rem;
}

.product-bju-table th,
.product-bju-table td {
    border: 1px solid rgba(245, 235, 224, 0.25);
    padding: 0.25rem 0.35rem;
    text-align: center;
}

.product-bju-table th {
    background: rgba(255, 255, 255, 0.06);
    font-weight: 600;
}

/* Блок "Добавить к заказу" на странице пиццы */
.add-to-order {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 1.25rem;
    border: 1px solid rgba(212, 165, 116, 0.2);
    margin-bottom: 1.5rem;
}

.add-to-order h2 {
    font-family: 'Playfair Display', serif;
    font-size: 1.15rem;
    margin-bottom: 0.75rem;
    color: var(--text);
}

.add-to-order-text {
    font-size: 0.9rem;
    color: rgba(245, 235, 224, 0.7);
    margin-bottom: 0.75rem;
}

.add-to-order-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.add-to-order-links a {
    display: inline-block;
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
    color: var(--text);
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 8px;
    text-decoration: none;
    transition: background 0.2s, border-color 0.2s;
}

.add-to-order-links a:hover {
    background: rgba(224, 124, 60, 0.2);
    border-color: var(--accent);
}

/* Секция доп. ингредиентов на странице пиццы */
.pizza-extras-section {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 1.25rem;
    border: 1px solid rgba(212, 165, 116, 0.2);
    margin-bottom: 1.5rem;
}

.pizza-extras-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.15rem;
    margin-bottom: 0.35rem;
    color: var(--text);
}

.pizza-extras-desc {
    font-size: 0.9rem;
    color: rgba(245, 235, 224, 0.7);
    margin-bottom: 1rem;
}

.pizza-extras-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.pizza-extra-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: rgba(0, 0, 0, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    font-size: 0.9rem;
}

.pizza-extra-name {
    color: var(--text);
}

.pizza-extra-price {
    color: #f4d35e;
    font-weight: 600;
}

.pizza-extra-add {
    padding: 0.35rem 0.65rem;
    font-size: 0.85rem;
    font-weight: 500;
    color: #1a1510;
    background: var(--accent);
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s;
}

.pizza-extra-add:hover {
    background: #e89a5a;
}

.add-to-order-section {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 1.25rem;
    border: 1px solid rgba(212, 165, 116, 0.2);
}

.add-to-order-section h2 {
    font-family: 'Playfair Display', serif;
    font-size: 1.15rem;
    margin-bottom: 0.5rem;
    color: var(--text);
}

/* === Блокнот «Ваш заказ» справа === */
#order-notepad {
    position: fixed;
    right: 1rem;
    top: calc(11rem + 5vh);
    z-index: 100;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

#order-notepad.order-notepad-visible {
    opacity: 1;
    pointer-events: auto;
}

.notepad-paper {
    width: 280px;
    min-height: 120px;
    background: #f5f0e6;
    background-image: linear-gradient(to bottom, transparent 0%, transparent 31px, rgba(0,0,0,0.04) 31px);
    background-size: 100% 32px;
    box-shadow: 2px 2px 12px rgba(0,0,0,0.35), 0 0 0 1px rgba(0,0,0,0.08), 6px 0 8px -4px rgba(0,0,0,0.15);
    border-radius: 2px 2px 8px 8px;
    padding: 12px 14px 16px;
    position: relative;
    font-family: 'Source Sans 3', sans-serif;
}

.notepad-paper::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 20px;
    background: linear-gradient(to right, rgba(0,0,0,0.06) 0%, transparent 100%);
    border-radius: 2px 0 0 8px;
    pointer-events: none;
}

.notepad-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.1rem;
    font-weight: 700;
    color: #2c2419;
    margin-bottom: 8px;
    padding-bottom: 6px;
    border-bottom: 1px solid rgba(0,0,0,0.12);
    line-height: 1.3;
}

.notepad-lines {
    margin-bottom: 10px;
}

.notepad-row {
    display: flex;
    align-items: center;
    gap: 6px;
    min-height: 28px;
    padding: 4px 0;
    border-bottom: 1px dashed rgba(0,0,0,0.08);
    font-size: 0.9rem;
    color: #2c2419;
}

.notepad-row:last-child {
    border-bottom: none;
}

.notepad-extras-header {
    font-size: 0.8rem;
    color: #5c5348;
    padding: 2px 0 2px 26px;
    margin-top: 2px;
    border-bottom: none;
}

.notepad-row-extra {
    padding-left: 26px;
}

.notepad-row-extra .notepad-item-name {
    font-size: 0.85rem;
}

.notepad-btn {
    flex-shrink: 0;
    width: 26px;
    height: 26px;
    border: 1px solid rgba(0,0,0,0.2);
    border-radius: 4px;
    background: #fff;
    color: #2c2419;
    font-size: 1.1rem;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s, border-color 0.15s;
}

.notepad-btn:hover {
    background: #e8e0d0;
    border-color: rgba(0,0,0,0.3);
}

.notepad-item-name {
    flex: 1;
    min-width: 0;
    line-height: 1.35;
}

.notepad-total {
    font-weight: 600;
    font-size: 0.95rem;
    color: #2c2419;
    margin-bottom: 6px;
}

.notepad-actions {
    display: flex;
    justify-content: space-between;
    gap: 0.5rem;
}

.notepad-clear {
    flex: 0 0 auto;
    padding: 0.45rem 0.75rem;
    font-size: 0.85rem;
    border-radius: 6px;
    border: 1px solid rgba(0,0,0,0.2);
    background: #fff;
    color: #2c2419;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
}

.notepad-clear:hover {
    background: #f0e6d8;
    border-color: rgba(0,0,0,0.3);
}

.notepad-done {
    flex: 1;
    text-align: center;
    padding: 0.6rem 1rem;
    font-size: 0.95rem;
    font-weight: 600;
    color: #1a1510;
    background: var(--accent);
    border-radius: 6px;
    text-decoration: none;
    transition: background 0.2s;
}

.notepad-done:hover {
    background: #e89a5a;
    color: #1a1510;
}

/* === Страница оформления заказа === */
.main-checkout {
    align-items: flex-start;
    padding: 2rem 1rem 4rem;
}

.checkout-content {
    max-width: 640px;
    margin: 0 auto;
    width: 100%;
}

.checkout-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.75rem;
    color: var(--text);
    margin-bottom: 1.5rem;
    text-align: center;
}

.order-status-card {
    background: var(--bg-card);
    border-radius: 16px;
    padding: 1.5rem 1.5rem 1.25rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    margin-top: 1rem;
}

.order-status-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1rem;
}

.order-status-label {
    font-size: 0.9rem;
    color: rgba(245, 235, 224, 0.8);
}

.order-status-state {
    font-size: 0.95rem;
    color: #f4d35e;
    margin-top: 0.2rem;
}

.order-status-time {
    text-align: right;
    font-size: 0.85rem;
    color: rgba(245, 235, 224, 0.75);
}

.order-status-body {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 1.3fr);
    gap: 1.5rem;
    margin-top: 0.5rem;
}

.order-status-block h2 {
    font-family: 'Playfair Display', serif;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.order-status-list {
    list-style: none;
    padding: 0;
    margin: 0 0 0.75rem 0;
    font-size: 0.95rem;
}

.order-status-list > li + li {
    margin-top: 0.25rem;
}

.order-status-sublist {
    list-style: none;
    padding-left: 1rem;
    margin-top: 0.2rem;
    font-size: 0.85rem;
    color: rgba(245, 235, 224, 0.75);
}

.order-status-total {
    font-weight: 600;
    color: #f4d35e;
}

.order-status-footer {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.25rem;
}

.order-status-btn-primary,
.order-status-btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.7rem 1.2rem;
    border-radius: 999px;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 600;
}

.order-status-btn-primary {
    background: var(--accent);
    color: #1a1510;
}

.order-status-btn-secondary {
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: rgba(245, 235, 224, 0.9);
}

@media (max-width: 700px) {
    .order-status-body {
        grid-template-columns: 1fr;
    }

    .order-status-time {
        text-align: left;
    }
}

.checkout-empty {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.checkout-empty a {
    color: var(--accent);
    text-decoration: none;
}

.checkout-body {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.checkout-summary.notepad-paper {
    box-shadow: 2px 2px 12px rgba(0,0,0,0.25), 0 0 0 1px rgba(0,0,0,0.08);
    margin-left: auto;
    margin-right: auto;
}

.checkout-list {
    list-style: none;
    margin: 0 0 10px 0;
    padding: 0;
    font-size: 0.9rem;
    color: #2c2419;
}

.checkout-list-item {
    padding: 4px 0;
    border-bottom: 1px dashed rgba(0,0,0,0.08);
}

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

.checkout-extras {
    list-style: none;
    margin: 0.25rem 0 0 0;
    padding: 0 0 0 1rem;
    font-size: 0.85rem;
    color: #4a4238;
}

.checkout-extras-title {
    font-weight: 600;
    color: #5c5348;
    margin-bottom: 0.15rem;
}

.checkout-extra-item {
    padding: 0.1rem 0;
}

/* === Адаптив под планшеты и мобильные === */
@media (max-width: 900px) {
    .main {
        flex-direction: column;
        padding: 1.25rem 1rem 2.5rem;
        padding-top: 1.25rem;
        gap: 1.25rem;
        min-height: auto;
    }

    .sidebar {
        width: 100%;
        padding: 0.5rem;
        border-radius: 12px;
    }

    .sidebar-nav {
        flex-direction: row;
        gap: 0.5rem;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
        padding: 0.25rem;
    }

    .sidebar-link {
        white-space: nowrap;
        margin: 0;
        padding: 0.65rem 0.9rem;
        min-height: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .main-category .sidebar {
        position: relative;
        top: auto;
    }
}

@media (max-width: 600px) {
    .pizza-detail-hero {
        grid-template-columns: 1fr;
        gap: 1rem;
        justify-items: center;
        text-align: center;
        margin-bottom: 1.75rem;
    }

    .pizza-detail-image {
        width: 120px;
        height: 120px;
    }

    .pizza-detail-title {
        font-size: 1.5rem;
    }

    .pizza-extras-list {
        flex-direction: column;
        align-items: stretch;
    }

    .pizza-extra-item {
        justify-content: space-between;
        width: 100%;
    }

    .product-grid {
        grid-template-columns: 1fr;
    }

    .product-card-add {
        position: static;
        width: 100%;
        height: 48px;
        border-radius: 0;
        margin-top: 0.75rem;
        font-size: 1.25rem;
    }

    .product-card {
        padding-bottom: 0;
    }
}

@media (max-width: 480px) {
    body.has-notepad.has-notepad-visible {
        padding-bottom: 240px;
    }

    .header {
        padding: 1rem 1rem 1.25rem;
    }

    .tagline {
        font-size: 0.9rem;
    }

    .pizza-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }

    .pizza-grid-card {
        padding: 0.75rem;
    }

    .pizza-grid-card-name {
        font-size: 0.95rem;
    }

    .pizza-grid-card-ingredients {
        font-size: 0.75rem;
    }

    /* Блокнот заказа превращаем в нижнюю панель */
    #order-notepad {
        left: 0;
        right: 0;
        top: auto;
        bottom: 0;
        padding: 0.75rem;
        display: flex;
        justify-content: center;
        pointer-events: none;
    }

    #order-notepad.order-notepad-visible {
        pointer-events: auto;
    }

    .notepad-paper {
        width: min(520px, calc(100vw - 1.5rem));
        max-height: 45vh;
        overflow: auto;
        border-radius: 12px;
    }

    .notepad-row {
        min-height: 36px;
        font-size: 0.95rem;
    }

    .notepad-btn {
        width: 32px;
        height: 32px;
        border-radius: 6px;
    }

    .notepad-done {
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .checkout-title {
        font-size: 1.6rem;
    }
}

/* Payment method tabs */
.payment-method-tabs {
    display: flex;
    gap: 8px;
    margin-top: 6px;
}

.payment-tab {
    flex: 1;
    padding: 10px 16px;
    border: 2px solid var(--bg-card, #e2e5ec);
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 500;
    font-family: inherit;
    transition: all 0.2s;
    text-align: center;
}

.payment-tab:hover:not(:disabled) {
    border-color: var(--primary, #e0592a);
    color: var(--primary, #e0592a);
}

.payment-tab.active {
    border-color: var(--primary, #e0592a);
    background: var(--primary, #e0592a);
    color: #fff;
}

.payment-tab:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Auth / profile */
.header-auth { margin-right: 12px; }
.header-auth-link {
    color: var(--primary, #e0592a);
    font-weight: 600;
    text-decoration: none;
    font-size: 0.95rem;
    white-space: nowrap;
}
.header-auth-link:hover { text-decoration: underline; }

.auth-card, .profile-layout {
    max-width: 560px;
    margin: 0 auto;
    padding: 8px 0 40px;
}
.profile-layout { max-width: 720px; }
.auth-label {
    display: block;
    margin: 14px 0 6px;
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text);
}
.auth-input {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 8px;
    font: inherit;
    box-sizing: border-box;
    color: var(--text);
    background: rgba(0, 0, 0, 0.35);
}
.auth-input::placeholder {
    color: rgba(245, 235, 224, 0.4);
}
.auth-input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 1px rgba(224, 124, 60, 0.45);
}
.auth-error { color: #ffb3a2; margin: 10px 0 0; font-size: 0.9rem; }
.auth-ok { color: #8fd9a8; margin: 10px 0 0; font-size: 0.9rem; }
.auth-hint {
    color: rgba(245, 235, 224, 0.72);
    font-size: 0.9rem;
    margin: 8px 0 0;
}
.auth-hint a {
    color: var(--accent);
    font-weight: 600;
}
.auth-dev {
    margin: 12px 0;
    padding: 10px 12px;
    background: rgba(224, 124, 60, 0.12);
    border: 1px dashed rgba(224, 124, 60, 0.55);
    border-radius: 8px;
    font-weight: 600;
    color: var(--text);
}
.auth-link-btn {
    display: inline-block;
    margin-top: 12px;
    background: none;
    border: none;
    color: var(--accent);
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    text-decoration: underline;
    padding: 0;
}
.btn-submit-secondary {
    background: transparent !important;
    color: var(--accent) !important;
    border: 2px solid var(--accent);
    margin-top: 12px;
}
.btn-submit-secondary:hover {
    background: rgba(224, 124, 60, 0.15) !important;
}
.profile-card {
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 18px 18px 20px;
    margin: 16px 0;
    color: var(--text);
}
.profile-h2 {
    font-size: 1.15rem;
    margin: 0 0 8px;
    color: var(--text);
}
.profile-orders-scroll {
    max-height: min(52vh, 480px);
    overflow-y: auto;
    overflow-x: hidden;
    margin: 4px -4px 0;
    padding: 0 4px 4px;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: rgba(224, 124, 60, 0.55) rgba(255, 255, 255, 0.06);
}
.profile-orders-scroll::-webkit-scrollbar {
    width: 8px;
}
.profile-orders-scroll::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.06);
    border-radius: 8px;
}
.profile-orders-scroll::-webkit-scrollbar-thumb {
    background: rgba(224, 124, 60, 0.55);
    border-radius: 8px;
}
.profile-orders-scroll::-webkit-scrollbar-thumb:hover {
    background: rgba(224, 124, 60, 0.75);
}
.promo-row { display: flex; gap: 8px; align-items: stretch; margin-top: 8px; }
.promo-row .auth-input { flex: 1; }
.promo-row .btn-submit { width: auto; margin: 0; white-space: nowrap; padding: 0 16px; }
.profile-actions { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; margin-top: 8px; }
.profile-actions .btn-submit { width: auto; display: inline-block; text-decoration: none; text-align: center; padding: 12px 20px; }
.profile-order {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 12px 0;
}
.profile-order:first-child { border-top: none; }
.profile-order-top {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    color: var(--text);
}
.profile-order-top span {
    color: var(--accent);
    font-weight: 600;
}
.profile-order-meta {
    color: rgba(245, 235, 224, 0.65);
    font-size: 0.85rem;
    margin-top: 4px;
}
.profile-order-items {
    margin-top: 6px;
    font-size: 0.95rem;
    color: rgba(245, 235, 224, 0.9);
}
.profile-order-promo { margin-top: 4px; color: var(--accent); font-size: 0.9rem; }
.profile-order-link { display: inline-block; margin-top: 6px; color: var(--accent); font-weight: 600; }
.profile-order-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 8px;
    align-items: center;
}
.profile-order-actions .profile-order-link {
    margin-top: 0;
    background: none;
    border: none;
    padding: 0;
    font: inherit;
    cursor: pointer;
    text-decoration: underline;
}
.profile-address-row {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: flex-start;
    padding: 10px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}
.profile-address-row:first-child { border-top: none; }
.profile-address-text { color: var(--text); flex: 1; line-height: 1.4; }
.profile-address-del { margin-top: 0 !important; flex-shrink: 0; }
.profile-stars, .profile-stars-pick { display: inline-flex; gap: 2px; }
.profile-stars .star { color: rgba(245, 235, 224, 0.35); }
.profile-stars .star.on { color: var(--accent); }
.star-btn {
    background: none;
    border: none;
    padding: 0 2px;
    font-size: 1.45rem;
    line-height: 1;
    color: rgba(245, 235, 224, 0.35);
    cursor: pointer;
}
.star-btn.on, .star-btn:hover { color: var(--accent); }
.profile-review-form { margin-top: 10px; }
.profile-review-form .btn-submit-secondary { width: auto; padding: 8px 14px; }
.profile-review-input { margin-top: 8px; resize: vertical; min-height: 56px; }
.profile-review-done {
    margin-top: 8px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}
.profile-review-text {
    color: rgba(245, 235, 224, 0.8);
    font-size: 0.9rem;
}

.promo-banner {
    margin: 0;
    padding: 12px 20px;
    text-align: center;
    font-weight: 600;
    font-size: 1rem;
    color: #1a1510;
    background: linear-gradient(90deg, #e07c3c, #f0a060);
    letter-spacing: 0.01em;
}
.promo-banner[hidden] { display: none !important; }

.saved-addresses {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin-bottom: 10px;
}
.saved-addresses-label {
    font-size: 0.85rem;
    color: rgba(245, 235, 224, 0.7);
    width: 100%;
}
.saved-address-chip {
    border: 1px solid rgba(224, 124, 60, 0.55);
    background: rgba(224, 124, 60, 0.12);
    color: var(--text);
    border-radius: 8px;
    padding: 6px 10px;
    font: inherit;
    font-size: 0.85rem;
    cursor: pointer;
    max-width: 100%;
    text-align: left;
}
.saved-address-chip:hover {
    background: rgba(224, 124, 60, 0.22);
}

.checkout-auth-gate {
    background: rgba(224, 124, 60, 0.1);
    border: 1px solid rgba(224, 124, 60, 0.35);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 16px;
    color: var(--text);
}
.checkout-discount-row { color: #27ae60; font-weight: 600; }

.auth-switch {
    margin-top: 18px;
    text-align: center;
    color: rgba(245, 235, 224, 0.72);
    font-size: 0.95rem;
}
.auth-switch .auth-link-btn {
    margin-top: 0;
    margin-left: 4px;
}

/* Active order mini chip (header) */
.active-order-chip {
    display: none;
    align-items: center;
    gap: 10px;
    max-width: min(320px, 42vw);
    padding: 8px 12px;
    border: none;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
    cursor: pointer;
    text-align: left;
    font: inherit;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,0.18);
    transition: background 0.2s, transform 0.15s;
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    z-index: 5;
}
.active-order-chip:hover {
    background: rgba(255, 255, 255, 0.22);
    transform: translate(-50%, -50%) translateY(-1px);
}
.active-order-chip-icon {
    font-size: 1.25rem;
    line-height: 1;
    flex-shrink: 0;
}
.active-order-chip-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
    line-height: 1.2;
}
.active-order-chip-text strong {
    font-size: 0.86rem;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.active-order-chip-text small {
    font-size: 0.72rem;
    opacity: 0.8;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.active-order-chip-arrow {
    margin-left: auto;
    font-size: 1.3rem;
    opacity: 0.75;
    flex-shrink: 0;
}

.active-order-modal {
    position: fixed;
    inset: 0;
    z-index: 1200;
    background: rgba(0,0,0,0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px 16px;
    box-sizing: border-box;
}
.active-order-dialog {
    position: relative;
    width: 100%;
    max-width: 420px;
    margin: 0 auto;
    background: #fff;
    color: #2d2d2d;
    border-radius: 16px;
    padding: 22px 20px 18px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.25);
    max-height: min(85vh, 640px);
    overflow-y: auto;
    flex-shrink: 0;
}
.active-order-close {
    position: absolute;
    top: 8px;
    right: 12px;
    border: none;
    background: none;
    font-size: 1.6rem;
    cursor: pointer;
    color: #999;
    line-height: 1;
}
.ao-live {
    text-align: center;
    padding: 12px;
    background: #fef9f5;
    border: 1px solid #f5ddd0;
    border-radius: 10px;
    margin-bottom: 16px;
}
.ao-live.cancelled { background: #fdf2f2; border-color: #f0c4c4; }
.ao-live-text { font-weight: 700; color: #e0592a; font-size: 1.05rem; }
.ao-live.cancelled .ao-live-text { color: #c0392b; }
.ao-live-sub { font-size: 0.85rem; color: #7a7a7a; margin-top: 4px; }

.ao-progress {
    display: flex;
    justify-content: space-between;
    position: relative;
    margin: 8px 0 20px;
    padding: 0 4px;
}
.ao-progress::before {
    content: '';
    position: absolute;
    top: 16px;
    left: 24px;
    right: 24px;
    height: 3px;
    background: #e2e5ec;
}
.ao-progress-fill {
    position: absolute;
    top: 16px;
    left: 24px;
    height: 3px;
    background: #e0592a;
    transition: width 0.4s ease;
}
.ao-step {
    position: relative;
    z-index: 1;
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}
.ao-step-dot {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #e2e5ec;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
}
.ao-step.active .ao-step-dot {
    background: #e0592a;
    box-shadow: 0 2px 10px rgba(224,89,42,0.35);
    transform: scale(1.08);
}
.ao-step.done .ao-step-dot { background: #27ae60; }
.ao-step-label {
    font-size: 0.65rem;
    text-align: center;
    color: #999;
    max-width: 64px;
    line-height: 1.2;
    font-weight: 500;
}
.ao-step.active .ao-step-label,
.ao-step.done .ao-step-label { color: #2d2d2d; font-weight: 600; }

.ao-meta {
    display: grid;
    gap: 8px;
    margin-bottom: 12px;
    font-size: 0.9rem;
}
.ao-meta div { display: flex; justify-content: space-between; gap: 12px; }
.ao-meta span { color: #7a7a7a; }
.ao-items {
    margin: 0 0 12px;
    padding-left: 18px;
    color: #444;
    font-size: 0.9rem;
}
.ao-profile-link {
    display: block;
    text-align: center;
    color: #e0592a;
    font-weight: 600;
    font-size: 0.9rem;
}

@media (max-width: 720px) {
    .active-order-chip {
        position: static;
        left: auto;
        top: auto;
        transform: none;
        max-width: none;
        padding: 7px 10px;
        order: 3;
        flex: 1 1 100%;
        margin-top: 4px;
    }
    .active-order-chip:hover {
        transform: translateY(-1px);
    }
    .header-right { margin-left: 0; }
}
