/* ── Reset & CSS Variables ── */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    /* Core Brand Colors */
    --brand-blue: #0028ab;
    --brand-cyan: #00d2ff;
    --brand-purple: #7000ff;

    /* Light Theme */
    --bg: #ffffff;
    --bg-secondary: #f4f7fb;
    --bg-tertiary: #e9eff6;
    --text-main: #0f172a;
    --text-muted: #475569;
    --card-bg: rgba(255, 255, 255, 0.7);
    --border-color: rgba(15, 23, 42, 0.08);
    --glass-border: rgba(255, 255, 255, 0.6);
    --nav-bg: rgba(255, 255, 255, 0.85);

    /* Action Colors */
    --p: #2e90f3;
    --p-hover: #1d72cf;
    --p-glow: rgba(46, 144, 243, 0.3);

    /* Shadows & Radii */
    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    --shadow-glass: 0 8px 32px 0 rgba(31, 38, 135, 0.07);

    --radius-md: 12px;
    --radius-lg: 24px;
    --radius-xl: 32px;
    --radius-pill: 9999px;

    /* Layout */
    --container-w: 1280px;
}

body.dark-mode {
    --bg: #030712;
    --bg-secondary: #0f172a;
    --bg-tertiary: #1e293b;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --card-bg: rgba(15, 23, 42, 0.7);
    --border-color: rgba(255, 255, 255, 0.1);
    --glass-border: rgba(255, 255, 255, 0.05);
    --nav-bg: rgba(3, 7, 18, 0.85);
    --shadow-glass: 0 8px 32px 0 rgba(0, 0, 0, 0.5);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg);
    color: var(--text-main);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -webkit-text-size-adjust: 100%;
    transition: background-color 0.4s ease, color 0.4s ease;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.03em;
}

a {
    text-decoration: none;
    color: inherit;
}

.container {
    width: 100%;
    max-width: var(--container-w);
    margin: 0 auto;
    padding: 0 1.25rem;
}

@media(min-width:768px) {
    .container { padding: 0 2rem; }
}

.section {
    padding: 4rem 0;
    position: relative;
}

@media(min-width:768px) {
    .section { padding: 6rem 0; }
}

@media(min-width:1024px) {
    .section { padding: 8rem 0; }
}

/* ── Dynamic Gradients & Glassmorphism ── */
.gradient-text {
    background: linear-gradient(135deg, var(--brand-blue), var(--brand-cyan));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
}

body.dark-mode .gradient-text {
    background: linear-gradient(135deg, #60a5fa, #38bdf8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.glass-panel {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-glass);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.4s ease, border-color 0.4s ease;
}

.glass-panel:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: var(--p);
}

/* ── Buttons ── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.75rem;
    border-radius: var(--radius-pill);
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 0.9375rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    outline: none;
    position: relative;
    overflow: hidden;
    min-height: 48px;
    -webkit-tap-highlight-color: transparent;
}

@media(min-width:768px) {
    .btn { padding: 1rem 2rem; font-size: 1rem; gap: 0.75rem; }
}

.btn-primary {
    background: linear-gradient(135deg, var(--p), var(--brand-blue), var(--brand-cyan), var(--p));
    background-size: 300% 100%;
    transition: all 0.4s ease;
    color: #ffffff;
    box-shadow: 0 10px 20px -5px var(--p-glow);
}

.btn-primary:hover {
    background-position: 100% 0;
    transform: translateY(-3px);
    box-shadow: 0 15px 30px -5px var(--p-glow);
    color: #ffffff;
}

.btn-secondary {
    background: transparent;
    color: var(--text-main);
    border: 2px solid var(--border-color);
}

.btn-secondary:hover {
    border-color: var(--p);
    color: var(--p);
    transform: translateY(-3px);
    background: var(--bg-secondary);
}

/* ── Navbar ── */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    transition: all 0.4s ease;
    padding: 1.5rem 0;
}

