/* ===== RESET & BASE ===== */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: #f5f5f5;
    color: #333;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

a {
    text-decoration: none;
    color: inherit;
}

/* ===== HEADER ===== */
.header {
    background: #fff;
    border-bottom: 1px solid #eee;
    padding: 12px 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-inner {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 20px;
    letter-spacing: 2px;
    cursor: pointer;
}

.logo-icon {
    width: 28px;
    height: 28px;
}

.logo-online {
    color: #333;
    font-weight: 600;
}

.logo-boutique {
    color: #999;
    font-weight: 300;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

.currency-selector {
    display: flex;
    align-items: center;
    border: 1px solid #ccc;
    border-radius: 4px;
    padding: 4px 6px;
    font-size: 13px;
    gap: 4px;
}

.currency-symbol {
    font-size: 12px;
    color: #666;
}

.currency-select {
    border: none;
    outline: none;
    font-size: 13px;
    background: transparent;
    cursor: pointer;
    color: #333;
    -webkit-appearance: none;
    appearance: none;
    padding-right: 12px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='5'%3E%3Cpath d='M0 0l4 5 4-5z' fill='%23666'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right center;
}

.cart-link {
    display: flex;
    align-items: center;
    padding: 4px 8px;
    border-left: 1px solid #ccc;
    cursor: pointer;
    position: relative;
}

.cart-icon {
    width: 20px;
    height: 20px;
    fill: #333;
}

.cart-count {
    position: absolute;
    top: -4px;
    right: -4px;
    background: #c41230;
    color: #fff;
    font-size: 10px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
}

/* ===== MAIN CONTENT ===== */
.main-content {
    flex: 1;
    max-width: 1100px;
    margin: 0 auto;
    width: 100%;
    padding: 30px 20px;
}

/* ===== HOME PAGE ===== */
.section-title {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 24px;
    color: #333;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.product-card {
    cursor: pointer;
    transition: transform 0.15s;
}

.product-card:hover {
    transform: translateY(-2px);
}

.product-card-image {
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    border-radius: 12px;
    background: #e8e8e8;
}

.product-card-name {
    margin-top: 10px;
    font-size: 14px;
    font-weight: 500;
    color: #333;
}

.product-card-price {
    font-size: 13px;
    color: #b8860b;
    margin-top: 2px;
}

/* ===== PRODUCT DETAIL PAGE ===== */
.product-detail {
    display: flex;
    gap: 60px;
    padding: 20px 0;
    align-items: flex-start;
}

.product-detail-image {
    width: 420px;
    min-width: 420px;
    aspect-ratio: 1;
    object-fit: cover;
    border-radius: 12px;
    background: #e8e8e8;
}

.product-detail-info {
    flex: 1;
    padding-top: 20px;
}

.product-detail-name {
    font-size: 32px;
    font-weight: 700;
    color: #333;
    margin-bottom: 8px;
}

.product-detail-price {
    font-size: 20px;
    color: #333;
    margin-bottom: 16px;
}

.product-detail-desc {
    font-size: 14px;
    color: #555;
    line-height: 1.5;
    margin-bottom: 24px;
}

.quantity-selector {
    display: inline-flex;
    align-items: center;
    border: 1px solid #ccc;
    border-radius: 4px;
    padding: 6px 10px;
    margin-bottom: 20px;
}

.quantity-select {
    border: none;
    outline: none;
    font-size: 14px;
    background: transparent;
    cursor: pointer;
    padding-right: 16px;
    -webkit-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='5'%3E%3Cpath d='M0 0l4 5 4-5z' fill='%23666'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right center;
}

.btn-add-to-cart {
    display: block;
    background: #c41230;
    color: #fff;
    border: none;
    padding: 10px 24px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

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

/* Ad banner */
.ad-banner {
    background: #f8a4a4;
    padding: 14px 20px;
    text-align: center;
    font-size: 14px;
    color: #333;
    margin-top: 40px;
    position: relative;
}

.ad-label {
    position: absolute;
    top: -18px;
    left: 8px;
    font-size: 11px;
    color: #c41230;
}

/* ===== CART PAGE ===== */
.cart-page {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: start;
}

.cart-left {
    /* left column */
}

.cart-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.cart-title {
    font-size: 26px;
    font-weight: 700;
    color: #333;
}

.btn-outline {
    border: 2px solid #c41230;
    color: #c41230;
    background: transparent;
    padding: 6px 18px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-outline:hover {
    background: #c41230;
    color: #fff;
}

.btn-filled {
    background: #c41230;
    color: #fff;
    border: 2px solid #c41230;
    padding: 6px 18px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-filled:hover {
    background: #a30f28;
    border-color: #a30f28;
}

.cart-items {
    border-top: 1px solid #ddd;
}

.cart-item {
    display: flex;
    gap: 16px;
    padding: 16px 0;
    border-bottom: 1px solid #ddd;
    align-items: flex-start;
}

.cart-item-image {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
    background: #e8e8e8;
}

.cart-item-details {
    flex: 1;
}

.cart-item-name {
    font-size: 14px;
    font-weight: 600;
    color: #333;
}

.cart-item-sku {
    font-size: 12px;
    color: #999;
    margin-top: 2px;
}

.cart-item-qty {
    font-size: 13px;
    color: #555;
    margin-top: 6px;
}

.cart-item-price {
    font-size: 14px;
    font-weight: 600;
    color: #333;
    white-space: nowrap;
}

.cart-shipping {
    display: flex;
    justify-content: space-between;
    padding: 16px 0;
    border-bottom: 1px solid #ddd;
    font-size: 14px;
    color: #555;
}

.cart-total {
    display: flex;
    justify-content: space-between;
    padding: 16px 0;
    font-size: 20px;
    font-weight: 700;
    color: #333;
}

.cart-empty-message {
    padding: 40px 0;
    text-align: center;
    color: #999;
    font-size: 16px;
}

/* Shipping & Payment forms */
.cart-right {
    /* right column */
}

.form-section-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 16px;
    color: #333;
}

.form-group {
    margin-bottom: 12px;
}

.form-row {
    display: flex;
    gap: 12px;
}

.form-row .form-group {
    flex: 1;
}

.form-label {
    display: block;
    font-size: 11px;
    color: #c41230;
    margin-bottom: 4px;
    font-weight: 500;
}

.form-input,
.form-select {
    width: 100%;
    border: none;
    border-bottom: 1px solid #ccc;
    padding: 8px 0;
    font-size: 14px;
    color: #333;
    background: transparent;
    outline: none;
    transition: border-color 0.2s;
}

.form-input:focus,
.form-select:focus {
    border-bottom-color: #c41230;
}

.form-select {
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='5'%3E%3Cpath d='M0 0l4 5 4-5z' fill='%23666'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right center;
    padding-right: 16px;
}

.cvv-input {
    letter-spacing: 4px;
}

.btn-place-order {
    display: block;
    margin: 24px auto 0;
    background: #c41230;
    color: #fff;
    border: none;
    padding: 10px 28px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-place-order:hover {
    background: #a30f28;
}

/* ===== ORDER CONFIRMATION ===== */
.order-confirmation {
    text-align: center;
    padding: 60px 20px;
}

.order-confirmation h1 {
    font-size: 28px;
    color: #333;
    margin-bottom: 8px;
}

.order-confirmation .subtitle {
    font-size: 14px;
    color: #666;
    margin-bottom: 30px;
}

.order-details {
    display: inline-block;
    text-align: left;
    margin-bottom: 30px;
}

.order-detail-row {
    margin-bottom: 12px;
}

.order-detail-label {
    font-size: 12px;
    color: #999;
    text-transform: capitalize;
}

.order-detail-value {
    font-size: 15px;
    color: #333;
    font-weight: 500;
}

.btn-continue {
    display: inline-block;
    background: #c41230;
    color: #fff;
    border: none;
    padding: 10px 28px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-continue:hover {
    background: #a30f28;
}

/* ===== FOOTER ===== */
.footer {
    background: #4a0028;
    color: #ccc;
    padding: 30px 20px;
    margin-top: auto;
}

.footer-inner {
    max-width: 1100px;
    margin: 0 auto;
}

.footer-copyright {
    font-size: 13px;
    margin-bottom: 10px;
    color: #ddd;
}

.footer-meta {
    font-size: 11px;
    color: #aaa;
    margin-bottom: 4px;
}

.footer-pod {
    font-size: 11px;
    color: #aaa;
}

.footer-pod span {
    color: #66ccff;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .product-detail {
        flex-direction: column;
        gap: 24px;
    }

    .product-detail-image {
        width: 100%;
        min-width: auto;
    }

    .cart-page {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .product-grid {
        grid-template-columns: 1fr;
    }
}

/* ===== ERROR PAGES ===== */

/* Payment Unavailable Error (payment mode) */
.payment-error {
    background: #fce4ec;
    border: 1px solid #e57373;
    border-radius: 6px;
    padding: 32px 28px;
    max-width: 700px;
}

.payment-error-title {
    font-size: 22px;
    font-weight: 700;
    color: #b71c1c;
    margin-bottom: 8px;
}

.payment-error-text {
    font-size: 14px;
    color: #555;
    margin-bottom: 16px;
}

.payment-error-note {
    font-size: 13px;
    color: #666;
    margin-bottom: 8px;
    line-height: 1.5;
}

/* Transaction Failed Error (currency mode) */
.transaction-failed {
    background: #fce4ec;
    border: 1px solid #e57373;
    border-radius: 6px;
    padding: 32px 28px;
    max-width: 500px;
    margin: 40px auto;
}

.transaction-failed-title {
    font-size: 20px;
    font-weight: 700;
    color: #b71c1c;
    margin-bottom: 8px;
}

.transaction-failed-subtitle {
    font-size: 13px;
    color: #555;
    margin-bottom: 20px;
    line-height: 1.5;
}

.transaction-failed-details {
    margin-bottom: 20px;
}

.transaction-failed-details p {
    font-size: 13px;
    color: #333;
    margin-bottom: 6px;
}

.transaction-failed-details strong {
    color: #b71c1c;
}

.transaction-failed-note {
    font-size: 12px;
    color: #888;
    line-height: 1.5;
}