/* =============================================
   Eastchester Group Ltd
   ============================================= */

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

:root {
    --bg: #0a0a0f;
    --bg-light: #fafaf9;
    --surface: #141419;
    --surface-2: #1c1c24;
    --surface-light: #ffffff;
    --border: rgba(255,255,255,0.08);
    --border-light: #e6e4e0;
    --text: #f0efe9;
    --text-2: #9e9c97;
    --text-dark: #18181b;
    --text-dark-2: #64645f;
    --accent: #6366f1;
    --accent-2: #818cf8;
    --glow: rgba(99,102,241,0.15);
    --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --ease: cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font);
    color: var(--text-dark);
    background: var(--bg-light);
    line-height: 1.6;
    overflow-x: hidden;
}

a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { max-width: 100%; display: block; }

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 32px;
}


/* ---- NAV ---- */

.nav {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 100;
    transition: background 0.4s, border-color 0.4s, backdrop-filter 0.4s;
}

.nav-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 72px;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 600;
    font-size: 16px;
    color: var(--text);
    transition: color 0.3s;
}

.logo-mark {
    width: 32px; height: 32px;
    background: var(--accent);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 16px;
    color: #fff;
    letter-spacing: -0.02em;
}

.logo-mark-sm {
    width: 28px; height: 28px;
    font-size: 14px;
    border-radius: 7px;
}

.nav.scrolled {
    background: rgba(10, 10, 15, 0.8);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-bottom: 1px solid var(--border);
}

/* After hero, switch nav to light mode */
.nav.light {
    background: rgba(250, 250, 249, 0.85);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-bottom: 1px solid var(--border-light);
}

.nav.light .nav-logo { color: var(--text-dark); }
.nav.light .nav-links a { color: var(--text-dark-2); }
.nav.light .nav-links a:hover { color: var(--text-dark); }
.nav.light .nav-toggle span { background: var(--text-dark); }

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

.nav-links a {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-2);
    transition: color 0.2s;
}

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

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}

.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text);
    border-radius: 2px;
    transition: all 0.3s var(--ease);
    transform-origin: center;
}

.nav-toggle.active span:first-child {
    transform: translateY(4px) rotate(45deg);
}

.nav-toggle.active span:last-child {
    transform: translateY(-4px) rotate(-45deg);
}


/* ---- BUTTONS ---- */

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font);
    font-size: 14px;
    font-weight: 500;
    padding: 12px 24px;
    border-radius: 10px;
    border: none;
    cursor: pointer;
    transition: all 0.25s var(--ease);
    white-space: nowrap;
}

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

.btn-primary:hover {
    background: var(--accent-2);
    box-shadow: 0 0 30px var(--glow);
    transform: translateY(-1px);
}

.btn-ghost {
    background: rgba(255,255,255,0.06);
    color: var(--text-2);
    border: 1px solid var(--border);
}

.btn-ghost:hover {
    background: rgba(255,255,255,0.1);
    color: var(--text);
    border-color: rgba(255,255,255,0.15);
}

.btn-nav {
    background: var(--accent);
    color: #fff !important;
    padding: 9px 20px;
    border-radius: 8px;
    font-size: 13px;
}

.btn-nav:hover { background: var(--accent-2); }

.nav.light .btn-nav {
    background: var(--text-dark);
    color: #fff !important;
}

.nav.light .btn-nav:hover {
    background: #333;
}

.btn-white {
    background: #fff;
    color: var(--text-dark);
}

.btn-white:hover {
    background: #f0efe9;
    transform: translateY(-1px);
    box-shadow: 0 8px 30px rgba(0,0,0,0.2);
}

.btn-lg {
    font-size: 16px;
    padding: 16px 32px;
    border-radius: 12px;
}


/* ---- HERO ---- */

.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    background: var(--bg);
    overflow: hidden;
}

.hero-glow {
    position: absolute;
    top: -20%;
    left: 50%;
    transform: translateX(-50%);
    width: 120%;
    height: 80%;
    background: radial-gradient(ellipse 50% 70% at 50% 30%,
        rgba(99,102,241,0.18) 0%,
        rgba(99,102,241,0.06) 40%,
        transparent 70%);
    pointer-events: none;
    animation: glowPulse 8s ease-in-out infinite alternate;
}

@keyframes glowPulse {
    0%   { opacity: 0.7; transform: translateX(-50%) scale(1); }
    100% { opacity: 1;   transform: translateX(-50%) scale(1.05); }
}

.hero-grid-bg {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(ellipse 80% 60% at 50% 40%, black 20%, transparent 70%);
    -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 40%, black 20%, transparent 70%);
    pointer-events: none;
}

.hero-noise {
    position: absolute;
    inset: 0;
    background: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
    background-repeat: repeat;
    pointer-events: none;
    opacity: 0.5;
}

.hero-fade {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 200px;
    background: linear-gradient(to bottom, transparent, var(--bg-light));
    pointer-events: none;
}

