﻿/* =========================
   Global / Base Styles
   ========================= */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* Unified background and consistent gutter even when no scrollbar is visible */
:root {
    /* Use the exact gradient as the page background so html and body match */
    --page-bg: radial-gradient(circle at top left, #0f172a 0%, #020617 45%, #020617 100%);
}

html {
    color-scheme: dark;
    scrollbar-gutter: stable; /* keep layout stable */
    overflow-y: scroll; /* always reserve vertical scrollbar gutter for consistency */
    background: var(--page-bg);
    scrollbar-width: thin; /* Firefox: thin track */
    /* Firefox thumb/track colors: first is thumb, second is track */
    scrollbar-color: rgba(148, 163, 184, 0.25) rgba(2, 6, 23, 1); /* subtle thumb on dark track */
}

/* WebKit (Chromium, Safari, Edge) */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--page-bg);
}

::-webkit-scrollbar-thumb {
    background: rgba(148, 163, 184, 0.25);
    border-radius: 8px;
    border: 2px solid transparent;
}

    ::-webkit-scrollbar-thumb:hover {
        background: rgba(148, 163, 184, 0.35);
    }

body {
    margin: 0;
    min-height: 100vh;
    background: var(--page-bg); /* same as html to avoid color mismatch */
    overflow-x: hidden;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", sans-serif;
    line-height: 1.6;
    color: #e5e7eb;
}

/* Ensure main containers account for scrollbar gutter */
.main, .container, header, nav {
    box-sizing: border-box;
}

/* Accessible focus styles */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid #22c55e;
    outline-offset: 2px;
}

/* Disable focus outline on non-interactive headings (programmatic focus from FocusOnNavigate)
   so we don't show a focus ring around the hero title on initial load */
:where(h1, h2, h3, h4, h5, h6):focus {
    outline: none;
}

/* Keep interactive elements accessible (already defined above) */

/* Layout Helpers */
.container {
    width: 100%;
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.section {
    padding: 5.5rem 0;
}

.section-header {
    text-align: center;
    margin-bottom: 2.75rem;
}

.section-eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-size: 0.75rem;
    color: #38bdf8;
    margin-bottom: 0.5rem;
}

.section-title {
    font-size: 2rem;
    font-weight: 600;
    color: #f9fafb;
    margin-bottom: 0.5rem;
}

.section-subtitle {
    max-width: 640px;
    margin: 0.5rem auto 0;
    color: #cbd5f5;
    font-size: 0.95rem;
}

/* =========================
   Navbar
   ========================= */
.navbar {
    position: sticky;
    top: 0;
    z-index: 40;
    backdrop-filter: blur(14px);
    background: linear-gradient(to bottom, rgba(15, 23, 42, 0.95), rgba(15, 23, 42, 0.75));
    border-bottom: 1px solid rgba(148, 163, 184, 0.2);
}

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.85rem 1.5rem;
}

