:root {
    --primary: #5266eb;
    --primary-hover: #3d52d5;
    --primary-light: #eef0fe;
    --text-primary: #1a1d29;
    --text-secondary: #6b7280;
    --text-tertiary: #9ca3af;
    --bg-primary: #fbfcfd;
    --bg-secondary: #f4f5f9;
    --surface: #ffffff;
    --border: #e5e7eb;
    --border-light: #f0f1f4;
    --success: #10b981;
    --error: #ef4444;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    overflow-x: hidden;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    overflow-x: hidden;
}

main {
    flex: 1;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 2rem;
    box-sizing: border-box;
    width: 100%;
}

/* Navigation */
header {
    background-color: var(--surface);
    border-bottom: 1px solid var(--border-light);
    padding: 1.25rem 0;
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(8px);
    background-color: rgba(255, 255, 255, 0.95);
}

header .container {
    padding: 0 1rem;
    max-width: 100%;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
}

.nav-left {
    flex: 1 1 0;
    display: flex;
    justify-content: flex-start;
}

.nav-center {
    flex: 0 0 auto;
    display: flex;
    justify-content: center;
    gap: 2rem;
    align-items: center;
}

.nav-right {
    flex: 1 1 0;
    display: flex;
    gap: 1rem;
    align-items: center;
    justify-content: flex-end;
}

nav h1 {
    font-size: 1.5rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    color: var(--text-primary);
    line-height: 1;
}

nav h1 a {
    color: var(--text-primary);
    text-decoration: none;
    transition: color 0.2s ease;
    display: block;
}

nav h1 a:hover {
    color: var(--primary);
}

.nav-logo {
    height: 32px;
    width: auto;
    display: block;
    transition: opacity 0.2s ease;
}

.nav-logo:hover {
    opacity: 0.8;
}

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

nav a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9375rem;
    transition: color 0.2s ease;
    position: relative;
}

nav a:hover {
    color: var(--text-primary);
}

.nav-link-plain {
    color: var(--text-secondary) !important;
    font-weight: 500;
}

.nav-link-plain:hover {
    color: var(--text-primary) !important;
}

.nav-disabled,
.nav-disabled a {
    opacity: 0.4;
    cursor: not-allowed !important;
    pointer-events: none;
}

.nav-cta {
    background: var(--primary);
    color: white !important;
    padding: 0.625rem 1.25rem;
    border-radius: 1.5rem;
    font-weight: 600;
    transition: all 0.2s ease;
}

.nav-cta:hover {
    background: var(--primary-hover);
    color: white !important;
    transform: translateY(-1px);
}

/* Mega Menu */
.nav-item-dropdown {
    position: relative;
}

.nav-link-dropdown {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    cursor: pointer;
}

.nav-link-dropdown svg {
    transition: transform 0.2s ease;
}

.nav-item-dropdown:hover .nav-link-dropdown svg {
    transform: rotate(180deg);
}

.mega-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    margin-top: 1.25rem;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease, margin-top 0.2s ease;
    z-index: 100;
}

.nav-item-dropdown:hover .mega-menu {
    opacity: 1;
    visibility: visible;
    margin-top: 0.75rem;
}

.mega-menu-content {
    background: var(--surface);
    border: 1px solid var(--border-light);
    border-radius: 0.75rem;
    box-shadow: var(--shadow-xl);
    padding: 2rem;
    display: grid;
    grid-template-columns: repeat(3, minmax(180px, 1fr));
    gap: 2rem;
    min-width: 600px;
}

.mega-column h4 {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-tertiary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 1rem;
}

.mega-column a {
    display: block;
    padding: 0.5rem 0;
    color: var(--text-primary);
    font-size: 0.9375rem;
    font-weight: 500;
}

.mega-column a:hover {
    color: var(--primary);
}

.mega-link-arrow {
    color: var(--primary) !important;
    font-weight: 600 !important;
    margin-top: 0.5rem;
    padding-top: 0.75rem !important;
    border-top: 1px solid var(--border-light);
}

.mega-link-arrow:hover {
    color: var(--primary-hover) !important;
}

/* Hero Section */
.hero {
    background: var(--surface);
    padding: 5rem 0 4rem;
    margin: 3rem 0;
    text-align: center;
    border-radius: 1rem;
    border: 1px solid var(--border-light);
}

