:root {
    --primary: #f59e0b;
    --primary-gradient: linear-gradient(135deg, #f59e0b 0%, #ea580c 100%);
    --bg-gradient: radial-gradient(circle at top center, #1e293b 0%, #0f172a 100%);
    --surface: rgba(30, 41, 59, 0.7);
    --surface-hover: rgba(30, 41, 59, 0.9);
    --text: #f8fafc;
    --text-secondary: #94a3b8;
    --border: rgba(255, 255, 255, 0.1);
    --glass: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);
    --shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.36);
}

body {
    font-family: 'Inter', sans-serif;
    background: var(--bg-gradient);
    color: var(--text);
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    overflow-x: hidden;
}

.container {
    background: var(--glass);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    padding: 60px 40px;
    border-radius: 24px;
    box-shadow: var(--shadow);
    max-width: 1400px;
    /* Increased to fit 4 plans */
    width: 95%;
    text-align: center;
    position: relative;
    overflow: hidden;
}

/* Background decoration */
.container::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 50% 50%, rgba(245, 158, 11, 0.08) 0%, transparent 50%);
    z-index: -1;
    animation: rotate 20s linear infinite;
}

@keyframes rotate {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

h1 {
    margin-bottom: 16px;
    font-size: 3rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    background: var(--primary-gradient);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 2px 10px rgba(245, 158, 11, 0.3));
}

p.subtitle {
    color: var(--text-secondary);
    margin-bottom: 50px;
    font-size: 1.2rem;
    font-weight: 400;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Toggle Switch */
.toggle-container {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 50px;
    gap: 20px;
    background: rgba(0, 0, 0, 0.2);
    padding: 10px 20px;
    border-radius: 50px;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
    border: 1px solid var(--border);
}

.toggle-label {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text);
    cursor: pointer;
    transition: color 0.3s;
}

.toggle-label.active {
    color: var(--primary);
}

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

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

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #334155;
    transition: .4s;
    border-radius: 34px;
    border: 1px solid var(--border);
}

.slider:before {
    position: absolute;
    content: "";
    height: 22px;
    width: 22px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

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

input:checked+.slider:before {
    transform: translateX(26px);
}

.discount-badge {
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
    font-size: 0.75rem;
    padding: 4px 10px;
    border-radius: 12px;
    font-weight: 700;
    letter-spacing: 0.02em;
    border: 1px solid rgba(16, 185, 129, 0.3);
    margin-left: 8px;
}

/* Plans Grid */
.plans {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    /* Adjusted for 4 plans */
    gap: 20px;
    /* Reduced gap slightly */
    align-items: stretch;
}

.plan-card {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 40px 30px;
    display: flex;
    flex-direction: column;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
}

.plan-card:hover {
    transform: translateY(-10px);
    background: var(--surface-hover);
    border-color: rgba(245, 158, 11, 0.3);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.plan-card h3 {
    font-size: 1.5rem;
    margin: 0 0 10px 0;
    color: var(--text);
}

.price,
.price-yearly {
    font-size: 3.5rem;
    font-weight: 800;
    margin: 20px 0;
    color: var(--text);
    letter-spacing: -0.02em;
}

.price span,
.price-yearly span {
    font-size: 1.1rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.original-price {
    text-decoration: line-through;
    color: var(--text-secondary);
    font-size: 1.5rem;
    margin-right: 10px;
    font-weight: 500;
}

/* Featured Card */
.plan-card.featured {
    background: linear-gradient(180deg, rgba(245, 158, 11, 0.1) 0%, rgba(30, 41, 59, 0.6) 100%);
    border: 1px solid rgba(245, 158, 11, 0.4);
    box-shadow: 0 0 30px rgba(245, 158, 11, 0.1);
    transform: scale(1.05);
    z-index: 1;
}

.plan-card.featured:hover {
    transform: scale(1.05) translateY(-10px);
    box-shadow: 0 20px 50px rgba(245, 158, 11, 0.2);
}

.badge {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary-gradient);
    color: white;
    padding: 8px 20px;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.4);
    text-transform: uppercase;
}

/* Features List */
ul {
    list-style: none;
    padding: 0;
    margin: 30px 0;
    text-align: left;
    flex-grow: 1;
}

li {
    margin-bottom: 16px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-size: 0.95rem;
    line-height: 1.5;
    color: var(--text-secondary);
}

li.check {
    color: var(--text);
}

li.check::before {
    content: '✓';
    color: var(--primary);
    font-weight: 900;
    background: rgba(245, 158, 11, 0.1);
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 0.8rem;
    flex-shrink: 0;
}

li.cross {
    opacity: 0.5;
    text-decoration: line-through;
}

li.cross::before {
    content: '✕';
    color: var(--text-secondary);
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* Feature Subtitles */
.feature-title {
    display: block;
    font-weight: 500;
}

.feature-sub {
    display: block;
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-top: 4px;
    font-weight: 400;
    opacity: 0.8;
}

li.highlight .feature-title {
    color: #fbbf24;
    font-weight: 700;
}

li.highlight::before {
    color: #fbbf24;
    background: rgba(251, 191, 36, 0.1);
    box-shadow: 0 0 10px rgba(251, 191, 36, 0.2);
}

/* Buttons */
.btn {
    width: 100%;
    padding: 16px;
    border-radius: 12px;
    border: none;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    letter-spacing: 0.02em;
}

.btn-primary {
    background: var(--primary-gradient);
    color: white;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(245, 158, 11, 0.5);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--border);
    color: var(--text-secondary);
}

.btn-outline:hover {
    border-color: var(--text);
    color: var(--text);
}

/* Status Message */
.status-msg {
    margin-top: 30px;
    padding: 15px;
    border-radius: 12px;
    font-weight: 500;
    display: none;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.status-msg.success {
    background: rgba(16, 185, 129, 0.1);
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.2);
}

.status-msg.error {
    background: rgba(239, 68, 68, 0.1);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.2);
}

/* Responsive */
@media (max-width: 1200px) {
    .plans {
        grid-template-columns: repeat(2, 1fr);
        /* 2x2 grid on medium screens */
    }
}

@media (max-width: 768px) {
    .plans {
        grid-template-columns: 1fr;
        /* Stack on mobile */
    }

    .plan-card.featured {
        transform: scale(1);
        order: -1;
    }

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

    h1 {
        font-size: 2.5rem;
    }

    .container {
        padding: 30px 20px;
    }
}