/* ---------- Custom fonts ---------- */
/* Drop the font files into /static/fonts/ — names below must match exactly. */
/* font-display: block hides text until the custom font loads, so users
   never see a fallback font flash before the real one shows up. */
@font-face {
    font-family: "GARODemo";
    src: url("../fonts/GARODemo.woff2") format("woff2"),
         url("../fonts/GARODemo.woff") format("woff"),
         url("../fonts/GARODemo.ttf") format("truetype"),
         url("../fonts/GARODemo.otf") format("opentype");
    font-display: block;
    font-weight: 400;
    font-style: normal;
}

@font-face {
    font-family: "Alyamama";
    src: url("../fonts/ArbFONTS-Alyamama-Light.ttf") format("truetype");
    font-display: block;
    font-weight: 300;
    font-style: normal;
}

:root {
    --bg: #0a0a0a;
    --surface: #141414;
    --surface-2: #1c1c1c;
    --text: #f2f2f2;
    --muted: #9a9a9a;
    --accent: #ff3d00;
    --brand-red: #800000;
    --border: #262626;
    --maxw: 1200px;
    --radius: 4px;
}

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

html { scroll-behavior: smooth; }

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, "Helvetica Neue", Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

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

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

h1, h2, h3, h4, h5, h6 {
    font-family: "GARODemo", serif;
    font-weight: 400;
    letter-spacing: 0.02em;
    line-height: 1.2;
    text-transform: uppercase;
}

/* ---------- Header / Nav ---------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(10, 10, 10, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
}
.site-nav {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 1.1rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}
.logo {
    font-weight: 800;
    font-size: 1.15rem;
    letter-spacing: -0.02em;
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
}
.logo .logo-mark {
    height: 34px;
    width: auto;
    display: block;
}
.logo .logo-text {
    color: var(--brand-red);
    font-weight: 800;
    letter-spacing: 0.02em;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin-bottom: 0.5rem;
}
.footer-brand .logo-mark {
    height: 30px;
    width: auto;
    display: block;
}
.footer-brand .logo-text {
    color: var(--brand-red);
    font-size: 1.15rem;
    font-weight: 800;
    margin: 0;
}
.nav-links {
    list-style: none;
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
}
.nav-links a {
    font-size: 0.95rem;
    color: var(--muted);
    transition: color 0.2s;
}
.nav-links a:hover { color: var(--text); }

/* ---------- Layout ---------- */
.site-main { flex: 1; }

section { padding: 5rem 1.5rem; }

section > h1,
section > h2 {
    max-width: var(--maxw);
    margin: 0 auto 2.5rem;
    font-size: clamp(1.8rem, 3.2vw, 2.6rem);
}

/* ---------- Hero ---------- */
.hero {
    position: relative;
    height: 90vh;
    min-height: 520px;
    overflow: hidden;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 0 1.5rem 4rem;
    border-bottom: 1px solid var(--border);
}
.hero-media {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 1;
}
.hero-content {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: var(--maxw);
    margin: 0 auto;
    text-align: center;
}
.hero-title {
    font-family: "GARODemo", serif;
    font-size: clamp(1.3rem, 2.5vw, 2rem);
    font-weight: 400;
    line-height: 1.15;
    letter-spacing: 0.08em;
    margin: 0 auto 0.75rem;
    max-width: 700px;
    text-transform: uppercase;
    color: var(--text);
}
.hero-description {
    font-family: "Alyamama", sans-serif;
    font-size: clamp(0.9rem, 1.1vw, 1.05rem);
    font-weight: 300;
    color: rgba(242, 242, 242, 0.95);
    max-width: 720px;
    line-height: 1.65;
    margin: 0 auto;
}

/* ---------- Our Services (full-width section under hero) ---------- */
.services-section {
    background: #000;
    padding: 5rem 1.5rem;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}