.nav.scrolled {
    padding: 0.75rem 0;
    background: var(--nav-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
}

.nav-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* iOS zoom prevention for form inputs */
input, button, textarea, select { font-size: 16px; }

.nav-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-family: 'Outfit', sans-serif;
    font-weight: 900;
    font-size: 1.5rem;
    letter-spacing: -0.02em;
    color: var(--text-main);
}

.brand-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--p), var(--brand-blue));
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    box-shadow: 0 4px 10px rgba(0, 40, 171, 0.3);
}

.nav-links {
    display: none;
    gap: 2.5rem;
    align-items: center;
}

@media (min-width: 1024px) {
    .nav-links {
        display: flex;
    }
}

.nav-link {
    font-weight: 500;
    font-size: 0.95rem;
    color: var(--text-muted);
    transition: color 0.3s;
    position: relative;
}

.nav-link:hover {
    color: var(--p);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--p);
    border-radius: 2px;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-link:hover::after {
    width: 100%;
}

.nav-actions {
    display: none;
    align-items: center;
    gap: 1.25rem;
}

@media (min-width: 1024px) {
    .nav-actions {
        display: flex;
    }
}

.theme-toggle {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid var(--border-color);
    background: var(--bg-secondary);
    color: var(--text-main);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
}

.theme-toggle:hover {
    background: var(--p);
    color: #fff;
    border-color: var(--p);
}

/* ── Mobile Menu ── */
.mobile-btn {
    display: block;
    background: none;
    border: none;
    color: var(--text-main);
    font-size: 1.5rem;
    cursor: pointer;
}

@media (min-width: 1024px) {
    .mobile-btn {
        display: none;
    }
}

/* ── Hero Section ── */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 6rem;
    position: relative;
    overflow: hidden;
}

/* Background Animated Glows */
.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.hero-glow-1 {
    position: absolute;
    top: -10%;
    left: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(46, 144, 243, 0.15) 0%, transparent 70%);
    filter: blur(60px);
    animation: float 10s ease-in-out infinite alternate;
}

.hero-glow-2 {
    position: absolute;
    bottom: -20%;
    right: -10%;
    width: 700px;
    height: 700px;
    background: radial-gradient(circle, rgba(0, 210, 255, 0.1) 0%, transparent 70%);
    filter: blur(80px);
    animation: float 12s ease-in-out infinite alternate-reverse;
}

body.dark-mode .hero-glow-1 {
    background: radial-gradient(circle, rgba(46, 144, 243, 0.25) 0%, transparent 70%);
}

body.dark-mode .hero-glow-2 {
    background: radial-gradient(circle, rgba(112, 0, 255, 0.2) 0%, transparent 70%);
}

@keyframes float {
    0% {
        transform: translate(0, 0) scale(1);
    }

    100% {
        transform: translate(50px, 50px) scale(1.1);
    }
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

@media (max-width: 1023px) {
    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
    }
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-pill);
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--p);
    margin-bottom: 2rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.hero-title {
    font-size: clamp(3rem, 5vw, 4.5rem);
    margin-bottom: 1.5rem;
    color: var(--text-main);
}

.hero-desc {
    font-size: 1.25rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 2.5rem;
    max-width: 600px;
}

@media (max-width: 1023px) {
    .hero-desc {
        margin-left: auto;
        margin-right: auto;
    }
}

.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

@media (max-width: 1023px) {
    .hero-actions {
        justify-content: center;
    }
}



/* Hero Graphic (Dashboard Mockup) */
.mockup-container {
    position: relative;
    z-index: 10;
    perspective: 1000px;
}

