/* ========================================
   CUSTOM PROPERTIES
   Palette derived from logo green #77bd43
   ======================================== */
:root {
    --green-500: #77bd43;
    --green-600: #5fa832;
    --green-700: #4a8c28;
    --green-400: #8fcf5a;
    --green-subtle: rgba(119, 189, 67, 0.08);
    --green-glow: rgba(119, 189, 67, 0.18);

    /* Light theme */
    --bg-primary: #FAFAF8;
    --bg-secondary: #F2F1ED;
    --bg-tertiary: #E8E7E2;
    --bg-card: #FFFFFF;
    --text-primary: #1B1B19;
    --text-secondary: #5E5D58;
    --text-tertiary: #8E8C85;
    --accent: var(--green-500);
    --accent-hover: var(--green-600);
    --accent-subtle: var(--green-subtle);
    --accent-glow: var(--green-glow);
    --border: rgba(27, 27, 25, 0.07);
    --border-strong: rgba(27, 27, 25, 0.14);
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.04);
    --shadow-md: 0 4px 24px rgba(0,0,0,0.06);
    --shadow-lg: 0 16px 48px rgba(0,0,0,0.08);

    /* Typography */
    --font-display: 'Fraunces', Georgia, serif;
    --font-body: 'Instrument Sans', -apple-system, sans-serif;

    /* Spacing */
    --space-xs: 0.5rem;
    --space-sm: 1rem;
    --space-md: 1.5rem;
    --space-lg: 3rem;
    --space-xl: 5rem;
    --space-2xl: 8rem;

    --max-width: 1200px;
    --radius: 12px;
    --radius-lg: 20px;
}

[data-theme="dark"] {
    --bg-primary: #111110;
    --bg-secondary: #1A1A18;
    --bg-tertiary: #232320;
    --bg-card: #1A1A18;
    --text-primary: #EDECE7;
    --text-secondary: #A5A39C;
    --text-tertiary: #6E6C66;
    --accent: #8fcf5a;
    --accent-hover: #a3db74;
    --accent-subtle: rgba(143, 207, 90, 0.1);
    --accent-glow: rgba(143, 207, 90, 0.18);
    --border: rgba(237, 236, 231, 0.06);
    --border-strong: rgba(237, 236, 231, 0.12);
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.3);
    --shadow-md: 0 4px 24px rgba(0,0,0,0.35);
    --shadow-lg: 0 16px 48px rgba(0,0,0,0.45);
}

/* ========================================
   RESET & BASE
   ======================================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
body {
    font-family: var(--font-body);
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.65;
    font-size: 17px;
    transition: background 0.4s ease, color 0.4s ease;
    overflow-x: hidden;
}
a { color: var(--accent); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--accent-hover); }
img { max-width: 100%; display: block; }
::selection { background: var(--accent); color: #fff; }

/* ========================================
   SCROLL PROGRESS
   ======================================== */
.scroll-progress {
    position: fixed; top: 0; left: 0; width: 0%;
    height: 2px; background: var(--accent); z-index: 9999;
}

/* ========================================
   LAYOUT
   ======================================== */
.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 clamp(1.5rem, 4vw, 3rem);
}
section { padding: var(--space-2xl) 0; }

/* ========================================
   BUTTONS
   ======================================== */
.btn {
    display: inline-flex; align-items: center; gap: 0.5rem;
    padding: 0.75rem 1.6rem; border-radius: 100px;
    font-family: var(--font-body); font-size: 0.9rem; font-weight: 600;
    letter-spacing: 0.01em; cursor: pointer; transition: all 0.3s ease; border: none;
}
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-hover); color: #fff; transform: translateY(-1px); box-shadow: 0 6px 20px var(--accent-glow); }
.btn-outline { background: transparent; color: var(--text-primary); border: 1.5px solid var(--border-strong); }
.btn-outline:hover { border-color: var(--accent); color: var(--accent); }
.btn-ghost { background: var(--accent-subtle); color: var(--accent); }
.btn-ghost:hover { background: var(--accent-glow); }
.btn-arrow::after { content: '\2192'; transition: transform 0.2s; }
.btn-arrow:hover::after { transform: translateX(4px); }

/* ========================================
   THEME TOGGLE
   ======================================== */
.theme-toggle {
    position: fixed; top: 1.5rem; right: 1.5rem; z-index: 100;
    width: 44px; height: 44px; border-radius: 50%;
    border: 1px solid var(--border-strong); background: var(--bg-card);
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    transition: all 0.3s; box-shadow: var(--shadow-sm);
}
.theme-toggle:hover { transform: scale(1.1); box-shadow: var(--shadow-md); }
.theme-toggle-icon { width: 18px; height: 18px; border-radius: 50%; background: var(--text-primary); transition: all 0.3s; }
[data-theme="dark"] .theme-toggle-icon { background: transparent; box-shadow: inset -6px -2px 0 0 var(--text-primary); }

