/* ==========================================================================
   Herrtwich Solutions — Design System
   Dark, minimal, one accent. Built for an enterprise-grade first impression.
   ========================================================================== */

/* --- 1. Tokens ---------------------------------------------------------- */

:root {
    /* Color */
    --bg: #0b0c0e;
    --bg-raised: #101114;
    --surface: rgba(255, 255, 255, 0.03);
    --surface-hover: rgba(255, 255, 255, 0.05);
    --border: rgba(255, 255, 255, 0.08);
    --border-strong: rgba(255, 255, 255, 0.16);
    --text: #f5f6f8;
    --text-secondary: #a6abb5;
    --text-muted: #70747e;
    --accent: #6e8bff;
    --accent-strong: #93a8ff;
    --accent-dim: rgba(110, 139, 255, 0.12);
    --success: #4ade80;

    /* Typography */
    --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

    /* Layout */
    --container: 1120px;
    --nav-height: 64px;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;

    /* Motion */
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    --speed: 0.25s;

    /* Depth */
    --shadow-card: 0 1px 2px rgba(0, 0, 0, 0.4), 0 8px 24px rgba(0, 0, 0, 0.25);
    --shadow-float: 0 24px 64px rgba(0, 0, 0, 0.5);
}

/* --- 2. Reset & base ----------------------------------------------------- */

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-sans);
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    overflow-x: hidden;
}

img,
svg {
    display: block;
    max-width: 100%;
}

a {
    color: inherit;
    text-decoration: none;
}

p a,
.section-subtitle a {
    color: var(--accent-strong);
    transition: color var(--speed) var(--ease-out);
}

p a:hover,
.section-subtitle a:hover {
    color: var(--text);
}

ul[class],
ol[class] {
    list-style: none;
}

button {
    font: inherit;
    color: inherit;
    background: none;
    border: none;
    cursor: pointer;
}

::selection {
    background: rgba(110, 139, 255, 0.35);
    color: var(--text);
}

:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
    border-radius: 4px;
}

/* Anchor targets clear the fixed nav */
section[id] {
    scroll-margin-top: calc(var(--nav-height) + 24px);
}

.skip-link {
    position: absolute;
    top: -48px;
    left: 16px;
    z-index: 200;
    padding: 10px 16px;
    background: var(--text);
    color: var(--bg);
    border-radius: var(--radius-sm);
    font-weight: 600;
    transition: top var(--speed) var(--ease-out);
}

.skip-link:focus {
    top: 12px;
}

/* --- 3. Layout primitives ------------------------------------------------ */

.container {
    width: 100%;
    max-width: var(--container);
    margin-inline: auto;
    padding-inline: 24px;
}

.section {
    padding-block: 120px;
}

.section-header {
    max-width: 640px;
    margin-bottom: 64px;
}

.eyebrow {
    display: inline-block;
    margin-bottom: 16px;
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--accent-strong);
}

.section-title {
    font-size: clamp(1.875rem, 4vw, 2.75rem);
    font-weight: 700;
    line-height: 1.12;
    letter-spacing: -0.03em;
}

.section-subtitle {
    margin-top: 20px;
    font-size: 1.125rem;
    line-height: 1.65;
    color: var(--text-secondary);
}

/* --- 4. Buttons ----------------------------------------------------------- */

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: var(--radius-sm);
    font-size: 0.9375rem;
    font-weight: 600;
    letter-spacing: -0.01em;
    white-space: nowrap;
    transition: background var(--speed) var(--ease-out),
        border-color var(--speed) var(--ease-out),
        color var(--speed) var(--ease-out),
        transform var(--speed) var(--ease-out),
        box-shadow var(--speed) var(--ease-out);
}

.btn:active {
    transform: scale(0.98);
}

.btn-primary {
    background: var(--text);
    color: var(--bg);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.1), 0 4px 16px rgba(0, 0, 0, 0.3);
}

.btn-primary:hover {
    background: #ffffff;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.2), 0 6px 24px rgba(110, 139, 255, 0.25);
}

