/* =========================================================
   Albatross Food — Cart page
   ========================================================= */

/* ---------- header ---------- */
.cart-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.cart-clear-btn {
    background: none;
    border: none;
    color: #c33;
    font-size: 13px;
    padding: 6px 10px;
    cursor: pointer;
    border-radius: 6px;
    touch-action: manipulation;
    user-select: none;
}

@media (hover: hover) {
    .cart-clear-btn:hover {
        background: #ffeaea;
    }
}

/* ---------- empty state ---------- */
.cart-empty {
    text-align: center;
    padding: 40px 16px;
    background: #fff;
    border: 1px dashed #ddd;
    border-radius: 12px;
    color: #666;
}

.cart-empty .btn {
    margin-top: 12px;
}

/* ---------- list ---------- */
.cart-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 12px;
}

.cart-item {
    display: grid;
    grid-template-columns: 64px 1fr auto;
    gap: 10px;
    background: #fff;
    border: 1px solid #eee;
    border-radius: 10px;
    padding: 8px;
    align-items: stretch;
}

.cart-item-img {
    width: 64px;
    height: 64px;
    background: #f4f4f4;
    border-radius: 8px;
    overflow: hidden;
}

.cart-item-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.cart-item-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
    gap: 4px;
}

.cart-item-name {
    font-size: 13px;
    font-weight: 600;
    line-height: 1.25;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.cart-item-price {
    font-size: 12px;
    color: #888;
}

/* ---------- qty controls ---------- */
.cart-item-controls {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: auto;
}

.qty-btn {
    width: 36px;
    height: 36px;
    border: 1px solid #ddd;
    background: #fff;
    border-radius: 8px;
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
    color: #333;
    touch-action: manipulation;
    user-select: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.qty-btn:disabled {
    opacity: .4;
    cursor: default;
}

@media (hover: hover) {
    .qty-btn:hover:not(:disabled) {
        background: #f4f4f4;
    }
}

.qty-value {
    min-width: 28px;
    text-align: center;
    font-weight: 700;
    font-size: 15px;
}

/* ---------- right (remove + sum) ---------- */
.cart-item-right {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: flex-end;
    gap: 6px;
}

.cart-remove {
    background: none;
    border: none;
    color: #c33;
    font-size: 18px;
    line-height: 1;
    padding: 6px 8px;
    cursor: pointer;
    border-radius: 6px;
    touch-action: manipulation;
    user-select: none;
}

@media (hover: hover) {
    .cart-remove:hover {
        background: #ffeaea;
    }
}

.cart-item-sum {
    font-weight: 700;
    font-size: 14px;
    white-space: nowrap;
}

/* ---------- total ---------- */
.cart-total {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 10px;
    padding: 12px 14px;
    margin-bottom: 12px;
}

.cart-total-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    font-size: 15px;
}

.cart-total-sum {
    font-size: 20px;
    font-weight: 800;
}

.cart-total-note {
    font-size: 12px;
    color: #888;
    margin-top: 4px;
}

/* ---------- actions ---------- */
.cart-actions {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
}

.cart-actions .btn {
    flex: 1;
}

.cart-actions .btn[disabled] {
    opacity: .5;
    cursor: not-allowed;
}

/* ---------- checkout modal ---------- */


.checkout-overlay[hidden] {
    display: none;
}



.checkout-header h3 {
    margin: 0;
    font-size: 16px;
}


.checkout-form .filter-row {
    gap: 4px;
}

.checkout-form input,
.checkout-form textarea {
    padding: 10px 12px;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: 15px;
    font-family: inherit;
    background: #fff;
    width: 100%;
    min-height: 44px;
}

.checkout-form textarea {
    min-height: 72px;
    resize: vertical;
}


.checkout-total span {
    font-size: 18px;
    font-weight: 800;
}

.checkout-actions {
    display: flex;
    gap: 8px;
}

/* ---------- thanks page ---------- */
.thanks-page {
    text-align: center;
    padding: 40px 16px;
    background: #fff;
    border-radius: 12px;
    border: 1px solid #eee;
}

.thanks-icon {
    font-size: 48px;
    margin-bottom: 8px;
}

.thanks-page h2 {
    margin-bottom: 12px;
}

.thanks-page p {
    color: #666;
    margin: 6px 0;
}

.thanks-order {
    font-size: 15px;
}

.thanks-page .btn {
    margin-top: 20px;
}

/* =========================================================
   Orders page
   ========================================================= */

.orders-head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 12px;
}

.orders-count {
    font-size: 13px;
    color: #888;
}

.orders-empty {
    text-align: center;
    padding: 40px 16px;
    background: #fff;
    border: 1px dashed #ddd;
    border-radius: 12px;
    color: #666;
}

.orders-empty .btn {
    margin-top: 12px;
}

.orders-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 20px;
}

/* ---------- card ---------- */
.order-card {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 10px;
    overflow: hidden;
}

.order-summary {
    list-style: none;
    cursor: pointer;
    padding: 10px 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    touch-action: manipulation;
    user-select: none;
}

.order-summary::-webkit-details-marker {
    display: none;
}

.order-card[open] .order-summary {
    border-bottom: 1px solid #eee;
    background: #fafafa;
}

.order-summary-left {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.order-number {
    font-weight: 700;
    font-size: 14px;
}

.order-meta {
    font-size: 12px;
    color: #888;
    display: flex;
    gap: 8px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.order-summary-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    flex-shrink: 0;
}

.order-total {
    font-weight: 700;
    font-size: 14px;
}

.order-status {
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 10px;
    background: #eef;
    color: #334;
    font-weight: 600;
}

.status-new {
    background: #fff3e6;
    color: #a35a13;
}

.status-confirmed {
    background: #e6efff;
    color: #2a4d99;
}

.status-delivered {
    background: #e6f7e6;
    color: #2a6a2a;
}

.status-cancelled {
    background: #ffefef;
    color: #a22;
}

/* ---------- expanded details ---------- */
.order-details {
    padding: 10px 12px 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.order-items {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.order-item {
    display: grid;
    grid-template-columns: 40px 1fr auto;
    gap: 8px;
    align-items: center;
}

.order-item-img {
    width: 40px;
    height: 40px;
    border-radius: 6px;
    overflow: hidden;
    background: #f4f4f4;
}

.order-item-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.order-item-name {
    font-size: 13px;
    font-weight: 600;
    line-height: 1.25;
}

.order-item-price {
    font-size: 11px;
    color: #888;
    margin-top: 2px;
}

.order-item-sum {
    font-size: 13px;
    font-weight: 700;
    white-space: nowrap;
}

.order-contact {
    padding: 8px 10px;
    background: #fafafa;
    border-radius: 8px;
    font-size: 13px;
    color: #444;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.order-contact-title {
    font-size: 11px;
    text-transform: uppercase;
    color: #888;
    margin-bottom: 2px;
    letter-spacing: .03em;
}

.order-comment {
    font-style: italic;
    color: #666;
}

.order-footer {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding-top: 8px;
    border-top: 1px solid #eee;
    font-size: 14px;
}

.order-footer-sum {
    font-size: 18px;
    font-weight: 800;
}