.nav-left {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo-mark {
    width: 32px;
    height: 32px;
    border-radius: 999px;
    background: conic-gradient(from 180deg, #22c55e, #0ea5e9, #6366f1, #22c55e);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 30px rgba(56, 189, 248, 0.6);
}

    .logo-mark span {
        font-size: 0.85rem;
        font-weight: 700;
        color: #0b1120;
    }

.logo-text-main {
    font-weight: 600;
    font-size: 1rem;
    color: #f9fafb;
}

.logo-text-sub {
    font-size: 0.7rem;
    color: #9ca3af;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

    .nav-links a {
        font-size: 0.9rem;
        color: #e5e7eb;
        text-decoration: none;
        opacity: 0.8;
        transition: opacity 0.15s ease, color 0.15s ease, background 0.15s ease;
        display: inline-block;
        padding: 0.25rem 0.5rem;
        border-radius: 8px;
    }

        .nav-links a:hover {
            opacity: 1;
            color: #f9fafb;
        }

.nav-cta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.btn-nav {
    padding: 0.4rem 0.9rem;
    border-radius: 999px;
    border: 1px solid rgba(148, 163, 184, 0.6);
    background: radial-gradient(circle at top left, rgba(148, 163, 184, 0.2), transparent);
    color: #e5e7eb;
    font-size: 0.8rem;
    text-decoration: none;
}

.btn-primary-small {
    padding: 0.42rem 0.95rem;
    border-radius: 999px;
    border: none;
    background: linear-gradient(135deg, #22c55e, #0ea5e9);
    color: #020617;
    font-weight: 600;
    font-size: 0.8rem;
    text-decoration: none;
    box-shadow: 0 16px 40px rgba(34, 197, 94, 0.25);
}

/* =========================
   Hamburger Menu (Mobile)
   ========================= */
.hamburger {
    display: none; /* Hidden by default on desktop */
    position: relative;
    width: 40px;
    height: 32px;
    border: 1px solid rgba(148,163,184,0.7);
    border-radius: 10px;
    background: radial-gradient(circle at top left, rgba(148,163,184,0.25), rgba(15,23,42,0.7));
    cursor: pointer;
    box-shadow: 0 8px 20px rgba(0,0,0,0.35);
    z-index: 60;
    flex-shrink: 0; /* prevent shrinking */
}

    .hamburger span {
        position: absolute;
        left: 9px;
        right: 9px;
        height: 2px;
        background: #f9fafb;
        border-radius: 2px;
        pointer-events: none;
    }

        .hamburger span:nth-child(1) {
            top: 9px;
        }

        .hamburger span:nth-child(2) {
            top: 15px;
        }

        .hamburger span:nth-child(3) {
            top: 21px;
        }

/* Mobile menu panel - hidden by default */
.mobile-menu {
    display: none;
    border-top: 1px solid rgba(148,163,184,0.25);
    background: linear-gradient(to bottom, rgba(15,23,42,0.97), rgba(15,23,42,0.94));
    backdrop-filter: blur(14px);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-in-out;
}

    /* When menu is open */
    .mobile-menu.mobile-menu-open {
        max-height: 500px;
    }

    .mobile-menu a {
        display: block;
        padding: 1rem;
        border-bottom: 1px solid rgba(148, 163, 184, 0.15);
        color: #e5e7eb;
        text-decoration: none;
        text-align: center;
        transition: background-color 0.2s ease-in-out;
    }

        .mobile-menu a:hover {
            background-color: rgba(148, 163, 184, 0.1);
        }

        .mobile-menu a:last-child {
            border-bottom: none;
        }

/* =========================
   Responsive Layout
   ========================= */

/* Tablet & Desktop: show nav links and CTAs, hide hamburger */
@media (min-width: 901px) {
    .hamburger {
        display: none !important;
    }

    .mobile-menu {
        display: none !important;
    }
}

/* Mobile: show hamburger, hide desktop nav */
@media (max-width: 900px) {
    .navbar {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
    }

    main {
        padding-top: 60px; /* reduced from 64px to minimize gap */
    }

    .nav-inner {
        padding: 0.75rem 1rem;
    }

    .nav-links {
        display: none !important;
    }

    .nav-cta {
        display: none !important;
    }

    .hamburger {
        display: inline-flex !important;
        align-items: center;
        justify-content: center;
    }

    /* Allow mobile menu to be displayed (but controlled by mobile-menu-open class) */
    .mobile-menu {
        display: block;
    }

    /* Reduce section padding on mobile */
    .section {
        padding: 2rem 0; /* reduced from 5.5rem */
    }

    /* Reduce hero padding on mobile */
    .hero {
        padding: 2rem 0 2.5rem; /* reduced from 5rem 0 4.5rem */
    }
}

/* Tablet behavior: hide CTAs to avoid crowding between ~769–1000px */
@media (min-width: 769px) and (max-width: 1000px) {
    .nav-cta {
        display: none;
    }

    .nav-inner {
        flex-wrap: nowrap;
    }
}

/* =========================
   Buttons & Badges
   ========================= */
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 0.7rem 1.35rem;
    border-radius: 999px;
    border: none;
    background: linear-gradient(135deg, #22c55e, #0ea5e9);
    color: #020617;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    text-decoration: none;
    box-shadow: 0 18px 45px rgba(34, 197, 94, 0.3);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 0.7rem 1.35rem;
    border-radius: 999px;
    border: 1px solid rgba(148, 163, 184, 0.7);
    background: radial-gradient(circle at top left, rgba(148, 163, 184, 0.15), rgba(15, 23, 42, 0.96));
    color: #e5e7eb;
    font-weight: 500;
    font-size: 0.9rem;
    cursor: pointer;
    text-decoration: none;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    border-radius: 999px;
    padding: 0.18rem 0.6rem;
    font-size: 0.75rem;
    border: 1px solid rgba(56, 189, 248, 0.6);
    background: radial-gradient(circle at left, rgba(56, 189, 248, 0.4), transparent);
    color: #e0f2fe;
}

/* =========================
   Hero
   ========================= */
.hero {
    padding: 5rem 0 4.5rem;
}

.hero-inner {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
    gap: 3rem;
    align-items: center;
}

.hero-kicker {
    margin-bottom: 0.75rem;
}

.hero-title {
    font-size: clamp(2.25rem, 4vw, 3.2rem);
    font-weight: 650;
    color: #f9fafb;
    letter-spacing: 0.02em;
    margin-bottom: 0.75rem;
}

.hero-highlight {
    background: linear-gradient(135deg, #22c55e, #0ea5e9);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-subtitle {
    font-size: 0.98rem;
    color: #cbd5f5;
    max-width: 520px;
    margin-bottom: 1.4rem;
    line-height: 1.7;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1.75rem;
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1.75rem;
    font-size: 0.8rem;
    color: #9ca3af;
}

    .hero-meta span strong {
        color: #e5e7eb;
    }

.hero-card {
    border-radius: 18px;
    border: 1px solid rgba(148, 163, 184, 0.35);
    background: radial-gradient(circle at top left, rgba(56, 189, 248, 0.16), rgba(15, 23, 42, 0.98));
    padding: 1.5rem 1.4rem;
    box-shadow: 0 18px 50px rgba(15, 23, 42, 0.9);
}

.hero-card-title {
    font-size: 0.85rem;
    font-weight: 600;
    color: #e5e7eb;
    margin-bottom: 0.4rem;
}

.hero-card-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.7rem;
    font-size: 0.8rem;
}

.hero-card-pill {
    padding: 0.4rem 0.6rem;
    border-radius: 999px;
    border: 1px solid rgba(148, 163, 184, 0.4);
    background: rgba(15, 23, 42, 0.8);
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

    .hero-card-pill span {
        display: inline-block;
    }

        .hero-card-pill span.dot {
            width: 7px;
            height: 7px;
            border-radius: 999px;
            background: #22c55e;
        }

/* Mobile hero */
@media (max-width: 900px) {
    .hero-inner {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* Compact hero for pricing & utility pages */
.hero--compact {
    padding: 3rem 0 2.5rem; /* was 5rem / 4.5rem */
}

@media (max-width: 900px) {
    .hero--compact {
        padding: 2rem 0 2rem;
    }
}


/* =========================
   Feature Grid
   ========================= */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.6rem;
}

.feature-card {
    border-radius: 18px;
    padding: 1.6rem 1.4rem;
    border: 1px solid rgba(148, 163, 184, 0.35);
    background: radial-gradient(circle at top left, rgba(148, 163, 184, 0.12), rgba(15, 23, 42, 0.96));
}

.feature-icon {
    width: 32px;
    height: 32px;
    border-radius: 999px;
    background: radial-gradient(circle at top left, rgba(56, 189, 248, 0.45), rgba(15, 23, 42, 0.96));
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.9rem;
    font-size: 0.95rem;
}

.feature-title {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.4rem;
}

.feature-body {
    font-size: 0.85rem;
    color: #cbd5f5;
}

@media (max-width: 900px) {
    .feature-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* =========================
   Pricing
   ========================= */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.6rem;
}

.pricing-card {
    border-radius: 18px;
    padding: 1.6rem 1.4rem;
    border: 1px solid rgba(148, 163, 184, 0.35);
    background: radial-gradient(circle at top left, rgba(56, 189, 248, 0.1), rgba(15, 23, 42, 0.97));
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.pricing-name {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.4rem;
}

.pricing-tagline {
    font-size: 0.8rem;
    color: #cbd5f5;
    margin-bottom: 0.9rem;
}

.pricing-price {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.2rem;
}

.pricing-note {
    font-size: 0.8rem;
    color: #cbd5f5;
    margin-bottom: 1rem;
}

.pricing-list {
    list-style: none;
    padding-left: 0;
}

    .pricing-list li {
        position: relative;
        padding-left: 1.5rem;
        margin-bottom: 0.5rem;
    }

        .pricing-list li::before {
            content: "✓";
            position: absolute;
            left: 0;
            top: 0.1rem;
            color: #22c55e; /* green */
            font-weight: 700;
        }


/* Lists inside cards need consistent indentation */
.card-body ul {
    padding-left: 1.25rem;
    margin-top: 0.5rem;
}

    .card-body ul li {
        margin-bottom: 0.35rem;
    }


@media (max-width: 900px) {
    .pricing-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* =========================
   Cards & Layout Blocks
   ========================= */
.split {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 2.4rem;
    align-items: flex-start;
}

@media (max-width: 900px) {
    .split {
        grid-template-columns: minmax(0, 1fr);
    }
}

.card {
    border-radius: 18px;
    padding: 1.6rem 1.4rem;
    border: 1px solid rgba(148, 163, 184, 0.35);
    background: radial-gradient(circle at top left, rgba(148, 163, 184, 0.16), rgba(15, 23, 42, 0.97));
}

.card-title {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.4rem;
}

.card-body {
    font-size: 0.85rem;
    color: #cbd5f5;
}

/* =========================
   Forms
   ========================= */
.form {
    display: grid;
    gap: 0.9rem;
}

.form-row {
    display: grid;
    gap: 0.9rem;
}

@media (min-width: 640px) {
    .form-row {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

label {
    display: block;
    font-size: 0.8rem;
    color: #e5e7eb;
    margin-bottom: 0.2rem;
}

input,
textarea {
    width: 100%;
    border-radius: 10px;
    border: 1px solid rgba(148, 163, 184, 0.6);
    background: rgba(15, 23, 42, 0.9);
    color: #e5e7eb;
    padding: 0.55rem 0.7rem;
    font-size: 0.85rem;
}

textarea {
    min-height: 120px;
    resize: vertical;
}

/* =========================
   Footer
   ========================= */
.footer {
    border-top: 1px solid rgba(148, 163, 184, 0.35);
    padding: 1.4rem 0 1.5rem;
    margin-top: 2rem;
    font-size: 0.75rem;
    color: #9ca3af;
}

.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
}

.footer-links {
    display: flex;
    gap: 1rem;
}

    .footer-links a {
        color: #9ca3af;
        text-decoration: none;
        font-size: 0.75rem;
    }

@media (max-width: 768px) {
    .footer-inner {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* =========================
   Utility classes
   ========================= */
.text-center {
    text-align: center;
}

.muted {
    color: #cbd5f5;
}

.mt-sm {
    margin-top: 0.75rem;
}

.mt-md {
    margin-top: 1.25rem;
}

.mt-lg {
    margin-top: 2rem;
}

/* =========================
   Code Blocks
   ========================= */
.code-block {
    margin-top: 0.8rem;
    font-size: 0.78rem;
    background: #020617;
    padding: 0.9rem 0.8rem;
    border-radius: 10px;
    border: 1px solid rgba(148, 163, 184, 0.6);
    white-space: pre;
    overflow: auto;
}

code {
    background: rgba(148, 163, 184, 0.2);
    padding: 0.15rem 0.35rem;
    border-radius: 4px;
    font-size: 0.8rem;
}

/* =========================
   Blazor Reconnect Modal
   ========================= */
#components-reconnect-modal {
    display: none;
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 1060; /* Higher than navbar */
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(8px);
}

    #components-reconnect-modal.show {
        display: flex;
        align-items: center;
        justify-content: center;
    }

html .components-reconnect-dialog {
    padding: 2rem 2.5rem;
    border-radius: 18px !important;
    border: 1px solid rgba(148, 163, 184, 0.35) !important;
    background: radial-gradient(circle at top left, rgba(56, 189, 248, 0.16), rgba(15, 23, 42, 0.98)) !important;
    background-color: rgba(15, 23, 42, 0.98) !important; /* in case background shorthand is overridden */
    box-shadow: 0 18px 50px rgba(15, 23, 42, 0.9) !important;
    color: #e5e7eb !important;
    max-width: 400px;
    width: 90%;
    text-align: center;
}

    .components-reconnect-dialog p {
        font-size: 1.1rem;
        color: #cbd5f5;
        margin: 0;
    }

html .components-reconnect-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(148, 163, 184, 0.2);
    border-top-color: #22c55e;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.components-reconnect-reload {
    display: inline-block;
    padding: 0.5rem 1.2rem;
    border-radius: 999px;
    border: 1px solid rgba(148, 163, 184, 0.6);
    background: radial-gradient(circle at top left, rgba(148, 163, 184, 0.2), transparent);
    color: #e5e7eb;
    font-size: 0.9rem;
    text-decoration: none;
    cursor: pointer;
    margin-top: 1.25rem;
}

/* =========================
   Blazor Error UI
   ========================= */
#blazor-error-ui {
    background: #b32121;
    padding: 1rem;
    color: white;
    display: none;
}

    #blazor-error-ui .dismiss {
        cursor: pointer;
        margin-left: 1rem;
    }

/* Active NavLink styling (Blazor adds `active` class automatically) */
.nav-links a.active {
    opacity: 1;
    color: #f9fafb;
    position: relative;
}

    /* Gradient underline indicator */
    .nav-links a.active::after {
        content: "";
        position: absolute;
        left: 0;
        right: 0;
        bottom: -8px;
        height: 3px;
        border-radius: 999px;
        background: linear-gradient(135deg, #22c55e, #0ea5e9);
        box-shadow: 0 6px 18px rgba(34, 197, 94, 0.35);
    }

/* Active background subtlety without affecting layout */
@media (hover: hover) {
    .nav-links a.active {
        background: radial-gradient(circle at top left, rgba(148, 163, 184, 0.12), rgba(15, 23, 42, 0));
    }
}

/* Keep brand logo and text on one line */
.nav-brand {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

.nav-brand > .d-flex {
    display: flex;
    align-items: center;
    gap: 0.9rem; /* increased spacing between logo and text */
    flex-wrap: nowrap; /* prevent logo and text block from wrapping apart */
}

/* Prevent the circular logo from shrinking/wrapping */
.logo-mark {
    flex: 0 0 auto;
}

/* Ensure text block can wrap internally if needed without forcing a break from the logo */
.nav-brand > .d-flex > div:last-child {
    min-width: 0;
}