.services-inner {
    max-width: 880px;
    margin: 0 auto;
    text-align: center;
}
.services-title {
    font-family: "GARODemo", serif;
    font-size: clamp(1.4rem, 3vw, 2.2rem);
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    color: var(--text);
    margin: 0 0 1.5rem;
}
.services-list {
    font-family: "Alyamama", sans-serif;
    font-size: clamp(0.9rem, 1.1vw, 1.05rem);
    font-weight: 300;
    line-height: 1.85;
    color: rgba(242, 242, 242, 0.82);
    margin: 0;
}

.hero-body-text {
    max-width: 780px;
    margin: 0 auto;
    padding: 5rem 1.5rem;
    text-align: center;
    font-size: clamp(1.1rem, 1.5vw, 1.35rem);
    line-height: 1.7;
    color: var(--muted);
}
.hero-body-text p { max-width: 780px; }

/* ---------- Clients (auto-scrolling marquee, right -> left) ---------- */
.clients {
    background: var(--surface);
    overflow: hidden;
    padding: 5rem 0;
}
.clients > h2 {
    max-width: var(--maxw);
    margin: 0 auto 2.5rem;
    padding: 0 1.5rem;
    font-size: clamp(1.8rem, 3.2vw, 2.6rem);
    text-align: center;
}
.clients-marquee {
    width: 100%;
    overflow: hidden;
    -webkit-mask-image: linear-gradient(to right, transparent 0, black 8%, black 92%, transparent 100%);
    mask-image: linear-gradient(to right, transparent 0, black 8%, black 92%, transparent 100%);
}
.clients-track {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    width: max-content;
    /* JS clones items until the track is wider than the viewport, then sets
       --marquee-set-width to one set's exact pixel width so the loop is gapless.
       Animation is paused until JS adds .is-ready (avoids a wrong-distance flash). */
    animation: clients-scroll 35s linear infinite;
    animation-play-state: paused;
}
.clients-track.is-ready { animation-play-state: running; }
.clients-track.is-ready:hover { animation-play-state: paused; }
.client-item {
    flex: 0 0 240px;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 80px;
    margin-right: 0;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}
.client-item:hover { opacity: 1; }
.client-item img {
    max-height: 70px;
    max-width: 200px;
    width: auto;
    height: auto;
    object-fit: contain;
}
.client-item span {
    color: var(--muted);
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.05em;
}

@keyframes clients-scroll {
    from { transform: translateX(0); }
    to   { transform: translateX(calc(-1 * var(--marquee-set-width, 100%))); }
}

/* ---------- Home banner (between Best Works and Our Clients) ---------- */
.banner {
    position: relative;
    background: var(--bg);
    padding: 6rem 3rem;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 3rem;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
}
.banner-label {
    position: absolute;
    top: 4rem;
    left: 1.5rem;
    font-size: 0.7rem;
    color: var(--muted);
    letter-spacing: 0.25em;
    text-transform: uppercase;
    font-weight: 600;
}
.banner-text {
    padding-left: 0;
    max-width: 760px;
    width: 100%;
    justify-self: center;
}
.banner-title {
    font-family: "GARODemo", serif;
    font-size: clamp(2.4rem, 4.5vw, 4rem);
    line-height: 1.05;
    text-transform: uppercase;
    letter-spacing: -0.005em;
    color: var(--text);
    margin: 0 0 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--accent);
}
.banner-description {
    font-family: "Alyamama", sans-serif;
    font-weight: 300;
    font-size: 0.95rem;
    line-height: 1.7;
    color: rgba(242, 242, 242, 0.75);
    margin: 0 0 2rem;
    max-width: none;
}
.banner-description p { margin: 0 0 0.5rem; }
.banner-description p:last-child { margin-bottom: 0; }
.banner-cta-row {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    flex-wrap: wrap;
}
.banner-button {
    display: inline-block;
    padding: 0.9rem 2rem;
    border: 1px solid var(--text);
    color: var(--text);
    font-size: 0.78rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    text-decoration: none;
    transition: background 0.2s, color 0.2s;
}
.banner-button:hover {
    background: var(--text);
    color: var(--bg);
}
.banner-meta {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--muted);
    position: relative;
    padding-left: 1.25rem;
}
.banner-meta::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 1px;
    height: 14px;
    background: rgba(255, 255, 255, 0.25);
}
.banner-cta-row > .banner-meta:first-child {
    padding-left: 0;
}
.banner-cta-row > .banner-meta:first-child::before {
    display: none;
}
.banner-media {
    width: 100%;
    max-width: 360px;
    aspect-ratio: 4 / 5;
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--surface-2);
    justify-self: start;
}
.banner-media img,
.banner-media video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