.mockup-window {
    background: var(--card-bg);
    border-radius: 20px;
    border: 1px solid var(--glass-border);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    overflow: hidden;
    transform: rotateY(-10deg) rotateX(5deg);
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.mockup-container:hover .mockup-window {
    transform: rotateY(0) rotateX(0);
}

.mockup-header {
    background: rgba(0, 0, 0, 0.03);
    padding: 1rem;
    display: flex;
    gap: 0.5rem;
    border-bottom: 1px solid var(--border-color);
}

body.dark-mode .mockup-header {
    background: rgba(255, 255, 255, 0.03);
}

.m-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.m-dot.r {
    background: #ff5f56;
}

.m-dot.y {
    background: #ffbd2e;
}

.m-dot.g {
    background: #27c93f;
}

.mockup-body {
    padding: 2rem;
    height: 400px;
    display: grid;
    grid-template-columns: 80px 1fr;
    gap: 2rem;
}

.m-skeleton {
    background: var(--bg-tertiary);
    border-radius: 8px;
    animation: pulse 2s infinite ease-in-out;
}

.m-chart {
    background: linear-gradient(180deg, rgba(46, 144, 243, 0.1), transparent);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    height: 180px;
    margin-top: 1.5rem;
    position: relative;
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

/* ── Stats Strip ── */
.stats-strip {
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    background: var(--bg-secondary);
    padding: 3rem 0;
}

.stats-grid {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
    gap: 2rem;
}

.stat-item {
    text-align: center;
}

.stat-num {
    font-size: 2.5rem;
    font-weight: 900;
    font-family: 'Outfit', sans-serif;
    color: var(--text-main);
    margin-bottom: 0.25rem;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* ── Features Section ── */
.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 4rem;
}

.section-tag {
    color: var(--p);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 0.85rem;
    margin-bottom: 1rem;
    display: block;
}

.section-title {
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 1.25rem;
}

.section-desc {
    font-size: 1.125rem;
    color: var(--text-muted);
    line-height: 1.7;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}

.feature-icon-wrapper {
    width: 64px;
    height: 64px;
    background: var(--bg-secondary);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    color: var(--p);
    border: 1px solid var(--border-color);
    transition: all 0.3s;
}

.glass-panel:hover .feature-icon-wrapper {
    background: var(--p);
    color: #fff;
    transform: scale(1.1) rotate(5deg);
}

.feature-title {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
}

.feature-desc {
    color: var(--text-muted);
    line-height: 1.6;
    font-size: 0.95rem;
}

/* ── Pricing Section ── */
.billing-toggle {
    display: inline-flex;
    background: var(--bg-secondary);
    padding: 0.5rem;
    border-radius: var(--radius-pill);
    border: 1px solid var(--border-color);
    margin: 0 auto 3rem;
}

.billing-btn {
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-pill);
    border: none;
    background: transparent;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.3s;
}

.billing-btn.active {
    background: var(--bg);
    color: var(--text-main);
    box-shadow: var(--shadow-sm);
}

.save-badge {
    background: rgba(34, 197, 94, 0.1);
    color: #22c55e;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-size: 0.7rem;
    margin-left: 0.5rem;
    font-weight: 800;
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.price-card {
    padding: 3rem 2rem;
    display: flex;
    flex-direction: column;
    position: relative;
}

.price-card.popular {
    border: 2px solid var(--p);
    transform: scale(1.02);
}

.price-card.popular:hover {
    transform: scale(1.02) translateY(-8px);
}

@media (max-width: 1023px) {
    .price-card.popular {
        transform: none;
    }

    .price-card.popular:hover {
        transform: translateY(-8px);
    }
}

.popular-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 5px;
    transform: translateX(-50%);
    background: var(--p);
    color: #fff;
    padding: 0.25rem 1rem;
    border-radius: var(--radius-pill);
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    box-shadow: 0 4px 10px var(--p-glow);
}

.plan-name {
    font-size: 1.125rem;
    font-weight: 800;
    margin-bottom: 1rem;
    color: var(--text-main);
}

.plan-price-wrap {
    margin-bottom: 0.5rem;
    display: flex;
    align-items: flex-end;
    gap: 0.25rem;
}

.plan-price {
    font-size: 3.5rem;
    font-weight: 900;
    font-family: 'Outfit', sans-serif;
    color: var(--text-main);
    line-height: 1;
}

.plan-mo {
    color: var(--text-muted);
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.plan-desc {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.plan-features {
    list-style: none;
    margin-bottom: 3rem;
    flex: 1;
}

.plan-features li {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 1rem;
    font-size: 0.95rem;
    color: var(--text-main);
    font-weight: 500;
}

.plan-features i {
    color: var(--p);
    margin-top: 2px;
}

/* ── FAQ Section ── */
.faq-wrapper {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    margin-bottom: 1rem;
    background: var(--bg);
    overflow: hidden;
    transition: all 0.3s;
}

.faq-item.active {
    border-color: var(--p);
    box-shadow: var(--shadow-sm);
}

.faq-question {
    width: 100%;
    padding: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: none;
    border: none;
    font-family: 'Outfit', sans-serif;
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--text-main);
    text-align: left;
    cursor: pointer;
}

.faq-icon {
    transition: transform 0.3s;
    color: var(--p);
}

.faq-item.active .faq-icon {
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    opacity: 0;
    padding: 0 1.5rem;
    color: var(--text-muted);
    line-height: 1.7;
    transition: all 0.3s ease;
}

.faq-item.active .faq-answer {
    max-height: 300px;
    opacity: 1;
    padding-bottom: 1.5rem;
}

/* ── CTA Section ── */
.cta-section {
    padding: 6rem 0;
}

.cta-box {
    background: linear-gradient(135deg, var(--brand-blue), var(--p));
    border-radius: var(--radius-xl);
    padding: 5rem 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
    color: #fff;
    box-shadow: 0 25px 50px -12px rgba(0, 40, 171, 0.5);
}

.cta-box::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 60%);
    animation: rotate 20s linear infinite;
}