.hero h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 600;
    margin-bottom: 1.5rem;
    letter-spacing: -0.03em;
    color: var(--text-primary);
    line-height: 1.1;
}

.hero p {
    font-size: clamp(1.125rem, 2vw, 1.375rem);
    margin-bottom: 2.5rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.5;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.875rem 1.75rem;
    background-color: var(--primary);
    color: white;
    text-decoration: none;
    border-radius: 0.5rem;
    font-weight: 600;
    font-size: 0.9375rem;
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
    font-family: inherit;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn:hover {
    background-color: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn:active {
    transform: translateY(0);
}

/* Cards */
.metric-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    margin: 3rem 0;
}

.metric-card {
    background: var(--surface);
    padding: 2rem;
    border-radius: 0.75rem;
    border: 1px solid var(--border-light);
    transition: all 0.2s ease;
}

.metric-card:hover {
    border-color: var(--border);
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
}

.metric-card h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
    letter-spacing: -0.01em;
}

.metric-card p {
    color: var(--text-secondary);
    font-size: 0.9375rem;
    line-height: 1.6;
    margin-bottom: 1.25rem;
}

.metric-card a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9375rem;
    display: inline-flex;
    align-items: center;
    transition: color 0.2s ease;
}

.metric-card a:hover {
    color: var(--primary-hover);
}

.metric-label {
    font-size: 0.8125rem;
    color: var(--text-tertiary);
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
}

.metric-value {
    font-size: 2rem;
    font-weight: 600;
    color: var(--text-primary);
    letter-spacing: -0.02em;
}

.metric-value.positive {
    color: var(--success);
}

.metric-value.negative {
    color: var(--error);
}

/* Chart Container */
.chart-container {
    background: var(--surface);
    padding: 2.5rem;
    border-radius: 0.75rem;
    border: 1px solid var(--border-light);
    margin: 2rem 0;
}

.chart-container h2 {
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 600;
    letter-spacing: -0.02em;
}

canvas {
    max-height: 400px;
}

/* Tables */
table {
    width: 100%;
    background: var(--surface);
    border-radius: 0.75rem;
    overflow: hidden;
    border: 1px solid var(--border-light);
    margin: 2rem 0;
}

th, td {
    padding: 1rem 1.25rem;
    text-align: left;
    border-bottom: 1px solid var(--border-light);
}

th {
    background-color: var(--bg-secondary);
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

td {
    color: var(--text-secondary);
    font-size: 0.9375rem;
}

tr:last-child td {
    border-bottom: none;
}

tr:hover td {
    background-color: var(--bg-primary);
}

/* Form Elements */
select {
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 1.25rem;
    padding-right: 2.5rem;
}

select,
input[type="text"],
input[type="number"],
input[type="date"],
input[type="email"],
input[type="password"],
.form-control {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    font-size: 0.9375rem;
    color: var(--text-primary);
    background-color: var(--surface);
    transition: all 0.2s ease;
    font-family: inherit;
}

select:hover,
input[type="text"]:hover,
input[type="number"]:hover,
input[type="date"]:hover,
input[type="email"]:hover,
input[type="password"]:hover,
.form-control:hover {
    border-color: var(--text-secondary);
}

select:focus,
input[type="text"]:focus,
input[type="number"]:focus,
input[type="date"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
.form-control:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-light);
}

/* Form Groups */
.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
}

optgroup {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.875rem;
    padding: 0.5rem 0;
}

option {
    padding: 0.5rem;
    color: var(--text-primary);
}

label {
    display: block;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    font-size: 0.9375rem;
}

/* Sections */
section {
    background: var(--surface);
    padding: 3rem;
    border-radius: 0.75rem;
    margin: 2rem 0;
    border: 1px solid var(--border-light);
}

section h2 {
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    font-size: 1.875rem;
    font-weight: 600;
    letter-spacing: -0.02em;
}

section h3 {
    color: var(--text-primary);
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    letter-spacing: -0.01em;
}

section p {
    color: var(--text-secondary);
    line-height: 1.7;
}

/* Footer */
footer {
    background-color: var(--text-primary);
    color: var(--bg-secondary);
    text-align: center;
    padding: 3rem 0;
    margin-top: 6rem;
    border-top: 1px solid var(--border);
}

footer p {
    color: var(--text-tertiary);
    font-size: 0.9375rem;
}

footer .footer-meta {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
}