@media (max-width: 900px) {
    .banner {
        grid-template-columns: 1fr;
        gap: 2rem;
        padding: 4rem 1.5rem;
    }
    .banner-label {
        position: static;
        display: block;
        margin-bottom: 1.5rem;
    }
    .banner-text {
        padding-left: 0;
        order: 2;
    }
    .banner-media {
        order: 1;
    }
}

/* ---------- Best Works (auto-scrolling image bar) ---------- */
.bestwork {
    background: var(--bg);
    padding: 4rem 0;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}
.bestwork-marquee {
    width: 100%;
    overflow: hidden;
    -webkit-mask-image: linear-gradient(to right, transparent 0, black 6%, black 94%, transparent 100%);
    mask-image: linear-gradient(to right, transparent 0, black 6%, black 94%, transparent 100%);
}
.bestwork-track {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 14px;
    width: max-content;
    animation: bestwork-scroll 50s linear infinite;
    animation-play-state: paused;
}
.bestwork-track.is-ready { animation-play-state: running; }
.bestwork-track.is-ready:hover { animation-play-state: paused; }
.bestwork-item {
    flex: 0 0 480px;
    height: 320px;
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--surface-2);
    position: relative;
}
.bestwork-item a,
.bestwork-item img {
    display: block;
    width: 100%;
    height: 100%;
}
.bestwork-item img {
    object-fit: cover;
    transition: transform 0.5s ease;
}
.bestwork-item:hover img { transform: scale(1.05); }

@keyframes bestwork-scroll {
    from { transform: translateX(0); }
    to   { transform: translateX(calc(-1 * var(--marquee-set-width, 100%))); }
}

@media (max-width: 700px) {
    .bestwork-item { flex-basis: 340px; height: 230px; }
}

/* ---------- Services ---------- */
.services {
    padding: 3.5rem 1.5rem;
    border-bottom: 1px solid var(--border);
    background: var(--surface);
}
.services-list {
    max-width: var(--maxw);
    margin: 0 auto;
    list-style: none;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    gap: 2rem 1rem;
}
.service {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.9rem;
    color: var(--muted);
    transition: color 0.3s ease, transform 0.3s ease;
    cursor: default;
}
.service:hover {
    color: var(--accent);
    transform: translateY(-4px);
}
.service svg {
    width: 44px;
    height: 44px;
    flex: none;
}
.service span {
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    text-align: center;
    font-weight: 600;
    color: var(--text);
}
.service:hover span { color: var(--accent); }