.btn-ghost,
.btn-secondary {
    border: 1px solid var(--border-strong);
    color: var(--text);
    background: transparent;
}

.btn-ghost:hover,
.btn-secondary:hover {
    background: var(--surface-hover);
    border-color: rgba(255, 255, 255, 0.28);
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.875rem;
}

.btn-lg {
    padding: 15px 32px;
    font-size: 1rem;
}

.btn-arrow {
    display: inline-block;
    transition: transform var(--speed) var(--ease-out);
}

.btn:hover .btn-arrow,
.service-card:hover .btn-arrow {
    transform: translateX(3px);
}

/* --- 5. Navigation -------------------------------------------------------- */

.navbar {
    position: fixed;
    inset-inline: 0;
    top: 0;
    z-index: 100;
    height: var(--nav-height);
    background: rgba(11, 12, 14, 0.65);
    -webkit-backdrop-filter: blur(16px) saturate(1.4);
    backdrop-filter: blur(16px) saturate(1.4);
    border-bottom: 1px solid transparent;
    transition: border-color var(--speed) var(--ease-out),
        background var(--speed) var(--ease-out);
}

.navbar.is-scrolled {
    background: rgba(11, 12, 14, 0.82);
    border-bottom-color: var(--border);
}

.nav-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: var(--nav-height);
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.logo-mark {
    width: 30px;
    height: 30px;
    color: var(--text);
}

.logo-stroke {
    stroke: var(--accent);
}

.logo-text {
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.logo-text-light {
    font-weight: 400;
    color: var(--text-secondary);
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 4px;
}

.nav-link {
    display: inline-block;
    padding: 8px 14px;
    border-radius: var(--radius-sm);
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: color var(--speed) var(--ease-out),
        background var(--speed) var(--ease-out);
}

.nav-link:hover {
    color: var(--text);
    background: var(--surface-hover);
}

.nav-cta-item {
    margin-left: 12px;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
    width: 40px;
    height: 40px;
    padding: 8px;
    border-radius: var(--radius-sm);
}

.nav-toggle span {
    display: block;
    height: 2px;
    width: 100%;
    background: var(--text);
    border-radius: 2px;
    transition: transform var(--speed) var(--ease-out),
        opacity var(--speed) var(--ease-out);
}

.nav-toggle.is-open span:nth-child(1) {
    transform: translateY(4px) rotate(45deg);
}

.nav-toggle.is-open span:nth-child(2) {
    transform: translateY(-4px) rotate(-45deg);
}

/* --- 6. Hero --------------------------------------------------------------- */

.hero {
    position: relative;
    padding-top: calc(var(--nav-height) + 96px);
    padding-bottom: 96px;
    overflow: hidden;
}

.hero-backdrop {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.hero-glow {
    position: absolute;
    top: -320px;
    left: 50%;
    transform: translateX(-50%);
    width: 1100px;
    height: 700px;
    background: radial-gradient(ellipse at center,
            rgba(110, 139, 255, 0.16) 0%,
            rgba(110, 139, 255, 0.05) 40%,
            transparent 70%);
}

.hero-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
    background-size: 56px 56px;
    -webkit-mask-image: radial-gradient(ellipse 90% 70% at 50% 0%, black 30%, transparent 80%);
    mask-image: radial-gradient(ellipse 90% 70% at 50% 0%, black 30%, transparent 80%);
}

.hero-layout {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
    align-items: center;
    gap: 64px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    margin-bottom: 28px;
    border: 1px solid var(--border);
    border-radius: 100px;
    background: var(--surface);
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.badge-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--success);
    box-shadow: 0 0 8px rgba(74, 222, 128, 0.7);
}

