:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --accent: #8b5cf6;
    --success: #10b981;
    --bg: #f8fafc;
    --glass: rgba(255, 255, 255, 0.8);
    --border: rgba(226, 232, 240, 0.8);
    --text: #1e293b;
    --text-light: #64748b;
    --warning-bg: #fffbed;
    --warning-border: #f59e0b;
    --warning-text: #b45309;
    --shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.05), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

body {
    background-color: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
}

.header-gradient {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 400px;
    background: linear-gradient(135deg, #eff6ff 0%, #ffffff 100%);
    z-index: -1;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

header {
    text-align: center;
    margin-bottom: 3rem;
}

.badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: #dbeafe;
    color: var(--primary);
    border-radius: 99px;
    font-size: 0.8rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

h1 {
    font-size: 2.5rem;
    font-weight: 800;
    color: #0f172a;
    letter-spacing: -0.025em;
    margin-bottom: 1rem;
}

.text-gradient {
    background: linear-gradient(135deg, var(--primary), var(--accent));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

header p {
    color: var(--text-light);
    font-size: 1.1rem;
}

/* Layout */
.grid-layout {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 2rem;
}

@media (max-width: 900px) {
    .grid-layout {
        grid-template-columns: 1fr;
    }
}

.panel {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.glass {
    background: var(--glass);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 2rem;
    box-shadow: var(--shadow);
}

/* Forms */
.section-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.input-wrapper,
.select-wrapper {
    margin-bottom: 1.5rem;
}

label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #475569;
}

input[type="number"],
select {
    width: 100%;
    padding: 0.75rem 1rem;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    font-size: 1rem;
    font-weight: 500;
    color: var(--text);
    outline: none;
    transition: all 0.2s;
}

input:focus,
select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.muted-text {
    font-size: 0.8rem;
    color: var(--text-light);
    display: block;
    margin-top: 0.25rem;
}

.slider-row {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}

.flex-1 {
    flex: 1;
}

.flex-2 {
    flex: 2;
}

@media (max-width: 600px) {
    .slider-row {
        flex-direction: column;
        gap: 0;
    }
}

.divider {
    height: 1px;
    background: #e2e8f0;
    margin: 0.5rem 0;
}

/* Radio Cards */
.radio-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.radio-card {
    position: relative;
    cursor: pointer;
}

.radio-card input {
    position: absolute;
    opacity: 0;
}

.radio-card span {
    display: block;
    padding: 0.75rem;
    text-align: center;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.2s;
}

.radio-card input:checked+span {
    border-color: var(--primary);
    background: #eff6ff;
    color: var(--primary);
}

/* Sliders */
.slider-container {
    margin-bottom: 1.5rem;
}

.slider-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.value-badge {
    background: #f1f5f9;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--primary);
}

input[type="range"] {
    width: 100%;
    height: 6px;
    background: #e2e8f0;
    border-radius: 5px;
    appearance: none;
    outline: none;
}

input[type="range"]::-webkit-slider-thumb {
    appearance: none;
    width: 20px;
    height: 20px;
    background: var(--primary);
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

/* Results */
.main-result {
    text-align: center;
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    color: white;
    border: none;
}

.main-result h3 {
    font-size: 1rem;
    font-weight: 500;
    color: #94a3b8;
    margin-bottom: 0.5rem;
}

.result-value {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
}

.result-sub {
    font-size: 1.1rem;
    color: #94a3b8;
}

.breakdown-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.card h4 {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-bottom: 0.5rem;
}

.card-val {
    font-size: 1.5rem;
    font-weight: 700;
}

.card-pct {
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.2rem 0.5rem;
    border-radius: 6px;
    background: #f1f5f9;
    color: var(--text-light);
}

.chart-container {
    padding: 1.5rem;
    position: relative;
    height: 350px;
}

/* Advanced Settings Toggle & Box */
.btn-secondary {
    background: white;
    color: var(--text);
    border: 1px solid #e2e8f0;
    padding: 0.75rem 1rem;
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
    justify-content: center;
}

.btn-secondary:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
}

.advanced-settings {
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 16px;
    border: 1px dashed #cbd5e1;
}

.mt-2 {
    margin-top: 1rem;
}

/* Smart Alerts */
.alert-box {
    background-color: var(--warning-bg);
    border-left: 4px solid var(--warning-border);
    padding: 1rem 1.5rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    animation: fadeIn 0.3s ease-in-out;
}

.alert-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.25rem;
}

.alert-icon {
    font-size: 1.2rem;
}

.alert-box h4 {
    color: var(--warning-text);
    font-size: 1rem;
    font-weight: 700;
}

.alert-box p {
    color: #78350f;
    font-size: 0.9rem;
    line-height: 1.5;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Lead Capture */
.lead-box {
    border: 2px solid var(--primary);
    background: white;
}

.lead-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
    color: var(--primary);
}

.lead-header h4 {
    font-size: 1.1rem;
    font-weight: 700;
}

.lead-box p {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

#lead-email {
    margin-bottom: 1rem;
}

.consent {
    display: flex;
    gap: 0.5rem;
    align-items: flex-start;
    margin-bottom: 1rem;
    cursor: pointer;
}

.consent input {
    margin-top: 0.25rem;
}

.consent span {
    font-size: 0.8rem;
    color: var(--text-light);
}

.btn-primary {
    width: 100%;
    padding: 1rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 12px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.2);
}

footer {
    text-align: center;
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid #e2e8f0;
    color: var(--text-light);
    font-size: 0.9rem;
}

.footer-links {
    margin-bottom: 1rem;
    display: flex;
    justify-content: center;
    gap: 1.5rem;
}

.footer-links a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
}

/* SEO Content */
.seo-content {
    margin-top: 4rem;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(10px);
    border-radius: 24px;
    border: 1px solid var(--border);
}

.seo-content h2 {
    font-size: 1.8rem;
    color: #0f172a;
    margin-bottom: 1rem;
    text-align: center;
}

.seo-content>p {
    color: var(--text-light);
    font-size: 1.05rem;
    text-align: center;
    max-width: 800px;
    margin: 0 auto 2rem auto;
}

.seo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.seo-article {
    background: white;
    padding: 1.5rem;
    border-radius: 16px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    border: 1px solid #e2e8f0;
}

.seo-article h3 {
    font-size: 1.2rem;
    color: var(--primary-dark);
    margin-bottom: 0.75rem;
}

.seo-article p {
    font-size: 0.95rem;
    color: #334155;
    margin-bottom: 0.75rem;
}

.seo-article ul {
    margin-left: 1.5rem;
    margin-bottom: 0.75rem;
}

.seo-article li {
    font-size: 0.9rem;
    color: #475569;
    margin-bottom: 0.25rem;
}