/* ================================================================
   GREET MARKETING — EDITORIAL / INDUSTRIAL DESIGN SYSTEM
   Typefaces: Barlow Condensed (headings) + Inter (body)
   ================================================================ */

@import url('https://fonts.googleapis.com/css2?family=Barlow+Condensed:ital,wght@0,400;0,600;0,700;0,800;0,900;1,700;1,800&family=Inter:wght@300;400;500;600;700&display=swap');

/* ─── Design Tokens ─── */
:root {
    --paper: #F5F1EB;
    /* warm oatmeal — primary background */
    --paper-alt: #EDE9E0;
    /* slightly darker warm cream */
    --paper-dark: #E2DDD4;
    /* used for alternating section tints */
    --ink: #1A1A18;
    /* charcoal, not pure black */
    --ink-mid: #3D3D38;
    /* medium charcoal */
    --ink-muted: #6A6A62;
    /* muted copy text */
    --rule: #2A2A24;
    /* razor-thin border / divider colour */
    --rule-light: rgba(42, 42, 36, 0.2);
    /* very subtle dividers */
    --accent: #E8440A;
    /* single orange accent — interactive only */
    --accent-hover: #C93608;
    /* darker orange on hover */
    --accent-subtle: #FFF0EB;
    /* very faint orange tint for backgrounds */

    --font-display: 'Barlow Condensed', sans-serif;
    --font-body: 'Inter', sans-serif;
    --header-height: 72px;
    --transition: all 0.28s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    --container-max: 1240px;
}

/* ─── Base Reset ─── */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--paper);
    color: var(--ink);
    font-family: var(--font-body);
    font-size: 1rem;
    line-height: 1.65;
    overflow-x: hidden;
}

/* ─── Custom Scrollbar ─── */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: var(--paper-alt);
}

::-webkit-scrollbar-thumb {
    background: var(--ink-mid);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent);
}

/* ─── Typography Foundation ─── */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-display);
    font-weight: 800;
    line-height: 0.95;
    letter-spacing: -0.03em;
    color: var(--ink);
    text-transform: uppercase;
}

h1 {
    font-size: clamp(3.5rem, 8vw, 7.5rem);
}

h2 {
    font-size: clamp(2.8rem, 6vw, 5.5rem);
}

h3 {
    font-size: clamp(1.8rem, 3.5vw, 2.8rem);
}

h4 {
    font-size: 1.4rem;
    letter-spacing: 0;
}

p {
    color: var(--ink-muted);
    font-size: 0.95rem;
    line-height: 1.7;
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition);
}

strong {
    color: var(--ink);
    font-weight: 600;
}

/* ─── Layout Container ─── */
.container {
    width: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 2rem;
}

/* ─── Sections ─── */
section {
    padding: 8rem 0;
    position: relative;
}

section+section {
    border-top: 1px solid var(--rule-light);
}

.section-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    font-family: var(--font-body);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--ink-muted);
    margin-bottom: 1.5rem;
}

.section-tag::before {
    content: '';
    display: block;
    width: 24px;
    height: 1px;
    background: var(--accent);
    flex-shrink: 0;
}

.section-header {
    max-width: 700px;
    margin: 0 auto 5rem auto;
    text-align: center;
}

.section-header .section-tag {
    justify-content: center;
}

.section-title {
    margin-bottom: 1.5rem;
}

.section-subtitle {
    font-size: 1rem;
    color: var(--ink-muted);
    max-width: 540px;
    margin: 0 auto;
    line-height: 1.7;
}

/* Step number labels */
.step-number {
    font-family: var(--font-display);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    color: var(--ink-muted);
    opacity: 0.6;
}

/* Rotated vertical label */
.vert-label {
    writing-mode: vertical-rl;
    text-orientation: mixed;
    transform: rotate(180deg);
    font-family: var(--font-body);
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--ink-muted);
}

/* ─── Horizontal Rule Divider ─── */
.rule-divider {
    width: 100%;
    height: 1px;
    background: var(--rule-light);
    margin: 2rem 0;
}