/* ---------- Behind the Scenes (horizontal slider, full-bleed) ---------- */
.behind-the-scenes {
    padding: 5rem 0;
}
.behind-the-scenes > h2 {
    max-width: var(--maxw);
    margin: 0 auto 2.5rem;
    padding: 0 1.5rem;
    font-size: clamp(1.8rem, 3.2vw, 2.6rem);
    text-align: center;
}
.bts-slider {
    width: 100%;
    margin: 0;
    position: relative;
}
.bts-viewport {
    overflow: hidden;
    border-radius: var(--radius);
}
.bts-track {
    display: flex;
    gap: 1rem;
    transition: transform 1s cubic-bezier(0.65, 0, 0.35, 1);
    will-change: transform;
}
.bts-slide {
    flex: 0 0 70%;
    aspect-ratio: 16 / 9;
    position: relative;
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--surface-2);
    opacity: 0.45;
    transform: scale(0.92);
    transition: opacity 0.55s ease, transform 0.55s ease;
    cursor: pointer;
}
.bts-slide.is-active {
    opacity: 1;
    transform: scale(1);
    cursor: default;
}
.bts-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.bts-slide figcaption {
    position: absolute;
    inset: auto 0 0 0;
    padding: 2rem 1.25rem 1rem;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.85));
    color: var(--text);
    font-size: 0.95rem;
    font-family: "Alyamama", sans-serif;
    font-weight: 300;
    opacity: 0;
    transition: opacity 0.4s ease;
}
.bts-slide.is-active figcaption { opacity: 1; }
.bts-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 52px;
    height: 52px;
    background: rgba(0, 0, 0, 0.55);
    color: var(--text);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 50%;
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
    z-index: 3;
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    transition: background 0.25s ease, transform 0.25s ease, border-color 0.25s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    user-select: none;
}
.bts-btn:hover {
    background: var(--accent);
    border-color: var(--accent);
    transform: translateY(-50%) scale(1.08);
}
.bts-btn-prev { left: 0.75rem; }
.bts-btn-next { right: 0.75rem; }

@media (max-width: 768px) {
    .bts-slide { flex: 0 0 86%; }
    .bts-btn { width: 44px; height: 44px; font-size: 1.3rem; }
}

/* ---------- Posts ---------- */
.posts { background: var(--surface); }
.posts-grid {
    max-width: var(--maxw);
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}
.post {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem;
    transition: border-color 0.3s, transform 0.3s;
}
.post:hover { border-color: var(--accent); transform: translateY(-4px); }
.post img, .post video {
    width: 100%;
    border-radius: var(--radius);
    margin-bottom: 1rem;
}
.post h3 { font-size: 1.15rem; margin-bottom: 0.75rem; }
.post p { color: var(--muted); font-size: 0.95rem; }

/* ---------- Projects list (grid of cover cards) ---------- */
.projects-page,
.academy-page {
    padding: 5rem 1.5rem;
}
.projects-page > h1,
.academy-page > h1 {
    max-width: var(--maxw);
    margin: 0 auto 2.5rem;
    font-size: clamp(2rem, 4vw, 3rem);
}
.projects-grid,
.academy-grid {
    max-width: var(--maxw);
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}
.project-card,
.academy-card {
    position: relative;
    display: block;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--surface-2);
    transition: transform 0.3s ease;
}
.project-card:hover,
.academy-card:hover { transform: translateY(-4px); }
.project-card img,
.academy-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}
.project-card:hover img,
.academy-card:hover img { transform: scale(1.06); }
.project-card-placeholder,
.academy-card-placeholder {
    display: block;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #1a1a1a 0%, #0d0d0d 100%);
}
.project-card-overlay,
.academy-card-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: flex-end;
    padding: 1rem 1.25rem;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, transparent 60%);
    transition: background 0.3s;
}
.project-card:hover .project-card-overlay,
.academy-card:hover .academy-card-overlay {
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.15) 100%);
}
.project-card-title,
.academy-card-title {
    color: var(--text);
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
    line-height: 1.3;
}
@media (max-width: 1024px) {
    .projects-grid, .academy-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
    .projects-grid, .academy-grid { grid-template-columns: 1fr; }
}

/* ---------- Behind The Scenes gallery page (5-column grid) ---------- */
.bts-gallery-page {
    padding: 5rem 1.5rem;
}
.bts-gallery-page > h1 {
    max-width: var(--maxw);
    margin: 0 auto 2.5rem;
    font-size: clamp(2rem, 4vw, 3rem);
}
/* Justified row mosaic. Each row has uniform height; image widths vary
   by aspect ratio. Images flex-grow to fill any leftover row width, so
   row right-edges always align cleanly. Image rendering uses object-fit
   cover — the only edges that get cropped are the small amount where an
   item stretched past its natural width to fill the row. */