.hero-title {
    font-size: clamp(2.375rem, 5.4vw, 3.875rem);
    font-weight: 700;
    line-height: 1.06;
    letter-spacing: -0.035em;
    background: linear-gradient(180deg, #ffffff 0%, rgba(255, 255, 255, 0.72) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    max-width: 520px;
    margin-top: 24px;
    font-size: 1.1875rem;
    line-height: 1.65;
    color: var(--text-secondary);
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 36px;
}

.hero-note {
    margin-top: 20px;
    font-size: 0.8125rem;
    color: var(--text-muted);
}

/* Hero console visual */

.hero-visual {
    position: relative;
}

.console-card {
    position: relative;
    z-index: 1;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0.02) 100%);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    box-shadow: var(--shadow-float);
    overflow: hidden;
}

.console-shadow {
    position: absolute;
    inset: 40% -10% -20% -10%;
    background: radial-gradient(ellipse at center, rgba(110, 139, 255, 0.14), transparent 70%);
    filter: blur(20px);
    z-index: 0;
}

.console-head {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 14px 18px;
    border-bottom: 1px solid var(--border);
}

.console-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
}

.console-title {
    margin-left: 10px;
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-muted);
    letter-spacing: 0.02em;
}

.console-body {
    padding: 10px 18px 18px;
}

.console-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 0.8438rem;
}

.console-label {
    color: var(--text-secondary);
    font-weight: 500;
}

.console-value {
    margin-left: auto;
    font-variant-numeric: tabular-nums;
    color: var(--text);
    font-weight: 600;
    font-size: 0.8125rem;
}

.status-pulse {
    position: relative;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

.status-ok {
    background: var(--success);
}

.status-pulse::after {
    content: "";
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    background: inherit;
    opacity: 0.4;
    animation: pulse 2.4s var(--ease-out) infinite;
}

@keyframes pulse {
    0% {
        transform: scale(0.6);
        opacity: 0.5;
    }

    70%,
    100% {
        transform: scale(1.6);
        opacity: 0;
    }
}

.console-chart {
    margin-top: 16px;
}

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

.console-chart-meta {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.console-chart-ok {
    color: var(--success);
    font-weight: 500;
}

/* --- 7. Trust & metrics ----------------------------------------------------- */

.trust {
    padding-block: 72px;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    background: var(--bg-raised);
}

.trust-label {
    text-align: center;
    font-size: 0.8125rem;
    font-weight: 500;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.trust-logos {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px 56px;
    margin-top: 28px;
}

.trust-logos span {
    font-size: 1.0625rem;
    font-weight: 600;
    letter-spacing: -0.01em;
    color: var(--text-muted);
    transition: color var(--speed) var(--ease-out);
}

.trust-logos span:hover {
    color: var(--text-secondary);
}

.metrics {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
    margin-top: 64px;
    padding-top: 56px;
    border-top: 1px solid var(--border);
}

.metric {
    display: flex;
    flex-direction: column-reverse;
    text-align: center;
}

.metric-value {
    font-size: clamp(1.875rem, 3.4vw, 2.625rem);
    font-weight: 700;
    letter-spacing: -0.03em;
    font-variant-numeric: tabular-nums;
    color: var(--text);
}

.metric-label {
    margin-top: 6px;
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* --- 8. Services -------------------------------------------------------------- */

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.service-card {
    position: relative;
    display: flex;
    flex-direction: column;
    padding: 32px 28px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--surface);
    cursor: pointer;
    overflow: hidden;
    transition: border-color var(--speed) var(--ease-out),
        background var(--speed) var(--ease-out),
        transform var(--speed) var(--ease-out);
}

/* pointer-following glow */
.service-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(480px circle at var(--mx, 50%) var(--my, 50%),
            rgba(110, 139, 255, 0.08), transparent 60%);
    opacity: 0;
    transition: opacity var(--speed) var(--ease-out);
    pointer-events: none;
}

.service-card:hover {
    border-color: var(--border-strong);
    background: var(--surface-hover);
    transform: translateY(-3px);
}

.service-card:hover::before {
    opacity: 1;
}

.service-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    margin-bottom: 22px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--accent-dim);
    color: var(--accent-strong);
}

.service-icon svg {
    width: 22px;
    height: 22px;
}