/* ─── Buttons ─── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.8rem;
    font-family: var(--font-body);
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    border-radius: 9999px;
    cursor: pointer;
    border: 1.5px solid transparent;
    transition: var(--transition);
    white-space: nowrap;
    position: relative;
    overflow: hidden;
}

.btn::after {
    content: '→';
    font-size: 0.9rem;
    transition: transform 0.22s ease;
    display: inline-block;
}

.btn-primary {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

.btn-primary:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
    color: #fff;
    transform: translateY(-2px);
}

.btn-primary:hover::after {
    transform: translateX(3px);
}

.btn-secondary {
    background: transparent;
    color: var(--ink);
    border-color: var(--rule);
}

.btn-secondary:hover {
    background: var(--ink);
    color: var(--paper);
    border-color: var(--ink);
    transform: translateY(-2px);
}

.btn-secondary:hover::after {
    transform: translateX(3px);
}

/* ─── Header / Navigation ─── */
header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--header-height);
    background: var(--paper);
    border-bottom: 1px solid var(--rule-light);
    z-index: 100;
    display: flex;
    align-items: center;
    transition: border-color 0.3s ease;
}

header.scrolled {
    border-bottom-color: var(--rule);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo-link {
    display: flex;
    align-items: center;
}

.logo-img {
    height: 34px;
    width: auto;
    object-fit: contain;
}

/* Force logo to appear in ink colour on cream background */
.logo-dark {
    filter: brightness(0);
}

nav {
    display: flex;
    align-items: center;
    gap: 2.5rem;
}

nav a {
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--ink-muted);
    position: relative;
    padding: 0.3rem 0;
}

nav a:hover,
nav a.active {
    color: var(--ink);
}

nav a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--accent);
    transition: width 0.25s ease;
}

nav a:hover::after,
nav a.active::after {
    width: 100%;
}

/* Mobile Hamburger */
.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    background: none;
    border: none;
    z-index: 101;
    padding: 5px;
}

.menu-toggle span {
    display: block;
    width: 22px;
    height: 1.5px;
    background-color: var(--ink);
    transition: var(--transition);
}

/* ─── Scroll Reveal Animations ─── */
.js-reveal {
    opacity: 0;
    transform: translateY(32px);
    transition: opacity 0.65s ease, transform 0.65s ease;
}

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

.js-reveal-delay-1 {
    transition-delay: 0.1s;
}

.js-reveal-delay-2 {
    transition-delay: 0.2s;
}

.js-reveal-delay-3 {
    transition-delay: 0.3s;
}

.js-reveal-delay-4 {
    transition-delay: 0.4s;
}

/* ─── Hero Section ─── */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: var(--header-height);
    border-bottom: 1px solid var(--rule-light);
    overflow: hidden;
    position: relative;
}

.hero-layout {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 0;
    align-items: stretch;
    width: 100%;
}

.hero-content {
    padding: 5rem 2rem 5rem 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.hero-eyebrow {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

.hero-eyebrow-line {
    width: 40px;
    height: 1px;
    background: var(--accent);
}

.hero-eyebrow-text {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--ink-muted);
}

.hero-title {
    font-size: clamp(4rem, 10vw, 9rem);
    line-height: 0.9;
    letter-spacing: -0.04em;
    margin-bottom: 2.5rem;
}

.hero-title .accent-word {
    color: var(--accent);
}

.hero-subtitle {
    font-size: 1rem;
    color: var(--ink-muted);
    max-width: 440px;
    line-height: 1.7;
    margin-bottom: 3rem;
    font-weight: 400;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
    flex-wrap: wrap;
}

/* Side strip with rotated label */
.hero-side-strip {
    width: 60px;
    border-left: 1px solid var(--rule-light);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    padding: 6rem 0;
}

.hero-stat-mini {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.3rem;
}

.hero-stat-mini-num {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    color: var(--ink);
    line-height: 1;
}

.hero-stat-mini-label {
    font-size: 0.6rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ink-muted);
    text-align: center;
}

/* ─── Clients Band ─── */
.clients-band {
    padding: 3.5rem 0;
    background: var(--paper-alt);
    border-top: 1px solid var(--rule-light);
    border-bottom: 1px solid var(--rule-light);
    overflow: hidden;
}

.clients-band-label {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--ink-muted);
    text-align: center;
    margin-bottom: 2.5rem;
}

.logo-carousel {
    display: flex;
    justify-content: space-around;
    align-items: center;
    flex-wrap: wrap;
    gap: 2.5rem;
}