.bts-gallery-grid {
    max-width: var(--maxw);
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.bts-gallery-item {
    /* flex-basis: auto starts each item at its image's natural width
       (height-locked). flex-grow: 1 lets it stretch to fill remaining
       row space. flex-shrink: 1 lets very narrow rows compress. */
    flex: 1 1 auto;
    height: 260px;
    min-width: 180px;
    overflow: hidden;
    border-radius: var(--radius);
    position: relative;
    background: transparent;
}
.bts-gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}
.bts-gallery-item:hover img { transform: scale(1.04); }
.bts-gallery-item figcaption {
    position: absolute;
    inset: auto 0 0 0;
    padding: 1.25rem 0.75rem 0.6rem;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.85));
    color: var(--text);
    font-size: 0.8rem;
}
@media (max-width: 900px) {
    .bts-gallery-item { height: 220px; }
}
@media (max-width: 600px) {
    .bts-gallery-item { height: 180px; min-width: 140px; }
}

/* ---------- Casting page (auto-rotating hero) ---------- */
.casting-hero {
    position: relative;
    min-height: 92vh;
    display: flex;
    align-items: flex-end;
    padding: 0 1.5rem 5rem;
    overflow: hidden;
    border-bottom: 1px solid var(--border);
    background-color: var(--surface-2);
}
.casting-slides {
    position: absolute;
    inset: 0;
    z-index: 0;
}
.casting-slide {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0;
    transition: opacity 1.2s ease-in-out;
}
.casting-slide.is-active { opacity: 1; }
.casting-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(10, 10, 10, 0.30) 0%,
        rgba(10, 10, 10, 0.78) 100%
    );
    pointer-events: none;
    z-index: 1;
}
.casting-content {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: var(--maxw);
    margin: 0 auto;
    text-align: left;
}
.casting-text {
    display: none;
}
.casting-text.is-active {
    display: block;
    animation: casting-text-fade 0.9s ease-in-out;
}
@keyframes casting-text-fade {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}
.casting-headline {
    font-size: clamp(2rem, 4.5vw, 3.6rem);
    font-weight: 700;
    line-height: 1.1;
    color: #ffffff;
    margin: 0 0 1.25rem;
    max-width: 1000px;
    letter-spacing: -0.01em;
    text-shadow: 0 2px 24px rgba(0, 0, 0, 0.5);
}
.casting-description {
    font-family: "Alyamama", sans-serif;
    font-size: clamp(1rem, 1.4vw, 1.25rem);
    font-weight: 300;
    color: rgba(242, 242, 242, 0.95);
    max-width: 1000px;
    line-height: 1.7;
    margin: 0 0 3.5rem;
}
.casting-button {
    display: inline-block;
    background: var(--accent);
    color: white;
    padding: 1rem 2.5rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 0.9rem;
    border-radius: var(--radius);
    transition: transform 0.2s, filter 0.2s;
    margin-top: 1rem;
}
.casting-button:hover {
    transform: translateY(-2px);
    filter: brightness(1.1);
}

/* ---------- News list (grid of cover images) ---------- */
.news-page {
    padding: 5rem 1.5rem;
}
.news-page > h1 {
    max-width: var(--maxw);
    margin: 0 auto 2.5rem;
    font-size: clamp(2rem, 4vw, 3rem);
}
.news-grid {
    max-width: var(--maxw);
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1rem;
}
.news-card {
    position: relative;
    display: block;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--surface-2);
    transition: transform 0.3s ease;
}
.news-card:hover { transform: translateY(-4px); }
.news-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}
.news-card:hover img { transform: scale(1.06); }
.news-card-placeholder {
    display: block;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #1a1a1a 0%, #0d0d0d 100%);
}
.news-card-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: flex-end;
    padding: 0.85rem;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0) 60%);
    transition: background 0.3s;
}
.news-card:hover .news-card-overlay {
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.15) 100%);
}
.news-card-title {
    color: var(--text);
    font-size: 0.85rem;
    font-weight: 600;
    line-height: 1.3;
    letter-spacing: 0.01em;
}
/* Arabic titles get pushed to the right edge of the card overlay. */
.news-card-title.lang-ar {
    margin-left: auto;
    text-align: right;
}
@media (max-width: 1024px) {
    .news-grid { grid-template-columns: repeat(4, 1fr); }
}
@media (max-width: 800px) {
    .news-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 540px) {
    .news-grid { grid-template-columns: repeat(2, 1fr); gap: 0.6rem; }
}