.service-card h3 {
    font-size: 1.125rem;
    font-weight: 600;
    letter-spacing: -0.015em;
    margin-bottom: 10px;
}

.service-card>p {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.6;
    flex-grow: 1;
}

.service-features {
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px solid var(--border);
}

.service-features li {
    position: relative;
    padding-left: 20px;
    margin-bottom: 8px;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.service-features li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 8px;
    width: 8px;
    height: 8px;
    border-radius: 2px;
    background: var(--accent-dim);
    box-shadow: inset 0 0 0 1.5px var(--accent);
}

.service-link {
    margin-top: 20px;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--accent-strong);
    opacity: 0;
    transform: translateY(4px);
    transition: opacity var(--speed) var(--ease-out),
        transform var(--speed) var(--ease-out);
}

.service-card:hover .service-link,
.service-card:focus-visible .service-link {
    opacity: 1;
    transform: translateY(0);
}

.services-note {
    margin-top: 40px;
    font-size: 0.875rem;
    color: var(--text-muted);
    max-width: 560px;
}

/* --- 9. Why ---------------------------------------------------------------------- */

.why {
    border-top: 1px solid var(--border);
    background: var(--bg-raised);
}

.why-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 48px 64px;
}

.why-item {
    position: relative;
    padding-left: 64px;
}

.why-index {
    position: absolute;
    left: 0;
    top: 2px;
    font-size: 0.875rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    color: var(--accent-strong);
    letter-spacing: 0.04em;
}

.why-index::after {
    content: "";
    position: absolute;
    left: 2px;
    top: 30px;
    width: 1px;
    height: 48px;
    background: linear-gradient(180deg, var(--border-strong), transparent);
}

.why-item h3 {
    font-size: 1.1875rem;
    font-weight: 600;
    letter-spacing: -0.015em;
    margin-bottom: 10px;
}

.why-item p {
    color: var(--text-secondary);
    font-size: 0.9688rem;
}

/* --- 10. Case studies --------------------------------------------------------------- */

.work-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.work-card {
    display: flex;
    flex-direction: column;
    padding: 32px 28px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: linear-gradient(180deg, var(--surface) 0%, transparent 100%);
    transition: border-color var(--speed) var(--ease-out),
        transform var(--speed) var(--ease-out);
}

.work-card:hover {
    border-color: var(--border-strong);
    transform: translateY(-3px);
}

.work-meta {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 32px;
}

.work-client {
    font-weight: 600;
    font-size: 0.9375rem;
    letter-spacing: -0.01em;
}

.work-tag {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.work-stat {
    font-size: clamp(2.5rem, 4.5vw, 3.25rem);
    font-weight: 700;
    line-height: 1;
    letter-spacing: -0.04em;
    font-variant-numeric: tabular-nums;
    background: linear-gradient(135deg, var(--text) 30%, var(--accent-strong) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.work-stat-label {
    margin-top: 10px;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.work-desc {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
    font-size: 0.9063rem;
    color: var(--text-secondary);
    line-height: 1.65;
}

/* --- 11. Process ----------------------------------------------------------------------- */

.process {
    border-top: 1px solid var(--border);
    background: var(--bg-raised);
}

.process-steps {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px 32px;
}

.process-step {
    position: relative;
    padding-top: 28px;
}

.process-step::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: -32px;
    height: 1px;
    background: var(--border);
}

.process-step:last-child::before {
    right: 0;
}

.process-step::after {
    content: "";
    position: absolute;
    top: -3.5px;
    left: 0;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 12px rgba(110, 139, 255, 0.8);
}

.process-number {
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--accent-strong);
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.06em;
}

.process-step h3 {
    margin-top: 12px;
    font-size: 1.125rem;
    font-weight: 600;
    letter-spacing: -0.015em;
}

.process-step p {
    margin-top: 10px;
    font-size: 0.9063rem;
    color: var(--text-secondary);
}

/* --- 12. Stack ---------------------------------------------------------------------------- */

.stack-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 12px;
}

.stack-item {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 22px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--surface);
    font-size: 0.9063rem;
    font-weight: 600;
    letter-spacing: -0.01em;
    color: var(--text-secondary);
    text-align: center;
    transition: color var(--speed) var(--ease-out),
        border-color var(--speed) var(--ease-out),
        background var(--speed) var(--ease-out),
        transform var(--speed) var(--ease-out);
}