.client-logo-img {
    height: 22px;
    opacity: 0.4;
    transition: opacity 0.25s ease;
    filter: brightness(0);
    object-fit: contain;
}

.client-logo-img:hover {
    opacity: 0.75;
}

.monochrome-logo {
    filter: grayscale(1) brightness(0) !important;
}

/* ─── Stats Strip ─── */
.stats-strip {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    border-left: 1px solid var(--rule-light);
}

.stat-cell {
    padding: 3.5rem 2rem;
    border-right: 1px solid var(--rule-light);
    border-top: 1px solid var(--rule-light);
    border-bottom: 1px solid var(--rule-light);
    text-align: center;
    transition: background 0.25s ease;
}

.stat-cell:hover {
    background: var(--paper-alt);
}

.stat-number {
    font-family: var(--font-display);
    font-size: clamp(2.5rem, 4vw, 4rem);
    font-weight: 900;
    color: var(--ink);
    line-height: 1;
    margin-bottom: 0.6rem;
}

.stat-number-static {
    font-family: var(--font-display);
    font-size: 4rem;
    font-weight: 900;
    color: var(--ink);
    line-height: 1;
}

.stat-label {
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--ink);
    margin-bottom: 0.3rem;
}

.stat-subtext {
    font-size: 0.72rem;
    color: var(--ink-muted);
}

/* ─── Services List ─── */
.services-list {
    margin-top: 1rem;
}

.service-row {
    display: grid;
    grid-template-columns: 80px 1fr auto;
    gap: 2rem;
    align-items: start;
    padding: 3rem 0;
    border-bottom: 1px solid var(--rule-light);
    transition: background 0.25s ease;
    cursor: default;
}

.service-row:first-child {
    border-top: 1px solid var(--rule-light);
}

.service-row:hover {
    background: var(--paper-alt);
    margin: 0 -2rem;
    padding: 3rem 2rem;
}

.service-num {
    font-family: var(--font-display);
    font-size: 3.5rem;
    font-weight: 900;
    letter-spacing: -0.04em;
    color: var(--rule-light);
    line-height: 1;
    transition: color 0.25s ease;
}

.service-row:hover .service-num {
    color: var(--accent);
}

.service-content h3 {
    margin-bottom: 0.8rem;
    font-size: clamp(1.6rem, 3vw, 2.4rem);
}

.service-content p {
    max-width: 520px;
    font-size: 0.9rem;
}

.service-tag-list {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.4rem;
    padding-top: 0.4rem;
}

.service-tag {
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--ink-muted);
    padding: 0.25rem 0.7rem;
    border: 1px solid var(--rule-light);
    border-radius: 9999px;
}

/* ─── Card Grid (generic) ─── */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 0;
    border: 1px solid var(--rule-light);
}

.card-item {
    padding: 3rem 2.5rem;
    border-right: 1px solid var(--rule-light);
    border-bottom: 1px solid var(--rule-light);
    transition: background 0.25s ease;
    position: relative;
}

.card-item:hover {
    background: var(--paper-alt);
}

.card-item:nth-child(3n) {
    border-right: none;
}

.card-num {
    font-family: var(--font-display);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    color: var(--ink-muted);
    margin-bottom: 1.5rem;
    opacity: 0.5;
}

.card-icon-wrapper {
    width: 44px;
    height: 44px;
    border: 1px solid var(--rule-light);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    color: var(--ink-mid);
    transition: var(--transition);
}

.card-item:hover .card-icon-wrapper {
    border-color: var(--accent);
    color: var(--accent);
}

.card-item h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    line-height: 1;
}

.card-item p {
    font-size: 0.88rem;
}

/* Legacy gradient-card support — map to editorial card */
.gradient-card {
    background: var(--paper-alt);
    border: 1px solid var(--rule-light);
    padding: 2.5rem;
    transition: background 0.25s ease;
    position: relative;
}

.gradient-card:hover {
    background: var(--paper-dark);
}

/* ─── Tech Tags ─── */
.tech-tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 1.5rem 0;
}

.tech-tag {
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    padding: 0.25rem 0.75rem;
    border: 1px solid var(--rule-light);
    color: var(--ink-muted);
}

/* ─── Featured Project ─── */
.featured-project {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    align-items: start;
    border: 1px solid var(--rule-light);
    margin-bottom: 4rem;
}

