/* =========================================================
   Red Dev Hub — Devoryx-inspired theme (red edition)
   ========================================================= */

:root {
    --bg: #0d0d0f;
    --bg-soft: #121215;
    --bg-elev: #17171b;
    --bg-elev-2: #1d1d22;
    --line: rgba(255, 255, 255, 0.1);
    --line-strong: rgba(255, 255, 255, 0.18);
    --text: #f7f5f1;
    --muted: rgba(255, 255, 255, 0.62);
    --muted-2: rgba(255, 255, 255, 0.78);
    --red: #b3001b;
    --red-bright: #d31b32;
    --red-deep: #6b0010;
    --red-glow: rgba(179, 0, 27, 0.3);
    --cream: #f4f1ea;
    --font-display: "Ubuntu", "Segoe UI", sans-serif;
    --font-body: "Ubuntu", "Segoe UI", sans-serif;
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
    --header-h: 88px;
    --radius: 18px;
}

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

html {
    scroll-behavior: auto;
    -webkit-text-size-adjust: 100%;
    overflow-x: clip;
}

html.lenis {
    height: auto;
}

.lenis.lenis-smooth {
    scroll-behavior: auto;
}

.lenis.lenis-stopped {
    overflow: hidden;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 1;
    opacity: 0.5;
    background:
        radial-gradient(ellipse 80% 50% at 50% -20%, rgba(179, 0, 27, 0.14), transparent 70%),
        radial-gradient(ellipse 40% 40% at 100% 100%, rgba(179, 0, 27, 0.07), transparent 70%);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

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

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

ul,
ol {
    margin: 0;
    padding: 0;
    list-style: none;
}

h1,
h2,
h3,
h4,
h5,
h6,
p {
    margin: 0;
}

::selection {
    background: var(--red);
    color: #fff;
}

:focus-visible {
    outline: 2px solid var(--red-bright);
    outline-offset: 3px;
}

::-webkit-scrollbar {
    width: 9px;
}
::-webkit-scrollbar-track {
    background: var(--bg);
}
::-webkit-scrollbar-thumb {
    background: #262626;
    border-radius: 999px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--red);
}

/* ---------- utilities ---------- */

.container {
    width: min(1440px, 100%);
    margin-inline: auto;
    padding-inline: clamp(20px, 4vw, 70px);
    position: relative;
    z-index: 2;
}

.section {
    padding-block: clamp(80px, 10vw, 160px);
    position: relative;
}

.section-light {
    --bg: #ffffff;
    --bg-soft: #f4f4f5;
    --bg-elev: #ffffff;
    --bg-elev-2: #f8f8f9;
    --line: rgba(10, 10, 12, 0.12);
    --line-strong: rgba(10, 10, 12, 0.24);
    --text: #0b0b0d;
    --muted: rgba(11, 11, 13, 0.56);
    --muted-2: rgba(11, 11, 13, 0.76);
    --red: #b3001b;
    --red-bright: #c9182f;
    --red-deep: #7a0012;
    --red-glow: rgba(179, 0, 27, 0.16);
    background: var(--bg);
    color: var(--text);
    position: relative;
    z-index: 2;
}

.section-light .service-row::before {
    background: var(--bg-soft);
}

.section-light .service-row:hover h3 {
    color: var(--red);
}

.section-light .service-row:hover .service-index,
.section-light .service-row:hover .service-desc {
    color: var(--muted-2);
}

.section-light .service-row:hover .service-tags {
    color: var(--red);
}

.section-light .service-row:hover .service-arrow {
    background: var(--red);
    border-color: var(--red);
    color: #fff;
}

.section-light .btn-ghost:hover {
    color: var(--bg);
}

.section-light .value-card {
    background: var(--bg);
}

.section-light .value-card:hover {
    background: var(--bg-elev);
}

.section-light .field input::placeholder,
.section-light .field textarea::placeholder {
    color: rgba(11, 11, 13, 0.38);
}

.section-light .field input:focus,
.section-light .field select:focus,
.section-light .field textarea:focus {
    box-shadow: 0 0 0 4px rgba(179, 0, 27, 0.1);
}

.section-light .field select {
    color-scheme: light;
}

/* On white sections the default .btn hover slides in a white layer, which is
   invisible here. Use a dark layer so the submit button visibly changes. */
.section-light .btn:not(.btn-ghost)::after {
    background: #0d0d0f;
}

.section-light .btn:not(.btn-ghost):hover {
    color: #ffffff;
    box-shadow: 0 12px 26px rgba(13, 13, 15, 0.18);
}

.section-light .form-message.is-error {
    background: rgba(179, 0, 27, 0.06);
    border-color: rgba(179, 0, 27, 0.3);
    color: #8a1020;
}

.section-light .form-message.is-success {
    background: rgba(18, 107, 58, 0.07);
    border-color: rgba(18, 107, 58, 0.3);
    color: #126b3a;
}

.section-light .cta-strip {
    background:
        radial-gradient(ellipse at 0% 50%, rgba(179, 0, 27, 0.1), transparent 55%),
        var(--bg-soft);
}

.section-label {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-size: 1.2rem;
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: capitalize;
    color: var(--muted-2);
    margin-bottom: 26px;
}

/* keep section labels clear of the section above */
.section > .container > .section-label,
.page-hero .section-label {
    margin-top: 24px;
}

.section-label::before {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--red);
    box-shadow: 0 0 12px var(--red-glow);
}

.display {
    font-family: var(--font-display);
    font-weight: 300;
    font-size: clamp(2.4rem, 5.1vw, 4.6rem);
    line-height: 1.06;
    letter-spacing: -0.03em;
    color: var(--muted);
    text-wrap: balance;
}

.display strong,
.display .accent {
    font-weight: 500;
    color: var(--text);
}

.section-head {
    display: grid;
    grid-template-columns: minmax(0, 0.62fr) minmax(0, 1fr);
    gap: 40px;
    align-items: start;
    padding-top: clamp(16px, 2vw, 28px);
    margin-bottom: clamp(48px, 6vw, 88px);
}

.section-head .display {
    max-width: 14ch;
}

.section-head.right {
    grid-template-columns: minmax(0, 1fr) minmax(0, 0.62fr);
}

.section-head.right .display {
    grid-column: 2;
    grid-row: 1;
    justify-self: end;
    text-align: right;
}

.section-head.right .section-label {
    grid-column: 1;
    grid-row: 1;
}

.eyebrow {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    color: var(--muted-2);
}

