/* ============================================================
   Cart Sidebar & Checkout styles
   ============================================================ */

/* Overlay */
.cart-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.45);
    z-index: 2000;
    transition: opacity 0.3s;
    opacity: 0;
}
.cart-overlay.open { display: block; opacity: 1; }

/* Sidebar */
.cart-sidebar {
    position: fixed;
    top: 0; right: -400px;
    width: 380px; max-width: 90vw;
    height: 100vh;
    background: #fff;
    z-index: 2001;
    box-shadow: -4px 0 25px rgba(0,0,0,0.15);
    transition: right 0.35s ease;
    display: flex;
    flex-direction: column;
}
.cart-sidebar.open { right: 0; }

/* Sidebar header */
.cart-sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 22px;
    border-bottom: 2px solid var(--gold, #B5985C);
    background: var(--dark, #0B3A67);
    color: #fff;
}
.cart-sidebar-header h3 {
    margin: 0;
    font-size: 1.3rem;
    font-family: 'Cormorant Garamond', Georgia, serif;
    color: var(--gold, #B5985C);
}
.cart-sidebar-header button {
    background: none;
    border: none;
    color: rgba(255,255,255,0.7);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0;
    line-height: 1;
}
.cart-sidebar-header button:hover { color: #fff; }

/* Sidebar body (scrollable) */
.cart-sidebar-body {
    flex: 1;
    overflow-y: auto;
    padding: 15px 22px;
}

/* Empty message */
.cart-empty-msg {
    text-align: center;
    padding: 60px 20px;
    color: #999;
}
.cart-empty-msg i {
    font-size: 3rem;
    color: #ddd;
    display: block;
    margin-bottom: 15px;
}
.cart-empty-msg p {
    font-size: 1.1rem;
    margin: 0;
}

/* Cart item row */
.cart-sidebar-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 0;
    border-bottom: 1px solid #f0f0f0;
    position: relative;
}
.cart-item-img {
    flex-shrink: 0;
    width: 65px;
    height: 65px;
    border-radius: 4px;
    overflow: hidden;
    background: #f8f5f0;
}
.cart-item-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 5px;
}
.cart-item-info { flex: 1; min-width: 0; }
.cart-item-name {
    font-size: 0.95rem;
    font-weight: 600;
    color: #0B3A67;
    margin-bottom: 3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.cart-item-price {
    font-size: 0.95rem;
    color: var(--gold, #B5985C);
    font-weight: 700;
    margin-bottom: 6px;
}

/* Quantity controls */
.cart-item-qty, .checkout-qty {
    display: inline-flex;
    align-items: center;
    gap: 0;
    border: 1px solid #ddd;
    border-radius: 3px;
    overflow: hidden;
}
.qty-btn {
    width: 30px;
    height: 30px;
    border: none;
    background: #f5f5f5;
    cursor: pointer;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #555;
    transition: 0.2s;
}
.qty-btn:hover { background: var(--gold, #B5985C); color: #fff; }
.qty-val {
    width: 36px;
    text-align: center;
    font-size: 0.95rem;
    font-weight: 600;
    border-left: 1px solid #ddd;
    border-right: 1px solid #ddd;
    line-height: 30px;
}
.cart-item-available {
    margin-top: 6px;
    font-size: 0.7rem;
    color: #5f6c78;
}

/* Remove button */
.cart-item-remove {
    flex-shrink: 0;
    background: none;
    border: none;
    color: #ccc;
    font-size: 1rem;
    cursor: pointer;
    padding: 5px;
    transition: 0.2s;
}
.cart-item-remove:hover { color: #e74c3c; }

/* Sidebar footer */
.cart-sidebar-footer {
    padding: 18px 22px;
    border-top: 1px solid #eee;
    background: #fafafa;
}
.cart-sidebar-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    font-size: 1.15rem;
}
.cart-sidebar-total strong { color: var(--gold, #B5985C); font-size: 1.3rem; }
.cart-sidebar-footer .btn-checkout {
    display: block;
    width: 100%;
    background: var(--gold, #B5985C);
    color: #fff;
    border: none;
    padding: 14px;
    font-size: 1.1rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 3px;
    cursor: pointer;
    text-align: center;
    text-decoration: none;
    transition: 0.3s;
}
.cart-sidebar-footer .btn-checkout:hover {
    background: #C9B47E;
    color: #fff;
    text-decoration: none;
}
.cart-sidebar-footer .btn-continue {
    display: block;
    width: 100%;
    text-align: center;
    margin-top: 10px;
    color: #888;
    font-size: 0.9rem;
    text-decoration: none;
    transition: 0.2s;
}
.cart-sidebar-footer .btn-continue:hover { color: var(--gold, #B5985C); }

/* ============================================================
   Checkout page
   ============================================================ */
.checkout-section { padding: 40px 0 60px; }
.checkout-section h1 {
    text-align: center;
    margin-bottom: 10px;
    font-size: 2.2rem;
}
.checkout-section .line {
    width: 60px;
    height: 2px;
    background: var(--gold, #B5985C);
    margin: 0 auto 35px;
}

.checkout-table {
    width: 100%;
    border-collapse: collapse;
}
.checkout-table th {
    background: var(--dark, #0B3A67);
    color: #fff;
    padding: 12px 15px;
    font-size: 0.95rem;
    text-align: left;
    font-weight: 600;
}
.checkout-table td {
    padding: 14px 15px;
    border-bottom: 1px solid #eee;
    vertical-align: middle;
    font-size: 1rem;
}
.checkout-table tr:hover td { background: #faf9f6; }

.checkout-thumb {
    width: 60px;
    height: 60px;
    object-fit: contain;
    background: #f8f5f0;
    border-radius: 4px;
    padding: 5px;
}

.checkout-summary {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 4px;
    padding: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}
.checkout-summary h3 {
    font-size: 1.3rem;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--gold, #B5985C);
}
.checkout-summary .summary-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    font-size: 1.05rem;
    border-bottom: 1px solid #f0f0f0;
}
.checkout-summary .summary-row.total {
    border-bottom: none;
    font-size: 1.3rem;
    font-weight: 700;
    padding-top: 12px;
    margin-top: 5px;
    border-top: 2px solid #eee;
}
.checkout-summary .summary-row.total span:last-child {
    color: var(--gold, #B5985C);
}

/* Payment form */
.checkout-form label {
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 5px;
    display: block;
}
.checkout-form input,
.checkout-form select,
.checkout-form textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 3px;
    font-size: 1rem;
    margin-bottom: 15px;
    font-family: 'Lora', Georgia, serif;
}
.checkout-form input:focus,
.checkout-form select:focus {
    border-color: var(--gold, #B5985C);
    outline: none;
}
.btn-order {
    display: block;
    width: 100%;
    background: var(--gold, #B5985C);
    color: #fff;
    border: none;
    padding: 16px;
    font-size: 1.15rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 3px;
    cursor: pointer;
    transition: 0.3s;
    margin-top: 10px;
}
.btn-order:hover { background: #C9B47E; }

.checkout-empty {
    text-align: center;
    padding: 80px 20px;
    color: #999;
}
.checkout-empty i {
    font-size: 4rem;
    color: #ddd;
    margin-bottom: 20px;
    display: block;
}

/* Payment method radios */
.payment-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 15px;
    border: 1px solid #eee;
    border-radius: 4px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: 0.2s;
}
.payment-option:hover { border-color: var(--gold, #B5985C); }
.payment-option input[type="radio"] { margin: 0; }
.payment-option i { font-size: 1.2rem; color: var(--gold, #B5985C); }

@media (max-width: 768px) {
    .checkout-table th:first-child,
    .checkout-table td:first-child { display: none; }
}


/* ============================================================
   UNIFIED CART + CHECKOUT — Savino Nasledje design
   ============================================================ */
.is-hidden{display:none!important}.checkout-page{background:#faf8f2}.checkout-section{padding:58px 0 76px}.checkout-layout{display:grid;grid-template-columns:minmax(0,1.55fr) minmax(340px,.75fr);gap:28px;align-items:start}.checkout-aside{display:grid;gap:22px;position:sticky;top:24px}.checkout-card{background:#fff;border:1px solid rgba(11,58,103,.12);box-shadow:0 10px 28px rgba(6,47,85,.055);padding:26px}.checkout-card__header{display:flex;align-items:flex-end;justify-content:space-between;gap:18px;padding-bottom:18px;border-bottom:1px solid rgba(181,152,92,.25)}.checkout-card h2{margin:0;color:#0b3a67;font-family:"Cormorant Garamond",Georgia,serif;font-size:1.65rem;font-weight:700}.checkout-back-link{color:#0b3a67;font-size:.78rem;text-decoration:none;border-bottom:1px solid #B5985C;padding-bottom:2px}.checkout-table-wrap{overflow-x:auto}.checkout-table th{background:#f7f3ea;color:#0b3a67;border-bottom:1px solid rgba(181,152,92,.35);font-family:"Lora",Georgia,serif;font-size:.72rem;font-weight:600;letter-spacing:.04em;text-transform:uppercase}.checkout-table td{border-bottom:1px solid rgba(11,58,103,.09);font-size:.86rem}.checkout-table tr:hover td{background:#fdfbf6}.checkout-col-image{width:82px}.checkout-col-remove{width:42px}.checkout-thumb{width:68px;height:68px;border:1px solid rgba(181,152,92,.25);background:#faf8f2}.checkout-summary{padding:26px}.checkout-summary .section-kicker,.checkout-delivery .section-kicker{margin-bottom:4px}.checkout-summary h2,.checkout-delivery h2{padding-bottom:15px;margin-bottom:13px;border-bottom:1px solid rgba(181,152,92,.3)}.checkout-summary .summary-row{font-size:.86rem;padding:11px 0}.checkout-summary .summary-row.total{font-size:1.02rem;border-top:1px solid #B5985C;margin-top:8px;padding-top:16px}.checkout-summary .summary-row.total span:last-child{color:#0b3a67;font-size:1.2rem}.checkout-form{display:grid;gap:13px}.form-row{display:grid;grid-template-columns:1fr 1fr;gap:12px}.form-field label,.payment-options legend{display:block;margin:0 0 6px;color:#333;font-size:.76rem;font-weight:600}.form-field label span{font-weight:400;color:#888}.checkout-form input,.checkout-form select,.checkout-form textarea{margin:0;width:100%;padding:11px 12px;border:1px solid #d9d4ca;border-radius:2px;background:#fff;font-family:"Lora",Georgia,serif;font-size:.82rem;transition:border-color .2s,box-shadow .2s}.checkout-form input:focus,.checkout-form select:focus,.checkout-form textarea:focus{border-color:#B5985C;box-shadow:0 0 0 3px rgba(181,152,92,.12);outline:0}.payment-options{display:grid;gap:8px;margin:4px 0 2px;padding:0;border:0}.payment-option{display:grid;grid-template-columns:auto 38px 1fr;align-items:center;gap:10px;margin:0;padding:11px;border:1px solid #e1ddd4;background:#faf8f2;cursor:pointer;transition:.2s}.payment-option:has(input:checked){border-color:#B5985C;background:#fffdf8}.payment-option input{width:auto;margin:0;accent-color:#0b3a67}.payment-option__icon{display:grid;place-items:center;width:36px;height:36px;color:#0b3a67;border:1px solid rgba(181,152,92,.45)}.payment-option strong,.payment-option small{display:block}.payment-option strong{color:#0b3a67;font-size:.78rem}.payment-option small{margin-top:2px;color:#777;font-size:.66rem}.btn-order{width:100%;border:1px solid #B5985C;cursor:pointer}.checkout-security{text-align:center;color:#777;font-size:.68rem;line-height:1.5;margin:0}.checkout-security i{color:#B5985C;margin-right:4px}.checkout-empty{max-width:620px;margin:0 auto;padding:58px 30px;text-align:center;background:#fff;border:1px solid rgba(181,152,92,.3)}.checkout-empty__icon{display:grid;place-items:center;width:72px;height:72px;margin:0 auto 20px;border:1px solid #B5985C;color:#0b3a67;font-size:1.55rem}.checkout-empty h2{color:#0b3a67;font-family:"Cormorant Garamond",Georgia,serif;font-size:2rem}.checkout-empty p{color:#666}.checkout-empty__button{margin-top:18px}
.cart-sidebar{background:#faf8f2!important}.cart-sidebar-header{background:#0b3a67!important;border-bottom:3px solid #B5985C!important}.cart-sidebar-header h3{font-family:"Cormorant Garamond",Georgia,serif!important;letter-spacing:.03em}.cart-sidebar-body{padding:12px 22px 22px!important}.cart-sidebar-item{background:#fff;border:1px solid rgba(11,58,103,.1)!important;margin-top:10px;padding:12px!important}.cart-item-name{font-family:"Cormorant Garamond",Georgia,serif;font-size:1rem!important}.cart-item-price{color:#0b3a67!important}.cart-sidebar-footer{background:#f7f3ea!important;border-top:1px solid rgba(181,152,92,.35)!important}.cart-sidebar-total strong{color:#0b3a67!important}.cart-sidebar-footer .btn-checkout{background:#0b3a67!important;border:1px solid #B5985C!important;border-radius:2px!important;font-family:"Cormorant Garamond",Georgia,serif!important}.cart-sidebar-footer .btn-checkout:hover{background:#B5985C!important;color:#0b3a67!important}
@media(max-width:991.98px){.checkout-layout{grid-template-columns:1fr}.checkout-aside{position:static}.checkout-card--items{order:1}.checkout-aside{order:2}}
@media(max-width:575.98px){.checkout-section{padding:38px 0 52px}.checkout-card{padding:18px}.checkout-card__header{align-items:flex-start;flex-direction:column}.form-row{grid-template-columns:1fr}.checkout-table{min-width:680px}.payment-option{grid-template-columns:auto 34px 1fr}}