/* ========================================
   NAV
   ======================================== */
.nav-bar {
    position: fixed; top: 0; left: 0; right: 0; z-index: 90;
    padding: 1.25rem 0; transition: all 0.4s;
    background: var(--bg-primary);
}
.nav-bar.scrolled {
    background: var(--bg-primary);
    border-bottom: 1px solid var(--border);
    padding: 0.7rem 0;
}
.nav-inner {
    display: flex; align-items: center; justify-content: space-between;
    max-width: var(--max-width); margin: 0 auto; padding: 0 clamp(1.5rem, 4vw, 3rem);
}
.nav-logo { height: 30px; transition: opacity 0.3s; }
.nav-links { display: flex; gap: 2rem; align-items: center; list-style: none; }
.nav-links a { color: var(--text-secondary); font-size: 0.88rem; font-weight: 500; letter-spacing: 0.02em; }
.nav-links a:hover { color: var(--text-primary); }
.nav-links a.btn-primary { color: #fff; }
.nav-links a.btn-primary:hover { color: #fff; }

/* ========================================
   HERO
   ======================================== */
.hero {
    min-height: 100vh; display: flex; align-items: center;
    position: relative; overflow: hidden; padding: var(--space-2xl) 0 var(--space-xl);
}
.hero::before {
    content: ''; position: absolute; top: -20%; right: -15%;
    width: 550px; height: 550px;
    background: radial-gradient(circle, var(--accent-glow), transparent 70%);
    border-radius: 50%; pointer-events: none;
    animation: drift 25s ease-in-out infinite;
}
.hero::after {
    content: ''; position: absolute; bottom: -10%; left: -10%;
    width: 350px; height: 350px;
    background: radial-gradient(circle, var(--accent-glow), transparent 70%);
    border-radius: 50%; pointer-events: none; opacity: 0.4;
    animation: drift 20s ease-in-out infinite reverse;
}
@keyframes drift {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(-30px, 25px) scale(1.04); }
    66% { transform: translate(15px, -15px) scale(0.96); }
}
.hero-grid {
    display: grid; grid-template-columns: 1.1fr 0.9fr;
    gap: var(--space-xl); align-items: center;
}
.hero-logo { width: clamp(160px, 18vw, 220px); margin-bottom: var(--space-lg); }
.hero h1 {
    font-family: var(--font-display); font-weight: 400;
    font-size: clamp(2.8rem, 5.5vw, 4.2rem);
    line-height: 1.1; letter-spacing: -0.02em; margin-bottom: var(--space-md);
}
.hero h1 .awesome-text {
    color: var(--accent); font-style: italic;
    font-variation-settings: 'SOFT' 100, 'WONK' 1;
}
.hero-sub {
    font-size: 1.1rem; color: var(--text-secondary);
    max-width: 500px; margin-bottom: var(--space-lg); line-height: 1.75;
}
.hero-ctas { display: flex; gap: 1rem; flex-wrap: wrap; }

.hero-right { position: relative; }
.hero-quote {
    position: relative; padding: var(--space-lg);
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius-lg); box-shadow: var(--shadow-lg);
}
.hero-quote::before {
    content: '\201C'; position: absolute; top: -0.1em; left: 0.3em;
    font-family: var(--font-display); font-size: 5.5rem;
    color: var(--accent); opacity: 0.15; line-height: 1;
}
.hero-quote blockquote {
    font-family: var(--font-display); font-size: 1.3rem;
    font-style: italic; line-height: 1.5; color: var(--text-primary);
}
.hero-quote cite {
    display: block; margin-top: var(--space-sm);
    font-family: var(--font-body); font-style: normal;
    font-size: 0.82rem; color: var(--text-tertiary);
    letter-spacing: 0.05em; text-transform: uppercase;
}

/* ========================================
   STATS BAR
   ======================================== */
.stats-bar {
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    background: var(--bg-secondary);
    padding: var(--space-lg) 0;
}
.stats-grid {
    display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--space-md);
    text-align: center;
}
.stat-item .stat-number {
    font-family: var(--font-display); font-size: 2.2rem;
    color: var(--accent); line-height: 1.1; font-weight: 400;
}
.stat-item .stat-label {
    font-size: 0.82rem; color: var(--text-tertiary);
    text-transform: uppercase; letter-spacing: 0.08em; font-weight: 500;
    margin-top: 0.3rem;
}

/* ========================================
   AI POSITIONING
   ======================================== */