footer .footer-creator {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-tertiary);
    font-size: 0.9375rem;
    text-decoration: none;
    transition: color 0.2s ease-in-out;
}

footer .footer-creator:hover,
footer .footer-creator:focus {
    color: var(--bg-secondary);
}

footer .footer-creator-logo {
    height: 16px;
    width: auto;
}

@media (min-width: 768px) {
    footer .footer-meta {
        flex-direction: row;
        justify-content: space-between;
    }
}

/* Main Hero Section */
.hero-main {
    background: var(--surface);
    padding: 6rem 0 5rem;
    margin: 3rem 0;
    border-radius: 1rem;
    border: 1px solid var(--border-light);
    text-align: center;
}

.hero-content {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 2rem;
}

.hero-badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: var(--primary-light);
    color: var(--primary);
    border-radius: 2rem;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 2rem;
}

.hero-main h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
    letter-spacing: -0.03em;
    color: var(--text-primary);
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

.hero-main p {
    font-size: clamp(1.125rem, 2vw, 1.375rem);
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 2.5rem;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 4rem;
}

.email-signup-form {
    display: flex;
    gap: 0.75rem;
    max-width: 500px;
    margin: 0 auto;
}

.email-signup-form input[type="email"] {
    flex: 1;
    padding: 0.875rem 1.5rem;
    font-size: 1rem;
    border: 1px solid var(--border);
    border-radius: 1.5rem;
    background: var(--surface);
}

.email-signup-form input[type="email"]:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-light);
}

.email-signup-form .btn {
    white-space: nowrap;
    padding: 0.875rem 2rem;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 4rem;
    padding-top: 3rem;
    border-top: 1px solid var(--border-light);
}

.stat-item {
    text-align: center;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

/* Button Variants */
.btn-primary,
.btn-secondary {
    display: inline-block;
    padding: 0.875rem 1.75rem;
    text-decoration: none;
    border-radius: 0.5rem;
    font-weight: 600;
    font-size: 0.9375rem;
    transition: all 0.2s ease;
    cursor: pointer;
    font-family: inherit;
    border: none;
}

.btn-primary {
    background-color: var(--primary);
    color: white;
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(82, 102, 235, 0.3);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-secondary {
    background-color: transparent;
    color: var(--primary);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    background-color: var(--primary-light);
    border-color: var(--primary);
}

/* Button Sizes */
.btn-full {
    width: 100%;
    display: block;
    text-align: center;
}

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

.btn-outline:hover {
    background-color: var(--bg-secondary);
    border-color: var(--text-primary);
}

.btn-large {
    padding: 1.125rem 2.5rem;
    font-size: 1.0625rem;
}

/* Section Headers */
.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-header h2 {
    font-size: clamp(1.875rem, 4vw, 2.5rem);
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

.section-header p {
    font-size: 1.125rem;
    color: var(--text-secondary);
    max-width: 700px;
    margin: 0 auto;
}

/* Features Section */
.features-section {
    background: var(--bg-primary);
    padding: 5rem 0;
    margin: 0;
    border: none;
    border-radius: 0;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 2rem;
}

.feature-card {
    background: var(--surface);
    padding: 2.5rem;
    border-radius: 1rem;
    border: 1px solid var(--border-light);
    transition: all 0.3s ease;
}

.feature-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-xl);
    transform: translateY(-4px);
}

.feature-highlight {
    border-color: var(--primary);
    background: linear-gradient(to bottom, var(--surface), var(--primary-light));
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    display: block;
}

.feature-card h3 {
    font-size: 1.375rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.feature-card p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.7;
}

.feature-list {
    list-style: none;
    padding: 0;
}

.feature-list li {
    padding: 0.5rem 0;
    color: var(--text-secondary);
    font-size: 0.9375rem;
    padding-left: 1.5rem;
    position: relative;
}

.feature-list li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--success);
    font-weight: 700;
}

/* Dashboard Preview */
.dashboard-preview {
    background: var(--surface);
    padding: 5rem 2rem;
    margin: 0;
    border: none;
    border-radius: 0;
}

.preview-container {
    max-width: 1000px;
    margin: 0 auto;
}

.preview-mockup {
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: var(--shadow-xl);
}

.mockup-header {
    background: var(--surface);
    border-bottom: 1px solid var(--border-light);
    padding: 1.5rem 2rem;
}

