/* =====================================================================
   Cyberworks — public website
   Theme colours come from the CMS and are injected as custom properties
   on :root by the layout, so everything below follows the admin's choices.
   ===================================================================== */

:root {
    --primary:        #2563eb;   /* overridden by site settings */
    --accent:         #0ea5e9;
    --primary-dark:   color-mix(in srgb, var(--primary) 82%, #000);
    --primary-soft:   color-mix(in srgb, var(--primary) 8%, #fff);
    --primary-ring:   color-mix(in srgb, var(--primary) 25%, transparent);

    --ink:            #0e1420;
    --ink-2:          #26303f;
    --body:           #4a5566;
    --muted:          #6b7688;
    --faint:          #98a1b0;

    --bg:             #ffffff;
    --bg-alt:         #f6f8fb;
    --bg-deep:        #0d1420;
    --bg-deep-2:      #131c2b;

    --line:           #e4e9f0;
    --line-strong:    #cfd7e3;

    --radius:         12px;
    --radius-sm:      8px;
    --radius-lg:      20px;

    --shadow-sm:      0 1px 2px rgba(14, 20, 32, .05);
    --shadow:         0 4px 16px rgba(14, 20, 32, .07);
    --shadow-lg:      0 18px 48px rgba(14, 20, 32, .13);

    --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

    --wrap: 1180px;
    --gutter: clamp(1rem, 4vw, 2rem);
    --section-y: clamp(3.5rem, 8vw, 6.5rem);
    --header-h: 74px;
}

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

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--header-h) + 1rem);
}
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

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

h1, h2, h3, h4, h5 {
    margin: 0 0 .5em;
    color: var(--ink);
    font-weight: 700;
    line-height: 1.18;
    letter-spacing: -.022em;
}
h1 { font-size: clamp(2.1rem, 5.2vw, 3.4rem); }
h2 { font-size: clamp(1.65rem, 3.6vw, 2.4rem); }
h3 { font-size: clamp(1.2rem, 2.2vw, 1.45rem); }
h4 { font-size: 1.08rem; }

p { margin: 0 0 1.1em; }
p:last-child { margin-bottom: 0; }

a { color: var(--primary); text-decoration: none; transition: color .15s; }
a:hover { color: var(--primary-dark); text-decoration: underline; }

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

ul, ol { margin: 0 0 1.1em; padding-left: 1.3em; }
li { margin-bottom: .35em; }

hr { border: 0; border-top: 1px solid var(--line); margin: 2.5rem 0; }

blockquote {
    margin: 1.75rem 0;
    padding: .35rem 0 .35rem 1.35rem;
    border-left: 3px solid var(--primary);
    color: var(--ink-2);
    font-size: 1.08rem;
}

code {
    font-family: var(--mono); font-size: .88em;
    background: var(--bg-alt); padding: .12em .38em;
    border-radius: 4px; color: var(--ink-2);
}
pre {
    background: var(--bg-deep); color: #dfe5ee;
    padding: 1.15rem; border-radius: var(--radius-sm);
    overflow-x: auto; font-size: .88rem; line-height: 1.6;
}
pre code { background: none; padding: 0; color: inherit; }

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

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

.sr-only {
    position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link:focus {
    position: fixed; top: 10px; left: 10px; z-index: 999;
    width: auto; height: auto; clip: auto; margin: 0;
    background: #fff; padding: .7rem 1.1rem;
    border-radius: var(--radius-sm); box-shadow: var(--shadow-lg);
}

/* =====================================================================
   Layout primitives
   ===================================================================== */

.wrap {
    width: min(var(--wrap), 100%);
    margin-inline: auto;
    padding-inline: var(--gutter);
}
.wrap--narrow { width: min(760px, 100%); }
.wrap--wide   { width: min(1360px, 100%); }

.section { padding-block: var(--section-y); }
.section--tight { padding-block: clamp(2.5rem, 5vw, 4rem); }
.section--alt { background: var(--bg-alt); }
.section--dark {
    background: var(--bg-deep);
    color: #b9c3d3;
}
.section--dark h1, .section--dark h2, .section--dark h3 { color: #fff; }
.section--dark a { color: #fff; }

.section-head { max-width: 66ch; margin-bottom: clamp(2rem, 4vw, 3rem); }
.section-head--center { margin-inline: auto; text-align: center; }
.section-head h2 { margin-bottom: .35em; }
.section-head p { font-size: 1.06rem; color: var(--muted); margin-bottom: 0; }

.eyebrow {
    display: inline-flex; align-items: center; gap: .5rem;
    font-size: .78rem; font-weight: 700;
    letter-spacing: .11em; text-transform: uppercase;
    color: var(--primary);
    margin-bottom: .85rem;
}
.eyebrow::before {
    content: ""; width: 22px; height: 2px;
    background: currentColor; border-radius: 2px;
}
.section-head--center .eyebrow::before { display: none; }
.section--dark .eyebrow { color: var(--accent); }

.grid { display: grid; gap: clamp(1.1rem, 2.4vw, 1.8rem); }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 290px), 1fr)); }
.grid--4 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); }