.muted {
    color: var(--muted);
}

.arrow {
    display: inline-block;
    transition: transform 0.45s var(--ease);
}

a:hover .arrow,
button:hover .arrow {
    transform: translate(4px, -4px);
}

/* ---------- buttons ---------- */

.btn {
    --btn-bg: var(--red);
    --btn-fg: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    min-height: 54px;
    padding: 0 26px;
    border-radius: 999px;
    background: var(--btn-bg);
    color: var(--btn-fg);
    font-weight: 600;
    font-size: 0.94rem;
    letter-spacing: 0.01em;
    position: relative;
    overflow: hidden;
    isolation: isolate;
    transition: color 0.4s var(--ease), transform 0.4s var(--ease);
}

.btn::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background: #fff;
    transform: translateY(101%);
    transition: transform 0.5s var(--ease);
}

.btn:hover {
    color: #0a0a0a;
    transform: translateY(-2px);
}

.btn:hover::after {
    transform: translateY(0);
}

.btn .arrow {
    font-size: 1.1em;
}

.btn-ghost {
    --btn-bg: transparent;
    --btn-fg: var(--text);
    border: 1px solid var(--line-strong);
}

.btn-ghost::after {
    background: var(--text);
}

.btn-ghost:hover {
    color: #0a0a0a;
    border-color: var(--text);
}

.link-line {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    font-size: 0.92rem;
    padding-bottom: 6px;
    border-bottom: 1px solid var(--line-strong);
    transition: color 0.3s ease, border-color 0.3s ease;
}

.link-line:hover {
    color: var(--red-bright);
    border-color: var(--red-bright);
}

/* ---------- header ---------- */

.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 90;
    transition: background 0.4s ease, border-color 0.4s ease, backdrop-filter 0.4s ease;
    border-bottom: 1px solid transparent;
}

.site-header.is-scrolled {
    background: rgba(13, 13, 15, 0.96);
    border-bottom-color: var(--line);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

/* ---------- scroll progress + back to top ---------- */

.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    z-index: 120;
    pointer-events: none;
    background: rgba(255, 255, 255, 0.06);
}

.scroll-progress-bar {
    display: block;
    width: 100%;
    height: 100%;
    transform: scaleX(0);
    transform-origin: 0 50%;
    background: linear-gradient(90deg, var(--red-deep), var(--red-bright));
    box-shadow: 0 0 12px var(--red-glow);
    transition: transform 0.1s linear;
}

.back-to-top {
    position: fixed;
    right: clamp(16px, 3vw, 32px);
    bottom: calc(clamp(16px, 3vw, 32px) + 76px);
    z-index: 95;
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    padding: 0;
    border-radius: 50%;
    border: 1px solid var(--line-strong);
    background: rgba(13, 13, 15, 0.92);
    color: var(--text);
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(14px) scale(0.92);
    box-shadow: 0 14px 34px rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: opacity 0.3s ease, transform 0.35s var(--ease),
        visibility 0.3s ease, background 0.3s ease, border-color 0.3s ease;
}

.back-to-top.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

/* let the chat widget own the bottom-right corner while it is open */
body.chat-open .back-to-top {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.back-to-top:hover {
    background: var(--red);
    border-color: var(--red-bright);
    transform: translateY(-3px) scale(1.04);
}

.back-to-top:focus-visible {
    outline: 2px solid var(--red-bright);
    outline-offset: 3px;
}

.back-to-top svg {
    width: 20px;
    height: 20px;
}

@media (prefers-reduced-motion: reduce) {
    .scroll-progress-bar,
    .back-to-top {
        transition-duration: 0.01ms;
    }
}

.header-inner {
    height: var(--header-h);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 1.12rem;
    letter-spacing: -0.02em;
    z-index: 2;
}

.brand-mark {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: var(--red);
    color: #fff;
    font-size: 1rem;
    box-shadow: 0 0 24px var(--red-glow);
    transition: transform 0.5s var(--ease);
}

.brand:hover .brand-mark {
    transform: rotate(-12deg) scale(1.06);
}

.brand-logo {
    width: auto;
    height: 52px;
    max-width: 200px;
    border-radius: 0;
    box-shadow: none;
    transition: transform 0.5s var(--ease);
}

.brand:hover .brand-logo {
    transform: scale(1.04);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 14px;
    z-index: 2;
}

.header-cta {
    padding: 12px 20px;
    border: 1px solid var(--line-strong);
    border-radius: 999px;
    font-size: 0.86rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: background 0.3s ease, border-color 0.3s ease, color 0.3s ease;
}

.header-cta:hover {
    background: var(--red);
    border-color: var(--red);
}

.menu-toggle {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    border: 1px solid var(--line-strong);
    display: grid;
    place-items: center;
    gap: 0;
    transition: background 0.3s ease, border-color 0.3s ease;
    position: relative;
}

.menu-toggle:hover {
    background: var(--red);
    border-color: var(--red);
}

.menu-toggle span {
    position: absolute;
    left: 50%;
    width: 20px;
    height: 2px;
    background: currentColor;
    border-radius: 2px;
    transition: transform 0.4s var(--ease), opacity 0.3s ease, top 0.4s var(--ease);
}

.menu-toggle span:nth-child(1) {
    top: 21px;
    transform: translateX(-50%);
}
.menu-toggle span:nth-child(2) {
    top: 28px;
    transform: translateX(-50%);
}
.menu-toggle span:nth-child(3) {
    top: 35px;
    transform: translateX(-50%);
    width: 13px;
    left: 21px;
}

body.menu-open .menu-toggle span:nth-child(1) {
    top: 28px;
    transform: translateX(-50%) rotate(45deg);
}
body.menu-open .menu-toggle span:nth-child(2) {
    opacity: 0;
}
body.menu-open .menu-toggle span:nth-child(3) {
    top: 28px;
    left: 50%;
    width: 20px;
    transform: translateX(-50%) rotate(-45deg);
}

/* ---------- off-canvas menu ---------- */

.nav-overlay {
    position: fixed;
    inset: 0;
    z-index: 80;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(6px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s ease;
}

body.menu-open {
    overflow: hidden;
}

body.menu-open .nav-overlay {
    opacity: 1;
    visibility: visible;
}

.nav-drawer {
    position: fixed;
    top: 0;
    right: 0;
    height: 100%;
    width: min(520px, 100%);
    z-index: 95;
    background: var(--bg-soft);
    border-left: 1px solid var(--line);
    transform: translateX(102%);
    transition: transform 0.7s var(--ease);
    display: flex;
    flex-direction: column;
    padding: 28px clamp(24px, 5vw, 56px) 40px;
    overflow-y: auto;
}

body.menu-open .nav-drawer {
    transform: translateX(0);
}

.nav-drawer-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: clamp(40px, 8vh, 90px);
}

.nav-drawer-brand {
    display: inline-flex;
    align-items: center;
    flex: 0 1 auto;
    min-width: 0;
}

.nav-drawer-logo {
    width: auto;
    height: 52px;
    max-width: 190px;
    border-radius: 0;
    box-shadow: none;
    transition: transform 0.4s var(--ease);
}

.nav-drawer-brand:hover .nav-drawer-logo {
    transform: scale(1.04);
}

.nav-close {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: 1px solid var(--line-strong);
    font-size: 1.3rem;
    display: grid;
    place-items: center;
    transition: background 0.3s ease;
}

.nav-close:hover {
    background: var(--red);
}

.nav-links {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.nav-links a {
    font-family: var(--font-display);
    font-size: clamp(2rem, 5vw, 3.4rem);
    line-height: 1.15;
    font-weight: 400;
    letter-spacing: -0.03em;
    color: var(--muted);
    display: flex;
    align-items: baseline;
    gap: 16px;
    padding: 8px 0;
    transition: color 0.3s ease, padding-left 0.4s var(--ease);
}

.nav-links a span {
    font-family: var(--font-body);
    font-size: 0.7rem;
    letter-spacing: 0.1em;
    color: var(--muted);
}

.nav-links a:hover,
.nav-links a.is-active {
    color: var(--text);
    padding-left: 12px;
}

.nav-drawer-foot {
    margin-top: auto;
    padding-top: 48px;
    border-top: 1px solid var(--line);
    display: grid;
    gap: 22px;
}

.nav-drawer-foot p {
    color: var(--muted);
    font-size: 0.9rem;
}

.nav-drawer-foot a {
    color: var(--text);
    font-size: 1.05rem;
}

.nav-socials {
    display: flex;
    gap: 18px;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--muted-2);
}

.nav-socials a:hover {
    color: var(--red-bright);
}

/* ---------- hero ---------- */

.hero {
    min-height: 100svh;
    padding-top: calc(var(--header-h) + 40px);
    padding-bottom: 60px;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.hero::after {
    content: "";
    position: absolute;
    inset: auto -10% -40% 40%;
    height: 70%;
    background: radial-gradient(ellipse at center, rgba(179, 0, 27, 0.12), transparent 68%);
    pointer-events: none;
}

.hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 0.42fr) minmax(0, 1fr);
    gap: clamp(30px, 5vw, 80px);
    align-items: center;
    width: 100%;
}