.stack-item:hover {
    color: var(--text);
    border-color: var(--border-strong);
    background: var(--surface-hover);
    transform: translateY(-2px);
}

/* --- 13. Security ---------------------------------------------------------------------------- */

.security {
    border-top: 1px solid var(--border);
    background: var(--bg-raised);
}

.security-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px 48px;
}

.security-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    margin-bottom: 18px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--accent-strong);
    background: var(--accent-dim);
}

.security-icon svg {
    width: 20px;
    height: 20px;
}

.security-item h3 {
    font-size: 1.0625rem;
    font-weight: 600;
    letter-spacing: -0.015em;
    margin-bottom: 8px;
}

.security-item p {
    font-size: 0.9063rem;
    color: var(--text-secondary);
}

/* --- 14. Testimonials --------------------------------------------------------------------------- */

.testimonial-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.testimonial-card {
    display: flex;
    flex-direction: column;
    padding: 32px 28px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--surface);
    transition: border-color var(--speed) var(--ease-out);
}

.testimonial-card:hover {
    border-color: var(--border-strong);
}

.testimonial-card blockquote {
    flex-grow: 1;
    font-size: 0.9688rem;
    line-height: 1.7;
    color: var(--text-secondary);
}

.testimonial-card figcaption {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

.testimonial-name {
    font-weight: 600;
    font-size: 0.9063rem;
}

.testimonial-role {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

/* --- 15. FAQ --------------------------------------------------------------------------------------- */

.faq {
    border-top: 1px solid var(--border);
}

.faq-layout {
    display: grid;
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
    gap: 64px;
    align-items: start;
}

.faq-header {
    margin-bottom: 0;
    position: sticky;
    top: calc(var(--nav-height) + 32px);
}

.faq-item {
    border-bottom: 1px solid var(--border);
}

.faq-item summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 22px 4px;
    font-size: 1.0313rem;
    font-weight: 600;
    letter-spacing: -0.015em;
    cursor: pointer;
    list-style: none;
    transition: color var(--speed) var(--ease-out);
}

.faq-item summary::-webkit-details-marker {
    display: none;
}

.faq-item summary:hover {
    color: var(--accent-strong);
}

.faq-icon {
    position: relative;
    flex-shrink: 0;
    width: 18px;
    height: 18px;
}

.faq-icon::before,
.faq-icon::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 14px;
    height: 1.5px;
    background: var(--text-muted);
    transform: translate(-50%, -50%);
    transition: transform var(--speed) var(--ease-out);
}

.faq-icon::after {
    transform: translate(-50%, -50%) rotate(90deg);
}

.faq-item[open] .faq-icon::after {
    transform: translate(-50%, -50%) rotate(0deg);
}

.faq-item p {
    padding: 0 32px 24px 4px;
    color: var(--text-secondary);
    font-size: 0.9375rem;
    line-height: 1.7;
}

/* --- 16. Inquiry / final CTA -------------------------------------------------------------------------- */

.inquiry {
    position: relative;
    border-top: 1px solid var(--border);
    overflow: hidden;
}

.inquiry-backdrop {
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 70% 50% at 50% 0%,
            rgba(110, 139, 255, 0.08), transparent 70%);
    pointer-events: none;
}

.inquiry .container {
    position: relative;
}

.inquiry-header {
    max-width: 720px;
    margin-inline: auto;
    text-align: center;
    margin-bottom: 56px;
}

.inquiry-form {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 22px 20px;
    max-width: 760px;
    margin-inline: auto;
    padding: 40px;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.015) 100%);
    box-shadow: var(--shadow-card);
}