.ai-position { overflow: hidden; }
.ai-position-inner {
    display: grid; grid-template-columns: 1fr 1fr;
    gap: var(--space-xl); align-items: start;
}
.label {
    display: inline-block; font-size: 0.72rem; font-weight: 700;
    letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent);
    margin-bottom: var(--space-md); padding: 0.35rem 0.85rem;
    background: var(--accent-subtle); border-radius: 100px;
}
.ai-position h2 {
    font-family: var(--font-display); font-weight: 400;
    font-size: clamp(2rem, 3.5vw, 2.7rem);
    line-height: 1.15; margin-bottom: var(--space-md);
}
.ai-position-lead {
    font-size: 1.12rem; color: var(--text-secondary); line-height: 1.75; margin-bottom: var(--space-lg);
}
.ai-position-right p { color: var(--text-secondary); margin-bottom: var(--space-md); line-height: 1.75; }
.ai-position-right p strong { color: var(--text-primary); font-weight: 600; }

.ai-services { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-sm); margin-top: var(--space-lg); }
.ai-service-card {
    padding: var(--space-md); border-radius: var(--radius);
    background: var(--bg-card); border: 1px solid var(--border); transition: all 0.3s;
}
.ai-service-card:hover { border-color: var(--accent); box-shadow: var(--shadow-md); transform: translateY(-2px); }
.ai-service-card h4 { font-size: 0.95rem; font-weight: 700; margin-bottom: 0.4rem; }
.ai-service-card p { font-size: 0.85rem; color: var(--text-tertiary); line-height: 1.55; margin-bottom: 0 !important; }

/* ========================================
   CAPABILITIES
   ======================================== */
.capabilities h2 {
    font-family: var(--font-display); font-weight: 400;
    font-size: clamp(2rem, 3vw, 2.4rem); margin-bottom: var(--space-xl);
}
.capabilities-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: var(--space-md);
}
.capability-item {
    padding: var(--space-lg); border: 1px solid var(--border);
    border-radius: var(--radius); background: var(--bg-card); transition: all 0.3s;
    position: relative; overflow: hidden;
}
.capability-item::before {
    content: ''; position: absolute; top: 0; left: 0; right: 0;
    height: 3px; background: var(--accent); transform: scaleX(0);
    transform-origin: left; transition: transform 0.4s ease;
}
.capability-item:hover::before { transform: scaleX(1); }
.capability-item:hover { box-shadow: var(--shadow-md); }
.capability-item .num {
    font-family: var(--font-display); font-size: 1.8rem;
    color: var(--accent); opacity: 0.35; margin-bottom: var(--space-sm); line-height: 1;
}
.capability-item h3 { font-size: 1.05rem; font-weight: 700; margin-bottom: 0.5rem; }
.capability-item p { color: var(--text-secondary); font-size: 0.93rem; line-height: 1.65; }

/* ========================================
   PROCESS
   ======================================== */
.process {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}
.process h2 {
    font-family: var(--font-display); font-weight: 400;
    font-size: clamp(2rem, 3vw, 2.4rem); margin-bottom: var(--space-sm);
}
.process .section-sub {
    color: var(--text-secondary); margin-bottom: var(--space-xl); font-size: 1.05rem; max-width: 600px;
}
.process-steps {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-md);
    position: relative;
}
.process-steps::before {
    content: ''; position: absolute; top: 28px; left: 16.6%; right: 16.6%;
    height: 2px; background: var(--border-strong);
}
.process-step {
    text-align: center; position: relative; z-index: 1;
}
.process-step .step-num {
    width: 56px; height: 56px; border-radius: 50%;
    background: var(--bg-card); border: 2px solid var(--accent);
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto var(--space-md);
    font-family: var(--font-display); font-size: 1.2rem; color: var(--accent);
    transition: all 0.3s;
}
.process-step:hover .step-num { background: var(--accent); color: #fff; }
.process-step h4 { font-size: 1rem; font-weight: 700; margin-bottom: 0.4rem; }
.process-step p { font-size: 0.88rem; color: var(--text-tertiary); line-height: 1.6; max-width: 280px; margin: 0 auto; }

/* ========================================
   FEATURED CLIENTS
   ======================================== */
.featured-clients {
    overflow: hidden;
}
.featured-clients h2 {
    font-family: var(--font-display); font-weight: 400;
    font-size: clamp(2rem, 3vw, 2.4rem); margin-bottom: 0.5rem;
}
.featured-clients .section-sub { color: var(--text-secondary); margin-bottom: var(--space-xl); font-size: 1.05rem; }

.featured-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-md); margin-bottom: var(--space-xl); }
.featured-item {
    padding: var(--space-lg) var(--space-md); text-align: center;
    border: 1px solid var(--border); border-radius: var(--radius);
    background: var(--bg-card); transition: all 0.3s;
}
.featured-item:hover { border-color: var(--accent); box-shadow: var(--shadow-md); transform: translateY(-2px); }
.featured-item .client-name { font-family: var(--font-display); font-size: 1.15rem; margin-bottom: 0.3rem; }
.featured-item .client-type {
    font-size: 0.78rem; color: var(--text-tertiary);
    text-transform: uppercase; letter-spacing: 0.08em; font-weight: 500;
}

