@import url('https://fonts.googleapis.com/css2?family=Cal+Sans:wght@400;700&display=swap');

:root {
    --primary: #1a1a1a;
    --secondary: #8a4d0f;
    --accent: #d4c9a8;
    --light: #fffef0;
    --dark: #121212;
    --text: #333;
    --error: #e74c3c;
}

h2 {
    font-size: 2rem;
    color: var(--light);
    margin-bottom: 1.5rem;
}

#cart-container {
    display: none;
    margin-bottom: 2rem;
}

#loading {
    text-align: center;
    padding: 2rem;
    font-size: 1.1rem;
    color: var(--text);
}

#empty-cart-message {
    display: none;
    text-align: center;
    padding: 3rem;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

#empty-cart-message p {
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
    color: var(--text);
}

#empty-cart-message a {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background: var(--secondary);
    color: white;
    text-decoration: none;
    border-radius: 4px;
    transition: background 0.3s ease;
}

#empty-cart-message a:hover {
    background: #a05a14;
}

.cart-item {
    display: flex;
    align-items: center;
    padding: 1.5rem;
    margin-bottom: 1rem;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    gap: 1.5rem;
}

.cart-item img {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 4px;
}

.item-info {
    flex: 1;
}

.item-info h3 {
    font-size: 1.2rem;
    margin: 0 0 0.5rem;
    color: var(--primary);
}

.item-info p {
    margin: 0 0 0.3rem;
    color: var(--text);
}

.item-info p:last-child {
    font-weight: bold;
    color: var(--secondary);
}

.item-controls {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.quantity-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.qty-btn {
    width: 30px;
    height: 30px;
    margin: 10px;
    background: var(--light);
    border: 0,2px solid var(--accent);
    border-radius: 50%;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.2s ease;
}

.qty-btn:hover {
    background: var(--accent);
    scale: 1.1;
    font-size: 1.1rem;
}

.qty-value {
    min-width: 20px;
    text-align: center;
}

.remove-btn {
    background: var(--secondary);
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background 0.2s ease;
}

.remove-btn:hover {
    background: #a05a14;
}

#cart-summary {
    display: none;
    background: white;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.summary-details {
    margin-bottom: 1.5rem;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 0;
    font-size: 1.1rem;
    border-bottom: 1px solid #eee;
}

.summary-row:last-child {
    font-weight: bold;
    font-size: 1.2rem;
    border-bottom: none;
}

/* cart actions */
.cart-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.secondary-btn {
    background: var(--primary);
    color: white;
    border: none;
    padding: 0.75rem;
    border-radius: 4px;
    cursor: pointer;
    flex: 1;
    font-size: 1rem;
    transition: background 0.3s ease;
}

.secondary-btn:hover {
    background: #333;
}

.add-to-cart {
    background: var(--secondary);
    color: white;
    border: none;
    padding: 0.75rem;
    border-radius: 4px;
    cursor: pointer;
    flex: 1;
    font-size: 1rem;
    transition: background 0.3s ease;
}

.add-to-cart:hover {
    background: #a05a14;
}

#order-confirmation {
    display: none;
    text-align: center;
    padding: 3rem 2rem;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

#order-confirmation h3 {
    color: var(--secondary);
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
}

#order-confirmation p {
    margin-bottom: 1rem;
    font-size: 1.1rem;
    color: var(--text);
}

#order-number {
    font-weight: bold;
    color: var(--secondary);
}

.cart-count {
    position: absolute;
    top: -8px;
    right: -8px;
    background: var(--secondary);
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.input-email {
    padding: 8px;
    border-radius: 4px 0 0 4px;
    border: 1px solid var(--accent);
    flex-grow: 1;
}

.search-btn {
    padding: 8px 15px;
    border-radius: 0 4px 4px 0;
    background: var(--secondary);
    color: var(--light);
    border: none;
    cursor: pointer;
}