.split {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: clamp(2rem, 5vw, 4rem);
    align-items: center;
}
@media (max-width: 860px) { .split { grid-template-columns: minmax(0, 1fr); } }

.with-aside {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: clamp(2rem, 4vw, 3.5rem);
    align-items: start;
}
@media (max-width: 940px) { .with-aside { grid-template-columns: minmax(0, 1fr); } }

.stack > * + * { margin-top: 1rem; }
.center { text-align: center; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.nowrap { white-space: nowrap; }
.mt-1 { margin-top: .5rem; } .mt-2 { margin-top: 1rem; } .mt-3 { margin-top: 2rem; }
.mb-0 { margin-bottom: 0; } .mb-2 { margin-bottom: 1rem; } .mb-3 { margin-bottom: 2rem; }

/* =====================================================================
   Buttons
   ===================================================================== */

.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
    padding: .8rem 1.5rem;
    font: inherit; font-size: .95rem; font-weight: 600; line-height: 1.2;
    border-radius: 999px;
    border: 1.5px solid transparent;
    cursor: pointer;
    text-decoration: none !important;
    transition: transform .14s, background .16s, border-color .16s, color .16s, box-shadow .16s;
    white-space: nowrap;
}
.btn:hover { transform: translateY(-1.5px); }
.btn:active { transform: translateY(0); }

.btn--primary {
    background: var(--primary); color: #fff;
    box-shadow: 0 6px 18px color-mix(in srgb, var(--primary) 30%, transparent);
}
.btn--primary:hover { background: var(--primary-dark); color: #fff; }

.btn--outline { border-color: var(--line-strong); color: var(--ink); background: transparent; }
.btn--outline:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-soft); }