.hero-inner {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    padding: 160px 32px 120px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-2);
    padding: 8px 18px 8px 14px;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border);
    border-radius: 100px;
    margin-bottom: 40px;
}

.badge-dot {
    width: 7px; height: 7px;
    background: #34d399;
    border-radius: 50%;
    box-shadow: 0 0 8px rgba(52,211,153,0.5);
    animation: dotPulse 2s ease-in-out infinite;
}

@keyframes dotPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

.hero h1 {
    font-size: clamp(44px, 6vw, 80px);
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -0.035em;
    color: var(--text);
    margin-bottom: 28px;
}

.text-gradient {
    background: linear-gradient(135deg, var(--accent-2) 0%, #c084fc 50%, var(--accent) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-sub {
    font-size: 18px;
    line-height: 1.7;
    color: var(--text-2);
    max-width: 520px;
    margin-bottom: 44px;
}

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


/* ---- MARQUEE ---- */

.marquee-wrap {
    padding: 32px 0;
    border-bottom: 1px solid var(--border-light);
    overflow: hidden;
    background: var(--bg-light);
}

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

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

.marquee-content {
    display: flex;
    align-items: center;
    gap: 0;
    flex-shrink: 0;
}

.marquee-content span {
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-dark-2);
    opacity: 0.5;
    white-space: nowrap;
}

.marquee-content .sep {
    width: 4px; height: 4px;
    background: var(--text-dark-2);
    border-radius: 50%;
    opacity: 0.3;
    margin: 0 28px;
    flex-shrink: 0;
}


/* ---- SECTIONS ---- */

.section {
    padding: 120px 0;
    position: relative;
}

.label {
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 20px;
}

.label-light { color: var(--accent-2); }

.section-header {
    max-width: 580px;
    margin-bottom: 72px;
}

.section-header h2 {
    font-size: clamp(32px, 4vw, 48px);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.03em;
    margin-bottom: 20px;
}

.section-sub {
    font-size: 17px;
    line-height: 1.7;
    color: var(--text-dark-2);
}


/* ---- ABOUT ---- */

.about-top {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: start;
    margin-bottom: 72px;
}

.about-left h2 {
    font-size: clamp(32px, 4vw, 48px);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.03em;
    color: var(--text-dark);
}

.about-right p {
    font-size: 16px;
    line-height: 1.8;
    color: var(--text-dark-2);
    margin-bottom: 16px;
}

.about-right p:last-child { margin-bottom: 0; }


/* ---- BENTO GRID ---- */

.bento {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr;
    gap: 16px;
}

.bento-card {
    background: var(--surface-light);
    border: 1px solid var(--border-light);
    border-radius: 16px;
    padding: 40px 36px;
    transition: all 0.35s var(--ease);
    position: relative;
    overflow: hidden;
}

.bento-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 16px;
    padding: 1px;
    background: linear-gradient(135deg, transparent 40%, var(--accent) 100%);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.35s var(--ease);
}

.bento-card:hover::before { opacity: 1; }
.bento-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(0,0,0,0.06);
}

.bento-icon {
    width: 48px; height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(99,102,241,0.08), rgba(99,102,241,0.03));
    border-radius: 12px;
    margin-bottom: 24px;
    color: var(--accent);
}

.bento-icon svg { width: 24px; height: 24px; }

.bento-card h3 {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 10px;
    letter-spacing: -0.01em;
}

.bento-card p {
    font-size: 15px;
    line-height: 1.65;
    color: var(--text-dark-2);
}


/* ---- DARK SECTION ---- */

.section-dark {
    background: var(--bg);
    color: var(--text);
    overflow: hidden;
}

.section-dark .section-header h2 { color: var(--text); }
.section-dark .section-sub { color: var(--text-2); }

.glow-orb {
    position: absolute;
    top: 10%; right: -10%;
    width: 600px; height: 600px;
    background: radial-gradient(circle, var(--glow) 0%, transparent 70%);
    pointer-events: none;
    opacity: 0.6;
}


/* ---- SERVICES GRID ---- */

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1px;
    background: var(--border);
    border-radius: 16px;
    overflow: hidden;
}

.service-card {
    background: var(--surface);
    padding: 44px 36px;
    transition: background 0.3s var(--ease);
    position: relative;
}

.service-card:hover {
    background: var(--surface-2);
}

.service-num {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: var(--accent-2);
    letter-spacing: 0.04em;
    margin-bottom: 20px;
    font-variant-numeric: tabular-nums;
}

.service-card h3 {
    font-size: 18px;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 12px;
    letter-spacing: -0.01em;
}

.service-card p {
    font-size: 14px;
    line-height: 1.7;
    color: var(--text-2);
}


/* ---- APPROACH TIMELINE ---- */

.approach-timeline {
    max-width: 640px;
}

.approach-step {
    display: flex;
    gap: 32px;
}

.step-marker {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-shrink: 0;
    padding-top: 6px;
}