.inquiry-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.inquiry-field.full-width {
    grid-column: 1 / -1;
}

.inquiry-field label {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.label-optional {
    color: var(--text-muted);
    font-weight: 400;
}

.inquiry-field input,
.inquiry-field select,
.inquiry-field textarea {
    width: 100%;
    padding: 12px 14px;
    font: inherit;
    font-size: 0.9375rem;
    color: var(--text);
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border-strong);
    border-radius: var(--radius-sm);
    transition: border-color var(--speed) var(--ease-out),
        box-shadow var(--speed) var(--ease-out),
        background var(--speed) var(--ease-out);
}

.inquiry-field input::placeholder,
.inquiry-field textarea::placeholder {
    color: var(--text-muted);
}

.inquiry-field select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5 11 1.5' fill='none' stroke='%23a6abb5' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 40px;
}

.inquiry-field textarea {
    resize: vertical;
    min-height: 110px;
}

.inquiry-field input:focus,
.inquiry-field select:focus,
.inquiry-field textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(110, 139, 255, 0.18);
    background: rgba(0, 0, 0, 0.45);
}

.inquiry-consent .checkbox-label {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    font-size: 0.8438rem;
    color: var(--text-muted);
    line-height: 1.55;
    cursor: pointer;
}

.inquiry-consent input[type="checkbox"] {
    width: 17px;
    height: 17px;
    margin-top: 2px;
    flex-shrink: 0;
    accent-color: var(--accent);
    cursor: pointer;
}

.inquiry-submit {
    align-items: center;
    text-align: center;
    gap: 14px;
    margin-top: 8px;
}

.inquiry-submit .btn {
    justify-content: center;
    min-width: 260px;
}

.inquiry-privacy {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.hp-field {
    position: absolute !important;
    left: -9999px !important;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.inquiry-feedback {
    max-width: 760px;
    margin: 20px auto 0;
    text-align: center;
    font-size: 0.9375rem;
    font-weight: 500;
    min-height: 1.5em;
}

.inquiry-feedback.success {
    color: var(--success);
}

.inquiry-feedback.error {
    color: #f87171;
}

/* --- 17. Footer -------------------------------------------------------------------------------------------- */

.footer {
    border-top: 1px solid var(--border);
    background: var(--bg-raised);
    padding: 72px 0 32px;
}

.footer-content {
    display: grid;
    grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr) minmax(0, 1fr);
    gap: 48px;
}

.footer-brand p {
    max-width: 320px;
    margin-top: 18px;
    font-size: 0.9063rem;
    color: var(--text-secondary);
}

.footer-mail {
    display: inline-block;
    margin-top: 14px;
    font-size: 0.9063rem;
    font-weight: 500;
    color: var(--accent-strong);
    transition: color var(--speed) var(--ease-out);
}

.footer-mail:hover {
    color: var(--text);
}

.footer-nav h4 {
    font-size: 0.8125rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--text-muted);
    margin-bottom: 18px;
}

.footer-nav li {
    margin-bottom: 10px;
}

.footer-nav a {
    font-size: 0.9063rem;
    color: var(--text-secondary);
    transition: color var(--speed) var(--ease-out);
}

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

.footer-bottom {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 64px;
    padding-top: 28px;
    border-top: 1px solid var(--border);
    font-size: 0.8125rem;
    color: var(--text-muted);
}

/* --- 18. Legal pages ------------------------------------------------------------------------------------------ */

.legal-page {
    display: flex;
    align-items: center;
    min-height: 100vh;
    padding: 48px 0;
}

.legal {
    width: 100%;
}

.legal-grid {
    display: grid;
    justify-items: center;
}

.legal-card {
    width: 100%;
    max-width: 640px;
    padding: 48px;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--surface);
    box-shadow: var(--shadow-card);
}

.legal-card h1 {
    font-size: 1.75rem;
    font-weight: 700;
    letter-spacing: -0.025em;
    margin-bottom: 24px;
}