.project-gallery {
    position: relative;
    overflow: hidden;
    aspect-ratio: 4/3;
    border-right: 1px solid var(--rule-light);
    background: var(--paper-alt);
    border-radius: 12px;
}

.slideshow-container {
    position: relative;
    width: 100%;
    height: 100%;
    padding: 2.5rem;
    display: flex;
    justify-content: center;
    align-items: center;
}

.slide {
    display: none;
    position: absolute;
    top: 2.5rem;
    bottom: 2.5rem;
    left: 2.5rem;
    right: 2.5rem;
    justify-content: center;
    align-items: center;
}

.slide.slide-active {
    display: flex;
}

.slide img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 8px;
    border: 1px solid var(--rule-light);
}

.slide-active {
    display: block;
    animation: fadeEffect 0.7s ease;
}

@keyframes fadeEffect {
    from {
        opacity: 0.3;
    }

    to {
        opacity: 1;
    }
}

.carousel-dots {
    position: absolute;
    bottom: 1.2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 0.4rem;
    z-index: 10;
}

.dot {
    width: 6px;
    height: 6px;
    background: rgba(26, 26, 24, 0.3);
    cursor: pointer;
    transition: var(--transition);
}

.dot.active {
    background: var(--accent);
    width: 14px;
}

.project-details {
    padding: 3.5rem 3rem;
}

.project-details h3 {
    margin: 1rem 0;
}

.client-quote {
    margin-top: 2rem;
    padding: 1.5rem;
    border-left: 2px solid var(--accent);
    background: var(--paper-alt);
    font-style: italic;
    color: var(--ink-muted);
    font-size: 0.9rem;
}

.quote-author {
    display: block;
    margin-top: 0.5rem;
    font-weight: 700;
    font-style: normal;
    color: var(--ink);
    font-size: 0.78rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

/* Faded teaser project */
.faded-project {
    position: relative;
    max-height: 420px;
    overflow: hidden;
    border: 1px solid var(--rule-light);
    padding: 3rem;
    background: var(--paper-alt);
    margin-bottom: 4rem;
}

.faded-project-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 65%;
    background: linear-gradient(to top, var(--paper-alt) 25%, rgba(237, 233, 224, 0.9) 55%, rgba(237, 233, 224, 0) 100%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: center;
    padding-bottom: 2.5rem;
    z-index: 3;
    text-align: center;
}

/* ─── Values Grid ─── */
.values-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0;
    border: 1px solid var(--rule-light);
    margin-top: 2rem;
}

.value-card {
    padding: 3.5rem 3rem;
    border-right: 1px solid var(--rule-light);
    border-bottom: 1px solid var(--rule-light);
    transition: background 0.25s ease;
}

.value-card:hover {
    background: var(--paper-alt);
}

.value-card:nth-child(2n) {
    border-right: none;
}

.value-card:nth-child(n+3) {
    border-bottom: none;
}

.value-num {
    font-family: var(--font-display);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 1rem;
}

.value-card h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

/* ─── Testimonials ─── */
.quotes-ticker {
    max-width: 860px;
    margin: 0 auto;
    text-align: center;
    position: relative;
    min-height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ticker-item {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.7s ease, transform 0.7s ease;
    pointer-events: none;
}

.ticker-item.active {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
    position: absolute;
}

.ticker-quote {
    font-family: var(--font-display);
    font-size: clamp(1.6rem, 3.5vw, 2.8rem);
    font-weight: 700;
    font-style: italic;
    color: var(--ink);
    line-height: 1.15;
    letter-spacing: -0.02em;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
}

.ticker-author {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--accent);
}

/* ─── CTA Banner ─── */
#cta-banner {
    background: var(--ink);
    color: var(--paper);
    text-align: center;
    padding: 8rem 0;
    border-top: none !important;
}

#cta-banner h2 {
    color: var(--paper);
    font-size: clamp(3rem, 7vw, 6.5rem);
    margin-bottom: 1.5rem;
}

#cta-banner p {
    color: rgba(245, 241, 235, 0.6);
    margin-bottom: 2.5rem;
    font-size: 1rem;
}

#cta-banner .btn-primary {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

#cta-banner .btn-primary:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
}