@keyframes rotate {
    100% {
        transform: rotate(360deg);
    }
}

.cta-content {
    position: relative;
    z-index: 10;
}

.cta-title {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    margin-bottom: 1.5rem;
    color: #fff;
}

.cta-desc {
    font-size: 1.25rem;
    opacity: 0.9;
    margin-bottom: 3rem;
    max-width: 600px;
    margin-inline: auto;
}

/* ── Footer ── */
.footer {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    padding: 3rem 0 2rem;
}

@media(min-width:768px) {
    .footer { padding: 5rem 0 2rem; }
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 4rem;
    margin-bottom: 4rem;
}

@media (max-width: 1023px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 600px) {
    .footer-grid {
        grid-template-columns: 1fr;
    }
}

.footer-title {
    font-size: 0.85rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-main);
    margin-bottom: 1.5rem;
}

.footer-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-links a {
    color: var(--text-muted);
    font-size: 0.95rem;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: var(--p);
}

.footer-bottom {
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: center;
    flex-direction: column;
    text-align: center;
    align-items: center;
    gap: 1rem;
    color: var(--text-muted);
    font-size: 0.875rem;
}

/* Fade Up Animation */
.fade-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.fade-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ── Theme Toggle (Subpages) ── */
.theme-toggle {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid var(--border-color);
    background: var(--bg);
    color: var(--text-main);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
    -webkit-tap-highlight-color: transparent;
}

.theme-toggle:hover {
    border-color: var(--p);
    color: var(--p);
}

body.dark-mode .theme-toggle {
    background: var(--bg-tertiary);
    border-color: rgba(255,255,255,0.1);
    color: #fff;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

/* ── Hero Title Responsive ── */
.hero-title {
    font-size: clamp(1.75rem, 5vw, 3.5rem);
}

.hero-desc {
    font-size: clamp(0.9375rem, 2.5vw, 1.25rem);
}

/* ── Legal Content Mobile ── */
@media(max-width:767px) {
    .glass-panel.legal-content {
        padding: 1.5rem !important;
    }
    .legal-content h2 {
        font-size: 1.25rem !important;
    }
}

/* ── Subpage Nav Brand Mobile ── */
@media(max-width:480px) {
    .nav-brand { font-size: 1.1rem; gap: 0.5rem; }
    .brand-icon { width: 34px; height: 34px; }
}