.hero-badge-wrap {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 34px;
}

.rotating-badge {
    width: clamp(150px, 14vw, 200px);
    height: clamp(150px, 14vw, 200px);
    position: relative;
    display: grid;
    place-items: center;
    color: var(--muted-2);
}

.rotating-badge svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    animation: spin 26s linear infinite;
}

.rotating-badge text {
    fill: currentColor;
    font-family: var(--font-body);
    font-size: 10.5px;
    letter-spacing: 0.32em;
    text-transform: uppercase;
}

.badge-core {
    width: 58px;
    height: 58px;
    border-radius: 50%;
    background: var(--red);
    display: grid;
    place-items: center;
    color: #fff;
    font-size: 1.25rem;
    box-shadow: 0 0 40px var(--red-glow);
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.hero-side-note {
    max-width: 230px;
    color: var(--muted);
    font-size: 0.9rem;
    line-height: 1.7;
    padding-left: 18px;
    border-left: 1px solid var(--line-strong);
}

.hero-eyebrow {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--muted-2);
    text-transform: capitalize;
    font-size: 1rem;
    margin-bottom: 28px;
}

.hero-eyebrow .dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--red);
    box-shadow: 0 0 14px var(--red-glow);
}

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(3.2rem, 8vw, 7.2rem);
    line-height: 0.98;
    font-weight: 600;
    letter-spacing: -0.045em;
    text-transform: uppercase;
    margin-bottom: 34px;
}

.hero-title .line {
    display: block;
    overflow: hidden;
}

.hero-title .line-inner {
    display: block;
}

.hero-title .line:nth-child(odd) .line-inner {
    color: var(--muted);
}

.hero-title .line-inner em {
    font-style: normal;
    color: var(--red);
}

.hero-tags {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0;
    border-top: 1px solid var(--line);
    margin-top: 8px;
}

.hero-tags li {
    padding: 22px 18px 0;
    border-left: 1px solid var(--line);
    font-size: 0.88rem;
    color: var(--muted-2);
    display: flex;
    gap: 10px;
    align-items: flex-start;
    min-height: 66px;
}

.hero-tags li:first-child {
    border-left: 0;
    padding-left: 0;
}

.hero-tags li span {
    color: var(--red);
    font-size: 0.8rem;
    line-height: 1.4;
}

.hero-scroll {
    position: absolute;
    left: clamp(20px, 4vw, 70px);
    bottom: 30px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.7rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--muted);
}

.hero-scroll .scroll-line {
    width: 46px;
    height: 1px;
    background: var(--line-strong);
    position: relative;
    overflow: hidden;
}

.hero-scroll .scroll-line::after {
    content: "";
    position: absolute;
    inset: 0;
    background: var(--red);
    transform: translateX(-100%);
    animation: scrollLine 2.2s ease-in-out infinite;
}

@keyframes scrollLine {
    0% { transform: translateX(-100%); }
    60%, 100% { transform: translateX(100%); }
}

/* ---------- marquee ---------- */

.marquee-band {
    border-block: 1px solid var(--line);
    padding-block: 26px;
    overflow: hidden;
    position: relative;
    z-index: 2;
    background: var(--bg-soft);
}

.marquee-track {
    display: flex;
    align-items: center;
    width: max-content;
    animation: marquee 34s linear infinite;
}

.marquee-band:hover .marquee-track {
    animation-play-state: paused;
}

.marquee-track span {
    font-family: var(--font-display);
    font-size: clamp(1.6rem, 3.4vw, 2.9rem);
    font-weight: 500;
    letter-spacing: -0.02em;
    text-transform: uppercase;
    padding-inline: 26px;
    display: inline-flex;
    align-items: center;
    gap: 26px;
    white-space: nowrap;
    color: var(--text);
}

.marquee-track span::after {
    content: "✱";
    color: var(--red);
    font-size: 0.7em;
}