#cta-banner .btn-secondary {
    background: transparent;
    color: var(--paper);
    border-color: rgba(245, 241, 235, 0.3);
}

#cta-banner .btn-secondary:hover {
    background: var(--paper);
    color: var(--ink);
    border-color: var(--paper);
}

/* ─── Footer ─── */
footer {
    background: var(--paper-alt);
    border-top: 1px solid var(--rule-light);
    padding: 5rem 0 2.5rem 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr repeat(3, 1fr);
    gap: 3rem;
    margin-bottom: 4rem;
    padding-bottom: 4rem;
    border-bottom: 1px solid var(--rule-light);
}

.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.footer-logo {
    height: 38px;
    width: auto;
    align-self: flex-start;
}

.footer-brand p {
    font-size: 0.88rem;
    max-width: 260px;
    color: var(--ink-muted);
}

.footer-socials {
    display: flex;
    gap: 0.75rem;
}

.social-icon-btn {
    width: 34px;
    height: 34px;
    border: 1px solid var(--rule-light);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--ink-muted);
    transition: var(--transition);
}

.social-icon-btn:hover {
    color: var(--accent);
    border-color: var(--accent);
}

.footer-col h4 {
    font-family: var(--font-body);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--ink);
    margin-bottom: 1.5rem;
}

.footer-col ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.footer-col ul a {
    font-size: 0.88rem;
    color: var(--ink-muted);
    transition: var(--transition);
}

.footer-col ul a:hover {
    color: var(--accent);
}

.footer-contact-info {
    font-size: 0.88rem;
    color: var(--ink-muted);
}

.footer-contact-info a {
    color: var(--accent) !important;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.78rem;
    color: var(--ink-muted);
}

.footer-legal-links {
    display: flex;
    gap: 2rem;
}

.footer-legal-links a:hover {
    color: var(--accent);
}

/* ─── AI Chatbot ─── */
#chatbot-container {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 1000;
    font-family: var(--font-body);
}

#chatbot-trigger {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--ink);
    border: 1.5px solid var(--ink);
    box-shadow: 0 4px 20px rgba(26, 26, 24, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    color: var(--paper);
}

#chatbot-trigger:hover {
    background: var(--accent);
    border-color: var(--accent);
    transform: scale(1.06) translateY(-2px);
}

#chatbot-trigger svg {
    width: 24px;
    height: 24px;
    transition: var(--transition);
}

#chatbot-trigger.active svg {
    transform: rotate(90deg);
}

#chatbot-window {
    position: absolute;
    bottom: 72px;
    right: 0;
    width: 370px;
    height: 510px;
    background: var(--paper);
    border: 1px solid var(--rule);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transform: translateY(16px) scale(0.95);
    opacity: 0;
    pointer-events: none;
    transition: var(--transition);
    box-shadow: 0 12px 48px rgba(26, 26, 24, 0.18);
}

#chatbot-window.active {
    transform: translateY(0) scale(1);
    opacity: 1;
    pointer-events: auto;
}

.chatbot-header {
    padding: 1rem 1.2rem;
    border-bottom: 1px solid var(--rule-light);
    display: flex;
    align-items: center;
    gap: 0.8rem;
    background: var(--paper-alt);
}

.chatbot-avatar {
    width: 30px;
    height: 30px;
    border: 1px solid var(--rule-light);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--ink-mid);
}

.chatbot-status {
    flex: 1;
}

.chatbot-status h4 {
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--ink);
    line-height: 1.2;
}

.chatbot-status span {
    font-size: 0.7rem;
    color: var(--accent);
    display: flex;
    align-items: center;
    gap: 0.25rem;
    font-weight: 500;
}

.chatbot-status span::before {
    content: '';
    width: 5px;
    height: 5px;
    background: var(--accent);
    border-radius: 50%;
    display: inline-block;
}

.chatbot-messages {
    flex: 1;
    padding: 1.2rem;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
}

.chat-message {
    max-width: 82%;
    padding: 0.75rem 1rem;
    font-size: 0.88rem;
    line-height: 1.5;
}

.chat-message.bot {
    background: var(--paper-alt);
    border: 1px solid var(--rule-light);
    color: var(--ink);
    align-self: flex-start;
}

.chat-message.user {
    background: var(--ink);
    color: var(--paper);
    font-weight: 500;
    align-self: flex-end;
}

