html {
    font-size: 16px;
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    background-color: #111010;
    font-family: Arial, 'Helvetica Neue', Helvetica, sans-serif;
    color: white;
}

/* Cart Drawer Styles */
.cart-drawer {
    position: fixed;
    top: 0;
    right: -400px; /* Hidden by default */
    width: 400px;
    height: 100vh;
    background-color: #1a1a1a;
    color: white;
    box-shadow: -2px 0 10px rgba(0, 0, 0, 0.5);
    transition: right 0.3s ease-in-out;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.cart-drawer.open {
    right: 0;
}

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #333;
}

.cart-header h2 {
    margin: 0;
    font-size: 1.5rem;
}

.close-btn {
    background: none;
    border: none;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-btn:hover {
    color: #ccc;
}

#cart-content {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
}

.cart-items {
    list-style: none;
    padding: 0;
    margin: 0;
}

.cart-item {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 15px 0;
    border-bottom: 1px solid #333;
}

.cart-item:last-child {
    border-bottom: none;
}

.item-details {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.item-name {
    font-weight: bold;
    font-size: 1rem;
}

.item-price {
    color: #ccc;
    font-size: 0.85rem;
}

.item-grind {
    color: #9ca3af;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.item-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}

.qty-btn {
    background-color: #333;
    color: white;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s;
}

.qty-btn:hover {
    background-color: #444;
}

.qty-btn:active {
    background-color: #222;
}

.item-qty {
    min-width: 30px;
    text-align: center;
    font-weight: bold;
    font-size: 1rem;
}

.item-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.item-total {
    font-weight: bold;
    font-size: 1.1rem;
}

.remove-btn {
    background-color: #d32f2f;
    color: white;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s;
}

.remove-btn:hover {
    background-color: #b71c1c;
}

.remove-btn:active {
    background-color: #9a0007;
}

.cart-total {
    margin-top: 20px;
    text-align: center;
}

.cart-total h3 {
    margin: 0;
    font-size: 1.25rem;
}

.cart-footer {
    padding: 20px;
    border-top: 1px solid #333;
    text-align: center;
    display: none;
}

.checkout-btn {
    background-color: #4caf50;
    color: white;
    border: none;
    padding: 12px 24px;
    font-size: 1rem;
    cursor: pointer;
    border-radius: 4px;
    width: 100%;
}

.checkout-btn:hover {
    background-color: #45a049;
}

/* Overlay when cart is open */
.cart-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 999;
    display: none;
}

.cart-overlay.active {
    display: block;
}

.grind-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    z-index: 1100;
    display: none;
}

.grind-modal-overlay.active {
    display: block;
}

.grind-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: min(92vw, 420px);
    background: #171717;
    color: white;
    border: 1px solid #2f2f2f;
    border-radius: 10px;
    padding: 18px;
    z-index: 1101;
    display: none;
}

.grind-modal.open {
    display: block;
}

.grind-modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 14px;
}

.grind-modal__header h3 {
    margin: 0;
    font-size: 1.1rem;
}

.grind-modal__close {
    background: transparent;
    border: none;
    color: white;
    font-size: 1.7rem;
    cursor: pointer;
    line-height: 1;
}

.grind-modal__options {
    display: grid;
    gap: 10px;
}

.grind-option-btn {
    width: 100%;
    min-height: 42px;
    border: 1px solid #3f3f46;
    border-radius: 8px;
    background: #202020;
    color: white;
    cursor: pointer;
    font-weight: 600;
}

.grind-option-btn:hover {
    background: #2a2a2a;
}