.marquee-track span:nth-child(even) {
    color: transparent;
    -webkit-text-stroke: 1px var(--muted-2);
}

@keyframes marquee {
    to {
        transform: translateX(-50%);
    }
}

/* ---------- who / about ---------- */

.who-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.6fr) minmax(0, 0.8fr);
    gap: clamp(40px, 6vw, 100px);
    align-items: end;
}

.who-statement {
    font-family: var(--font-display);
    font-size: clamp(1.65rem, 3.1vw, 2.9rem);
    line-height: 1.25;
    letter-spacing: -0.028em;
    font-weight: 300;
    color: var(--text);
    text-wrap: balance;
}

.who-statement .accent {
    color: var(--muted);
}

.who-side {
    display: grid;
    gap: 26px;
    padding-bottom: 8px;
}

.who-side p {
    color: var(--muted-2);
    font-size: 0.95rem;
    line-height: 1.75;
}

.happy-clients {
    display: flex;
    align-items: center;
    gap: 14px;
}

.avatar-stack {
    display: flex;
}

.avatar-stack img {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--bg);
    margin-left: -10px;
}

.avatar-stack img:first-child {
    margin-left: 0;
}

.happy-clients span {
    font-size: 0.82rem;
    color: var(--muted-2);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    margin-top: clamp(60px, 8vw, 110px);
    border-top: 1px solid var(--line);
}

.stat {
    padding: 40px 30px 10px;
    border-left: 1px solid var(--line);
}

.stat:first-child {
    border-left: 0;
    padding-left: 0;
}

.stat-value {
    font-family: var(--font-display);
    font-size: clamp(3.4rem, 7vw, 6.4rem);
    line-height: 1;
    font-weight: 300;
    letter-spacing: -0.04em;
    display: flex;
    align-items: flex-start;
}

.stat-value .stat-number {
    display: inline-block;
}

.stat-value sup {
    font-size: 0.32em;
    color: var(--red);
    top: 0.3em;
    position: relative;
    margin-left: 4px;
}

.stat p {
    margin-top: 16px;
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--muted);
    max-width: 22ch;
    line-height: 1.6;
}

/* ---------- services list ---------- */

.service-list {
    border-top: 1px solid var(--line);
}

.service-row {
    display: grid;
    grid-template-columns: 90px minmax(0, 1.05fr) minmax(0, 0.75fr) minmax(0, 0.95fr) 56px;
    gap: clamp(18px, 3vw, 48px);
    align-items: center;
    padding: clamp(26px, 3.4vw, 44px) clamp(4px, 1vw, 16px);
    border-bottom: 1px solid var(--line);
    position: relative;
    isolation: isolate;
    transition: color 0.4s ease, padding-left 0.5s var(--ease);
}

.service-row::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background: var(--red);
    transform: scaleY(0);
    transform-origin: bottom;
    transition: transform 0.5s var(--ease);
}

.service-row:hover {
    padding-left: clamp(16px, 2.4vw, 34px);
}

.service-row:hover::before {
    transform: scaleY(1);
}

.service-row:hover .service-index,
.service-row:hover .service-desc,
.service-row:hover .service-tags {
    color: rgba(255, 255, 255, 0.8);
}

.service-index {
    font-family: var(--font-display);
    font-size: 1.15rem;
    color: var(--muted);
    align-self: start;
    padding-top: 10px;
    transition: color 0.3s ease;
}

.service-row h3 {
    font-family: var(--font-display);
    font-size: clamp(1.55rem, 2.8vw, 2.55rem);
    line-height: 1.05;
    font-weight: 400;
    letter-spacing: -0.03em;
}

.service-tags {
    font-size: 0.72rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--red);
    line-height: 1.8;
    font-weight: 500;
    transition: color 0.3s ease;
}

.service-desc {
    font-size: 0.88rem;
    line-height: 1.7;
    color: var(--muted-2);
    transition: color 0.3s ease;
}

.service-arrow {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: 1px solid var(--line-strong);
    display: grid;
    place-items: center;
    font-size: 1.1rem;
    transition: background 0.4s ease, border-color 0.4s ease, transform 0.4s var(--ease);
}

.service-row:hover .service-arrow {
    background: #fff;
    color: #0a0a0a;
    border-color: #fff;
    transform: rotate(45deg);
}

/* ---------- project cards ---------- */

.project-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(18px, 2.4vw, 28px);
}

.project-card {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 22px;
    padding: clamp(24px, 3vw, 36px);
    border: 1px solid var(--line);
    border-radius: calc(var(--radius) + 6px);
    background:
        radial-gradient(circle at 100% 0%, rgba(179, 0, 27, 0.14), transparent 44%),
        linear-gradient(155deg, var(--bg-elev-2), var(--bg-soft));
    overflow: hidden;
    transition: border-color 0.4s ease, transform 0.5s var(--ease), box-shadow 0.4s ease;
}

.project-card::before {
    content: "";
    position: absolute;
    top: 24px;
    bottom: 24px;
    left: 0;
    width: 2px;
    background: var(--red);
    transform: scaleY(0);
    transform-origin: top;
    transition: transform 0.5s var(--ease);
}

.project-card:hover {
    border-color: rgba(179, 0, 27, 0.45);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
    transform: translateY(-6px);
}

.project-card:hover::before {
    transform: scaleY(1);
}

.project-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.project-number {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border: 1px solid var(--line-strong);
    border-radius: 50%;
    color: var(--muted-2);
    font-family: var(--font-display);
    font-size: 0.72rem;
    transition: background 0.3s ease, border-color 0.3s ease, color 0.3s ease;
}

.project-card:hover .project-number {
    background: var(--red);
    border-color: var(--red);
    color: #fff;
}

.project-tag {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: var(--red-bright);
    font-size: 0.56rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    white-space: nowrap;
}

.project-tag::before {
    content: "";
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: currentColor;
    box-shadow: 0 0 8px var(--red-glow);
}

.project-card-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.project-title {
    font-family: var(--font-display);
    font-size: clamp(1.4rem, 2.5vw, 2.05rem);
    font-weight: 400;
    line-height: 1.05;
    letter-spacing: -0.03em;
    transition: color 0.3s ease;
}

.project-card:hover .project-title {
    color: var(--red-bright);
}

.project-sub {
    color: var(--muted);
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.11em;
}

.project-desc {
    margin-top: 2px;
    color: var(--muted-2);
    font-size: 0.86rem;
    line-height: 1.7;
}