.all-clients-toggle {
    display: flex; align-items: center; justify-content: center; gap: 0.5rem;
    margin: 0 auto var(--space-md); padding: 0.6rem 1.5rem;
    background: transparent; border: 1px solid var(--border-strong); border-radius: 100px;
    cursor: pointer; font-family: var(--font-body); font-size: 0.85rem;
    color: var(--text-secondary); font-weight: 500; transition: all 0.3s;
}
.all-clients-toggle:hover { border-color: var(--accent); color: var(--accent); }
.all-clients-toggle .toggle-arrow { transition: transform 0.3s; display: inline-block; }
.all-clients-toggle.open .toggle-arrow { transform: rotate(180deg); }

.all-clients-wrap { max-height: 0; overflow: hidden; transition: max-height 0.6s ease; }
.all-clients-wrap.open { max-height: 1200px; }
.client-cloud { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.35rem 0.9rem; padding: var(--space-md) 0; }
.client-cloud span { font-size: 0.82rem; color: var(--text-tertiary); white-space: nowrap; transition: color 0.2s; }
.client-cloud span:hover { color: var(--accent); }
.client-cloud span::after { content: '\00B7'; margin-left: 0.9rem; color: var(--border-strong); }
.client-cloud span:last-child::after { display: none; }

/* ========================================
   AI CTA
   ======================================== */
.ai-cta-section { position: relative; overflow: hidden; }
.ai-cta-card {
    position: relative; padding: var(--space-xl);
    border-radius: var(--radius-lg); background: var(--bg-secondary);
    border: 1px solid var(--border); text-align: center; overflow: hidden;
}
.ai-cta-card::before {
    content: ''; position: absolute; top: -50px; left: 50%; transform: translateX(-50%);
    width: 450px; height: 450px;
    background: radial-gradient(circle, var(--accent-glow), transparent 70%);
    border-radius: 50%; pointer-events: none; opacity: 0.6;
}
.ai-cta-card h2 {
    font-family: var(--font-display); font-weight: 400;
    font-size: clamp(2rem, 3.5vw, 2.7rem); margin-bottom: var(--space-md); position: relative;
}
.ai-cta-card p { color: var(--text-secondary); font-size: 1.1rem; max-width: 550px; margin: 0 auto var(--space-lg); line-height: 1.75; position: relative; }
.ai-cta-buttons { display: flex; justify-content: center; gap: 1rem; flex-wrap: wrap; position: relative; }

/* ========================================
   NEWSLETTER
   ======================================== */
.newsletter-section { position: relative; overflow: hidden; }
.newsletter-inner {
    display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-xl); align-items: center;
}
.newsletter-copy .label { margin-bottom: var(--space-md); }
.newsletter-copy h2 {
    font-family: var(--font-display); font-weight: 400;
    font-size: clamp(2rem, 3.5vw, 2.7rem); line-height: 1.15; margin-bottom: var(--space-md);
}
.newsletter-copy .newsletter-lead {
    color: var(--text-secondary); font-size: 1.05rem; line-height: 1.75; margin-bottom: var(--space-sm);
}
.newsletter-copy .newsletter-details {
    color: var(--text-tertiary); font-size: 0.88rem; line-height: 1.65;
}
.newsletter-form-wrap {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius-lg); padding: var(--space-xl);
    box-shadow: var(--shadow-md); position: relative; overflow: hidden;
}
.newsletter-form-wrap::before { display: none; }
.newsletter-logo {
    display: block; border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    margin: calc(-1 * var(--space-xl)) calc(-1 * var(--space-xl)) var(--space-lg) calc(-1 * var(--space-xl));
    width: calc(100% + 2 * var(--space-xl)); max-width: none; height: auto;
}
.newsletter-form-wrap h3 {
    font-family: var(--font-display); font-weight: 400;
    font-size: 1.3rem; margin-bottom: 0.4rem;
}
.newsletter-form-wrap .form-sub {
    color: var(--text-tertiary); font-size: 0.88rem; margin-bottom: var(--space-lg);
}
.newsletter-form {
    display: flex; gap: 0.75rem;
}
.newsletter-form input[type="email"] {
    flex: 1; padding: 0.8rem 1.2rem;
    border: 1.5px solid var(--border-strong); border-radius: 100px;
    background: var(--bg-primary); color: var(--text-primary);
    font-family: var(--font-body); font-size: 0.95rem;
    transition: all 0.3s; outline: none;
}
.newsletter-form input[type="email"]::placeholder { color: var(--text-tertiary); }
.newsletter-form input[type="email"]:focus {
    border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-subtle);
}
.newsletter-form button {
    padding: 0.8rem 1.8rem; border-radius: 100px; border: none;
    background: var(--accent); color: #fff;
    font-family: var(--font-body); font-size: 0.9rem; font-weight: 600;
    cursor: pointer; transition: all 0.3s; white-space: nowrap;
}
.newsletter-form button:hover {
    background: var(--accent-hover); transform: translateY(-1px);
    box-shadow: 0 6px 20px var(--accent-glow);
}
.newsletter-form .form-note {
    margin-top: 0.6rem; font-size: 0.78rem; color: var(--text-tertiary);
}