.mockup-tabs {
    display: flex;
    gap: 2rem;
}

.mockup-tabs span {
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--text-secondary);
    padding-bottom: 0.5rem;
    cursor: pointer;
    transition: color 0.2s ease;
}

.mockup-tabs span:hover {
    color: var(--text-primary);
}

.mockup-tabs span.active {
    color: var(--primary);
    border-bottom: 2px solid var(--primary);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.mockup-content {
    padding: 2rem;
}

.mockup-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.mockup-card {
    background: var(--surface);
    padding: 1.5rem;
    border-radius: 0.75rem;
    border: 1px solid var(--border-light);
}

.mockup-label {
    font-size: 0.8125rem;
    color: var(--text-tertiary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.mockup-value {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.mockup-value.large {
    font-size: 2.25rem;
}

.mockup-change {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.mockup-change.positive {
    color: var(--success);
}

.mockup-progress {
    background: var(--bg-secondary);
    height: 8px;
    border-radius: 4px;
    margin: 1rem 0 0.75rem;
    overflow: hidden;
}

.progress-bar {
    background: linear-gradient(90deg, var(--primary), var(--success));
    height: 100%;
    border-radius: 4px;
}

.mockup-chart {
    background: var(--surface);
    padding: 2rem;
    border-radius: 0.75rem;
    border: 1px solid var(--border-light);
    margin-bottom: 1.5rem;
}

.chart-placeholder {
    height: 200px;
    position: relative;
    border-radius: 1rem;
    overflow: hidden;
}

.chart-svg {
    width: 100%;
    height: 100%;
}

.mockup-list {
    background: var(--surface);
    border-radius: 0.75rem;
    border: 1px solid var(--border-light);
    overflow: hidden;
}

.list-item {
    display: flex;
    justify-content: space-between;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border-light);
    font-size: 0.9375rem;
}

.list-item:last-child {
    border-bottom: none;
}

.list-item .positive {
    color: var(--success);
    font-weight: 600;
}

/* Goal Feature Section */
.goal-feature {
    background: var(--bg-primary);
    padding: 5rem 2rem;
    margin: 0;
    border: none;
    border-radius: 0;
}

.goal-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.feature-badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: var(--primary-light);
    color: var(--primary);
    border-radius: 2rem;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
}

.goal-text h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    letter-spacing: -0.02em;
}

.goal-text p {
    font-size: 1.125rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 2rem;
}

.goal-benefits {
    list-style: none;
    padding: 0;
}

.goal-benefits li {
    margin-bottom: 1.5rem;
}

.goal-benefits strong {
    display: block;
    font-size: 1.0625rem;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.goal-benefits span {
    font-size: 0.9375rem;
    color: var(--text-secondary);
}

.calculator-mockup {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: var(--shadow-xl);
}

.calc-header {
    background: var(--primary);
    color: white;
    padding: 1.25rem 1.5rem;
    font-weight: 600;
    font-size: 1.0625rem;
}

.calc-body {
    padding: 2rem 1.5rem;
}

.calc-input {
    margin-bottom: 1.5rem;
}

.calc-input label {
    display: block;
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.calc-input input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border);
    border-radius: 1rem;
    font-size: 1rem;
    color: var(--text-primary);
    background: var(--bg-primary);
    font-weight: 500;
}

.calc-result {
    background: var(--primary-light);
    padding: 1.5rem;
    border-radius: 0.75rem;
    margin-top: 2rem;
    text-align: center;
}

.result-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.result-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.result-date {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

/* How It Works */
.how-it-works {
    background: var(--surface);
    padding: 5rem 2rem;
    margin: 0;
    border: none;
    border-radius: 0;
}

/* Custom Index Feature */
.custom-index-feature {
    background: var(--bg-primary);
    padding: 5rem 2rem;
    margin: 0;
    border: none;
    border-radius: 0;
}

.custom-index-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.filter-mockup {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: var(--shadow-xl);
}

.filter-header {
    background: var(--bg-secondary);
    padding: 1.5rem;
    border-bottom: 1px solid var(--border-light);
}

.filter-body {
    padding: 1.5rem;
}

.filter-section {
    margin-bottom: 1.5rem;
}

.filter-section:last-child {
    margin-bottom: 0;
}

.filter-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
}

.filter-select {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: 1rem;
    cursor: default;
    pointer-events: none;
}

.filter-select span {
    font-weight: 500;
    color: var(--text-primary);
}

.filter-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.filter-chip {
    padding: 0.5rem 1rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 2rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
    cursor: default;
    pointer-events: none;
}

.filter-chip.active {
    background: var(--primary-light);
    border-color: var(--primary);
    color: var(--primary);
    font-weight: 600;
}

.filter-result {
    background: var(--bg-primary);
    padding: 1rem;
    border-radius: 1rem;
    border: 1px solid var(--border-light);
}

.result-preview {
    background: var(--surface);
    border-radius: 1rem;
    border: 1px solid var(--border-light);
    overflow: hidden;
}

.preview-item {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border-light);
    font-size: 0.875rem;
}

.preview-item:last-child {
    border-bottom: none;
}

.preview-item span:first-child {
    font-weight: 500;
    color: var(--text-primary);
}

.filter-action {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-light);
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 3rem;
    max-width: 1200px;
    margin: 0 auto;
}