.project-card-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--line);
}

.project-domain {
    color: var(--muted-2);
    font-size: 0.7rem;
    letter-spacing: 0.06em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.project-card:hover .project-domain {
    color: #fff;
}

.project-arrow {
    flex: none;
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border: 1px solid var(--line-strong);
    border-radius: 50%;
    font-size: 1rem;
    transition: background 0.4s ease, border-color 0.4s ease, color 0.4s ease, transform 0.4s var(--ease);
}

.project-card:hover .project-arrow {
    background: #fff;
    border-color: #fff;
    color: #0a0a0a;
    transform: rotate(45deg);
}

/* ---------- process ---------- */

.process-layout {
    display: grid;
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
    gap: clamp(40px, 6vw, 100px);
    align-items: start;
}

.process-sticky {
    position: sticky;
    top: calc(var(--header-h) + 30px);
    display: grid;
    gap: 26px;
}

.process-sticky p {
    color: var(--muted-2);
    max-width: 40ch;
    line-height: 1.75;
}

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

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

.accordion-trigger {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 22px;
    padding: 28px 4px;
    text-align: left;
    transition: color 0.3s ease;
}

.accordion-index {
    font-family: var(--font-display);
    color: var(--muted);
    font-size: 0.95rem;
    min-width: 44px;
}

.accordion-title {
    font-family: var(--font-display);
    font-size: clamp(1.1rem, 2vw, 1.65rem);
    font-weight: 400;
    letter-spacing: -0.02em;
    flex: 1;
}

.accordion-icon {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 1px solid var(--line-strong);
    display: grid;
    place-items: center;
    font-size: 1.2rem;
    transition: background 0.3s ease, transform 0.4s var(--ease), border-color 0.3s ease;
    flex-shrink: 0;
}

.accordion-item.is-open .accordion-icon {
    background: var(--red);
    border-color: var(--red);
    transform: rotate(45deg);
}

.accordion-item.is-open .accordion-trigger {
    color: var(--red-bright);
}

.accordion-panel {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.5s var(--ease);
}

.accordion-item.is-open .accordion-panel {
    grid-template-rows: 1fr;
}

.accordion-panel > div {
    overflow: hidden;
}

.accordion-panel p {
    padding: 0 4px 28px 66px;
    color: var(--muted-2);
    font-size: 0.92rem;
    line-height: 1.75;
    max-width: 58ch;
}

/* ---------- team ---------- */

.team-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: clamp(18px, 2.2vw, 32px);
}

.team-card {
    position: relative;
}

.team-photo {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius);
    aspect-ratio: 3 / 4;
    background: var(--bg-elev);
}

.team-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(1);
    transition: filter 0.6s ease, transform 0.8s var(--ease);
}

.team-card:hover .team-photo img {
    filter: grayscale(0);
    transform: scale(1.05);
}

.team-socials {
    position: absolute;
    left: 14px;
    bottom: 14px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 0.4s ease, transform 0.4s var(--ease);
}

.team-card:hover .team-socials {
    opacity: 1;
    transform: translateY(0);
}

.team-socials a {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(5, 5, 5, 0.7);
    backdrop-filter: blur(8px);
    display: grid;
    place-items: center;
    font-size: 0.72rem;
    font-weight: 600;
    transition: background 0.3s ease;
}

.team-socials a:hover {
    background: var(--red);
}

.team-info {
    padding-top: 18px;
}

.team-info h3 {
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 500;
    letter-spacing: -0.02em;
}

.team-info p {
    color: var(--muted);
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-top: 4px;
}

/* ---------- testimonials ---------- */

.testimonial-top {
    display: grid;
    grid-template-columns: minmax(0, 0.7fr) minmax(0, 1fr);
    gap: 40px;
    align-items: end;
    margin-bottom: clamp(40px, 5vw, 70px);
}

.rating-block {
    display: flex;
    align-items: center;
    gap: 26px;
    flex-wrap: wrap;
}

.rating-score {
    font-family: var(--font-display);
    font-size: clamp(2.6rem, 5vw, 4.6rem);
    line-height: 1;
    font-weight: 300;
    letter-spacing: -0.04em;
}

.rating-score span {
    font-size: 0.32em;
    color: var(--muted);
}

.rating-meta p {
    font-size: 0.82rem;
    color: var(--muted-2);
    max-width: 24ch;
}

.stars {
    color: var(--red);
    letter-spacing: 3px;
    font-size: 0.9rem;
    margin-bottom: 6px;
}

.trusted-marquee {
    overflow: hidden;
    border-block: 1px solid var(--line);
    padding-block: 18px;
    margin-bottom: clamp(36px, 5vw, 64px);
}

.trusted-track {
    display: flex;
    width: max-content;
    animation: marquee 26s linear infinite;
}

.trusted-track span {
    display: inline-flex;
    align-items: center;
    gap: 18px;
    padding-inline: 24px;
    font-size: 0.78rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--muted-2);
    white-space: nowrap;
}

.trusted-track span::after {
    content: "";
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--red);
}

.testimonial-slider {
    position: relative;
    overflow: hidden;
}

.testimonial-track {
    display: flex;
    gap: 24px;
    transition: transform 0.7s var(--ease);
    will-change: transform;
}

.testimonial-card {
    flex: 0 0 calc((100% - 48px) / 3);
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: clamp(24px, 3vw, 38px);
    display: flex;
    flex-direction: column;
    gap: 22px;
    min-height: 280px;
}

.testimonial-quote-mark {
    font-family: var(--font-display);
    font-size: 3rem;
    line-height: 0.6;
    color: var(--red);
}

.testimonial-quote {
    font-size: 0.98rem;
    line-height: 1.75;
    color: var(--muted-2);
    flex: 1;
}

.testimonial-person {
    display: flex;
    align-items: center;
    gap: 14px;
    border-top: 1px solid var(--line);
    padding-top: 20px;
}

.testimonial-person img {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
}

.testimonial-person h4 {
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 500;
}

.testimonial-person p {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--muted);
}

.slider-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 28px;
    justify-content: flex-end;
}

.slider-btn {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: 1px solid var(--line-strong);
    display: grid;
    place-items: center;
    transition: background 0.3s ease, border-color 0.3s ease;
}

.slider-btn:hover:not(:disabled) {
    background: var(--red);
    border-color: var(--red);
}

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

/* ---------- blog / insights ---------- */

.insight-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(22px, 3vw, 40px);
}

.insight-card {
    display: block;
    border-top: 1px solid var(--line);
    padding-top: 22px;
}