/* Newsletter form states */
.newsletter-form.is-loading button { opacity: 0.7; pointer-events: none; }
.newsletter-form.is-loading .btn-text { visibility: hidden; }
.newsletter-form.is-loading .btn-loading {
    position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
}
.newsletter-form.is-loading .btn-loading::after {
    content: ''; width: 18px; height: 18px; border: 2px solid rgba(255,255,255,0.3);
    border-top-color: #fff; border-radius: 50%; animation: spin 0.6s linear infinite;
}
.newsletter-form button { position: relative; }
.btn-loading { display: none; }
@keyframes spin { to { transform: rotate(360deg); } }

.form-success {
    display: flex; align-items: center; gap: 0.6rem;
    padding: 0.8rem 0; font-size: 0.92rem; color: var(--accent); font-weight: 500;
}
.form-success svg { flex-shrink: 0; }
.form-error {
    padding: 0.6rem 0; font-size: 0.85rem; color: #d63031;
}
.form-error a { color: #d63031; text-decoration: underline; }

/* Inline newsletter (CTA section) */
.cta-newsletter-inline {
    margin-top: var(--space-lg); position: relative;
}
.cta-newsletter-inline .newsletter-form {
    max-width: 480px; margin: 0 auto;
}
.cta-newsletter-inline .newsletter-label {
    font-size: 0.88rem; color: var(--text-secondary); margin-bottom: 0.75rem;
}

/* ========================================
   ABOUT
   ======================================== */
.about-section {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}
.about-section h2 {
    font-family: var(--font-display); font-weight: 400;
    font-size: clamp(2rem, 3vw, 2.4rem); margin-bottom: var(--space-lg);
}
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-xl); align-items: start; }
.about-grid p { color: var(--text-secondary); margin-bottom: var(--space-md); line-height: 1.75; }

/* ========================================
   FOOTER
   ======================================== */
footer { padding: var(--space-xl) 0 var(--space-lg); border-top: 1px solid var(--border); }
.footer-inner { display: flex; justify-content: space-between; align-items: start; flex-wrap: wrap; gap: var(--space-lg); }
.footer-brand p { color: var(--text-tertiary); font-size: 0.88rem; margin-top: 0.5rem; }
.footer-links { display: flex; gap: 2rem; }
.footer-links a { color: var(--text-secondary); font-size: 0.88rem; font-weight: 500; }
.footer-links a:hover { color: var(--accent); }
.footer-copy {
    width: 100%; text-align: center; padding-top: var(--space-lg); margin-top: var(--space-md);
    border-top: 1px solid var(--border); color: var(--text-tertiary); font-size: 0.82rem;
}

/* ========================================
   CONTACT PANEL
   ======================================== */
