/* ================================================
   FUDA Pricing - Premium SaaS Design
   Aligned with FUDA Design System (Beige/Orange)
   ================================================ */

.pricing-section {
    padding: 100px 24px 80px;
    max-width: 1200px;
    margin: 0 auto;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg, #fafaf9);
}

/* ========== HEADER ========== */
.pricing-header {
    text-align: center;
    margin-bottom: 64px;
}

.pricing-title {
    font-size: 48px;
    font-weight: 700;
    color: var(--text, #1c1917);
    margin: 0 0 16px 0;
    letter-spacing: -0.02em;
    line-height: 1.1;
}

.pricing-subtitle {
    color: var(--text-secondary, #78716c);
    font-size: 18px;
    margin: 0 0 32px 0;
    font-weight: 400;
    line-height: 1.5;
}

/* ========== BILLING TOGGLE ========== */
.billing-toggle {
    display: inline-flex;
    background: var(--surface, #ffffff);
    border: 1px solid var(--border, #e7e5e4);
    border-radius: 10px;
    padding: 4px;
    gap: 4px;
}

.toggle-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary, #78716c);
    padding: 10px 20px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s ease;
}

.toggle-btn.active {
    background: #1c1917;
    color: #ffffff;
}

.toggle-btn:hover:not(.active) {
    color: var(--text, #1c1917);
}

.discount {
    color: #16a34a;
    font-size: 12px;
    font-weight: 600;
    margin-left: 6px;
}

.toggle-btn.active .discount {
    color: rgba(255,255,255,0.8);
}

/* ========== PRICING GRID ========== */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    background: transparent;
    border-radius: 16px;
    overflow: visible;
    margin-bottom: 24px;
}

/* ========== PRICING CARDS ========== */
.pricing-card {
    background: rgba(0, 0, 0, 0.05);
    padding: 32px 28px;
    display: flex;
    flex-direction: column;
    min-height: 420px;
    transition: background 0.3s ease;
    border-radius: 12px;
    border: 1px solid var(--border, #e7e5e4);
    box-shadow: none;
}

.pricing-card:hover {
    background: rgba(0, 0, 0, 0.3);
    /* Override modern.css hover effects */
    transform: none;
    border-color: var(--border, #e7e5e4);
    box-shadow: none;
}

/* Plan Name */
.plan-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary, #78716c);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin: 0 0 8px 0;
}

/* Tagline */
.plan-tagline {
    font-size: 15px;
    color: var(--text-secondary, #78716c);
    margin: 0 0 24px 0;
    line-height: 1.4;
    min-height: 42px;
}

/* ========== PRICING ========== */
.plan-price {
    margin-bottom: 24px;
    display: flex;
    align-items: baseline;
    gap: 2px;
}

.price {
    font-size: 42px;
    font-weight: 700;
    color: var(--text, #1c1917);
    letter-spacing: -0.02em;
    line-height: 1;
}

.period {
    color: var(--text-tertiary, #a8a29e);
    font-size: 14px;
    font-weight: 400;
    margin-left: 4px;
}

/* ========== FEATURES ========== */
.features {
    list-style: none;
    padding: 24px 0 0 0;
    margin: 0;
    flex-grow: 1;
    border-top: 1px solid var(--border, #e7e5e4);
}

.features li {
    position: relative;
    padding-left: 24px;
    margin-bottom: 12px;
    color: var(--text-secondary, #78716c);
    font-size: 14px;
    line-height: 1.5;
}

.features li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 6px;
    width: 14px;
    height: 14px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%23f97316'%3E%3Cpath fill-rule='evenodd' d='M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z' clip-rule='evenodd'/%3E%3C/svg%3E") center/contain no-repeat;
}

/* ========== BUTTONS ========== */
.plan-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 44px;
    border-radius: 8px;
    font-weight: 500;
    font-size: 14px;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.15s ease;
    border: none;
    margin-top: 24px;
}

.cta-primary {
    background: #1c1917;
    color: #ffffff;
}

.cta-primary:hover {
    background: #000000;
    transform: translateY(-1px);
}

.cta-outline {
    background: transparent;
    border: 1px solid var(--border, #e7e5e4);
    color: var(--text, #1c1917);
}

.cta-outline:hover {
    background: var(--beige, #f5f5f4);
    border-color: var(--text-tertiary, #a8a29e);
}

/* ========== ENTERPRISE BAR ========== */
.enterprise-bar {
    background: var(--surface, #ffffff);
    border: 1px solid var(--border, #e7e5e4);
    border-radius: 16px;
    padding: 28px 32px;
    margin-bottom: 32px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.enterprise-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
}

.enterprise-text h3 {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary, #78716c);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin: 0 0 6px 0;
}

.enterprise-text p {
    color: var(--text-secondary, #78716c);
    font-size: 15px;
    margin: 0;
    line-height: 1.5;
}

.enterprise-bar .plan-cta {
    width: auto;
    flex-shrink: 0;
    margin-top: 0;
    padding: 0 24px;
}

/* ========== NOTE ========== */
.pricing-note {
    text-align: center;
    color: var(--text-tertiary, #a8a29e);
    font-size: 13px;
    margin: 0;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1024px) {
    .pricing-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .pricing-card {
        min-height: 380px;
    }
}

@media (max-width: 640px) {
    .pricing-section {
        padding: 80px 16px 60px;
    }
    
    .pricing-title {
        font-size: 32px;
    }
    
    .pricing-subtitle {
        font-size: 16px;
    }
    
    .pricing-grid {
        grid-template-columns: 1fr;
    }
    
    .pricing-card {
        min-height: auto;
        padding: 28px 24px;
    }
    
    .plan-tagline {
        min-height: auto;
    }
    
    .price {
        font-size: 36px;
    }
    
    .enterprise-content {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }
    
    .enterprise-bar {
        padding: 24px 20px;
    }
    
    .enterprise-bar .plan-cta {
        width: 100%;
    }
    
    .billing-toggle {
        width: 100%;
        max-width: 280px;
    }
    
    .toggle-btn {
        flex: 1;
    }
}

/* ========== MODAL ========== */
.modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.85);
    backdrop-filter: blur(4px);
    z-index: 1000;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.modal-overlay.active {
    display: flex;
}

.modal-content {
    background: #111111;
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 32px;
    max-width: 400px;
    width: 100%;
    position: relative;
}

.modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 24px;
    cursor: pointer;
    transition: color 0.15s;
    line-height: 1;
}

.modal-close:hover {
    color: var(--text-primary);
}

.modal-header {
    text-align: center;
    margin-bottom: 24px;
}

.modal-header h3 {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 4px 0;
}

.modal-header p {
    color: var(--text-muted);
    font-size: 14px;
    margin: 0;
}

.control-group {
    margin-bottom: 20px;
}

.label-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    font-size: 14px;
    color: var(--text-secondary);
}

.value-badge {
    background: rgba(99,102,241,0.15);
    color: var(--accent);
    padding: 3px 10px;
    border-radius: 100px;
    font-weight: 600;
    font-size: 13px;
}

.fuda-range {
    width: 100%;
    height: 4px;
    -webkit-appearance: none;
    appearance: none;
    background: rgba(255,255,255,0.1);
    border-radius: 4px;
    outline: none;
}

.fuda-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    background: var(--accent);
    border-radius: 50%;
    cursor: pointer;
}

.fuda-range::-moz-range-thumb {
    width: 16px;
    height: 16px;
    background: var(--accent);
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

.bill-summary {
    background: rgba(255,255,255,0.02);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 20px;
}

.bill-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    color: var(--text-muted);
    font-size: 13px;
}

.bill-total {
    display: flex;
    justify-content: space-between;
    padding-top: 10px;
    border-top: 1px solid var(--border);
    font-weight: 600;
    font-size: 15px;
    color: var(--text-primary);
}

.btn-primary {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 44px;
    background: var(--text-primary);
    color: #000;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.15s;
}

.btn-primary:hover {
    background: rgba(255,255,255,0.9);
}

.full-width {
    width: 100%;
}