.insight-media {
    aspect-ratio: 16 / 10;
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--bg-elev);
    margin-bottom: 20px;
}

.insight-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s var(--ease);
}

.insight-card:hover .insight-media img {
    transform: scale(1.06);
}

.insight-cat {
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--red);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.insight-card h3 {
    font-family: var(--font-display);
    font-size: clamp(1.15rem, 1.8vw, 1.5rem);
    font-weight: 400;
    letter-spacing: -0.02em;
    text-transform: uppercase;
    transition: color 0.3s ease;
}

.insight-card:hover h3 {
    color: var(--red-bright);
}

.insight-meta {
    margin-top: 14px;
    font-size: 0.72rem;
    color: var(--muted);
    letter-spacing: 0.04em;
}

/* ---------- page hero (inner pages) ---------- */

.page-hero {
    padding-top: calc(var(--header-h) + clamp(70px, 10vw, 130px));
    padding-bottom: clamp(50px, 7vw, 90px);
    border-bottom: 1px solid var(--line);
    position: relative;
    overflow: hidden;
}

.page-hero::after {
    content: "";
    position: absolute;
    right: -10%;
    top: 10%;
    width: 55%;
    height: 120%;
    background: radial-gradient(ellipse at center, rgba(179, 0, 27, 0.14), transparent 65%);
    pointer-events: none;
}

.page-hero .display {
    font-size: clamp(3rem, 8vw, 8rem);
    line-height: 0.98;
    text-transform: uppercase;
    font-weight: 500;
    color: var(--text);
    letter-spacing: -0.05em;
    margin-bottom: 26px;
}

.page-hero .display .muted {
    color: var(--muted);
}

.page-hero p {
    max-width: 52ch;
    color: var(--muted-2);
    font-size: clamp(1rem, 1.5vw, 1.2rem);
    line-height: 1.7;
}

.page-hero .breadcrumb {
    display: flex;
    gap: 10px;
    align-items: center;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--muted);
    margin-bottom: 22px;
}

.page-hero .breadcrumb a:hover {
    color: var(--red-bright);
}

/* ---------- CTA / footer ---------- */

.site-footer {
    position: relative;
    z-index: 2;
    border-top: 1px solid var(--line);
    background: var(--bg-soft);
    overflow: hidden;
}

.footer-cta {
    padding-block: clamp(70px, 9vw, 130px);
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
    gap: clamp(36px, 6vw, 100px);
    align-items: end;
}

.footer-cta .display {
    font-size: clamp(2.2rem, 4.4vw, 4rem);
    color: var(--text);
    text-transform: capitalize;
    font-weight: 300;
    letter-spacing: -0.04em;
    max-width: 20ch;
}

.footer-cta .display em {
    font-style: normal;
    color: var(--red);
}

.footer-contact {
    display: grid;
    gap: 20px;
    padding-bottom: 8px;
}

.footer-contact .eyebrow {
    color: var(--muted);
}

.footer-mail {
    font-family: var(--font-display);
    font-size: clamp(1.2rem, 2.2vw, 1.9rem);
    letter-spacing: -0.02em;
    color: var(--text);
    border-bottom: 1px solid var(--line-strong);
    padding-bottom: 8px;
    width: fit-content;
    transition: color 0.3s ease, border-color 0.3s ease;
}

.footer-mail:hover {
    color: var(--red-bright);
    border-color: var(--red-bright);
}

.footer-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 18px 28px;
    padding-block: 30px;
    border-top: 1px solid var(--line);
    font-size: 0.86rem;
    color: var(--muted-2);
}

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

.footer-wordmark {
    font-family: var(--font-display);
    font-weight: 500;
    font-size: clamp(3.6rem, 16vw, 15rem);
    line-height: 0.82;
    letter-spacing: -0.06em;
    text-transform: uppercase;
    text-align: center;
    white-space: nowrap;
    color: transparent;
    -webkit-text-stroke: 1px rgba(255, 255, 255, 0.22);
    padding-block: 20px 10px;
    user-select: none;
    transition: -webkit-text-stroke-color 0.4s ease, color 0.4s ease;
}

.footer-wordmark:hover {
    color: rgba(179, 0, 27, 0.08);
    -webkit-text-stroke-color: rgba(179, 0, 27, 0.55);
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    padding-block: 24px;
    border-top: 1px solid var(--line);
    font-size: 0.75rem;
    color: var(--muted);
    flex-wrap: wrap;
}

.footer-socials {
    display: flex;
    gap: 20px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 0.72rem;
}

.footer-socials a:hover {
    color: var(--red-bright);
}

/* ---------- forms ---------- */

.contact-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
    gap: clamp(40px, 6vw, 100px);
    align-items: start;
}

.contact-form {
    display: grid;
    gap: 18px;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.field {
    display: grid;
    gap: 8px;
}

.field label {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--muted-2);
}

.field input,
.field select,
.field textarea {
    width: 100%;
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 15px 16px;
    color: var(--text);
    font-family: var(--font-body);
    font-size: 0.94rem;
    transition: border-color 0.3s ease, background 0.3s ease, box-shadow 0.3s ease;
}

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

.field-captcha {
    gap: 10px;
}

/* Keep the Turnstile widget compact instead of stretching across the form. */
.turnstile-wrap {
    width: 100%;
    max-width: 320px;
}

.turnstile-wrap .cf-turnstile,
.turnstile-wrap iframe {
    max-width: 100%;
}

.captcha-row {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}

.captcha-question {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 54px;
    padding: 0 18px;
    border-radius: 12px;
    border: 1px dashed var(--line-strong);
    background: var(--bg-elev);
    color: var(--text);
    font-weight: 600;
    letter-spacing: 0.03em;
    user-select: none;
}

.captcha-row input {
    flex: 1 1 160px;
    min-width: 0;
}

.field-hint {
    font-size: 0.78rem;
    line-height: 1.5;
    color: var(--muted);
}

.field input::placeholder,
.field textarea::placeholder {
    color: rgba(255, 255, 255, 0.28);
}

.field input:focus,
.field select:focus,
.field textarea:focus {
    outline: none;
    border-color: var(--red);
    background: var(--bg-elev);
    box-shadow: 0 0 0 4px rgba(179, 0, 27, 0.1);
}

.field select {
    /* Keep the native dropdown popup in the same colour scheme as the field
       so option text never renders white-on-white. */
    color-scheme: dark;
    cursor: pointer;
}