.legal-card h2 {
    font-size: 1.125rem;
    font-weight: 600;
    margin: 28px 0 10px;
}

.legal-card p {
    color: var(--text-secondary);
    font-size: 0.9375rem;
    margin-bottom: 16px;
    white-space: pre-line;
}

.legal-card a {
    color: var(--accent-strong);
}

.legal-card .btn {
    margin-top: 16px;
}

/* --- 19. Reveal animations -------------------------------------------------------------------------------------- */

/* Hidden state only applies when JS is available (html.js is set inline
   in <head>), so the page stays fully readable without JavaScript. */

.js [data-reveal] {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
    transition-delay: var(--reveal-delay, 0s);
}

.js [data-reveal].is-visible {
    opacity: 1;
    transform: translateY(0);
}

.js [data-reveal-stagger]>* {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s var(--ease-out), transform 0.6s var(--ease-out);
    transition-delay: var(--reveal-delay, 0s);
}

.js [data-reveal-stagger].is-visible>* {
    opacity: 1;
    transform: translateY(0);
}

/* --- 20. Responsive ------------------------------------------------------------------------------------------------ */

@media (max-width: 1024px) {
    .hero-layout {
        grid-template-columns: 1fr;
        gap: 56px;
    }

    .hero-visual {
        max-width: 520px;
    }

    .services-grid,
    .work-grid,
    .testimonial-grid,
    .security-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .process-steps {
        grid-template-columns: repeat(2, 1fr);
    }

    .process-step:nth-child(even)::before {
        right: 0;
    }

    .stack-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .faq-layout {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .faq-header {
        position: static;
    }
}

@media (max-width: 768px) {
    .section {
        padding-block: 80px;
    }

    .section-header {
        margin-bottom: 48px;
    }

    .nav-toggle {
        display: flex;
    }

    /* Floating menu card. Note: .navbar's backdrop-filter makes it the
       containing block for this fixed element, so offsets are relative
       to the navbar — which sits at the viewport origin. */
    .nav-menu {
        position: fixed;
        top: calc(var(--nav-height) + 8px);
        left: 12px;
        right: 12px;
        flex-direction: column;
        align-items: stretch;
        gap: 4px;
        padding: 12px;
        background: #0e0f12;
        border: 1px solid var(--border);
        border-radius: var(--radius-md);
        box-shadow: 0 24px 48px rgba(0, 0, 0, 0.6);
        transform: translateY(-8px);
        opacity: 0;
        visibility: hidden;
        transition: transform var(--speed) var(--ease-out),
            opacity var(--speed) var(--ease-out),
            visibility var(--speed);
    }

    .nav-menu.is-open {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }

    .nav-link {
        padding: 12px 14px;
        font-size: 1rem;
    }

    .nav-cta-item {
        margin: 8px 0 0;
    }

    .nav-cta-item .btn {
        width: 100%;
        justify-content: center;
    }

    .hero {
        padding-top: calc(var(--nav-height) + 64px);
        padding-bottom: 64px;
    }

    .metrics {
        grid-template-columns: repeat(2, 1fr);
        gap: 36px 20px;
    }

    .why-grid,
    .security-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .inquiry-form {
        grid-template-columns: 1fr;
        padding: 28px 22px;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
}

@media (max-width: 560px) {

    .services-grid,
    .work-grid,
    .testimonial-grid {
        grid-template-columns: 1fr;
    }

    .process-steps {
        grid-template-columns: 1fr;
    }

    .process-step::before {
        right: 0;
    }

    .stack-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .stack-item {
        padding: 16px 8px;
        font-size: 0.8125rem;
    }

    .hero-actions .btn {
        width: 100%;
        justify-content: center;
    }

    .legal-card {
        padding: 32px 24px;
    }
}

/* --- 21. Reduced motion ---------------------------------------------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    [data-reveal],
    [data-reveal-stagger]>* {
        opacity: 1;
        transform: none;
    }
}
