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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #f3f6fc;
    color: #1a2332;
    line-height: 1.6;
    min-height: 100vh;
}

/* ============================================
   CONTAINER
   ============================================ */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 24px 32px 40px;
}

/* ============================================
   HEADER
   ============================================ */
.header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 0 20px;
    border-bottom: 1px solid #e2e8f0;
    margin-bottom: 24px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.5rem;
    font-weight: 700;
    color: #1a2332;
}

.logo span {
    color: #0066ff;
}

.logo span:first-child {
    color: #1a2332;
}

.nav {
    display: flex;
    gap: 32px;
    font-size: 0.95rem;
}

.nav a {
    color: #4a5568;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
    position: relative;
}

.nav a:hover {
    color: #0066ff;
}

.nav a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    right: 0;
    height: 2px;
    background: #0066ff;
    transform: scaleX(0);
    transition: transform 0.2s;
}

.nav a:hover::after {
    transform: scaleX(1);
}

.user-badge .avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: #e2e8f0;
    border-radius: 50%;
    font-weight: 600;
    font-size: 0.9rem;
    color: #2d3748;
    border: 2px solid transparent;
    transition: border-color 0.2s;
    cursor: pointer;
}

.user-badge .avatar:hover {
    border-color: #0066ff;
}

/* ============================================
   BREADCRUMB
   ============================================ */
.breadcrumb {
    font-size: 0.85rem;
    color: #718096;
    margin-bottom: 28px;
    padding: 10px 0;
}

.breadcrumb .separator {
    margin: 0 8px;
    color: #a0aec0;
}

.breadcrumb .current {
    color: #1a2332;
    font-weight: 600;
}

/* ============================================
   CHECKOUT GRID
   ============================================ */
.checkout-grid {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 40px;
    margin-bottom: 40px;
}

/* ============================================
   ORDER SECTION
   ============================================ */
.order-section {
    background: #ffffff;
    border-radius: 16px;
    padding: 32px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
    border: 1px solid #eef2f6;
}

.order-section h2 {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 20px;
    color: #1a2332;
}

.order-items {
    border-bottom: 2px solid #f0f4f8;
    padding-bottom: 16px;
    margin-bottom: 20px;
}

.order-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
}

.order-item:first-child {
    padding-top: 0;
}

.item-info {
    display: flex;
    align-items: center;
    gap: 14px;
}

.item-icon {
    font-size: 1.5rem;
    width: 40px;
    height: 40px;
    background: #f0f4f8;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.item-name {
    font-weight: 600;
    font-size: 0.95rem;
    color: #1a2332;
}

.item-desc {
    font-size: 0.8rem;
    color: #718096;
}

.item-price {
    font-weight: 700;
    color: #1a2332;
}

.order-totals {
    margin-bottom: 20px;
}

.total-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    font-size: 0.95rem;
    color: #4a5568;
}

.total-row .discount {
    color: #38a169;
}

.total-row.grand-total {
    border-top: 2px solid #e2e8f0;
    margin-top: 8px;
    padding-top: 16px;
    font-weight: 700;
    font-size: 1.15rem;
    color: #1a2332;
}

.trust-badges {
    display: flex;
    gap: 20px;
    padding-top: 16px;
    border-top: 1px solid #eef2f6;
    font-size: 0.8rem;
    color: #4a5568;
    flex-wrap: wrap;
}

.trust-badges span {
    display: flex;
    align-items: center;
    gap: 6px;
}

/* ============================================
   PAYMENT SECTION
   ============================================ */
.payment-section {
    background: #ffffff;
    border-radius: 16px;
    padding: 32px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
    border: 1px solid #eef2f6;
}

.payment-section h2 {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 4px;
    color: #1a2332;
}

.section-sub {
    color: #718096;
    font-size: 0.9rem;
    margin-bottom: 24px;
}

/* Form Elements */
.payment-form {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

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

.form-group label {
    display: block;
    font-weight: 600;
    font-size: 0.85rem;
    color: #2d3748;
    margin-bottom: 6px;
}

.form-group input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    font-size: 0.95rem;
    font-family: 'Inter', sans-serif;
    transition: all 0.2s;
    background: #fafbfc;
    color: #1a2332;
}

.form-group input:focus {
    outline: none;
    border-color: #0066ff;
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(0, 102, 255, 0.08);
}

.form-group input::placeholder {
    color: #a0aec0;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

/* Card Input Wrapper */
.card-input-wrapper {
    position: relative;
}

.card-input-wrapper input {
    padding-right: 60px;
}

.card-icons {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.2rem;
    opacity: 0.6;
}

/* CVV Wrapper */
.cvv-wrapper {
    position: relative;
}

.cvv-wrapper input {
    padding-right: 44px;
}

.cvv-tip {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    cursor: help;
    font-size: 0.9rem;
    color: #a0aec0;
    transition: color 0.2s;
}

.cvv-tip:hover {
    color: #0066ff;
}

/* Submit Button */
.submit-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    padding: 16px 32px;
    background: linear-gradient(135deg, #0066ff, #0044cc);
    color: #ffffff;
    border: none;
    border-radius: 12px;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    margin-top: 8px;
    font-family: 'Inter', sans-serif;
    box-shadow: 0 4px 16px rgba(0, 102, 255, 0.25);
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(0, 102, 255, 0.35);
}

.submit-btn:active {
    transform: translateY(0px);
}

.btn-icon {
    transition: transform 0.3s;
}

.submit-btn:hover .btn-icon {
    transform: translateX(4px);
}

/* Form Footer */
.form-footer {
    margin-top: 18px;
    text-align: center;
    font-size: 0.8rem;
    color: #718096;
}

.form-footer a {
    color: #0066ff;
    text-decoration: none;
    font-weight: 500;
}

.form-footer a:hover {
    text-decoration: underline;
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
    border-top: 1px solid #e2e8f0;
    padding-top: 24px;
    margin-top: 20px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: #718096;
}

.footer-links {
    display: flex;
    gap: 24px;
}

.footer-links a {
    color: #4a5568;
    text-decoration: none;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: #0066ff;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 968px) {
    .checkout-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .container {
        padding: 16px;
    }
}

@media (max-width: 600px) {
    .header {
        flex-wrap: wrap;
        gap: 12px;
    }

    .nav {
        gap: 16px;
        font-size: 0.85rem;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .order-section,
    .payment-section {
        padding: 20px;
    }

    .trust-badges {
        gap: 12px;
    }

    .footer-content {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }
}