.typing-indicator {
    display: flex;
    gap: 4px;
    padding: 0.5rem 0.75rem;
    background: var(--paper-alt);
    border: 1px solid var(--rule-light);
    align-self: flex-start;
}

.typing-indicator span {
    width: 5px;
    height: 5px;
    background: var(--ink-muted);
    border-radius: 50%;
    animation: typing 1s infinite alternate;
}

.typing-indicator span:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-indicator span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typing {
    0% {
        transform: translateY(0);
        opacity: 0.3;
    }

    100% {
        transform: translateY(-4px);
        opacity: 1;
    }
}

.chatbot-input-area {
    padding: 0.9rem 1rem;
    border-top: 1px solid var(--rule-light);
    background: var(--paper-alt);
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.chatbot-input-row {
    display: flex;
    gap: 0.5rem;
    width: 100%;
}

.chatbot-turnstile-wrapper {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0.4rem;
    border: 1px dashed var(--rule-light);
    background: var(--paper);
}

.chatbot-input {
    flex: 1;
    background: var(--paper);
    border: 1px solid var(--rule-light);
    padding: 0.55rem 0.9rem;
    color: var(--ink);
    font-size: 0.88rem;
    font-family: var(--font-body);
    outline: none;
    transition: border-color 0.25s;
}

.chatbot-input:focus {
    border-color: var(--accent);
}

.chatbot-send-btn {
    width: 34px;
    height: 34px;
    background: var(--ink);
    color: var(--paper);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.chatbot-send-btn:hover {
    background: var(--accent);
}

/* In-chat contact form */
.chat-form-container {
    background: var(--paper-alt);
    border: 1px solid var(--accent);
    padding: 1rem;
    margin-top: 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.chat-form-container h5 {
    font-family: var(--font-body);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--accent);
    border-bottom: 1px solid rgba(232, 68, 10, 0.2);
    padding-bottom: 0.4rem;
}

.chat-form-field {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.chat-form-field label {
    font-size: 0.68rem;
    color: var(--ink-muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.chat-form-field input,
.chat-form-field textarea {
    background: var(--paper);
    border: 1px solid var(--rule-light);
    padding: 0.4rem 0.6rem;
    color: var(--ink);
    font-size: 0.8rem;
    font-family: var(--font-body);
    outline: none;
}

.chat-form-field input:focus,
.chat-form-field textarea:focus {
    border-color: var(--accent);
}

.chat-form-submit {
    background: var(--accent);
    color: #fff;
    font-weight: 700;
    font-size: 0.75rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    border: none;
    padding: 0.5rem;
    cursor: pointer;
    transition: var(--transition);
}

.chat-form-submit:hover {
    background: var(--accent-hover);
}

/* ─── Contact / Form Styles ─── */
.contact-form-layout {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 5rem;
    align-items: flex-start;
}

.contact-info-panel h3 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
}

.contact-details-list {
    margin: 2rem 0;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-detail-item {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.contact-detail-icon {
    width: 38px;
    height: 38px;
    border: 1px solid var(--rule-light);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--ink-mid);
    flex-shrink: 0;
}

.form-card {
    background: var(--paper-alt);
    border: 1px solid var(--rule-light);
    padding: 3rem;
}

.form-group-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
    color: var(--ink-mid);
}

.form-control {
    width: 100%;
    background: var(--paper);
    border: 1px solid var(--rule-light);
    padding: 0.8rem 1rem;
    color: var(--ink);
    font-family: var(--font-body);
    font-size: 0.95rem;
    transition: border-color 0.25s;
    outline: none;
}

.form-control:focus {
    border-color: var(--accent);
}

textarea.form-control {
    min-height: 140px;
    resize: vertical;
}

.turnstile-wrapper {
    margin-bottom: 1.5rem;
}

.alert {
    padding: 0.9rem 1.2rem;
    margin-bottom: 2rem;
    font-size: 0.88rem;
    font-weight: 500;
    border-left: 3px solid;
}

.alert-success {
    background: #f0fdf4;
    border-color: #22c55e;
    color: #166534;
}

.alert-error {
    background: #fef2f2;
    border-color: #ef4444;
    color: #991b1b;
}

.submit-btn-wrapper {
    position: relative;
}

/* ─── Service Section Detail (services page) ─── */
.service-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5rem;
    align-items: center;
    margin-bottom: 8rem;
}

.service-section:nth-child(even)>*:first-child {
    order: 2;
}

.service-section:nth-child(even)>*:last-child {
    order: 1;
}

.service-section:has(.service-graphic[style*="display: none"]) {
    grid-template-columns: 1fr;
}

.service-graphic {
    width: 100%;
    aspect-ratio: 1/1;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--rule-light);
    background: var(--paper-alt);
}

.svg-animation-wrapper {
    width: 80%;
    height: 80%;
    position: relative;
}

.svg-animation-wrapper svg {
    width: 100%;
    height: 100%;
}

/* ─── Responsive ─── */
@media (max-width: 1100px) {
    .stats-strip {
        grid-template-columns: repeat(3, 1fr);
    }

    .stat-cell:nth-child(3n) {
        border-right: none;
    }

    .stat-cell:nth-child(4),
    .stat-cell:nth-child(5),
    .stat-cell:nth-child(6) {
        border-top: none;
    }
}

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

    .hero-side-strip {
        display: none;
    }

    .hero-content {
        padding: 5rem 0 4rem 0;
        text-align: center;
        align-items: center;
    }

    .hero-eyebrow {
        justify-content: center;
    }

    .hero-subtitle {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-actions {
        justify-content: center;
    }

    .featured-project {
        grid-template-columns: 1fr;
    }

    .project-gallery {
        border-right: none;
        border-bottom: 1px solid var(--rule-light);
    }

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

    .value-card {
        border-right: none;
    }

    .footer-grid {
        grid-template-columns: 1.5fr 1fr;
    }

    .contact-form-layout {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .service-section {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .service-section:nth-child(even)>*:first-child,
    .service-section:nth-child(even)>*:last-child {
        order: unset;
    }

    .about-hero-grid {
        grid-template-columns: 1fr !important;
    }

    .about-hero-grid>div:last-child {
        display: none;
    }

    .about-mission-grid {
        grid-template-columns: 1fr !important;
    }
}

@media (max-width: 768px) {
    :root {
        --header-height: 64px;
    }

    h1 {
        font-size: clamp(2.8rem, 10vw, 4.5rem);
    }

    h2 {
        font-size: clamp(2.2rem, 8vw, 3.5rem);
    }

    header {
        background: var(--paper) !important;
        z-index: 200;
    }

    .menu-toggle {
        display: flex;
        z-index: 201;
    }

    nav {
        position: fixed;
        top: 64px;
        left: 0;
        right: 0;
        bottom: 0;
        height: calc(100vh - 64px);
        background: var(--paper);
        border-top: 1px solid var(--rule-light);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 2rem;
        padding: 3rem;
        transform: translateY(-100%);
        opacity: 0;
        pointer-events: none;
        transition: var(--transition);
        z-index: 199;
    }

    nav.active {
        transform: translateY(0);
        opacity: 1;
        pointer-events: auto;
    }

    nav a {
        font-size: 1.1rem;
    }

    .menu-toggle.active span:nth-child(1) {
        transform: translateY(6.5px) rotate(45deg);
    }

    .menu-toggle.active span:nth-child(2) {
        opacity: 0;
    }

    .menu-toggle.active span:nth-child(3) {
        transform: translateY(-6.5px) rotate(-45deg);
    }

    section {
        padding: 5rem 0;
    }

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

    .stat-cell:nth-child(even) {
        border-right: none;
    }

    .service-row {
        grid-template-columns: 50px 1fr;
        gap: 1.2rem;
    }

    .service-tag-list {
        display: none;
    }

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

    .card-item {
        border-right: none;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    #chatbot-container {
        bottom: 1rem;
        right: 1rem;
    }

    #chatbot-window {
        width: calc(100vw - 2rem);
        right: 0;
        bottom: 68px;
        height: 460px;
    }

    .form-group-row {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .form-card {
        padding: 1.5rem;
    }

    .faded-project {
        padding: 1.5rem;
    }

    .faded-project>div {
        grid-template-columns: 1fr !important;
    }

    .ticker-quote {
        font-size: 1.4rem;
    }

    .hero-title {
        font-size: clamp(3rem, 12vw, 5.5rem);
    }
}