﻿/* ============================================================
   3-STEP CHECKOUT WORKFLOW & STEPPER BAR STYLES
   ============================================================ */

.checkout-step-page {
    padding-top: 25px;
    padding-bottom: 60px;
    max-width: 1160px;
    margin: 0 auto;
    padding-left: 20px;
    padding-right: 20px;
}

/* Page Header with Arrow */
.step-header {
    margin-bottom: 25px;
}

.step-header-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.step-back-arrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #C9A227;
    font-size: 20px;
    text-decoration: none;
    transition: transform 0.2s;
}

.step-back-arrow:hover {
    transform: translateX(-4px);
}

[dir="rtl"] .step-back-arrow:hover {
    transform: translateX(4px);
}

.step-header h2 {
    font-size: 22px;
    font-weight: 700;
    color: #111;
    margin: 0;
}

.step-header p {
    font-size: 13px;
    color: #777;
    margin-top: 4px;
    margin-bottom: 0;
}

/* Stepper Bar */
.stepper-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    max-width: 550px;
    margin: 0 auto 35px auto;
    position: relative;
    padding: 0 10px;
}

.stepper-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 2;
    text-decoration: none;
}

.stepper-node {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #f1f5f9;
    border: 2px solid #cbd5e1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    color: #94a3b8;
    transition: all 0.3s ease;
}

.stepper-node .node-ring {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: transparent;
    border: 3px solid #10b981;
}

.stepper-item.active .stepper-node {
    background: #ffffff;
    border-color: #10b981;
    box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.15);
}

.stepper-item.completed .stepper-node {
    background: #10b981;
    border-color: #10b981;
    color: #ffffff;
}

.stepper-label {
    font-size: 13px;
    font-weight: 600;
    color: #94a3b8;
    margin-top: 8px;
    transition: color 0.3s;
}

.stepper-item.active .stepper-label,
.stepper-item.completed .stepper-label {
    color: #10b981;
}

.stepper-line {
    flex: 1;
    height: 3px;
    background: #e2e8f0;
    margin: 0 12px;
    margin-bottom: 24px;
    transition: background 0.3s ease;
}

.stepper-line.completed {
    background: #10b981;
}

/* 2-Column Workflow Layout */
.workflow-layout {
    display: grid;
    grid-template-columns: 1fr 360px;
    gap: 30px;
    align-items: start;
}

/* Common Sidebar Styles */
.sidebar-box {
    background: #ffffff;
    border: 1px solid #edf2f7;
    border-radius: 16px;
    padding: 22px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.03);
    margin-bottom: 20px;
}

.sidebar-title {
    font-size: 16px;
    font-weight: 700;
    color: #1a202c;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid #f0f0f0;
}

.summary-line {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
    font-size: 14px;
    color: #4a5568;
}

.summary-line.total-line {
    font-size: 16px;
    font-weight: 700;
    color: #1a202c;
    border-top: 1px dashed #e2e8f0;
    padding-top: 14px;
    margin-top: 14px;
    margin-bottom: 0;
}

.summary-line .mono {
    font-family: 'IBM Plex Mono', monospace;
}

/* Coupon Card in Sidebar */
.sidebar-coupon {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 14px 16px;
    margin-bottom: 18px;
    overflow: hidden;
}

.sidebar-coupon-head {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    user-select: none;
}

.sidebar-coupon-icon {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #e0f2fe;
    color: #0284c7;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}

.sidebar-coupon-text {
    flex: 1;
}

.sidebar-coupon-text h4 {
    font-size: 13.5px;
    font-weight: 700;
    color: #0284c7;
    margin: 0;
}

.sidebar-coupon-text p {
    font-size: 11.5px;
    color: #64748b;
    margin: 0;
}

.coupon-chevron {
    color: #94a3b8;
    font-size: 14px;
    transition: transform 0.25s ease;
    flex-shrink: 0;
}

.sidebar-coupon.open .coupon-chevron,
.coupon-card.open .coupon-chevron {
    transform: rotate(90deg);
}

.coupon-body {
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    margin-top: 0;
    transition: all 0.3s ease;
}

.sidebar-coupon.open .coupon-body,
.coupon-card.open .coupon-body {
    max-height: 160px;
    opacity: 1;
    margin-top: 12px;
}

/* Orange Pill Action Buttons */
.btn-orange-pill {
    background: linear-gradient(135deg, #C9A227 0%, #f97316 100%);
    color: #ffffff;
    border: none;
    border-radius: 25px;
    padding: 14px 36px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.25s ease;
    box-shadow: 0 4px 14px rgba(249, 115, 22, 0.35);
    text-decoration: none;
}

.btn-orange-pill:hover {
    background: linear-gradient(135deg, #ea580c 0%, #dd6b20 100%);
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(249, 115, 22, 0.45);
    color: #fff;
}

/* Back Link/Button */
.btn-back-link {
    background: #f1f5f9;
    color: #C9A227;
    border: 1px solid #cbd5e1;
    border-radius: 25px;
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s ease;
}

.btn-back-link:hover {
    background: #e2e8f0;
    color: #1e293b;
}

/* Action Footer Container */
.step-actions-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 30px;
}

.step-actions-footer.align-end {
    justify-content: flex-end;
}

/* Toggle Pills for Shipping Method */
.delivery-toggle-pills {
    display: inline-flex;
    background: #f1f5f9;
    padding: 4px;
    border-radius: 20px;
    margin-bottom: 22px;
}

.delivery-pill {
    padding: 8px 20px;
    border-radius: 16px;
    font-size: 13.5px;
    font-weight: 600;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    background: transparent;
}

.delivery-pill.active {
    background: #C9A227;
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(255, 140, 0, 0.3);
}

/* Address Card Design */
.saved-address-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 18px;
    font-size: 13.5px;
    color: #9C7A1E;
    line-height: 1.6;
    position: relative;
    max-width: 320px;
}

.saved-address-card h5 {
    font-size: 15px;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: 4px;
}

.saved-address-card p {
    margin: 2px 0;
    color: #C9A227;
}

/* Media Queries for Responsive Stepper */
@media (max-width: 900px) {
    .workflow-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 580px) {
    .stepper-label {
        font-size: 11.5px;
    }
    .stepper-node {
        width: 28px;
        height: 28px;
    }
    .stepper-line {
        margin: 0 6px 20px 6px;
    }
    .step-actions-footer.align-end {
        justify-content: center;
    }
    .step-actions-footer.align-end .btn-orange-pill {
        width: 100%;
        text-align: center;
    }
}
