:root {
    --bg-color: #fdf2f8;
    --card-bg: #ffffff;
    --primary: #f472b6;
    --secondary: #c084fc;
    --text: #374151;
    --text-light: #9ca3af;
    --border: #fbcfe8;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-color);
    color: var(--text);
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.container {
    width: 90%;
    max-width: 1200px;
    height: 90vh;
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.8);
}

header {
    padding: 20px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border);
}

.logo {
    font-size: 1.5rem;
    font-weight: 600;
    background: linear-gradient(45deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.user-info {
    font-weight: 600;
    color: var(--text);
}

main {
    display: flex;
    flex: 1;
    overflow: hidden;
}

.products-section {
    flex: 2;
    padding: 40px;
    overflow-y: auto;
}

.products-section h1 {
    margin-bottom: 24px;
    font-weight: 400;
    color: var(--text);
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 24px;
}

.product-card {
    background: var(--card-bg);
    border-radius: 16px;
    padding: 16px;
    transition: transform 0.2s, box-shadow 0.2s;
    border: 1px solid transparent;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 20px rgba(244, 114, 182, 0.1);
    border-color: var(--border);
}

.product-img {
    width: 100%;
    height: 150px;
    background-color: #f3f4f6;
    border-radius: 12px;
    margin-bottom: 16px;
    object-fit: cover;
}

.product-info h3 {
    font-size: 1rem;
    margin-bottom: 4px;
}

.product-info p {
    color: var(--primary);
    font-weight: 600;
    margin-bottom: 12px;
}

.add-btn {
    width: 100%;
    padding: 10px;
    border: none;
    border-radius: 8px;
    background: var(--text);
    color: white;
    cursor: pointer;
    transition: background 0.2s;
}

.add-btn:hover {
    background: var(--primary);
}

.cart-section {
    flex: 1;
    background: rgba(255, 255, 255, 0.5);
    border-left: 1px solid var(--border);
    padding: 30px;
    display: flex;
    flex-direction: column;
}

.cart-section h2 {
    margin-bottom: 20px;
    font-size: 1.2rem;
}

.cart-items {
    flex: 1;
    overflow-y: auto;
    margin-bottom: 20px;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid #f3f4f6;
    font-size: 0.9rem;
}

.empty-msg {
    color: var(--text-light);
    text-align: center;
    margin-top: 40px;
}

.coupon-area {
    display: flex;
    gap: 8px;
    margin-bottom: 10px;
}

#coupon-code {
    flex: 1;
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
    outline: none;
}

#apply-coupon {
    padding: 10px 16px;
    background: var(--secondary);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
}

#coupon-message {
    font-size: 0.8rem;
    margin-bottom: 20px;
    height: 20px;
}

.success { color: green; }
.error { color: red; }

.cart-total {
    display: flex;
    justify-content: space-between;
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 20px;
}

.checkout-btn {
    width: 100%;
    padding: 16px;
    background: linear-gradient(45deg, var(--primary), var(--secondary));
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.2s;
}

.checkout-btn:hover {
    opacity: 0.9;
}

#checkout-message {
    margin-top: 15px;
    font-weight: 600;
    text-align: center;
    word-break: break-all;
}
