:root {
    --primary: #2563eb;
    --primary-hover: #1d4ed8;
    --primary-light: #eff6ff;

    --background: #f8fafc;
    --surface: rgba(255, 255, 255, 0.78);
    --surface-solid: #ffffff;
    --surface-hover: rgba(255, 255, 255, 0.94);

    --text: #0f172a;
    --text-secondary: #334155;
    --text-muted: #64748b;

    --border: rgba(148, 163, 184, 0.24);
    --border-strong: rgba(148, 163, 184, 0.42);

    --code-background: #0f172a;
    --code-text: #e2e8f0;

    --card-shadow:
        0 10px 35px rgba(15, 23, 42, 0.08);

    --card-shadow-hover:
        0 18px 45px rgba(15, 23, 42, 0.14);

    --radius: 18px;
    --nav-height: 72px;
}

@media (prefers-color-scheme: dark) {
    :root {
        --background: #020617;
        --surface: rgba(15, 23, 42, 0.68);
        --surface-solid: #0f172a;
        --surface-hover: rgba(30, 41, 59, 0.82);

        --text: #f8fafc;
        --text-secondary: #cbd5e1;
        --text-muted: #94a3b8;

        --border: rgba(148, 163, 184, 0.16);
        --border-strong: rgba(148, 163, 184, 0.3);

        --primary-light: rgba(37, 99, 235, 0.14);

        --card-shadow:
            0 10px 35px rgba(0, 0, 0, 0.24);

        --card-shadow-hover:
            0 18px 45px rgba(0, 0, 0, 0.34);
    }
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family:
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        Roboto,
        Helvetica,
        Arial,
        sans-serif;

    color: var(--text);
    background:
        radial-gradient(
            circle at 10% 0%,
            rgba(37, 99, 235, 0.08),
            transparent 35%
        ),
        radial-gradient(
            circle at 90% 15%,
            rgba(59, 130, 246, 0.06),
            transparent 30%
        ),
        var(--background);

    line-height: 1.6;
}

a {
    color: inherit;
}

button {
    font: inherit;
}

.container {
    width: min(1180px, calc(100% - 40px));
    margin: 0 auto;
}

/* ================================
   Navigation
================================= */

.navbar{
    position:sticky;
    top:0;
    z-index:1000;

    background:color-mix(
        in srgb,
        var(--surface) 92%,
        transparent
    );

    backdrop-filter:blur(16px);

    border-bottom:1px solid var(--border);
}

.nav-container{
    height:70px;

    display:flex;
    align-items:center;
    justify-content:space-between;
}

.logo{
    text-decoration:none;
    font-weight:800;
    color:var(--primary);
}

.nav-links{
    display:flex;
    align-items:center;
    gap:28px;

    list-style:none;
}

.nav-links a{
    text-decoration:none;
    color:var(--text-secondary);

    font-size:.95rem;
    font-weight:600;
}

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

.nav-contact{
    background:var(--primary);
    color:white !important;

    padding:9px 16px;
    border-radius:8px;
}

/* ================================
   Hero
================================= */

.hero {
    padding: 100px 0 65px;
}

.hero-content {
    max-width: 820px;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    margin-bottom: 18px;

    color: var(--primary);

    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.eyebrow::before {
    content: "";

    width: 28px;
    height: 2px;

    background: var(--primary);
    border-radius: 999px;
}

.hero h1 {
    margin: 0;

    font-size: clamp(2.8rem, 6vw, 4.8rem);
    line-height: 1.03;
    letter-spacing: -0.055em;
}

.hero h1 span {
    color: var(--primary);
}

.hero p {
    max-width: 720px;

    margin: 26px 0 0;

    color: var(--text-muted);

    font-size: 1.15rem;
    line-height: 1.75;
}

/* ================================
   Filters
================================= */

.samples-toolbar {
    position: sticky;
    top: var(--nav-height);
    z-index: 50;

    padding: 16px 0;

    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);

    background: color-mix(
        in srgb,
        var(--background) 88%,
        transparent
    );

    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

.filter-list {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
}

.filter-button {
    padding: 9px 15px;

    border: 1px solid var(--border);
    border-radius: 999px;

    background: var(--surface);
    color: var(--text-muted);

    cursor: pointer;

    font-size: 0.85rem;
    font-weight: 600;

    transition:
        background 0.2s ease,
        color 0.2s ease,
        border-color 0.2s ease,
        transform 0.2s ease;
}

.filter-button:hover {
    color: var(--text);
    border-color: var(--border-strong);
    transform: translateY(-1px);
}

.filter-button.active {
    border-color: var(--primary);
    background: var(--primary);
    color: #fff;
}

/* ================================
   Samples
================================= */

.samples-section {
    padding: 65px 0 100px;
}

.section-heading {
    margin-bottom: 30px;
}

.section-heading h2 {
    margin: 0 0 8px;

    font-size: 1.75rem;
    letter-spacing: -0.03em;
}

.section-heading p {
    margin: 0;

    color: var(--text-muted);
}

.samples-grid {
    display: grid;
    grid-template-columns:
        repeat(2, minmax(0, 1fr));

    gap: 24px;
}

/* ================================
   Sample Card
================================= */

.sample-card {
    display: flex;
    flex-direction: column;

    min-width: 0;

    padding: 28px;

    border: 1px solid var(--border);
    border-radius: var(--radius);

    background: var(--surface);

    box-shadow: var(--card-shadow);

    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);

    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease,
        border-color 0.25s ease;
}

