/* pricing.css
   Pricing cards and billing toggle.
   Loaded on: pricing. */

/* ===== PRICING ===== */
.pricing-section {
    padding: 100px 0;
}

.billing-toggle {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-bottom: 60px;
    flex-wrap: wrap;
}

.toggle-label {
    color: var(--text-secondary);
    font-weight: 600;
    font-size: clamp(0.9rem, 1.5vw, 1rem);
}

.toggle-switch {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 30px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #334155;
    transition: background-color 0.4s;
    border-radius: 34px;
}

.toggle-slider::before {
    position: absolute;
    content: "";
    height: 22px;
    width: 22px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: transform 0.4s;
    border-radius: 50%;
}

input:checked + .toggle-slider {
    background-color: var(--primary);
}

input:checked + .toggle-slider::before {
    transform: translateX(30px);
}

.savings-badge {
    background: var(--secondary);
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
    gap: clamp(25px, 3vw, 40px);
    margin-bottom: 80px;
}

.pricing-card {
    border-radius: 20px;
    padding: clamp(30px, 4vw, 50px) clamp(25px, 3vw, 40px);
    transition-duration: 0.4s;
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.pricing-card.featured {
    border-color: var(--primary);
    transform: scale(1.05);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.pricing-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-card-hover);
}

.pricing-card.featured:hover {
    transform: scale(1.05) translateY(-10px);
}

.plan-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary);
    color: white;
    padding: 8px 20px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 700;
}

.plan-header {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 25px;
    border-bottom: 1px solid var(--border);
}

.plan-name {
    margin-top: 0;
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 800;
    margin-bottom: 15px;
    color: var(--text-primary);
}

.pricing-row {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
    margin-left: 0;
}

.plan-price-free {
    font-size: clamp(2rem, 5vw, 2.1rem);
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 10px;
}

.plan-price {
    display: flex;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 10px;
    position: relative;
    align-items: flex-start;
}

.amount {
    font-size: clamp(2rem, 5vw, 3.2rem);
    position: relative;
}

.currency {
    font-size: clamp(0.8rem, 1.5vw, 1.5rem);
    margin-right: 2px;
    margin-top: 0.2em;
}

.cents {
    font-size: clamp(0.8rem, 1.5vw, 1.5rem);
    margin-top: 0.2em;
}

.price-period {
    color: var(--text-secondary);
    font-size: 1rem;
}

.plan-description {
    color: var(--text-secondary);
    font-size: clamp(0.9rem, 1.5vw, 1rem);
    line-height: 1.6;
}

.plan-features {
    flex-grow: 1;
    margin: 30px 0;
}

/* Plan feature list: feature name with a short description beneath */
.plan-features .feature-list {
    margin: 0;
    padding-left: 0;
}

.plan-features .feature-list li {
    margin-bottom: 16px;
    line-height: 1.45;
}

.plan-features .feature-list li:last-child {
    margin-bottom: 0;
}

.plan-features .feature-list i {
    margin-top: 3px;
}

.feature-name {
    display: block;
    font-weight: 600;
    color: var(--text-primary);
}

.feature-desc {
    display: block;
    margin-top: 2px;
    font-size: 0.875rem;
    color: var(--text-muted);
}

.plan-actions {
    text-align: center;
    margin-top: auto;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .pricing-card.featured {
        transform: scale(1);
    }

    .pricing-card.featured:hover {
        transform: translateY(-10px);
    }
}

@media (max-width: 480px) {
    .pricing-row {
        gap: 12px;
    }

    .amount {
        font-size: 1.8rem;
    }
}
