/* ========== MAIN STYLES EXTRACTED FROM KINEED INDEX ========== */
:root {
    /* Colores Principales */
    --teal-primary: #1e8789;
    --teal-dark: #166668;
    --teal-light: #e6f4f4;

    /* Acentos */
    --yellow-accent: #ffd166;
    --red-alert: #ef476f;
    --blue-info: #118ab2;

    /* Escala de Grises */
    --white: #ffffff;
    --bg-light: #f8f9fa;
    --text-dark: #2d3436;
    --text-gray: #636e72;
    --border-light: #dfe6e9;

    /* Sombras y Efectos */
    --shadow-sm: 0 4px 6px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 8px 15px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 20px 30px rgba(0, 0, 0, 0.1);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
}

body {
    font-family: 'Inter', sans-serif;
    color: var(--text-dark);
    background: var(--bg-light);
    /* Changed to light bg for inner pages */
    line-height: 1.6;
    margin: 0;
    padding: 0;
}

/* Header Re-use */
.header {
    background: var(--white);
    padding: 16px 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.logo {
    font-size: 24px;
    font-weight: 800;
    color: var(--teal-primary);
    text-decoration: none;
    letter-spacing: -0.5px;
}

.nav {
    display: flex;
    gap: 32px;
}

.nav a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 500;
    font-size: 15px;
    transition: color 0.3s ease;
}

.nav a:hover {
    color: var(--teal-primary);
}

/* Utilities */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    text-decoration: none;
}

.btn-primary {
    background: var(--teal-primary);
    color: white;
}

.btn-primary:hover {
    background: var(--teal-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(30, 135, 137, 0.3);
}

/* Cart Specific Styles */
.page-title {
    margin: 40px 0 30px;
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--text-dark);
}

.cart-grid {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 40px;
    align-items: start;
    padding-bottom: 80px;
}

/* Product List */
.cart-products {
    background: white;
    border-radius: var(--radius-lg);
    padding: 20px;
    box-shadow: var(--shadow-sm);
}

.cart-item {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 20px 0;
    border-bottom: 1px solid var(--border-light);
}

.cart-item:last-child {
    border-bottom: none;
}

.item-img {
    width: 80px;
    height: 80px;
    border-radius: var(--radius-md);
    object-fit: cover;
    background: #f1f1f1;
}

.item-details {
    flex: 1;
}

.item-name {
    font-weight: 700;
    font-size: 1.1rem;
    margin-bottom: 4px;
    color: var(--text-dark);
}

.item-price {
    font-weight: 600;
    color: var(--teal-primary);
}

/* Quantity Controls */
.qty-control {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--bg-light);
    padding: 4px;
    border-radius: 20px;
}

.qty-btn {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: none;
    background: white;
    cursor: pointer;
    font-weight: 700;
    color: var(--teal-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.qty-input {
    width: 30px;
    text-align: center;
    border: none;
    background: transparent;
    font-weight: 600;
    font-size: 0.9rem;
}

/* Remove Button */
.btn-remove {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-gray);
    background: transparent;
    border: none;
    cursor: pointer;
    border-radius: 50%;
    transition: all 0.2s;
}

.btn-remove:hover {
    background: #fff0f0;
    color: var(--red-alert);
}

/* Order Summary */
.order-summary {
    background: white;
    border-radius: var(--radius-lg);
    padding: 30px;
    box-shadow: var(--shadow-md);
    position: sticky;
    top: 100px;
}

.summary-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 24px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 16px;
    font-size: 0.95rem;
    color: var(--text-gray);
}

.summary-row.total {
    margin-top: 24px;
    padding-top: 20px;
    border-top: 2px dashed var(--border-light);
    color: var(--text-dark);
    font-weight: 800;
    font-size: 1.3rem;
    align-items: center;
}

.btn-checkout {
    width: 100%;
    padding: 16px;
    font-size: 1.1rem;
    margin-top: 24px;
}

/* Loading State */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
}

.loading-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid var(--teal-light);
    border-top-color: var(--teal-primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Responsive */
@media (max-width: 900px) {
    .cart-grid {
        grid-template-columns: 1fr;
    }

    .header {
        padding: 16px 20px;
    }
}