.field select option {
    background-color: var(--bg-elev);
    color: var(--text);
}

.field select option:checked,
.field select option:hover,
.field select option:focus {
    background-color: var(--red);
    color: #ffffff;
}

.honeypot {
    position: absolute !important;
    left: -9999px !important;
    width: 1px !important;
    height: 1px !important;
    opacity: 0 !important;
}

.form-message {
    padding: 16px 18px;
    border-radius: 12px;
    font-size: 0.9rem;
    border: 1px solid var(--line);
    scroll-margin-top: calc(var(--header-h) + 24px);
}

.form-message:focus {
    outline: none;
}

.form-message:focus-visible {
    outline: 2px solid var(--red);
    outline-offset: 3px;
}

.form-message.is-error {
    background: rgba(179, 0, 27, 0.08);
    border-color: rgba(179, 0, 27, 0.4);
    color: #ffb3ba;
}

.form-message.is-success {
    background: rgba(34, 197, 94, 0.08);
    border-color: rgba(34, 197, 94, 0.4);
    color: #a7f3c0;
}

.hidden {
    display: none !important;
}

.contact-aside {
    display: grid;
    gap: 26px;
    padding: clamp(26px, 3vw, 40px);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--bg-soft);
}

.contact-aside h3 {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 400;
    letter-spacing: -0.02em;
}

.contact-detail {
    display: grid;
    gap: 6px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--line);
}

.contact-detail:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.contact-detail span {
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--muted);
}

.contact-detail a,
.contact-detail p {
    font-size: 0.95rem;
    color: var(--text);
    line-height: 1.6;
}

.contact-detail a:hover {
    color: var(--red-bright);
}

/* ---------- project filters / extra ---------- */

.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: clamp(34px, 5vw, 60px);
}

.filter-btn {
    padding: 10px 18px;
    border-radius: 999px;
    border: 1px solid var(--line-strong);
    color: var(--muted-2);
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    transition: background 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

.filter-btn:hover {
    border-color: var(--red);
    color: var(--text);
}

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

.project-item.is-hidden {
    display: none;
}

.value-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1px;
    background: var(--line);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
}

.value-card {
    background: var(--bg);
    padding: clamp(24px, 3vw, 40px);
    min-height: 240px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    transition: background 0.4s ease;
}

.value-card:hover {
    background: var(--bg-elev);
}

.value-card .value-index {
    font-family: var(--font-display);
    color: var(--red);
    font-size: 0.9rem;
}

.value-card h3 {
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 400;
    letter-spacing: -0.02em;
}

.value-card p {
    color: var(--muted-2);
    font-size: 0.86rem;
    line-height: 1.7;
    margin-top: auto;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1px;
    background: var(--line);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
}

.feature-card {
    background: var(--bg);
    padding: clamp(24px, 3vw, 38px);
    min-height: 210px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: background 0.4s ease;
}

.feature-card:hover {
    background: var(--bg-elev);
}

.feature-card .value-index {
    font-family: var(--font-display);
    color: var(--red);
    font-size: 0.9rem;
}

.feature-card h3 {
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 400;
    letter-spacing: -0.02em;
}

.feature-card p {
    color: var(--muted-2);
    font-size: 0.86rem;
    line-height: 1.7;
    margin-top: auto;
}

.page-hero .hero-actions {
    margin-top: 30px;
}

.section-light .feature-card {
    background: var(--bg);
}

.section-light .feature-card:hover {
    background: var(--bg-elev);
}

.split-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(24px, 4vw, 60px);
}

.split-card {
    border-top: 1px solid var(--line);
    padding-top: 26px;
}

.split-card h3 {
    font-family: var(--font-display);
    font-size: clamp(1.6rem, 2.8vw, 2.4rem);
    font-weight: 300;
    letter-spacing: -0.03em;
    margin-bottom: 14px;
}

.split-card p {
    color: var(--muted-2);
    line-height: 1.8;
}

.timeline {
    position: relative;
    display: grid;
    gap: 0;
    border-top: 1px solid var(--line);
}

.timeline-item {
    display: grid;
    grid-template-columns: 130px minmax(0, 0.7fr) minmax(0, 1fr);
    gap: clamp(20px, 4vw, 60px);
    padding: clamp(24px, 3vw, 38px) 0;
    border-bottom: 1px solid var(--line);
    align-items: start;
}

.timeline-year {
    font-family: var(--font-display);
    font-size: 1.1rem;
    color: var(--red);
}

.timeline-item h3 {
    font-family: var(--font-display);
    font-size: 1.35rem;
    font-weight: 400;
    letter-spacing: -0.02em;
}

.timeline-item p {
    color: var(--muted-2);
    font-size: 0.9rem;
    line-height: 1.75;
}