.step-dot {
    width: 12px; height: 12px;
    border-radius: 50%;
    border: 2px solid var(--accent);
    background: var(--bg-light);
    flex-shrink: 0;
    position: relative;
    z-index: 1;
}

.step-line {
    width: 2px;
    flex: 1;
    background: var(--border-light);
    margin: 8px 0;
}

.step-body {
    padding-bottom: 48px;
}

.step-num {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: var(--accent);
    letter-spacing: 0.04em;
    margin-bottom: 8px;
    font-variant-numeric: tabular-nums;
}

.step-body h3 {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 10px;
    letter-spacing: -0.01em;
}

.step-body p {
    font-size: 15px;
    line-height: 1.7;
    color: var(--text-dark-2);
}


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

.section-cta {
    background: var(--bg);
    text-align: center;
    overflow: hidden;
    position: relative;
}

.cta-glow {
    position: absolute;
    bottom: -30%;
    left: 50%;
    transform: translateX(-50%);
    width: 140%;
    height: 80%;
    background: radial-gradient(ellipse 50% 60% at 50% 80%,
        rgba(99,102,241,0.12) 0%, transparent 70%);
    pointer-events: none;
}

.cta-inner {
    max-width: 560px;
    margin: 0 auto;
    position: relative;
}

.cta-inner h2 {
    font-size: clamp(32px, 4vw, 48px);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.03em;
    color: var(--text);
    margin-bottom: 20px;
}

.cta-sub {
    font-size: 17px;
    line-height: 1.7;
    color: var(--text-2);
    margin-bottom: 40px;
}

.cta-note {
    display: block;
    margin-top: 20px;
    font-size: 13px;
    color: rgba(255,255,255,0.3);
}


/* ---- FOOTER ---- */

.footer {
    background: var(--bg-light);
    border-top: 1px solid var(--border-light);
    padding: 64px 0 0;
}

.footer-top {
    display: flex;
    justify-content: space-between;
    gap: 48px;
    padding-bottom: 48px;
}

.footer-brand .nav-logo {
    color: var(--text-dark);
    margin-bottom: 4px;
}

.footer-tagline {
    font-size: 14px;
    color: var(--text-dark-2);
    line-height: 1.6;
    margin-top: 12px;
}

.footer-links {
    display: flex;
    gap: 72px;
}

.footer-col {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-col h4 {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-dark);
    margin-bottom: 6px;
}

.footer-col a {
    font-size: 14px;
    color: var(--text-dark-2);
    transition: color 0.2s;
}

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

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 0;
    border-top: 1px solid var(--border-light);
    font-size: 13px;
    color: var(--text-dark-2);
}

.footer-legal {
    display: flex;
    gap: 24px;
}

.footer-legal a {
    font-size: 13px;
    color: var(--text-dark-2);
    transition: color 0.2s;
}

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


/* ---- REVEAL ANIMATIONS ---- */

.reveal {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}

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

.reveal[data-delay="1"] { transition-delay: 0.1s; }
.reveal[data-delay="2"] { transition-delay: 0.2s; }
.reveal[data-delay="3"] { transition-delay: 0.3s; }
.reveal[data-delay="4"] { transition-delay: 0.4s; }
.reveal[data-delay="5"] { transition-delay: 0.5s; }


/* ---- RESPONSIVE ---- */

@media (max-width: 1024px) {
    .services-grid { grid-template-columns: repeat(2, 1fr); }
    .bento { grid-template-columns: 1fr 1fr; }
    .bento-wide { grid-column: 1 / -1; }
}

@media (max-width: 768px) {
    .container { padding: 0 20px; }

    .nav-inner { padding: 0 20px; }

    .nav-toggle { display: flex; }

    .nav-links {
        position: fixed;
        inset: 0;
        top: 0;
        background: var(--bg);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 8px;
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.3s var(--ease);
        z-index: -1;
    }

    .nav-links.open {
        opacity: 1;
        pointer-events: all;
        z-index: 99;
    }

    .nav-links a {
        font-size: 24px !important;
        font-weight: 600;
        color: var(--text) !important;
        padding: 12px 0;
    }

    .nav-links .btn-nav {
        margin-top: 16px;
        font-size: 16px !important;
        padding: 14px 32px;
    }

    .hero-inner { padding: 140px 20px 100px; }

    .hero h1 { font-size: clamp(36px, 8vw, 56px); }
    .hero h1 br { display: none; }

    .about-top {
        grid-template-columns: 1fr;
        gap: 32px;
    }

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

    .bento-wide { grid-column: auto; }

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

    .section { padding: 80px 0; }

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

    .approach-step { gap: 20px; }

    .footer-top {
        flex-direction: column;
        gap: 40px;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }

    .cta-inner h2 br { display: none; }
}

@media (max-width: 480px) {
    .hero-actions {
        flex-direction: column;
    }

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

    .hero-badge { font-size: 11px; }
}