.step-card {
    text-align: center;
}

.step-number {
    width: 4rem;
    height: 4rem;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 auto 1.5rem;
}

.step-card h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.step-card p {
    color: var(--text-secondary);
    line-height: 1.7;
}

/* Public Backtests */
.public-backtests {
    background: var(--surface);
    padding: 5rem 2rem;
    margin: 0;
    border: none;
    border-radius: 0;
}

.cta-center {
    text-align: center;
    margin-top: 3rem;
}

/* CTA Section */
.cta-section {
    background: linear-gradient(135deg, var(--primary) 0%, #3d52d5 100%);
    padding: 5rem 2rem;
    margin: 0;
    border: none;
    border-radius: 0;
    text-align: center;
}

.cta-content {
    max-width: 800px;
    margin: 0 auto;
}

.cta-content h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    color: white;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

.cta-content p {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 2.5rem;
}

.cta-actions {
    margin-bottom: 1.5rem;
}

.cta-section .btn-primary {
    background-color: white;
    color: var(--primary);
}

.cta-section .btn-primary:hover {
    background-color: var(--bg-primary);
    transform: translateY(-2px);
}

.cta-note {
    font-size: 0.9375rem;
    color: rgba(255, 255, 255, 0.8);
}

/* Responsive */
@media (max-width: 1024px) {
    .goal-content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .custom-index-content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .hero-stats {
        gap: 2rem;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 1rem;
    }

    section,
    .hero,
    .hero-main,
    .features-section,
    .dashboard-preview,
    .goal-feature,
    .how-it-works,
    .custom-index-feature,
    .public-backtests,
    .cta-section {
        border: none;
        border-radius: 0;
        margin: 0;
    }

    .chart-container,
    .metric-card,
    .feature-card {
        border: none;
    }

    .chart-container {
        padding: 1.5rem 1rem;
    }

    .feature-card {
        padding: 1.5rem 1rem;
    }

    h1, h2, h3, h4, h5, h6, p, a, span, div {
        word-wrap: break-word;
        overflow-wrap: break-word;
        hyphens: auto;
        max-width: 100%;
    }

    .section-header h2 {
        font-size: 1.5rem !important;
        line-height: 1.3;
    }

    .section-header p {
        font-size: 0.95rem !important;
    }

    .cta-content h2 {
        font-size: 1.5rem !important;
        line-height: 1.3;
    }

    .cta-content p {
        font-size: 1rem !important;
    }

    .goal-text h2 {
        font-size: 1.5rem !important;
        line-height: 1.3;
    }

    .btn-large {
        padding: 0.875rem 1.5rem;
        font-size: 0.9375rem;
    }

    main {
        max-width: 100vw;
        overflow-x: hidden;
    }

    .preview-container,
    .goal-content,
    .custom-index-content {
        max-width: 100%;
        padding: 0;
    }

    .nav-links {
        gap: 1rem;
    }

    nav a {
        font-size: 0.875rem;
    }

    .mega-menu {
        left: auto;
        right: 0;
        transform: none;
    }

    .mega-menu-content {
        grid-template-columns: 1fr;
        min-width: auto;
        max-width: calc(100vw - 2rem);
        padding: 1.5rem;
    }

    .nav-cta {
        display: none;
    }

    .nav-center {
        display: none;
    }

    nav {
        gap: 0.75rem;
    }

    header {
        padding: 1rem 0;
    }

    header .container {
        padding: 0 1rem;
    }

    .nav-right {
        gap: 0.5rem;
    }

    .nav-right a {
        font-size: 0.875rem;
        white-space: nowrap;
    }

    .nav-logo {
        height: 28px;
    }

    .hero {
        padding: 2rem 0 1.5rem;
        margin: 0;
    }

    .hero-main {
        padding: 2rem 0 1.5rem;
    }

    .hero-content {
        padding: 0 1rem;
        max-width: 100%;
        width: 100%;
    }

    .hero-main h1 {
        font-size: 1.75rem !important;
        line-height: 1.2;
        margin-bottom: 1rem;
    }

    .hero-main p {
        font-size: 1rem !important;
        line-height: 1.5;
        margin-bottom: 1.5rem;
    }

    .hero-badge {
        font-size: 0.75rem;
        padding: 0.4rem 0.8rem;
        margin-bottom: 1rem;
    }

    .hero-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .hero-stats {
        flex-direction: column;
        gap: 2rem;
    }

    .metric-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .metric-card {
        padding: 1.25rem 1rem;
    }

    .mockup-card {
        padding: 1rem;
    }

    .mockup-chart {
        padding: 1rem;
    }

    .mockup-content,
    .mockup-header,
    .preview-mockup {
        max-width: 100%;
        overflow: hidden;
    }

    .mockup-value {
        font-size: 1.25rem !important;
    }

    .mockup-value.large {
        font-size: 1.5rem !important;
    }

    .features-grid {
        grid-template-columns: 1fr;
        padding: 0 1rem;
    }

    .steps-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .mockup-row {
        grid-template-columns: 1fr;
    }

    section {
        padding: 2rem 1rem;
    }

    .dashboard-preview,
    .goal-feature,
    .how-it-works,
    .custom-index-feature,
    .public-backtests,
    .cta-section,
    .features-section {
        padding: 2rem 1rem;
    }
}

/* iPhone and small mobile screens */
@media (max-width: 480px) {
    body, html {
        max-width: 100vw;
        overflow-x: hidden !important;
    }

    .container {
        padding: 0 0.75rem !important;
        max-width: 100vw !important;
    }

    .hero-content {
        padding: 0 0.75rem !important;
        max-width: 100% !important;
        box-sizing: border-box;
    }

    .hero-main h1 {
        font-size: 1.5rem !important;
        line-height: 1.2 !important;
        word-break: break-word;
    }

    .hero-main p {
        font-size: 0.9rem !important;
    }

    section,
    .hero,
    .hero-main,
    .features-section,
    .dashboard-preview,
    .goal-feature,
    .how-it-works,
    .custom-index-feature,
    .public-backtests,
    .cta-section {
        padding: 1.5rem 0.75rem !important;
        margin: 0 !important;
        width: 100% !important;
        max-width: 100vw !important;
        box-sizing: border-box;
    }

    .btn-large {
        padding: 0.75rem 1rem !important;
        font-size: 0.875rem !important;
    }

    .nav-right a {
        font-size: 0.8125rem !important;
        padding: 0.5rem 0.75rem !important;
    }
}

/* ===================================
   AUTH PAGES (Login/Register)
   =================================== */

.auth-container {
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
}

.auth-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    padding: 40px;
    max-width: 450px;
    width: 100%;
}

.auth-title {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 8px 0;
}

.auth-subtitle {
    font-size: 15px;
    color: var(--text-secondary);
    margin: 0 0 32px 0;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-row {
    display: flex;
    gap: 16px;
}

.form-group-half {
    flex: 1;
}

.form-help {
    display: block;
    margin-top: 6px;
    font-size: 13px;
    color: var(--text-secondary);
}

.auth-link {
    text-align: center;
    margin-top: 16px;
    font-size: 14px;
    color: var(--text-secondary);
}

.auth-link a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

.auth-link a:hover {
    text-decoration: underline;
}

/* ===================================
   ALERTS
   =================================== */

.alert {
    padding: 16px;
    border-radius: 8px;
    margin-bottom: 24px;
    font-size: 14px;
}

.alert-success {
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #6ee7b7;
}

.alert-error {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fca5a5;
}

/* Auth page responsive */
@media (max-width: 640px) {
    .auth-card {
        padding: 32px 24px;
    }

    .form-row {
        flex-direction: column;
    }
}