.btn--light { background: #fff; color: var(--ink); }
.btn--light:hover { background: #f1f4f9; color: var(--ink); }

.btn--ghost-light { border-color: rgba(255,255,255,.35); color: #fff; }
.btn--ghost-light:hover { background: rgba(255,255,255,.12); border-color: #fff; color: #fff; }

.btn--sm { padding: .55rem 1.05rem; font-size: .875rem; }
.btn--lg { padding: .95rem 1.9rem; font-size: 1.02rem; }
.btn--block { width: 100%; }

.btn-row { display: flex; gap: .75rem; flex-wrap: wrap; }
.btn-row--center { justify-content: center; }

.link-arrow {
    display: inline-flex; align-items: center; gap: .4rem;
    font-weight: 600; font-size: .93rem;
    text-decoration: none !important;
}
.link-arrow svg { width: 16px; height: 16px; transition: transform .16s; }
.link-arrow:hover svg { transform: translateX(3px); }

/* =====================================================================
   Header
   ===================================================================== */

.site-header {
    position: sticky; top: 0; z-index: 100;
    background: rgba(255, 255, 255, .92);
    backdrop-filter: saturate(180%) blur(12px);
    border-bottom: 1px solid transparent;
    transition: border-color .2s, box-shadow .2s;
}
.site-header.is-stuck {
    border-bottom-color: var(--line);
    box-shadow: 0 1px 12px rgba(14, 20, 32, .05);
}
.site-header__inner {
    display: flex; align-items: center; gap: 1.5rem;
    min-height: var(--header-h);
}

.brand { display: flex; align-items: center; gap: .65rem; flex: none; text-decoration: none !important; }
.brand:hover { text-decoration: none; }
.brand__logo { max-height: 42px; width: auto; }
.brand__mark {
    width: 38px; height: 38px; border-radius: 10px; flex: none;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    display: grid; place-items: center;
    color: #fff; font-weight: 800; font-size: 1.05rem;
}
.brand__text { display: flex; flex-direction: column; line-height: 1.15; }
.brand__name { font-weight: 750; color: var(--ink); font-size: 1.08rem; letter-spacing: -.02em; }
.brand__tag { font-size: .7rem; color: var(--muted); font-weight: 500; }

.nav { margin-left: auto; }
.nav__list { display: flex; align-items: center; gap: .2rem; list-style: none; margin: 0; padding: 0; }
.nav__item { position: relative; }
.nav__link {
    display: flex; align-items: center; gap: .3rem;
    padding: .55rem .8rem;
    font-size: .93rem; font-weight: 550;
    color: var(--ink-2); border-radius: var(--radius-sm);
    text-decoration: none !important;
    transition: color .15s, background .15s;
}
.nav__link:hover { color: var(--primary); background: var(--primary-soft); }
.nav__item.is-current > .nav__link { color: var(--primary); font-weight: 650; }
.nav__caret { width: 13px; height: 13px; opacity: .6; transition: transform .18s; }
.nav__item:hover .nav__caret, .nav__item.is-open .nav__caret { transform: rotate(180deg); }

.nav__sub {
    position: absolute; top: calc(100% + 6px); left: 0;
    min-width: 210px; padding: .4rem;
    background: #fff; border: 1px solid var(--line);
    border-radius: var(--radius); box-shadow: var(--shadow-lg);
    list-style: none; margin: 0;
    opacity: 0; visibility: hidden; transform: translateY(-6px);
    transition: opacity .16s, transform .16s, visibility .16s;
}
.nav__item:hover .nav__sub,
.nav__item:focus-within .nav__sub,
.nav__item.is-open .nav__sub { opacity: 1; visibility: visible; transform: translateY(0); }
.nav__sub li { margin: 0; }
.nav__sub .nav__link { padding: .5rem .7rem; font-size: .89rem; border-radius: var(--radius-sm); }

.nav__cta { margin-left: .5rem; }

.nav-toggle {
    display: none; margin-left: auto;
    width: 42px; height: 42px; padding: 0;
    background: none; border: 1px solid var(--line); border-radius: var(--radius-sm);
    cursor: pointer; color: var(--ink);
    align-items: center; justify-content: center;
}
.nav-toggle:hover { background: var(--bg-alt); }
.nav-toggle svg { width: 21px; height: 21px; }
.nav-toggle .icon-close { display: none; }
body.nav-open .nav-toggle .icon-close { display: block; }
body.nav-open .nav-toggle .icon-open { display: none; }

@media (max-width: 900px) {
    .nav-toggle { display: inline-flex; }
    .nav {
        position: fixed; inset: var(--header-h) 0 auto 0;
        background: #fff; border-bottom: 1px solid var(--line);
        box-shadow: var(--shadow-lg);
        max-height: calc(100dvh - var(--header-h));
        overflow-y: auto;
        margin: 0; padding: .75rem var(--gutter) 1.5rem;
        transform: translateY(-12px); opacity: 0; visibility: hidden;
        transition: opacity .18s, transform .18s, visibility .18s;
    }
    body.nav-open .nav { opacity: 1; visibility: visible; transform: translateY(0); }
    .nav__list { flex-direction: column; align-items: stretch; gap: 0; }
    .nav__link { padding: .8rem .4rem; font-size: 1rem; border-radius: 0; border-bottom: 1px solid var(--line); }
    .nav__item.is-current > .nav__link { background: var(--primary-soft); }
    .nav__sub {
        position: static; opacity: 1; visibility: visible; transform: none;
        border: 0; box-shadow: none; padding: 0 0 0 1rem;
        display: none;
    }
    .nav__item.is-open .nav__sub { display: block; }
    .nav__cta { margin: .9rem 0 0; }
    .nav__cta .btn { width: 100%; }
}

/* =====================================================================
   Hero
   ===================================================================== */

.hero {
    position: relative;
    color: #fff;
    background: linear-gradient(140deg, var(--bg-deep) 0%, #16233a 55%, #1c2b4a 100%);
    overflow: hidden;
}
.hero::after {
    content: ""; position: absolute; inset: 0;
    background:
        radial-gradient(700px 380px at 12% 8%, color-mix(in srgb, var(--primary) 34%, transparent), transparent 62%),
        radial-gradient(560px 320px at 88% 92%, color-mix(in srgb, var(--accent) 26%, transparent), transparent 60%);
    pointer-events: none;
}
.hero__slide {
    position: relative; z-index: 1;
    padding-block: clamp(4.5rem, 12vw, 8.5rem);
    display: none;
}
.hero__slide.is-active { display: block; animation: hero-in .5s ease-out; }
@keyframes hero-in { from { opacity: 0; transform: translateY(14px); } }

.hero__bg {
    position: absolute; inset: 0; z-index: 0;
    object-fit: cover; width: 100%; height: 100%;
    opacity: .28;
}
.hero__inner { position: relative; z-index: 2; max-width: 46rem; }
.hero__inner--center { margin-inline: auto; text-align: center; }
.hero__inner--right { margin-left: auto; text-align: right; }

.hero .eyebrow { color: var(--accent); }
.hero h1 { color: #fff; margin-bottom: .45em; text-wrap: balance; }
.hero__sub {
    font-size: clamp(1.05rem, 2vw, 1.22rem);
    color: #c2ccdb; max-width: 40rem; margin-bottom: 2rem;
}
.hero__inner--center .hero__sub { margin-inline: auto; }
.hero__inner--right .hero__sub { margin-left: auto; }

.hero__dots {
    position: absolute; bottom: 1.75rem; left: 50%; transform: translateX(-50%);
    z-index: 3; display: flex; gap: .5rem;
}
.hero__dot {
    width: 9px; height: 9px; border-radius: 50%; padding: 0;
    border: 0; cursor: pointer;
    background: rgba(255, 255, 255, .32);
    transition: background .18s, width .18s;
}
.hero__dot.is-active { background: #fff; width: 26px; border-radius: 999px; }

/* Compact banner for interior pages */
.page-hero {
    position: relative;
    background: linear-gradient(140deg, var(--bg-deep) 0%, #16233a 100%);
    color: #fff; overflow: hidden;
    padding-block: clamp(3rem, 7vw, 5rem);
}
.page-hero::after {
    content: ""; position: absolute; inset: 0;
    background: radial-gradient(620px 320px at 15% 0%, color-mix(in srgb, var(--primary) 32%, transparent), transparent 65%);
}
.page-hero__bg {
    position: absolute; inset: 0; width: 100%; height: 100%;
    object-fit: cover; opacity: .25;
}
.page-hero__inner { position: relative; z-index: 2; max-width: 52rem; }
.page-hero h1 { color: #fff; margin-bottom: .3em; }
.page-hero p { color: #c2ccdb; font-size: 1.08rem; margin-bottom: 0; }

.breadcrumbs {
    display: flex; flex-wrap: wrap; gap: .45rem; align-items: center;
    list-style: none; margin: 0 0 1rem; padding: 0;
    font-size: .85rem; color: rgba(255, 255, 255, .62);
}
.breadcrumbs a { color: rgba(255, 255, 255, .85); }
.breadcrumbs li::after { content: "/"; margin-left: .45rem; opacity: .45; }
.breadcrumbs li:last-child::after { content: ""; }

/* =====================================================================
   Cards
   ===================================================================== */

.card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    display: flex; flex-direction: column;
    transition: transform .2s, box-shadow .2s, border-color .2s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: transparent; }

.card__media {
    position: relative; display: block;
    aspect-ratio: 16 / 10; overflow: hidden;
    background: var(--bg-alt);
}
.card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.card:hover .card__media img { transform: scale(1.045); }
.card__media--tall { aspect-ratio: 4 / 5; }
.card__media--square { aspect-ratio: 1 / 1; }

.card__placeholder {
    width: 100%; height: 100%;
    display: grid; place-items: center;
    background: linear-gradient(135deg, var(--bg-alt), #eef2f8);
    color: var(--faint);
}
.card__placeholder svg { width: 34px; height: 34px; }

.card__body { padding: 1.35rem; flex: 1; display: flex; flex-direction: column; }
.card__title { font-size: 1.15rem; margin-bottom: .4rem; letter-spacing: -.015em; }
.card__title a { color: var(--ink); text-decoration: none !important; }
.card__title a:hover { color: var(--primary); }
.card__excerpt { color: var(--muted); font-size: .93rem; margin-bottom: 1rem; }
.card__foot {
    margin-top: auto; padding-top: .9rem;
    border-top: 1px solid var(--line);
    display: flex; align-items: center; gap: .6rem;
    font-size: .82rem; color: var(--faint);
}
.card__meta {
    display: flex; flex-wrap: wrap; gap: .5rem 1rem;
    font-size: .8rem; color: var(--faint); margin-bottom: .6rem;
}
.card__meta span { display: inline-flex; align-items: center; gap: .3rem; }
.card__meta svg { width: 14px; height: 14px; }

.tag-pill {
    position: absolute; top: .8rem; left: .8rem; z-index: 2;
    background: rgba(13, 20, 32, .78);
    backdrop-filter: blur(6px);
    color: #fff; font-size: .72rem; font-weight: 650;
    padding: .28rem .65rem; border-radius: 999px;
    letter-spacing: .01em;
}
.tag-pill--featured { background: var(--primary); }

.chip {
    display: inline-flex; align-items: center; gap: .3rem;
    font-size: .75rem; font-weight: 600;
    padding: .25rem .6rem; border-radius: 999px;
    background: var(--bg-alt); color: var(--muted);
    border: 1px solid var(--line);
}
.chip-row { display: flex; flex-wrap: wrap; gap: .4rem; }

/* Service card */
.service-card {
    background: #fff; border: 1px solid var(--line);
    border-radius: var(--radius); padding: 1.75rem;
    transition: transform .2s, box-shadow .2s, border-color .2s;
    display: flex; flex-direction: column;
}
.service-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: transparent; }
.service-card__icon {
    width: 52px; height: 52px; border-radius: 14px;
    display: grid; place-items: center; margin-bottom: 1.15rem;
    background: var(--primary-soft); color: var(--primary);
}
.service-card__icon svg { width: 25px; height: 25px; }
.service-card__icon img { width: 28px; height: 28px; object-fit: contain; }
.service-card h3 { font-size: 1.18rem; margin-bottom: .45rem; }
.service-card p { color: var(--muted); font-size: .93rem; margin-bottom: 1.1rem; }
.service-card .link-arrow { margin-top: auto; }

/* Stat counter */
.stat { text-align: center; }
.stat__value {
    font-size: clamp(2.2rem, 5vw, 3.1rem);
    font-weight: 800; line-height: 1;
    letter-spacing: -.035em;
    color: var(--ink);
    font-variant-numeric: tabular-nums;
}
.section--dark .stat__value { color: #fff; }
.stat__label { font-size: .92rem; color: var(--muted); margin-top: .5rem; font-weight: 550; }
.section--dark .stat__label { color: #9fabbd; }
.stat__desc { font-size: .8rem; color: var(--faint); margin-top: .2rem; }

/* Testimonial */
.testimonial {
    background: #fff; border: 1px solid var(--line);
    border-radius: var(--radius); padding: 1.85rem;
    display: flex; flex-direction: column; height: 100%;
}
.testimonial__stars { color: #f0b429; letter-spacing: .12em; margin-bottom: .9rem; font-size: 1rem; }
.testimonial__quote { color: var(--ink-2); font-size: 1rem; margin-bottom: 1.35rem; }
.testimonial__quote p:last-child { margin-bottom: 0; }
.testimonial__person { margin-top: auto; display: flex; align-items: center; gap: .8rem; }
.testimonial__avatar {
    width: 46px; height: 46px; border-radius: 50%; object-fit: cover; flex: none;
    background: var(--primary-soft); color: var(--primary);
    display: grid; place-items: center; font-weight: 700; font-size: .95rem;
}
.testimonial__name { font-weight: 650; color: var(--ink); font-size: .95rem; line-height: 1.3; }
.testimonial__role { font-size: .82rem; color: var(--faint); }

/* Team */
.person { text-align: center; }
.person__photo {
    aspect-ratio: 1/1; border-radius: var(--radius);
    overflow: hidden; margin-bottom: 1rem;
    background: var(--bg-alt);
}
.person__photo img { width: 100%; height: 100%; object-fit: cover; transition: transform .45s; }
.person:hover .person__photo img { transform: scale(1.05); }
.person__name { font-size: 1.05rem; margin-bottom: .1rem; }
.person__name a { color: var(--ink); text-decoration: none !important; }
.person__name a:hover { color: var(--primary); }
.person__role { color: var(--muted); font-size: .88rem; }
.person__social { display: flex; gap: .5rem; justify-content: center; margin-top: .7rem; }
.person__social a {
    width: 32px; height: 32px; border-radius: 50%;
    display: grid; place-items: center;
    background: var(--bg-alt); color: var(--muted);
    transition: background .15s, color .15s;
}
.person__social a:hover { background: var(--primary); color: #fff; }
.person__social svg { width: 15px; height: 15px; }

/* Partner logos */
.logo-strip {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 1px; background: var(--line);
    border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
}
.logo-strip__item {
    background: #fff; padding: 1.6rem 1.1rem;
    display: grid; place-items: center; min-height: 108px;
}
.logo-strip__item img {
    max-height: 44px; width: auto; object-fit: contain;
    filter: grayscale(1); opacity: .62;
    transition: filter .2s, opacity .2s;
}
.logo-strip__item:hover img { filter: none; opacity: 1; }
.logo-strip__name { color: var(--faint); font-weight: 650; font-size: .9rem; text-align: center; }

/* =====================================================================
   Gallery
   ===================================================================== */

.masonry {
    columns: 3 260px;
    column-gap: 1rem;
}
.masonry > * { break-inside: avoid; margin-bottom: 1rem; }

.gallery-item {
    position: relative; display: block;
    border-radius: var(--radius); overflow: hidden;
    background: var(--bg-alt); cursor: zoom-in;
}
.gallery-item img { width: 100%; transition: transform .45s; }
.gallery-item:hover img { transform: scale(1.05); }
.gallery-item__cap {
    position: absolute; inset: auto 0 0 0;
    padding: 1.6rem .9rem .8rem;
    background: linear-gradient(transparent, rgba(13, 20, 32, .82));
    color: #fff; font-size: .85rem; font-weight: 550;
    opacity: 0; transition: opacity .2s;
}
.gallery-item:hover .gallery-item__cap,
.gallery-item:focus-visible .gallery-item__cap { opacity: 1; }

.lightbox {
    position: fixed; inset: 0; z-index: 200;
    background: rgba(8, 12, 20, .93);
    display: none; align-items: center; justify-content: center;
    padding: clamp(1rem, 4vw, 3rem);
}
.lightbox.is-open { display: flex; }
.lightbox__img { max-width: 100%; max-height: 82vh; border-radius: var(--radius-sm); }
.lightbox__cap {
    color: #cfd6e2; text-align: center; margin-top: 1rem;
    font-size: .92rem; max-width: 60ch;
}
.lightbox__close, .lightbox__nav {
    position: absolute; background: rgba(255, 255, 255, .1);
    border: 0; color: #fff; cursor: pointer;
    width: 46px; height: 46px; border-radius: 50%;
    display: grid; place-items: center;
    transition: background .15s;
}
.lightbox__close:hover, .lightbox__nav:hover { background: rgba(255, 255, 255, .22); }
.lightbox__close { top: 1.2rem; right: 1.2rem; }
.lightbox__nav--prev { left: 1.2rem; top: 50%; transform: translateY(-50%); }
.lightbox__nav--next { right: 1.2rem; top: 50%; transform: translateY(-50%); }
.lightbox svg { width: 22px; height: 22px; }

/* =====================================================================
   Article / rich text
   ===================================================================== */

.prose { font-size: 1.045rem; line-height: 1.75; color: var(--ink-2); }
.prose > *:first-child { margin-top: 0; }
.prose h2 { font-size: clamp(1.4rem, 2.6vw, 1.8rem); margin: 2.2rem 0 .7rem; }
.prose h3 { font-size: clamp(1.15rem, 2vw, 1.35rem); margin: 1.9rem 0 .55rem; }
.prose h4 { margin: 1.5rem 0 .4rem; }
.prose ul, .prose ol { margin-bottom: 1.3em; }
.prose li { margin-bottom: .45em; }
.prose li::marker { color: var(--primary); }
.prose img { border-radius: var(--radius); margin: 1.8rem 0; }
.prose figure { margin: 1.8rem 0; }
.prose figcaption { font-size: .86rem; color: var(--faint); text-align: center; margin-top: .6rem; }
.prose table {
    width: 100%; border-collapse: collapse; margin: 1.6rem 0; font-size: .93rem;
    display: block; overflow-x: auto;
}
.prose th, .prose td { border: 1px solid var(--line); padding: .65rem .85rem; text-align: left; }
.prose th { background: var(--bg-alt); font-weight: 650; color: var(--ink); }
.prose a { text-decoration: underline; text-underline-offset: 2px; }
.prose iframe { width: 100%; aspect-ratio: 16/9; border: 0; border-radius: var(--radius); margin: 1.8rem 0; }

.article-head { margin-bottom: 2rem; }
.article-meta {
    display: flex; flex-wrap: wrap; gap: .6rem 1.4rem;
    align-items: center; color: var(--faint); font-size: .89rem;
    margin-bottom: 1.5rem;
}
.article-meta span { display: inline-flex; align-items: center; gap: .4rem; }
.article-meta svg { width: 15px; height: 15px; }
.article-hero {
    border-radius: var(--radius-lg); overflow: hidden; margin-bottom: 2.5rem;
    aspect-ratio: 16/8; background: var(--bg-alt);
}
.article-hero img { width: 100%; height: 100%; object-fit: cover; }

.author-box {
    display: flex; gap: 1.1rem; align-items: flex-start;
    padding: 1.5rem; margin-top: 2.5rem;
    background: var(--bg-alt); border-radius: var(--radius);
}
.author-box__avatar {
    width: 58px; height: 58px; border-radius: 50%; flex: none; object-fit: cover;
    background: var(--primary-soft); color: var(--primary);
    display: grid; place-items: center; font-weight: 700;
}

.share-row { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; margin-top: 2rem; }
.share-row a, .share-row button {
    width: 38px; height: 38px; border-radius: 50%;
    display: grid; place-items: center;
    background: var(--bg-alt); color: var(--muted);
    border: 1px solid var(--line); cursor: pointer;
    transition: background .15s, color .15s, border-color .15s;
}
.share-row a:hover, .share-row button:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.share-row svg { width: 16px; height: 16px; }

/* Detail meta panel (projects, events) */
.fact-list { list-style: none; margin: 0; padding: 0; }
.fact-list li {
    display: flex; gap: 1rem; padding: .8rem 0;
    border-bottom: 1px solid var(--line); font-size: .92rem;
}
.fact-list li:last-child { border-bottom: 0; }
.fact-list dt, .fact-list__key {
    color: var(--faint); flex: 0 0 40%; font-weight: 550;
}
.fact-list dd, .fact-list__val { margin: 0; color: var(--ink-2); font-weight: 550; }

.aside-card {
    background: #fff; border: 1px solid var(--line);
    border-radius: var(--radius); padding: 1.4rem;
}
.aside-card + .aside-card { margin-top: 1.25rem; }
.aside-card__title {
    font-size: .82rem; font-weight: 700; text-transform: uppercase;
    letter-spacing: .09em; color: var(--faint); margin-bottom: 1rem;
}
.aside-card--dark {
    background: var(--bg-deep); border-color: transparent; color: #b9c3d3;
}
.aside-card--dark h3, .aside-card--dark .aside-card__title { color: #fff; }

.aside-list { list-style: none; margin: 0; padding: 0; }
.aside-list li { padding: .55rem 0; border-bottom: 1px solid var(--line); }
.aside-list li:last-child { border-bottom: 0; padding-bottom: 0; }
.aside-list li:first-child { padding-top: 0; }
.aside-list a { color: var(--ink-2); font-weight: 550; font-size: .93rem; text-decoration: none !important; }
.aside-list a:hover { color: var(--primary); }
.aside-list__count { color: var(--faint); font-size: .82rem; float: right; }

.aside-post { display: flex; gap: .8rem; align-items: flex-start; }
.aside-post__thumb {
    width: 62px; height: 62px; border-radius: var(--radius-sm);
    object-fit: cover; flex: none; background: var(--bg-alt);
}
.aside-post__title { font-size: .9rem; font-weight: 600; line-height: 1.35; color: var(--ink); }
.aside-post__date { font-size: .78rem; color: var(--faint); margin-top: .2rem; }

/* =====================================================================
   Forms
   ===================================================================== */

.form-field { margin-bottom: 1.15rem; }
.form-label {
    display: block; font-size: .88rem; font-weight: 600;
    color: var(--ink); margin-bottom: .4rem;
}
.form-label .req { color: #d0342c; }

.form-input, .form-select, .form-textarea {
    width: 100%; padding: .78rem .95rem;
    font: inherit; font-size: .96rem; color: var(--ink);
    background: #fff; border: 1.5px solid var(--line-strong);
    border-radius: var(--radius-sm);
    transition: border-color .15s, box-shadow .15s;
}
.form-input:focus, .form-select:focus, .form-textarea:focus {
    outline: none; border-color: var(--primary);
    box-shadow: 0 0 0 4px var(--primary-ring);
}
.form-input::placeholder, .form-textarea::placeholder { color: var(--faint); }
.form-textarea { min-height: 148px; resize: vertical; line-height: 1.6; }
.form-select { appearance: none; padding-right: 2.4rem;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5.5 7.5L10 12l4.5-4.5' stroke='%236b7688' stroke-width='1.7' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat; background-position: right .8rem center; background-size: 18px;
}
.form-input.has-error, .form-textarea.has-error, .form-select.has-error {
    border-color: #d0342c; background: #fffafa;
}
.form-error { color: #c0322b; font-size: .84rem; margin-top: .35rem; }
.form-help { color: var(--muted); font-size: .84rem; margin-top: .35rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 1rem; }
@media (max-width: 620px) { .form-row { grid-template-columns: 1fr; } }

.honeypot { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }

.alert {
    display: flex; gap: .75rem; align-items: flex-start;
    padding: 1rem 1.15rem; border-radius: var(--radius);
    margin-bottom: 1.5rem; font-size: .95rem;
}
.alert svg { width: 19px; height: 19px; flex: none; margin-top: .12rem; }
.alert--success { background: #e8f7f0; color: #0b5c42; }
.alert--error   { background: #fdecec; color: #8f2620; }
.alert--info    { background: #eaf3fc; color: #17527f; }
.alert--warning { background: #fdf4e3; color: #7a4a00; }

/* Search box */
.searchbar { display: flex; gap: .6rem; }
.searchbar .form-input { flex: 1; }

/* Filter bar */
.filters {
    display: flex; flex-wrap: wrap; gap: .5rem;
    margin-bottom: 2.25rem;
}
.filters__link {
    padding: .5rem 1.05rem; border-radius: 999px;
    font-size: .89rem; font-weight: 600;
    background: var(--bg-alt); color: var(--muted);
    border: 1px solid transparent;
    text-decoration: none !important; transition: all .15s;
}
.filters__link:hover { color: var(--primary); border-color: var(--line-strong); }
.filters__link.is-active { background: var(--primary); color: #fff; }
.filters__count { opacity: .65; font-size: .82em; margin-left: .25rem; }

/* =====================================================================
   Pagination
   ===================================================================== */

.pagination {
    display: flex; justify-content: center; align-items: center;
    gap: .3rem; flex-wrap: wrap; margin-top: 3rem;
}
.pagination__link {
    min-width: 42px; height: 42px; padding: 0 .7rem;
    display: inline-flex; align-items: center; justify-content: center;
    border: 1px solid var(--line); border-radius: var(--radius-sm);
    color: var(--ink-2); font-weight: 600; font-size: .92rem;
    background: #fff; text-decoration: none !important;
    transition: all .15s;
}
.pagination__link:hover { border-color: var(--primary); color: var(--primary); }
.pagination__link.is-active { background: var(--primary); border-color: var(--primary); color: #fff; }
.pagination__link.is-disabled { opacity: .38; pointer-events: none; }
.pagination__gap { padding: 0 .35rem; color: var(--faint); }
.pagination svg { width: 17px; height: 17px; }

/* =====================================================================
   Empty state
   ===================================================================== */

.empty-state {
    text-align: center; padding: clamp(3rem, 8vw, 5rem) 1.5rem;
    border: 1px dashed var(--line-strong); border-radius: var(--radius-lg);
    background: var(--bg-alt);
}
.empty-state__icon {
    width: 58px; height: 58px; margin: 0 auto 1.25rem;
    border-radius: 16px; background: #fff;
    display: grid; place-items: center; color: var(--faint);
    border: 1px solid var(--line);
}
.empty-state__icon svg { width: 26px; height: 26px; }
.empty-state h3 { margin-bottom: .4rem; }
.empty-state p { max-width: 46ch; margin: 0 auto 1.5rem; color: var(--muted); }

/* =====================================================================
   CTA band
   ===================================================================== */

.cta-band {
    position: relative; overflow: hidden;
    background: linear-gradient(130deg, var(--primary), color-mix(in srgb, var(--accent) 75%, var(--primary)));
    color: #fff;
    border-radius: var(--radius-lg);
    padding: clamp(2.5rem, 6vw, 4rem);
    text-align: center;
}
.cta-band::after {
    content: ""; position: absolute; inset: 0;
    background: radial-gradient(520px 260px at 85% 15%, rgba(255,255,255,.2), transparent 60%);
}
.cta-band > * { position: relative; z-index: 1; }
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255, 255, 255, .9); font-size: 1.08rem; max-width: 54ch; margin-inline: auto; }

/* =====================================================================
   Footer
   ===================================================================== */

.site-footer {
    background: var(--bg-deep);
    color: #98a4b6;
    padding-top: clamp(3rem, 6vw, 4.5rem);
    font-size: .93rem;
}
.site-footer h3, .site-footer h4 { color: #fff; }
.site-footer a { color: #b6c1d1; text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }

.footer-grid {
    display: grid;
    grid-template-columns: 1.6fr repeat(3, 1fr);
    gap: clamp(1.75rem, 4vw, 3rem);
    padding-bottom: 3rem;
}
@media (max-width: 940px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer-grid { grid-template-columns: 1fr; } }

.footer-heading {
    font-size: .78rem; font-weight: 700; color: #fff;
    text-transform: uppercase; letter-spacing: .1em; margin-bottom: 1.1rem;
}
.footer-list { list-style: none; margin: 0; padding: 0; }
.footer-list li { margin-bottom: .6rem; }

.footer-contact { list-style: none; margin: 0; padding: 0; }
.footer-contact li { display: flex; gap: .7rem; margin-bottom: .85rem; align-items: flex-start; }
.footer-contact svg { width: 17px; height: 17px; flex: none; margin-top: .18rem; color: var(--accent); }

.social-row { display: flex; gap: .6rem; flex-wrap: wrap; margin-top: 1.25rem; }
.social-row a {
    width: 38px; height: 38px; border-radius: 50%;
    display: grid; place-items: center;
    background: rgba(255, 255, 255, .07); color: #cfd7e3;
    transition: background .15s, color .15s, transform .15s;
}
.social-row a:hover { background: var(--primary); color: #fff; transform: translateY(-2px); }
.social-row svg { width: 17px; height: 17px; }

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, .09);
    padding-block: 1.5rem;
    display: flex; flex-wrap: wrap; gap: .75rem 1.5rem;
    align-items: center; justify-content: space-between;
    font-size: .87rem;
}
.footer-bottom ul { display: flex; gap: 1.25rem; list-style: none; margin: 0; padding: 0; flex-wrap: wrap; }

.hours-list { list-style: none; margin: 0; padding: 0; font-size: .88rem; }
.hours-list li {
    display: flex; justify-content: space-between; gap: 1rem;
    padding: .3rem 0;
}
.hours-list .is-today { color: #fff; font-weight: 600; }
.badge-open {
    display: inline-flex; align-items: center; gap: .35rem;
    font-size: .76rem; font-weight: 650;
    padding: .18rem .55rem; border-radius: 999px;
    background: rgba(18, 128, 92, .18); color: #4ade80;
}
.badge-open__dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge-closed { background: rgba(255,255,255,.08); color: #98a4b6; }

/* Map */
.map-frame {
    border-radius: var(--radius); overflow: hidden;
    border: 1px solid var(--line); background: var(--bg-alt);
    aspect-ratio: 16/9;
}
.map-frame iframe { width: 100%; height: 100%; border: 0; display: block; }

/* Back to top */
.to-top {
    position: fixed; right: 1.4rem; bottom: 1.4rem; z-index: 90;
    width: 44px; height: 44px; border-radius: 50%;
    background: var(--primary); color: #fff; border: 0;
    display: grid; place-items: center; cursor: pointer;
    box-shadow: var(--shadow-lg);
    opacity: 0; visibility: hidden; transform: translateY(10px);
    transition: opacity .2s, transform .2s, visibility .2s;
}
.to-top.is-visible { opacity: 1; visibility: visible; transform: translateY(0); }
.to-top svg { width: 19px; height: 19px; }

/* Preview banner shown to signed-in admins viewing unpublished content */
.preview-bar {
    background: #7a4a00; color: #fff;
    padding: .7rem var(--gutter); font-size: .9rem;
    display: flex; align-items: center; gap: .6rem; justify-content: center;
    flex-wrap: wrap; text-align: center;
}
.preview-bar a { color: #fff; text-decoration: underline; font-weight: 600; }
.preview-bar svg { width: 17px; height: 17px; }

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .55s ease, transform .55s ease; }
.reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; } }

@media print {
    .site-header, .site-footer, .to-top, .share-row, .pagination, .filters { display: none !important; }
    body { font-size: 12pt; }
    a[href^="http"]::after { content: " (" attr(href) ")"; font-size: .85em; color: #555; }
}