.sample-card:hover {
    transform: translateY(-4px);

    border-color: var(--border-strong);

    box-shadow: var(--card-shadow-hover);
}

.sample-card.hidden {
    display: none;
}

.sample-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;

    margin-bottom: 16px;
}

.sample-category {
    color: var(--primary);

    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.sample-language {
    padding: 4px 9px;

    border: 1px solid var(--border);
    border-radius: 6px;

    color: var(--text-muted);

    font-family:
        "SFMono-Regular",
        Consolas,
        "Liberation Mono",
        monospace;

    font-size: 0.7rem;
}

.sample-card h3 {
    margin: 0 0 10px;

    font-size: 1.35rem;
    letter-spacing: -0.025em;
}

.sample-card .description {
    margin: 0 0 22px;

    color: var(--text-muted);
    font-size: 0.94rem;
}

.code-preview {
    position: relative;

    margin: 0 0 22px;

    overflow: hidden;

    border: 1px solid rgba(148, 163, 184, 0.12);
    border-radius: 12px;

    background: var(--code-background);

    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.code-header {
    display: flex;
    align-items: center;
    justify-content: space-between;

    padding: 10px 14px;

    border-bottom: 1px solid rgba(148, 163, 184, 0.12);

    color: #94a3b8;

    font-family:
        "SFMono-Regular",
        Consolas,
        "Liberation Mono",
        monospace;

    font-size: 0.72rem;
}

.code-dots {
    display: flex;
    gap: 5px;
}

.code-dots span {
    width: 7px;
    height: 7px;

    border-radius: 50%;

    background: #475569;
}

.code-preview pre {
    margin: 0;

    padding: 18px;

    overflow-x: auto;

    color: var(--code-text);

    font-family:
        "SFMono-Regular",
        Consolas,
        "Liberation Mono",
        monospace;

    font-size: 0.76rem;
    line-height: 1.7;
}

.code-preview code {
    font-family: inherit;
}

.sample-footer {
    margin-top: auto;
}

.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;

    margin-bottom: 22px;
}

.tag {
    padding: 5px 9px;

    border: 1px solid var(--border);
    border-radius: 6px;

    color: var(--text-muted);

    font-size: 0.72rem;
    font-weight: 600;
}

.sample-links {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
}

.sample-link {
    color: var(--primary);

    text-decoration: none;

    font-size: 0.87rem;
    font-weight: 700;
}

.sample-link:hover {
    text-decoration: underline;
}

.case-study-link {
    color: var(--text-muted);

    text-decoration: none;

    font-size: 0.8rem;
    font-weight: 600;
}

.case-study-link:hover {
    color: var(--text);
}

/* ================================
   Empty State
================================= */

.empty-state {
    display: none;

    padding: 60px 20px;

    text-align: center;

    color: var(--text-muted);
}

.empty-state.visible {
    display: block;
}

/* ================================
   CTA
================================= */

.cta-section {
    padding: 0 0 100px;
}

.cta {
    padding: 55px 50px;

    border-radius: 24px;

    background:
        linear-gradient(
            135deg,
            #2563eb,
            #1d4ed8
        );

    color: white;

    box-shadow:
        0 20px 50px rgba(37, 99, 235, 0.2);
}

.cta h2 {
    margin: 0 0 12px;

    font-size: 2rem;
    letter-spacing: -0.035em;
}

.cta p {
    max-width: 650px;

    margin: 0 0 25px;

    color: rgba(255, 255, 255, 0.82);
}

.cta-button {
    display: inline-flex;
    align-items: center;

    padding: 11px 18px;

    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 8px;

    background: rgba(255, 255, 255, 0.12);
    color: white;

    text-decoration: none;

    font-size: 0.87rem;
    font-weight: 700;

    backdrop-filter: blur(8px);

    transition:
        background 0.2s ease,
        transform 0.2s ease;
}

.cta-button:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
}

/* ================================
   Footer
================================= */

footer {
    padding: 30px 0;

    border-top: 1px solid var(--border);

    color: var(--text-muted);

    font-size: 0.82rem;
}

.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

/* ================================
   Responsive
================================= */

@media (max-width: 800px) {
    .nav-links {
        gap: 15px;
    }

    .nav-links a:nth-child(-n+2) {
        display: none;
    }

    .hero {
        padding: 70px 0 50px;
    }

    .samples-grid {
        grid-template-columns: 1fr;
    }

    .cta {
        padding: 40px 28px;
    }
}

@media (max-width: 560px) {
    .container {
        width: min(100% - 28px, 1180px);
    }

    .hero h1 {
        font-size: 2.8rem;
    }

    .hero p {
        font-size: 1rem;
    }

    .sample-card {
        padding: 22px;
    }

    .sample-links {
        align-items: flex-start;
        flex-direction: column;
    }

    .footer-inner {
        flex-direction: column;
        align-items: flex-start;
    }
}