.contact-panel { position: fixed; top: 0; right: 0; bottom: 0; z-index: 200; pointer-events: none; }
.contact-panel.open { pointer-events: all; }
.contact-panel-overlay {
    position: fixed; inset: 0; background: rgba(0,0,0,0.4);
    backdrop-filter: blur(4px); opacity: 0; transition: opacity 0.3s;
}
.contact-panel.open .contact-panel-overlay { opacity: 1; }
.contact-panel-content {
    position: fixed; top: 0; right: 0; bottom: 0;
    width: min(420px, 90vw); background: var(--bg-card);
    padding: var(--space-xl) var(--space-lg);
    transform: translateX(100%); transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    overflow-y: auto; border-left: 1px solid var(--border);
}
.contact-panel.open .contact-panel-content { transform: translateX(0); }
.contact-panel-close {
    position: absolute; top: 1.5rem; right: 1.5rem;
    width: 40px; height: 40px; border-radius: 50%;
    border: 1px solid var(--border-strong); background: transparent;
    color: var(--text-primary); font-size: 1.3rem; cursor: pointer;
    display: flex; align-items: center; justify-content: center; transition: all 0.2s;
}
.contact-panel-close:hover { background: var(--accent); color: #fff; border-color: var(--accent); }
.contact-panel h2 { font-family: var(--font-display); font-size: 1.8rem; margin-bottom: var(--space-sm); }
.contact-panel .panel-intro { color: var(--text-secondary); margin-bottom: var(--space-lg); line-height: 1.65; }
.contact-links { display: flex; flex-direction: column; gap: 0.75rem; }
.contact-links a {
    display: block; padding: 1rem 1.25rem; border: 1px solid var(--border);
    border-radius: var(--radius); color: var(--text-primary); font-weight: 500; transition: all 0.2s;
}
.contact-links a:hover { border-color: var(--accent); background: var(--accent-subtle); color: var(--accent); }
.contact-links .contact-email { background: var(--accent); color: #fff; border-color: var(--accent); text-align: center; font-weight: 600; }
.contact-links .contact-email:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: #fff; }

/* ========================================
   CASE STUDY
   ======================================== */
.case-study {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}
.case-study h2 {
    font-family: var(--font-display); font-weight: 400;
    font-size: clamp(2rem, 3vw, 2.4rem); margin-bottom: var(--space-sm);
}
.case-study .section-sub { color: var(--text-secondary); margin-bottom: var(--space-xl); font-size: 1.05rem; }
.case-study-card {
    display: grid; grid-template-columns: 1fr 1.2fr; gap: var(--space-xl);
    align-items: start;
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius-lg); overflow: hidden;
}
.case-study-meta {
    padding: var(--space-xl) var(--space-lg);
}
.case-study-meta .label { margin-bottom: var(--space-sm); }
.case-study-meta h3 {
    font-family: var(--font-display); font-weight: 400;
    font-size: 1.6rem; line-height: 1.25; margin-bottom: var(--space-md);
}
.case-study-meta p { color: var(--text-secondary); line-height: 1.75; margin-bottom: var(--space-md); }
.case-study-meta p:last-of-type { margin-bottom: var(--space-lg); }
.case-study-tags { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: var(--space-lg); }
.case-study-tags span {
    font-size: 0.75rem; font-weight: 600; letter-spacing: 0.04em;
    padding: 0.3rem 0.75rem; border-radius: 100px; text-transform: uppercase;
    background: var(--bg-secondary); color: var(--text-tertiary); border: 1px solid var(--border);
}
.case-study-results {
    padding: var(--space-xl) var(--space-lg);
    background: var(--bg-secondary);
    display: flex; flex-direction: column; justify-content: center; height: 100%;
}
.case-study-results h4 {
    font-size: 0.75rem; font-weight: 700; letter-spacing: 0.1em;
    text-transform: uppercase; color: var(--text-tertiary); margin-bottom: var(--space-md);
}
.result-item { margin-bottom: var(--space-md); padding-bottom: var(--space-md); border-bottom: 1px solid var(--border); }
.result-item:last-child { margin-bottom: 0; padding-bottom: 0; border-bottom: none; }
.result-item .result-label { font-size: 0.82rem; color: var(--text-tertiary); margin-bottom: 0.2rem; text-transform: uppercase; letter-spacing: 0.06em; font-weight: 500; }
.result-item .result-value { font-family: var(--font-display); font-size: 1.3rem; color: var(--text-primary); }

/* ========================================
   WHO THIS IS FOR
   ======================================== */
.who-for h2 {
    font-family: var(--font-display); font-weight: 400;
    font-size: clamp(2rem, 3vw, 2.4rem); margin-bottom: var(--space-sm);
}
.who-for .section-sub { color: var(--text-secondary); margin-bottom: var(--space-xl); font-size: 1.05rem; max-width: 600px; }
.who-for-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: var(--space-md); }
.who-for-item {
    padding: var(--space-lg); border: 1px solid var(--border);
    border-radius: var(--radius); background: var(--bg-card); transition: all 0.3s;
    position: relative; padding-left: calc(var(--space-lg) + 4px);
}
.who-for-item::before {
    content: ''; position: absolute; left: 0; top: var(--space-md); bottom: var(--space-md);
    width: 3px; background: var(--accent); border-radius: 2px; opacity: 0.4;
    transition: opacity 0.3s;
}
.who-for-item:hover::before { opacity: 1; }
.who-for-item:hover { box-shadow: var(--shadow-md); }
.who-for-item h4 { font-size: 1rem; font-weight: 700; margin-bottom: 0.4rem; }
.who-for-item p { color: var(--text-secondary); font-size: 0.93rem; line-height: 1.65; }

/* ========================================
   LATEST THINKING
   ======================================== */
.latest-thinking {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}
.latest-thinking h2 {
    font-family: var(--font-display); font-weight: 400;
    font-size: clamp(2rem, 3vw, 2.4rem); margin-bottom: var(--space-sm);
}
.latest-thinking .section-sub { color: var(--text-secondary); margin-bottom: var(--space-xl); font-size: 1.05rem; }
.articles-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-md); }
.article-card {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); padding: var(--space-lg);
    transition: all 0.3s; display: flex; flex-direction: column;
}
.article-card:hover { border-color: var(--accent); box-shadow: var(--shadow-md); transform: translateY(-3px); }
.article-card .article-tag {
    font-size: 0.7rem; font-weight: 700; letter-spacing: 0.1em;
    text-transform: uppercase; color: var(--accent); margin-bottom: var(--space-sm);
}
.article-card h3 {
    font-family: var(--font-display); font-weight: 400;
    font-size: 1.2rem; line-height: 1.3; margin-bottom: var(--space-sm);
}
.article-card h3 a { color: var(--text-primary); }
.article-card h3 a:hover { color: var(--accent); }
.article-card p { color: var(--text-secondary); font-size: 0.9rem; line-height: 1.65; flex-grow: 1; margin-bottom: var(--space-md); }
.article-card .read-more {
    font-size: 0.85rem; font-weight: 600; color: var(--accent);
    display: inline-flex; align-items: center; gap: 0.4rem;
}
.article-card .read-more::after { content: '\2192'; transition: transform 0.2s; }
.article-card:hover .read-more::after { transform: translateX(4px); }