.cta-strip {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: clamp(36px, 5vw, 70px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
    background:
        radial-gradient(ellipse at 0% 50%, rgba(179, 0, 27, 0.16), transparent 55%),
        var(--bg-soft);
    flex-wrap: wrap;
}

.cta-strip h2 {
    font-family: var(--font-display);
    font-size: clamp(1.8rem, 3.4vw, 3.2rem);
    font-weight: 300;
    letter-spacing: -0.035em;
    line-height: 1.1;
    max-width: 20ch;
}

/* ---------- 404 ---------- */

.error-page {
    min-height: 100svh;
    display: grid;
    place-items: center;
    text-align: center;
    padding: calc(var(--header-h) + 40px) 20px 80px;
    position: relative;
}

.error-code {
    font-family: var(--font-display);
    font-size: clamp(8rem, 28vw, 24rem);
    line-height: 0.8;
    font-weight: 600;
    letter-spacing: -0.06em;
    color: transparent;
    -webkit-text-stroke: 1px rgba(255, 255, 255, 0.2);
    position: relative;
}

.error-code span {
    color: var(--red);
    -webkit-text-stroke: 0;
}

.error-page h1 {
    font-family: var(--font-display);
    font-size: clamp(1.6rem, 3vw, 2.4rem);
    font-weight: 300;
    letter-spacing: -0.03em;
    margin-top: 10px;
}

.error-page p {
    color: var(--muted-2);
    max-width: 46ch;
    margin: 14px auto 30px;
}

/* ---------- utilities ---------- */

[id] {
    scroll-margin-top: calc(var(--header-h) + 24px);
}

.skip-link {
    position: fixed;
    top: 12px;
    left: 12px;
    z-index: 400;
    padding: 12px 20px;
    border-radius: 999px;
    background: var(--red);
    color: #fff;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    transform: translateY(-160%);
    transition: transform 0.3s var(--ease);
}

.skip-link:focus {
    transform: translateY(0);
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    align-items: center;
}

.contact-map iframe {
    width: 100%;
    border: 0;
    border-radius: 12px;
    display: block;
    filter: grayscale(1) contrast(1.05);
    opacity: 0.85;
}

/* ---------- reveal states ---------- */

.js [data-split] {
    opacity: 0;
}

html:not(.gsap-ready) [data-split],
.no-js [data-split] {
    opacity: 1 !important;
}

.split-word {
    will-change: transform;
}

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

.js [data-reveal="left"] {
    transform: translateX(-54px);
}

.js [data-reveal="right"] {
    transform: translateX(54px);
}

.js [data-reveal="scale"] {
    transform: scale(0.94);
}

.js [data-reveal].is-visible {
    opacity: 1;
    transform: none;
}

/* CSS-only fallback if GSAP fails to load */
html:not(.gsap-ready) [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
}

.no-js [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
}

/* ---------- custom cursor ---------- */

.cursor-dot,
.cursor-ring {
    position: fixed;
    top: 0;
    left: 0;
    pointer-events: none;
    z-index: 200;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    opacity: 0;
}

.cursor-dot {
    width: 6px;
    height: 6px;
    background: var(--red-bright);
}

.cursor-ring {
    width: 38px;
    height: 38px;
    border: 1px solid rgba(179, 0, 27, 0.5);
    transition: width 0.3s var(--ease), height 0.3s var(--ease), border-color 0.3s ease, opacity 0.3s ease;
}

body.cursor-active .cursor-dot,
body.cursor-active .cursor-ring {
    opacity: 1;
}

body.cursor-hover .cursor-ring {
    width: 66px;
    height: 66px;
    border-color: var(--red);
}

@media (hover: none), (pointer: coarse) {
    .cursor-dot,
    .cursor-ring {
        display: none;
    }
}

/* ---------- reusable social icons ---------- */

.social-ring {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 1px solid var(--line-strong);
    display: inline-grid;
    place-items: center;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    transition: background 0.3s ease, border-color 0.3s ease, transform 0.3s var(--ease);
}

.social-ring:hover {
    background: var(--red);
    border-color: var(--red);
    transform: translateY(-3px);
}

/* ---------- responsive ---------- */

@media (max-width: 1100px) {
    .section-head,
    .section-head.right {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    .section-head.right .display {
        grid-column: 1;
        grid-row: 2;
        justify-self: start;
        text-align: left;
    }
    .section-head.right .section-label {
        grid-column: 1;
        grid-row: 1;
    }
    .hero-grid {
        grid-template-columns: 1fr;
        gap: 44px;
    }
    .hero-badge-wrap {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }
    .hero-side-note {
        max-width: 260px;
    }
    .who-grid,
    .process-layout,
    .contact-layout,
    .footer-cta {
        grid-template-columns: 1fr;
    }
    .process-sticky {
        position: static;
    }
    .team-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .value-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .testimonial-card {
        flex-basis: calc((100% - 24px) / 2);
    }
}

@media (max-width: 900px) {
    .feature-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .hero-tags {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .hero-tags li {
        border-left: 0;
        padding-left: 0;
        border-top: 1px solid var(--line);
        padding-top: 16px;
        margin-top: 16px;
    }
    .hero-tags li:nth-child(-n + 2) {
        border-top: 0;
        margin-top: 0;
    }
    .service-row {
        grid-template-columns: 56px minmax(0, 1fr) 46px;
        gap: 16px;
    }
    .service-tags,
    .service-desc {
        grid-column: 2 / -1;
        padding-top: 4px;
    }
    .service-arrow {
        grid-column: 3;
        grid-row: 1;
    }
    .project-grid {
        grid-template-columns: 1fr;
    }
    .insight-grid {
        grid-template-columns: 1fr;
    }
    .testimonial-top {
        grid-template-columns: 1fr;
        gap: 22px;
    }
    .testimonial-card {
        flex-basis: 100%;
    }
    .timeline-item {
        grid-template-columns: 90px 1fr;
    }
    .timeline-item p {
        grid-column: 2;
    }
    .split-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    :root {
        --header-h: 74px;
    }
    .header-cta {
        display: none;
    }
    .brand {
        font-size: 1rem;
    }
    .brand-mark {
        width: 36px;
        height: 36px;
    }
    .brand-logo {
        width: auto;
        height: 40px;
    }
    .menu-toggle {
        width: 46px;
        height: 46px;
    }
    .menu-toggle span:nth-child(1) { top: 18px; }
    .menu-toggle span:nth-child(2) { top: 25px; }
    .menu-toggle span:nth-child(3) { top: 32px; left: 18px; }
    body.menu-open .menu-toggle span:nth-child(1),
    body.menu-open .menu-toggle span:nth-child(3) { top: 25px; }
    .hero-badge-wrap {
        flex-direction: column;
        align-items: flex-start;
    }
    .hero-side-note {
        display: none;
    }
    .hero-title {
        font-size: clamp(2.8rem, 13vw, 4.6rem);
    }
    .hero-tags {
        grid-template-columns: 1fr;
    }
    .hero-tags li:nth-child(2) {
        border-top: 1px solid var(--line);
        margin-top: 16px;
    }
    .stats-grid {
        grid-template-columns: 1fr;
    }
    .project-card {
        gap: 18px;
        padding: 24px 20px;
    }
    .project-title {
        font-size: clamp(1.2rem, 6vw, 1.55rem);
    }
    .project-desc {
        font-size: 0.82rem;
    }
    .project-domain {
        font-size: 0.64rem;
    }
    .stat {
        border-left: 0;
        border-top: 1px solid var(--line);
        padding: 26px 0;
    }
    .stat:first-child {
        border-top: 0;
    }
    .team-grid {
        grid-template-columns: 1fr;
    }
    .value-grid,
    .feature-grid {
        grid-template-columns: 1fr;
    }
    .form-row {
        grid-template-columns: 1fr;
    }
    .footer-bottom {
        flex-direction: column;
        align-items: flex-start;
    }
    .footer-wordmark {
        /* Scale the one-line wordmark to the mobile content width so the
           full "RED DEV HUB" stays visible below 640px. */
        font-size: clamp(2rem, 14vw, 5.5rem);
    }
    .slider-controls {
        justify-content: flex-start;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    .js [data-reveal] {
        opacity: 1;
        transform: none;
    }
}
