/* =========================================================
   MENÜDEN SİPARİŞ VE SEPET SAYFASI
   ========================================================= */

.page-hero--cart {
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
}

.ordering-menu-section,
.cart-page-section {
    padding-block: 86px;
    background: var(--cream, #f6f3ea);
}

/* MENÜ ÜST SEPET ÇUBUĞU */

.menu-order-toolbar {
    position: sticky;
    top: 92px;
    z-index: 30;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px;
    margin-bottom: 58px;
    padding: 22px 24px;
    background: rgba(255, 255, 255, 0.97);
    border: 1px solid rgba(170, 165, 142, 0.35);
    box-shadow: 0 16px 38px rgba(0, 0, 0, 0.08);
    backdrop-filter: blur(12px);
}

.menu-order-toolbar > div {
    display: grid;
    gap: 5px;
}

.menu-order-toolbar > div > strong {
    color: var(--green, #1f2d1b);
    font-size: 24px;
    font-weight: 900;
}

.menu-order-toolbar > div > small {
    color: #777777;
    font-size: 12px;
}

.menu-cart-link {
    min-width: 230px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 15px 18px;
    color: #ffffff;
    background: var(--green, #1f2d1b);
    border: 1px solid var(--green, #1f2d1b);
    text-decoration: none;
    transition:
        transform var(--transition, 180ms ease),
        background var(--transition, 180ms ease),
        border-color var(--transition, 180ms ease);
}

.menu-cart-link:hover,
.menu-cart-link:focus-visible {
    color: #ffffff;
    background: var(--gold-dark, #8e7d3b);
    border-color: var(--gold-dark, #8e7d3b);
    outline: none;
    transform: translateY(-2px);
}

.menu-cart-link > span {
    font-size: 13px;
    font-weight: 900;
    text-transform: uppercase;
}

.menu-cart-link > strong {
    font-size: 12px;
    white-space: nowrap;
}

.order-feedback {
    min-height: 24px;
    margin: -36px 0 30px;
    color: var(--green, #1f2d1b);
    font-size: 13px;
    font-weight: 800;
    text-align: right;
    opacity: 0;
    transform: translateY(-4px);
    transition:
        opacity 180ms ease,
        transform 180ms ease;
}

.order-feedback.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* KATEGORİLER */

.ordering-category + .ordering-category {
    margin-top: 78px;
}

.ordering-category__heading {
    margin-bottom: 28px;
    padding-bottom: 18px;
    border-bottom: 1px solid rgba(170, 165, 142, 0.38);
}

.ordering-category__heading h2 {
    margin-top: 7px;
    color: var(--green, #1f2d1b);
    font-size: clamp(36px, 4vw, 52px);
    font-weight: 900;
    letter-spacing: -2px;
    line-height: 1;
}

.ordering-product-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.ordering-product-card {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 22px;
    padding: 25px;
    background: #ffffff;
    border: 1px solid rgba(170, 165, 142, 0.32);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.035);
    transition:
        transform var(--transition, 180ms ease),
        box-shadow var(--transition, 180ms ease),
        border-color var(--transition, 180ms ease);
}

.ordering-product-card:hover {
    border-color: var(--gold, #b8a866);
    box-shadow: 0 20px 42px rgba(0, 0, 0, 0.08);
    transform: translateY(-4px);
}

.ordering-product-card__top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
}

.ordering-product-card__top h3 {
    color: var(--green, #1f2d1b);
    font-size: 19px;
    font-weight: 900;
    line-height: 1.25;
}

.ordering-product-card__top > strong {
    flex: 0 0 auto;
    color: var(--gold-dark, #8e7d3b);
    font-size: 18px;
    font-weight: 900;
    white-space: nowrap;
}

/* PORSİYON SEÇİCİ */

.portion-selector {
    padding: 0;
    margin: 0;
    border: 0;
}

.portion-selector legend {
    margin-bottom: 10px;
    color: #777777;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.7px;
    text-transform: uppercase;
}

.portion-selector__options {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
}

.portion-selector label {
    position: relative;
    cursor: pointer;
}

.portion-selector input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.portion-selector label > span {
    min-width: 122px;
    display: grid;
    gap: 2px;
    padding: 10px 12px;
    color: var(--green, #1f2d1b);
    background: #f4f1e8;
    border: 1px solid transparent;
    font-size: 12px;
    font-weight: 800;
    text-align: center;
    transition:
        color 160ms ease,
        background 160ms ease,
        border-color 160ms ease;
}

.portion-selector label > span small {
    color: #777777;
    font-size: 10px;
    font-weight: 700;
}

.portion-selector input:checked + span {
    color: #ffffff;
    background: var(--green, #1f2d1b);
    border-color: var(--green, #1f2d1b);
}

.portion-selector input:checked + span small {
    color: rgba(255, 255, 255, 0.78);
}

.portion-selector input:focus-visible + span {
    outline: 3px solid rgba(184, 168, 102, 0.3);
    outline-offset: 2px;
}

/* ADET VE SEPETE EKLE */

.ordering-product-card__actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-top: auto;
}

.quantity-picker {
    display: grid;
    grid-template-columns: 38px 44px 38px;
    align-items: center;
    min-height: 42px;
    border: 1px solid rgba(170, 165, 142, 0.52);
}

.quantity-picker button {
    height: 40px;
    padding: 0;
    color: var(--green, #1f2d1b);
    background: transparent;
    border: 0;
    cursor: pointer;
    font-size: 20px;
    font-weight: 700;
    transition:
        color 160ms ease,
        background 160ms ease;
}

.quantity-picker button:hover,
.quantity-picker button:focus-visible {
    color: #ffffff;
    background: var(--gold-dark, #8e7d3b);
    outline: none;
}

.quantity-picker span {
    display: grid;
    place-items: center;
    color: var(--green, #1f2d1b);
    font-size: 14px;
    font-weight: 900;
}

.add-to-cart-button,
.complete-order-button {
    min-height: 44px;
    padding: 0 22px;
    color: #ffffff;
    background: var(--gold-dark, #8e7d3b);
    border: 1px solid var(--gold-dark, #8e7d3b);
    cursor: pointer;
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
    transition:
        background var(--transition, 180ms ease),
        border-color var(--transition, 180ms ease),
        transform var(--transition, 180ms ease);
}

.add-to-cart-button:hover,
.add-to-cart-button:focus-visible,
.complete-order-button:hover,
.complete-order-button:focus-visible {
    color: #ffffff;
    background: var(--green, #1f2d1b);
    border-color: var(--green, #1f2d1b);
    outline: none;
    transform: translateY(-2px);
}

.menu-order-bottom {
    display: flex;
    justify-content: center;
    margin-top: 70px;
}

/* =========================================================
   SEPET SAYFASI
   ========================================================= */

.cart-page-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(330px, 0.8fr);
    align-items: start;
    gap: 28px;
}

.cart-products-panel,
.cart-checkout-panel {
    background: #ffffff;
    border: 1px solid rgba(170, 165, 142, 0.34);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.045);
}

.cart-products-panel {
    min-width: 0;
    padding: 30px;
}

.cart-panel-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 22px;
    margin-bottom: 22px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(170, 165, 142, 0.36);
}

.cart-panel-heading h2,
.cart-checkout-panel h2 {
    margin-top: 6px;
    color: var(--green, #1f2d1b);
    font-size: 31px;
    font-weight: 900;
    letter-spacing: -1.3px;
    line-height: 1.05;
}

.cart-back-link {
    flex: 0 0 auto;
    color: var(--gold-dark, #8e7d3b);
    font-size: 12px;
    font-weight: 900;
    text-decoration: none;
    text-transform: uppercase;
}

.cart-back-link:hover,
.cart-back-link:focus-visible {
    color: var(--green, #1f2d1b);
    outline: none;
}

.cart-product-list {
    display: grid;
    gap: 14px;
}

.cart-product-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    align-items: center;
    gap: 18px;
    padding: 18px;
    background: #f8f6ef;
    border: 1px solid rgba(170, 165, 142, 0.25);
}

.cart-product-item__info {
    min-width: 0;
}

.cart-product-item__info h3 {
    color: var(--green, #1f2d1b);
    font-size: 16px;
    font-weight: 900;
}

.cart-product-item__info p {
    margin-top: 5px;
    color: #777777;
    font-size: 11px;
}

.cart-product-item__price {
    min-width: 92px;
    color: var(--gold-dark, #8e7d3b);
    font-size: 15px;
    font-weight: 900;
    text-align: right;
}

.cart-item-actions {
    display: grid;
    justify-items: end;
    gap: 8px;
}

.cart-item-remove {
    padding: 0;
    color: #a34135;
    background: transparent;
    border: 0;
    cursor: pointer;
    font-size: 10px;
    font-weight: 900;
    text-transform: uppercase;
}

.cart-item-remove:hover,
.cart-item-remove:focus-visible {
    color: #6e1f18;
    outline: none;
    text-decoration: underline;
}

.cart-empty-state {
    padding: 52px 24px;
    color: #777777;
    text-align: center;
}

.cart-empty-state strong {
    display: block;
    color: var(--green, #1f2d1b);
    font-size: 22px;
    font-weight: 900;
}

.cart-empty-state p {
    max-width: 480px;
    margin: 12px auto 22px;
    font-size: 13px;
}

/* ÖDEME PANELİ */

.cart-checkout-panel {
    position: sticky;
    top: 92px;
    padding: 30px;
}

.cart-price-summary {
    display: grid;
    gap: 13px;
    margin-top: 25px;
    padding: 20px;
    background: #f4f1e8;
}

.cart-price-summary > div {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    color: #666666;
    font-size: 12px;
}

.cart-price-summary > div strong {
    color: var(--green, #1f2d1b);
    font-size: 14px;
    font-weight: 900;
}

.cart-price-summary__total {
    margin-top: 4px;
    padding-top: 14px;
    border-top: 1px solid rgba(170, 165, 142, 0.5);
}

.cart-price-summary__total span,
.cart-price-summary__total strong {
    color: var(--green, #1f2d1b) !important;
    font-size: 18px !important;
    font-weight: 900 !important;
}

.payment-options {
    display: grid;
    gap: 10px;
    margin: 26px 0 0;
    padding: 0;
    border: 0;
}

.payment-options legend,
.delivery-address-field > span {
    margin-bottom: 10px;
    color: var(--green, #1f2d1b);
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
}

.payment-options label {
    position: relative;
    display: block;
    cursor: pointer;
}

.payment-options input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.payment-options label > span {
    display: grid;
    gap: 4px;
    padding: 15px 16px;
    background: #ffffff;
    border: 1px solid rgba(170, 165, 142, 0.48);
    transition:
        border-color 160ms ease,
        background 160ms ease;
}

.payment-options label > span strong {
    color: var(--green, #1f2d1b);
    font-size: 13px;
    font-weight: 900;
}

.payment-options label > span small {
    color: #777777;
    font-size: 10px;
}

.payment-options input:checked + span {
    background: #f4f1e8;
    border-color: var(--gold-dark, #8e7d3b);
    box-shadow: inset 4px 0 0 var(--gold-dark, #8e7d3b);
}

.payment-options input:focus-visible + span {
    outline: 3px solid rgba(184, 168, 102, 0.3);
    outline-offset: 2px;
}

.delivery-address-field {
    display: grid;
    margin-top: 26px;
}

.delivery-address-field textarea {
    width: 100%;
    resize: vertical;
    min-height: 118px;
    padding: 14px 15px;
    color: var(--green, #1f2d1b);
    background: #ffffff;
    border: 1px solid rgba(170, 165, 142, 0.52);
    font: inherit;
    font-size: 12px;
    line-height: 1.6;
}

.delivery-address-field textarea:focus {
    border-color: var(--gold-dark, #8e7d3b);
    outline: 3px solid rgba(184, 168, 102, 0.18);
}

.checkout-validation-message {
    min-height: 20px;
    margin-top: 12px;
    color: #a34135;
    font-size: 11px;
    font-weight: 800;
}

.complete-order-button {
    width: 100%;
    min-height: 52px;
    margin-top: 8px;
}

.complete-order-button:disabled {
    cursor: not-allowed;
    opacity: 0.48;
    transform: none;
}

.checkout-note {
    display: block;
    margin-top: 13px;
    color: #777777;
    font-size: 10px;
    line-height: 1.6;
    text-align: center;
}

/* TABLET */

@media (max-width: 1000px) {
    .cart-page-layout {
        grid-template-columns: 1fr;
    }

    .cart-checkout-panel {
        position: static;
    }
}

@media (max-width: 850px) {
    .ordering-product-grid {
        grid-template-columns: 1fr;
    }

    .menu-order-toolbar {
        top: 78px;
    }
}

/* TELEFON */

@media (max-width: 600px) {
    .ordering-menu-section,
    .cart-page-section {
        padding-block: 58px;
    }

    .menu-order-toolbar {
        position: static;
        align-items: stretch;
        flex-direction: column;
        margin-bottom: 45px;
        padding: 18px;
    }

    .menu-cart-link {
        min-width: 0;
        width: 100%;
    }

    .order-feedback {
        margin: -28px 0 24px;
        text-align: left;
    }

    .ordering-category + .ordering-category {
        margin-top: 58px;
    }

    .ordering-product-card {
        padding: 20px;
    }

    .ordering-product-card__top {
        gap: 12px;
    }

    .ordering-product-card__top h3 {
        font-size: 17px;
    }

    .ordering-product-card__top > strong {
        font-size: 16px;
    }

    .portion-selector__options {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .portion-selector label > span {
        min-width: 0;
    }

    .ordering-product-card__actions {
        align-items: stretch;
        flex-direction: column;
    }

    .quantity-picker {
        width: 100%;
        grid-template-columns: 44px 1fr 44px;
    }

    .add-to-cart-button {
        width: 100%;
    }

    .cart-products-panel,
    .cart-checkout-panel {
        padding: 20px;
    }

    .cart-panel-heading {
        align-items: flex-start;
        flex-direction: column;
    }

    .cart-product-item {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .cart-product-item__price {
        min-width: 0;
        text-align: left;
    }

    .cart-item-actions {
        justify-items: stretch;
    }

    .cart-item-actions .quantity-picker {
        width: 100%;
    }

    .cart-item-remove {
        justify-self: end;
    }
}

/* Yönetim panelinden girilen ürün ve kategori açıklamaları */
.ordering-category__heading p {
    max-width: 720px;
    margin-top: 10px;
    color: #7f7f7f;
    line-height: 1.65;
}

.ordering-product-card__top > div {
    min-width: 0;
}

.ordering-product-description {
    margin-top: 8px;
    color: #8b8b8b;
    font-size: 12px;
    line-height: 1.55;
}

/* =========================================================
   SİPARİŞ DURUMU, ADRES KAYDI VE ÜCRETSİZ TESLİMAT
   ========================================================= */

.restaurant-hours-status {
    display: grid;
    gap: 5px;
    margin-top: 22px;
    padding: 14px 16px;
    border: 1px solid transparent;
    font-size: 11px;
    line-height: 1.5;
}

.restaurant-hours-status strong {
    font-size: 12px;
    font-weight: 900;
}

.restaurant-hours-status span {
    opacity: 0.86;
}

.restaurant-hours-status.is-open {
    color: #215d35;
    background: #edf8f0;
    border-color: #b9ddc4;
}

.restaurant-hours-status.is-closed {
    color: #8a271f;
    background: #fff0ee;
    border-color: #efb8b1;
}

.cart-price-summary > div.is-free-delivery span,
.cart-price-summary > div.is-free-delivery strong {
    color: #b3261e !important;
    text-decoration-line: line-through;
    text-decoration-color: #d31313;
    text-decoration-thickness: 2px;
}

.free-delivery-note {
    margin: -4px 0 1px;
    color: #1f6a37;
    font-size: 11px;
    font-weight: 900;
    line-height: 1.45;
}

.address-save-section {
    display: grid;
    gap: 8px;
    margin-top: 12px;
}

.save-address-button {
    width: 100%;
    min-height: 44px;
    padding: 10px 18px;
    color: var(--green, #1f2d1b);
    background: #f4f1e8;
    border: 1px solid var(--gold-dark, #8e7d3b);
    cursor: pointer;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 0.2px;
    text-transform: uppercase;
    transition:
        background 160ms ease,
        color 160ms ease,
        transform 160ms ease;
}

.save-address-button:hover,
.save-address-button:focus-visible {
    color: #ffffff;
    background: var(--green, #1f2d1b);
    outline: none;
    transform: translateY(-1px);
}

.address-save-status {
    min-height: 18px;
    margin: 0;
    font-size: 10px;
    font-weight: 800;
    line-height: 1.5;
}

.address-save-status.is-saved {
    color: #1f6a37;
}

.address-save-status.is-pending {
    color: #9a5d19;
}

.checkout-validation-message.is-error {
    color: #a32118;
}

.checkout-validation-message.is-success {
    color: #1f6a37;
}

@media (max-width: 600px) {
    .restaurant-hours-status {
        padding: 13px 14px;
    }

    .cart-price-summary {
        padding: 17px;
    }

    .cart-price-summary > div {
        align-items: flex-start;
    }

    .save-address-button,
    .complete-order-button {
        min-height: 50px;
    }
}

/* =========================================================
   SEPET - KVKK AYDINLATMA TEYİDİ
========================================================= */

.kvkk-order-notice {
    display: grid;
    gap: 9px;

    margin: 18px 0 4px;
    padding: 15px 16px;

    border: 1px solid rgba(196, 183, 124, 0.55);
    border-radius: 10px;
    background: rgba(196, 183, 124, 0.08);
}

.kvkk-order-confirmation {
    display: grid;
    grid-template-columns: 21px minmax(0, 1fr);
    align-items: start;
    gap: 11px;

    color: #333333;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.55;

    cursor: pointer;
}

.kvkk-order-confirmation input {
    width: 18px;
    height: 18px;
    margin: 2px 0 0;

    accent-color: #a99c67;
    cursor: pointer;
}

.kvkk-order-confirmation a {
    color: #8c7d43;
    font-weight: 800;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.kvkk-order-confirmation a:hover {
    color: #5f542d;
}

.kvkk-order-notice > small {
    display: block;
    padding-left: 32px;

    color: #737373;
    font-size: 11px;
    line-height: 1.5;
}

@media (max-width: 600px) {
    .kvkk-order-notice {
        padding: 13px;
    }

    .kvkk-order-confirmation {
        grid-template-columns: 20px minmax(0, 1fr);
        gap: 9px;
        font-size: 12px;
    }

    .kvkk-order-notice > small {
        padding-left: 29px;
    }
}