/* ========================================
   ABOUT (with headshot)
   ======================================== */
.about-intro {
    display: grid; grid-template-columns: auto 1fr; gap: var(--space-xl); align-items: start;
    margin-bottom: var(--space-xl);
}
.headshot {
    width: 150px; height: 150px; border-radius: 50%; overflow: hidden;
    border: 3px solid var(--accent); box-shadow: var(--shadow-md);
    flex-shrink: 0; position: relative;
    background: var(--bg-tertiary);
}
.headshot img {
    width: 100%; height: 100%; object-fit: cover;
    transition: transform 0.4s ease;
}
.headshot:hover img {
    transform: scale(1.05);
}
.about-intro-text h2 {
    font-family: var(--font-display); font-weight: 400;
    font-size: clamp(2rem, 3vw, 2.4rem); margin-bottom: var(--space-sm);
}
.about-intro-text .about-lead {
    color: var(--text-secondary); font-size: 1.1rem; line-height: 1.7;
}

/* ========================================
   BACK TO TOP
   ======================================== */
.back-to-top {
    position: fixed; bottom: 2rem; right: 2rem;
    width: 44px; height: 44px; border-radius: 50%;
    background: var(--bg-card); border: 1px solid var(--border-strong);
    color: var(--text-primary); font-size: 1.1rem; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    opacity: 0; pointer-events: none; transition: all 0.3s;
    box-shadow: var(--shadow-md); z-index: 50;
}
.back-to-top.visible { opacity: 1; pointer-events: all; }
.back-to-top:hover { transform: translateY(-2px); border-color: var(--accent); color: var(--accent); }

/* ========================================
   ANIMATIONS
   ======================================== */
/* Only hide .reveal when JS has run (progressive enhancement: visible without JS) */
html.js-reveal .reveal {
    opacity: 0; transform: translateY(28px);
    transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}
html.js-reveal .reveal.visible { opacity: 1; transform: translateY(0); }
.reveal-d1 { transition-delay: 0.1s; }
.reveal-d2 { transition-delay: 0.2s; }
.reveal-d3 { transition-delay: 0.3s; }
.reveal-d4 { transition-delay: 0.4s; }
.reveal-d5 { transition-delay: 0.5s; }
.reveal-d6 { transition-delay: 0.6s; }