/* ---------- Arabic content (auto-applied via news_extras filter) ---------- */
.lang-ar {
    font-family: "Alyamama", "Segoe UI", sans-serif;
    direction: rtl;
    text-align: right;
    line-height: 1.85;
}
/* Inherit through linebreaks-wrapped paragraphs */
.lang-ar p {
    direction: rtl;
    text-align: right;
}

/* ---------- News detail page ---------- */
.news-detail {
    max-width: 900px;
    margin: 0 auto;
    padding: 4rem 1.5rem 5rem;
}
.news-detail-back {
    margin-bottom: 1.5rem;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}
.news-detail-back a {
    color: var(--muted);
    transition: color 0.2s;
}
.news-detail-back a:hover { color: var(--accent); }
.news-detail h1 {
    font-size: clamp(1.8rem, 3.5vw, 2.6rem);
    margin-bottom: 0.5rem;
    line-height: 1.2;
}
.news-detail time {
    display: block;
    color: var(--muted);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 2.5rem;
}
.news-detail-body {
    font-size: 1.05rem;
    line-height: 1.75;
    color: rgba(242, 242, 242, 0.85);
    margin-bottom: 3rem;
}
.news-detail-images {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1rem;
}
.news-detail-images figure {
    aspect-ratio: 4 / 3;
    overflow: hidden;
    border-radius: var(--radius);
    position: relative;
}
.news-detail-images img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}
.news-detail-images figure:hover img { transform: scale(1.04); }
.news-detail-images figcaption {
    position: absolute;
    bottom: 0.5rem;
    left: 0.75rem;
    font-size: 0.8rem;
    color: var(--muted);
}

/* ---------- News page hero (legacy, no longer used) ---------- */
.news-hero {
    min-height: 70vh;
    background: linear-gradient(180deg, var(--surface) 0%, var(--bg) 100%);
    border-bottom: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 5rem 1.5rem;
}
.news-hero > h1 {
    text-align: center;
    font-size: clamp(2.5rem, 5vw, 4rem);
    margin-bottom: 3rem;
}
.news-list {
    max-width: var(--maxw);
    margin: 0 auto;
    display: grid;
    gap: 2rem;
    width: 100%;
}
.news-item {
    padding: 2rem;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    transition: border-color 0.3s;
}
.news-item:hover { border-color: var(--accent); }
.news-item h2 {
    font-size: clamp(1.3rem, 2vw, 1.7rem);
    margin-bottom: 0.5rem;
}
.news-item time {
    color: var(--muted);
    font-size: 0.85rem;
    display: block;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}
.news-item p { color: var(--muted); margin-bottom: 1rem; }
.news-images {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 0.75rem;
    margin-top: 1.5rem;
}
.news-images figure {
    aspect-ratio: 4 / 3;
    overflow: hidden;
    border-radius: var(--radius);
}
.news-images img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ---------- About ---------- */
.about-section {
    position: relative;
    padding: 6rem 1.5rem;
    overflow: hidden;
}
.about-section.has-bg {
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}
.about-section.has-bg::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.2);
    pointer-events: none;
    z-index: 0;
}
.about {
    position: relative;
    z-index: 1;
    max-width: var(--maxw);
    margin: 0 auto;
    display: grid;
    gap: 3rem;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}
.about article h2 {
    font-size: clamp(1.6rem, 2.5vw, 2.2rem);
    margin-bottom: 1rem;
    position: relative;
    padding-bottom: 0.75rem;
}
.about article h2::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 3px;
    background: var(--accent);
}
.about article p { color: var(--muted); font-size: 1.05rem; }