.hero-enter {
    opacity: 0; transform: translateY(35px);
    animation: heroIn 0.85s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.hero-enter-1 { animation-delay: 0.1s; }
.hero-enter-2 { animation-delay: 0.25s; }
.hero-enter-3 { animation-delay: 0.4s; }
.hero-enter-4 { animation-delay: 0.55s; }
.hero-enter-5 { animation-delay: 0.7s; }
@keyframes heroIn { to { opacity: 1; transform: translateY(0); } }

/* ========================================
   RESPONSIVE
   ======================================== */
@media (max-width: 900px) {
    .hero-grid { grid-template-columns: 1fr; gap: var(--space-lg); }
    .hero-right { max-width: 500px; }
    .ai-position-inner { grid-template-columns: 1fr; }
    .ai-services { grid-template-columns: 1fr; }
    .about-grid { grid-template-columns: 1fr; }
    .featured-grid { grid-template-columns: 1fr 1fr; }
    .process-steps { grid-template-columns: 1fr; gap: var(--space-lg); }
    .process-steps::before { display: none; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); gap: var(--space-md); }
    .nav-links .nav-link-text { display: none; }
    .case-study-card { grid-template-columns: 1fr; }
    .articles-grid { grid-template-columns: 1fr; }
    .about-intro { grid-template-columns: 1fr; text-align: center; }
    .headshot { margin: 0 auto; }
    .newsletter-inner { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
    body { font-size: 16px; }
    section { padding: var(--space-xl) 0; }
    .featured-grid { grid-template-columns: 1fr; }
    .hero-ctas { flex-direction: column; }
    .hero-ctas .btn { text-align: center; justify-content: center; }
    .ai-cta-card { padding: var(--space-lg); }
    .footer-inner { flex-direction: column; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .newsletter-form { flex-direction: column; }
    .newsletter-form button { width: 100%; }
    .newsletter-form-wrap { padding: var(--space-lg); }
}

/* ========================================
   ARTICLE (single post) & BLOG CTA
   ======================================== */
.article-header { padding-top: calc(var(--space-2xl) + 2rem); padding-bottom: var(--space-lg); text-align: center; }
.article-header h1 {
    font-family: var(--font-display);
    font-weight: 400;
    font-size: clamp(2rem, 4.5vw, 3rem);
    line-height: 1.15;
    letter-spacing: -0.02em;
    margin-bottom: var(--space-sm);
    max-width: 780px;
    margin-left: auto;
    margin-right: auto;
}
.article-meta {
    color: var(--text-tertiary);
    font-size: 0.9rem;
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}
.article-meta span { display: inline-flex; align-items: center; gap: 0.35rem; }

.article-body {
    max-width: 720px;
    margin: 0 auto;
    padding: 0 clamp(1.5rem, 4vw, 3rem) var(--space-xl);
}
.article-body h2 {
    font-family: var(--font-display);
    font-weight: 400;
    font-size: clamp(1.4rem, 2.5vw, 1.75rem);
    margin: var(--space-xl) 0 var(--space-sm);
    line-height: 1.25;
}
.article-body h3 {
    font-family: var(--font-display);
    font-weight: 400;
    font-size: 1.2rem;
    margin: var(--space-lg) 0 0.5rem;
    line-height: 1.3;
}
.article-body p {
    margin-bottom: var(--space-md);
    color: var(--text-secondary);
    line-height: 1.75;
}
.article-body ul, .article-body ol {
    margin-bottom: var(--space-md);
    padding-left: 1.5rem;
    color: var(--text-secondary);
    line-height: 1.75;
}
.article-body li { margin-bottom: 0.5rem; }
.article-body strong { color: var(--text-primary); font-weight: 600; }

.author-bio {
    max-width: 720px;
    margin: 0 auto var(--space-xl);
    padding: var(--space-lg);
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
}
.author-bio h3 {
    font-family: var(--font-display);
    font-weight: 400;
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}
.author-bio p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.65;
    margin-bottom: var(--space-sm);
}

.back-home {
    max-width: 720px;
    margin: 0 auto;
    padding: 0 clamp(1.5rem, 4vw, 3rem) var(--space-lg);
}
.back-home a {
    color: var(--text-tertiary);
    font-size: 0.9rem;
    font-weight: 500;
}
.back-home a:hover { color: var(--accent); }
.back-home a::before { content: '\2190 '; }

.blog-cta {
    max-width: 820px; margin: var(--space-xl) auto;
    padding: 0 clamp(1.5rem, 4vw, 3rem);
}
.blog-cta-box {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius-lg); box-shadow: var(--shadow-md);
    display: grid; grid-template-columns: 1fr 1fr;
    overflow: hidden;
}
.blog-cta-left, .blog-cta-right {
    padding: clamp(1.5rem, 3vw, 2.25rem);
    display: flex; flex-direction: column;
}
.blog-cta-right {
    border-left: 1px solid var(--border);
}
.blog-cta-box h3 {
    font-family: var(--font-display); font-weight: 400;
    font-size: 1.25rem; line-height: 1.3;
    margin-bottom: 0.6rem;
}
.blog-cta-box p {
    color: var(--text-secondary); font-size: 0.9rem; line-height: 1.65;
}
.blog-cta-left p { margin-bottom: var(--space-lg); flex: 1; }
.blog-cta-left .btn { align-self: flex-start; }
.blog-cta-newsletter-head {
    display: flex; align-items: center; gap: 0.65rem;
    margin-bottom: 0.6rem;
}
.blog-cta-newsletter-logo {
    width: 40px; height: 40px; border-radius: 8px;
    object-fit: cover; flex-shrink: 0;
}
.blog-cta-newsletter-head h3 { margin-bottom: 0; }
.blog-cta-right > p { margin-bottom: var(--space-md); flex: 1; }
.blog-cta-form {
    display: flex; gap: 0.5rem;
}
.blog-cta-form input[type="email"] {
    flex: 1; padding: 0.65rem 1rem;
    border: 1.5px solid var(--border-strong); border-radius: 100px;
    background: var(--bg-primary); color: var(--text-primary);
    font-family: var(--font-body); font-size: 0.85rem;
    transition: all 0.3s; outline: none; min-width: 0;
}
.blog-cta-form input[type="email"]::placeholder { color: var(--text-tertiary); }
.blog-cta-form input[type="email"]:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-subtle); }
.blog-cta-form button {
    padding: 0.65rem 1.2rem; border-radius: 100px; border: none;
    background: var(--accent); color: #fff;
    font-family: var(--font-body); font-size: 0.82rem; font-weight: 600;
    cursor: pointer; transition: all 0.3s; white-space: nowrap;
}
.blog-cta-form button:hover { background: var(--accent-hover); transform: translateY(-1px); box-shadow: 0 6px 20px var(--accent-glow); }

@media (max-width: 700px) {
    .blog-cta-box { grid-template-columns: 1fr; }
    .blog-cta-right { border-left: none; border-top: 1px solid var(--border); }
}
@media (max-width: 600px) {
    .blog-cta-form { flex-direction: column; }
    .blog-cta-form button { width: 100%; }
}