/* ---------- Team ---------- */
.team { background: var(--surface); }
.team-list {
    max-width: var(--maxw);
    margin: 0 auto;
    list-style: none;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 2rem;
}
.team-member { text-align: center; }
.team-member img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    margin-bottom: 1rem;
    filter: grayscale(100%);
    transition: filter 0.4s;
    border-radius: var(--radius);
}
.team-member:hover img { filter: grayscale(0); }
.team-member h3 {
    font-size: 1.05rem;
    margin-bottom: 0.25rem;
}
.team-member .role {
    color: var(--accent);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 0.75rem;
}
.team-member .bio {
    color: var(--muted);
    font-size: 0.9rem;
}

/* ---------- Contact ---------- */
.contact-page {
    max-width: 620px;
    margin: 0 auto;
    padding: 6rem 1.5rem;
}
.contact-page h1 {
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 0.75rem;
}
.contact-page > p {
    color: var(--muted);
    margin-bottom: 2.5rem;
}
.contact-form {
    display: grid;
    gap: 1.75rem;
}
.form-field label {
    display: block;
    font-size: 0.8rem;
    margin-bottom: 0.5rem;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}
.form-field input,
.form-field textarea {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid var(--border);
    padding: 0.75rem 0;
    color: var(--text);
    font: inherit;
    font-size: 1rem;
    outline: none;
    transition: border-color 0.2s;
}
.form-field input:focus,
.form-field textarea:focus { border-color: var(--accent); }
.form-field textarea { min-height: 120px; resize: vertical; }
.contact-form button {
    justify-self: start;
    background: var(--accent);
    color: white;
    border: none;
    padding: 1rem 2rem;
    font: inherit;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    border-radius: var(--radius);
    transition: transform 0.2s, filter 0.2s;
}
.contact-form button:hover { transform: translateY(-2px); filter: brightness(1.1); }
.errors {
    list-style: none;
    color: #ff6b6b;
    font-size: 0.85rem;
    margin-top: 0.5rem;
}
/* Honeypot — visually hidden but reachable for bots that "see" everything */
.hp-field {
    position: absolute !important;
    left: -10000px !important;
    top: auto !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
}
.contact-success {
    max-width: 600px;
    margin: 0 auto;
    padding: 8rem 1.5rem;
    text-align: center;
}
.contact-success h1 { font-size: 2.5rem; margin-bottom: 1rem; }
.contact-success p { color: var(--muted); margin-bottom: 1rem; }

/* ---------- Footer ---------- */
.site-footer {
    background: #000;
    border-top: 1px solid var(--border);
    padding: 3rem 1.5rem 1.5rem;
}
.footer-inner {
    max-width: var(--maxw);
    margin: 0 auto;
    display: grid;
    gap: 2.5rem;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}
.footer-company h3 {
    font-size: 1.15rem;
    margin-bottom: 0.5rem;
}
.footer-company p,
.footer-contact p {
    color: var(--muted);
    font-size: 0.9rem;
    margin-bottom: 0.4rem;
}
.footer-contact a { color: var(--muted); }
.footer-contact a:hover { color: var(--accent); }
.footer-social {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-content: start;
}
.footer-social a {
    color: var(--muted);
    font-size: 0.85rem;
    transition: color 0.2s;
}
.footer-social a:hover { color: var(--accent); }
.footer-copy {
    grid-column: 1 / -1;
    text-align: center;
    color: var(--muted);
    padding-top: 1.5rem;
    margin-top: 1rem;
    border-top: 1px solid var(--border);
    font-size: 0.8rem;
}

/* ---------- Responsive ---------- */
@media (max-width: 640px) {
    .site-nav { padding: 1rem; }
    .nav-links { gap: 1.25rem; font-size: 0.9rem; }
    section { padding: 3.5rem 1rem; }
    .hero { height: 80vh; min-height: 420px; }
}
