/* Tanweer Energy Solutions — design system v0.1 (homepage preview)
   Tokens follow docs/DESIGN.md and the Tanweer Brand Guidelines. */

/* ---------- Fonts (brand files, subset) ---------- */
@font-face { font-family: "Archivo Expanded"; src: url("../../fonts/archivo-expanded-medium.woff") format("woff"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Archivo Expanded"; src: url("../../fonts/archivo-expanded-semibold.woff") format("woff"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Poppins"; src: url("../../fonts/poppins-regular.woff") format("woff"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Poppins"; src: url("../../fonts/poppins-medium.woff") format("woff"); font-weight: 500; font-display: swap; }
@font-face { font-family: "IBM Plex Sans Arabic"; src: url("../../fonts/plex-arabic-regular.woff") format("woff"); font-weight: 400; font-display: swap; }
@font-face { font-family: "IBM Plex Sans Arabic"; src: url("../../fonts/plex-arabic-medium.woff") format("woff"); font-weight: 500; font-display: swap; }
@font-face { font-family: "IBM Plex Sans Arabic"; src: url("../../fonts/plex-arabic-semibold.woff") format("woff"); font-weight: 600; font-display: swap; }

/* ---------- Tokens ---------- */
:root {
  --ink: #0D0C0C;
  --navy: #263C82;
  --navy-deep: #1C2D63;
  --navy-soft: #B9C0D6;
  --orange: #F27722;
  --grey: #8D8D8D;
  --white: #FFFFFF;
  --paper: #F4F3F0;
  --line: #E2E0DB;
  --muted: #5A5856;

  --f-display: "Archivo Expanded", "Archivo", system-ui, sans-serif;
  --f-body: "Poppins", system-ui, -apple-system, "Segoe UI", sans-serif;
  --f-ar: "IBM Plex Sans Arabic", "Noto Sans Arabic", "Segoe UI", Tahoma, sans-serif;

  /* fluid type scale (≈1.25) */
  --t-xs: 0.8125rem;
  --t-sm: 0.9375rem;
  --t-base: clamp(1rem, 0.96rem + 0.2vw, 1.0625rem);
  --t-md: clamp(1.125rem, 1.05rem + 0.35vw, 1.3125rem);
  --t-lg: clamp(1.375rem, 1.2rem + 0.8vw, 1.625rem);
  --t-xl: clamp(1.75rem, 1.4rem + 1.5vw, 2.5625rem);
  --t-2xl: clamp(2.125rem, 1.5rem + 2.8vw, 3.25rem);
  --t-3xl: clamp(2.5rem, 1.6rem + 4vw, 4.125rem);

  --gutter: clamp(16px, 2vw, 24px);
  --margin: clamp(16px, 5vw, 80px);
  --maxw: 1320px;
  --section: clamp(80px, 11vw, 168px);
  --cut: clamp(64px, 9vw, 140px);       /* 60° corner cut height */
  --ease: cubic-bezier(.2,.7,.2,1);
  color-scheme: light;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--white); color: var(--ink);
  font-family: var(--f-body); font-size: var(--t-base); line-height: 1.6;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
:lang(ar) body, body:lang(ar) { font-family: var(--f-ar); line-height: 1.8; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
p { margin: 0; }
h1, h2, h3 { margin: 0; font-family: var(--f-display); font-weight: 600; letter-spacing: -0.01em; text-wrap: balance; }
:lang(ar) :is(h1, h2, h3) { font-family: var(--f-ar); letter-spacing: 0; }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 3px; border-radius: 2px; }
.skip { position: absolute; inset-inline-start: 16px; top: -100px; z-index: 100; background: var(--ink); color: var(--white); padding: 12px 16px; }
.skip:focus { top: 16px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.wrap { width: 100%; max-width: calc(var(--maxw) + 2 * var(--margin)); margin-inline: auto; padding-inline: var(--margin); }
.grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); }

/* eyebrow / label */
.label {
  display: inline-flex; align-items: center; gap: 12px;
  font-family: var(--f-display); font-weight: 500; font-size: var(--t-xs);
  text-transform: uppercase; letter-spacing: 0.1em; color: var(--muted);
}
.label::before { content: ""; width: 24px; height: 2px; background: var(--orange); }
:lang(ar) .label { font-family: var(--f-ar); font-size: var(--t-sm); letter-spacing: 0; text-transform: none; }

/* buttons & links */
.btn {
  display: inline-flex; align-items: center; gap: 14px; min-height: 52px; padding: 0 26px;
  font-family: var(--f-display); font-weight: 500; font-size: var(--t-sm); letter-spacing: 0.01em;
  background: var(--orange); color: var(--ink); border: 0; cursor: pointer;
  transition: background .25s var(--ease), transform .25s var(--ease);
}
.btn:hover { background: #FF8A3D; }
.btn:active { transform: translateY(1px); }
:lang(ar) .btn { font-family: var(--f-ar); font-size: var(--t-base); }
.arrow { width: 18px; height: 12px; flex: none; transition: transform .25s var(--ease); }
:dir(rtl) .arrow { transform: scaleX(-1); }
.btn:hover .arrow, .link:hover .arrow { transform: translateX(4px); }
:dir(rtl) .btn:hover .arrow, :dir(rtl) .link:hover .arrow { transform: scaleX(-1) translateX(4px); }

.link {
  display: inline-flex; align-items: center; gap: 12px; font-weight: 500;
  background: linear-gradient(currentColor, currentColor) no-repeat 0 100% / 0 1px;
  padding-block: 4px; transition: background-size .35s var(--ease);
}
:dir(rtl) .link { background-position: 100% 100%; }
.link:hover { background-size: 100% 1px; }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.94); backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid transparent; transition: border-color .3s; }
.site-header.is-scrolled { border-bottom-color: var(--line); }
.site-header .wrap { display: flex; align-items: center; gap: 32px; min-height: 84px; }
.brand { display: block; flex: none; }
.brand img { height: 40px; width: auto; }
:lang(ar) .brand img { height: 48px; }
.nav { margin-inline-start: auto; }
.nav ul { display: flex; gap: clamp(18px, 2.2vw, 34px); list-style: none; margin: 0; padding: 0; }
.nav a { font-size: var(--t-sm); font-weight: 500; padding-block: 6px; background: linear-gradient(var(--orange), var(--orange)) no-repeat 0 100% / 0 2px; transition: background-size .3s var(--ease); }
:dir(rtl) .nav a { background-position: 100% 100%; }
.nav a:hover, .nav a[aria-current="page"] { background-size: 100% 2px; }
.lang { font-size: var(--t-sm); font-weight: 500; color: var(--muted); padding: 6px 0; }
.lang:hover { color: var(--ink); }
.site-header .btn { min-height: 44px; padding-inline: 20px; }
.menu-toggle { display: none; margin-inline-start: auto; width: 44px; height: 44px; border: 0; background: none; cursor: pointer; padding: 10px; }
.menu-toggle span { display: block; height: 2px; background: var(--ink); margin-block: 6px; transition: transform .3s var(--ease), opacity .3s; }

@media (max-width: 1240px) {
  .nav, .site-header .btn, .site-header .lang { display: none; }
  .menu-toggle { display: block; }
  .site-header.is-open .nav { display: block; position: fixed; inset: 84px 0 0; background: var(--white); padding: 32px var(--margin); }
  .site-header.is-open .nav ul { flex-direction: column; gap: 4px; }
  .site-header.is-open .nav a { display: block; font-family: var(--f-display); font-size: var(--t-xl); padding-block: 10px; }
  :lang(ar) .site-header.is-open .nav a { font-family: var(--f-ar); }
  .site-header.is-open .nav .nav-extra { display: flex; gap: 24px; align-items: center; margin-top: 32px; }
  .site-header.is-open .menu-toggle span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
  .site-header.is-open .menu-toggle span:nth-child(2) { opacity: 0; }
  .site-header.is-open .menu-toggle span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
}
.nav-extra { display: none; }
.site-header.is-open .nav .nav-extra .btn { display: inline-flex; }

/* ---------- Hero ---------- */
.hero { padding-block: clamp(40px, 6vw, 88px) var(--section); }
.hero .grid { align-items: end; row-gap: 48px; }
.hero-copy { grid-column: 1 / span 5; padding-bottom: clamp(0px, 3vw, 40px); }
.hero h1 { font-size: var(--t-3xl); line-height: 1.04; margin-block: 28px 28px; }
:lang(ar) .hero h1 { line-height: 1.3; font-weight: 600; }
.hero-lead { font-size: var(--t-md); color: var(--muted); max-width: 34ch; }
:lang(ar) .hero-lead { max-width: 40ch; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 28px; margin-top: 40px; }
.hero-figure { grid-column: 6 / -1; margin: 0; margin-inline-end: calc(-1 * var(--margin)); }
.cut { position: relative; }
.cut img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover;
  clip-path: polygon(0 0, 100% 0, 100% 100%, calc(var(--cut) * 0.577) 100%, 0 calc(100% - var(--cut))); }
:dir(rtl) .cut img { clip-path: polygon(0 0, 100% 0, 100% calc(100% - var(--cut)), calc(100% - var(--cut) * 0.577) 100%, 0 100%); }
.cut::after { /* orange sliver along the 60° edge */
  content: ""; position: absolute; inset-inline-start: 0; bottom: 0; width: calc(var(--cut) * 0.577); height: var(--cut);
  background: var(--orange); clip-path: polygon(0 0, 0 100%, 100% 100%); }
:dir(rtl) .cut::after { clip-path: polygon(100% 0, 100% 100%, 0 100%); }
figcaption { margin-top: 16px; font-size: var(--t-xs); color: var(--muted); padding-inline-start: calc(var(--cut) * 0.577 + 16px); }
:lang(ar) figcaption { font-size: var(--t-sm); }

/* ---------- Statement ---------- */
.statement { background: var(--paper); padding-block: var(--section); }
.statement h2 { grid-column: 1 / span 9; font-size: var(--t-2xl); line-height: 1.12; margin-top: 28px; }
:lang(ar) .statement h2 { line-height: 1.45; }
.statement .cols { grid-column: 4 / -1; display: grid; grid-template-columns: 1fr 1fr; gap: var(--gutter) calc(var(--gutter) * 2); margin-top: clamp(40px, 6vw, 80px); color: #2C2A29; }
.statement .head { grid-column: 1 / -1; }

/* ---------- Services index ---------- */
.services { padding-block: var(--section); }
.section-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 24px; margin-bottom: clamp(40px, 6vw, 72px); }
.section-head h2 { font-size: var(--t-2xl); line-height: 1.1; margin-top: 20px; max-width: 18ch; }
:lang(ar) .section-head h2 { line-height: 1.45; max-width: 22ch; }
.svc-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--ink); counter-reset: svc; }
.svc-list li { border-bottom: 1px solid var(--line); }
.svc-list a { display: grid; grid-template-columns: 72px minmax(0, 5fr) minmax(0, 6fr) 40px; gap: var(--gutter); align-items: baseline; padding-block: clamp(22px, 2.6vw, 32px); position: relative; transition: background-color .3s var(--ease); }
.svc-list a::before { counter-increment: svc; content: counter(svc, decimal-leading-zero); font-family: var(--f-display); font-size: var(--t-xs); color: var(--muted); font-feature-settings: "tnum"; }
.svc-list h3 { font-size: var(--t-lg); line-height: 1.2; transition: color .25s; }
:lang(ar) .svc-list h3 { line-height: 1.5; }
.svc-list p { color: var(--muted); max-width: 52ch; }
.svc-list .arrow { justify-self: end; align-self: center; color: var(--ink); opacity: .35; transition: opacity .25s, transform .25s var(--ease); }
.svc-list a:hover { background-color: var(--paper); }
.svc-list a:hover h3 { color: var(--navy); }
.svc-list a:hover .arrow { opacity: 1; }

/* ---------- Featured project ---------- */
.feature { position: relative; background: var(--navy); color: var(--white); padding-block: var(--section); overflow: hidden; isolation: isolate; }
.feature .contour { position: absolute; inset: 0; z-index: -1; color: #fff; opacity: .07; width: 100%; height: 100%; }
.feature .label { color: var(--navy-soft); }
.feature .grid { row-gap: 56px; align-items: start; }
.feature-copy { grid-column: 1 / span 5; }
.feature h2 { font-size: var(--t-2xl); line-height: 1.1; margin-block: 24px 24px; }
:lang(ar) .feature h2 { line-height: 1.45; }
.feature-lead { color: #E3E7F2; max-width: 44ch; }
.feature-media { grid-column: 7 / -1; margin: 0; }
.feature-media img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.feature-media figcaption { color: var(--navy-soft); padding-inline-start: 0; }
.specs { margin: 48px 0 40px; display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 5fr); border-top: 1px solid rgba(255,255,255,.28); }
.specs dt, .specs dd { margin: 0; padding-block: 14px; border-bottom: 1px solid rgba(255,255,255,.16); font-size: var(--t-sm); }
.specs dt { color: var(--navy-soft); padding-inline-end: 16px; }
.specs dd { font-feature-settings: "tnum"; }
.specs .big { font-family: var(--f-display); font-size: var(--t-lg); font-weight: 600; color: var(--white); line-height: 1.3; }
.specs .big small { font-size: var(--t-sm); font-weight: 500; color: var(--orange); margin-inline-start: 4px; }
:lang(ar) .specs .big { font-family: var(--f-display); }
.feature .link { color: var(--white); }

/* ---------- Projects rail ---------- */
.projects { padding-block: var(--section); }
.proj-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: clamp(40px, 5vw, 64px) var(--gutter); }
.proj { grid-column: span 4; }
.proj:nth-child(2) { margin-top: clamp(0px, 8vw, 120px); }
.proj a { display: block; }
.proj .ph { overflow: hidden; background: var(--paper); }
.proj img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; transition: transform .8s var(--ease); }
.proj a:hover img { transform: scale(1.035); }
.proj .meta { margin-top: 20px; font-family: var(--f-display); font-size: var(--t-xs); text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
:lang(ar) .proj .meta { font-family: var(--f-ar); font-size: var(--t-sm); letter-spacing: 0; text-transform: none; }
.proj h3 { font-size: var(--t-lg); line-height: 1.25; margin-top: 8px; }
:lang(ar) .proj h3 { line-height: 1.5; }
.proj p { margin-top: 10px; color: var(--muted); font-size: var(--t-sm); }

/* ---------- Process ---------- */
.process { background: var(--paper); padding-block: var(--section); }
.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gutter); counter-reset: st; }
.steps li { border-top: 2px solid var(--ink); padding-top: 24px; position: relative; }
.steps li::before { counter-increment: st; content: counter(st, decimal-leading-zero); position: absolute; top: -2px; inset-inline-start: 0; width: 48px; height: 2px; background: var(--orange); font-size: 0; }
.steps .n { font-family: var(--f-display); font-size: var(--t-xs); color: var(--muted); font-feature-settings: "tnum"; }
.steps h3 { font-size: var(--t-lg); margin-block: 14px 12px; }
.steps p { color: var(--muted); font-size: var(--t-sm); max-width: 32ch; }

/* ---------- Equipment ---------- */
.equipment { padding-block: clamp(64px, 8vw, 112px); border-bottom: 1px solid var(--line); }
.equipment .grid { align-items: start; row-gap: 32px; }
.equipment .intro { grid-column: 1 / span 4; }
.equipment .intro p { margin-top: 16px; color: var(--muted); font-size: var(--t-sm); max-width: 36ch; }
.brands { grid-column: 6 / -1; list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 14px 34px; direction: ltr; justify-content: flex-start; }
:dir(rtl) .brands { justify-content: flex-end; }
.brands li { font-family: var(--f-display); font-weight: 600; font-size: var(--t-md); color: #3A3837; letter-spacing: -0.01em; }

/* ---------- CTA ---------- */
.cta { position: relative; background: var(--ink); color: var(--white); padding-block: var(--section); overflow: hidden; }
.cta::before { content: ""; position: absolute; top: 0; bottom: 0; inset-inline-end: 0; width: 26%; background: var(--orange);
  clip-path: polygon(0 100%, 100% 100%, 100% 0, 46% 0); }
:dir(rtl) .cta::before { clip-path: polygon(100% 100%, 0 100%, 0 0, 54% 0); }
.cta .inner { position: relative; max-width: 760px; }
.cta h2 { font-size: var(--t-3xl); line-height: 1.04; margin-block: 24px 24px; }
:lang(ar) .cta h2 { line-height: 1.35; }
.cta .label { color: var(--grey); }
.cta p:not(.label) { color: #C9C7C4; font-size: var(--t-md); max-width: 46ch; }
.cta .actions { display: flex; flex-wrap: wrap; align-items: center; gap: 28px; margin-top: 40px; }
.cta .link { color: var(--white); }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: #C9C7C4; padding-block: 72px 32px; border-top: 1px solid #2A2827; font-size: var(--t-sm); }
.site-footer .grid { row-gap: 48px; }
.f-brand { grid-column: 1 / span 3; }
.f-brand img { height: 44px; width: auto; }
:lang(ar) .f-brand img { height: 56px; }
.f-brand p { margin-top: 20px; max-width: 32ch; }
.f-col { grid-column: span 2; }
.f-col.wide { grid-column: span 4; }
.f-col.contact { grid-column: span 3; }
.f-col h2 { font-family: var(--f-display); font-size: var(--t-xs); font-weight: 500; letter-spacing: .1em; text-transform: uppercase; color: var(--grey); margin-bottom: 18px; }
:lang(ar) .f-col h2 { font-family: var(--f-ar); font-size: var(--t-sm); letter-spacing: 0; }
.f-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.f-col a:hover { color: var(--white); }
.f-col address { font-style: normal; display: grid; gap: 10px; }
.social { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: 20px; }
.legal { grid-column: 1 / -1; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; padding-top: 28px; border-top: 1px solid #2A2827; font-size: var(--t-xs); color: var(--grey); }
:lang(ar) .legal { font-size: var(--t-sm); }
.ltr { direction: ltr; unicode-bidi: isolate; }

/* ---------- Inner pages ---------- */
.btn.ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ink); }
.btn.ghost:hover { background: var(--ink); color: var(--white); }
.site-header .wrap { gap: 24px; }
.page-head { padding-block: clamp(40px, 6vw, 88px) clamp(48px, 6vw, 80px); border-bottom: 1px solid var(--line); }
.page-head h1 { font-size: var(--t-3xl); line-height: 1.05; margin-top: 24px; max-width: 18ch; }
:lang(ar) .page-head h1 { line-height: 1.35; max-width: 22ch; }
.page-lead { margin-top: 28px; font-size: var(--t-md); color: var(--muted); max-width: 56ch; }
.crumbs ol { list-style: none; margin: 0 0 40px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; font-size: var(--t-xs); color: var(--muted); }
.crumbs li + li::before { content: "/"; margin-inline-end: 8px; color: var(--line); }
.crumbs a:hover { color: var(--ink); }
:lang(ar) .crumbs ol { font-size: var(--t-sm); }
.tight { padding-block: clamp(48px, 6vw, 96px); }
.big-lead { grid-column: 1 / span 6; font-size: var(--t-lg); line-height: 1.5; }
:lang(ar) .big-lead { line-height: 1.8; }
.about-intro { padding-block: clamp(56px, 7vw, 112px); }
.about-fig { grid-column: 8 / -1; margin: 0; }
.about-fig img, .svc-fig img, .gallery img, .proj-hero img { width: 100%; object-fit: cover; }
.pillars { background: var(--paper); padding-block: clamp(64px, 8vw, 128px); }
.pillars .grid { row-gap: 48px; }
.pillar { grid-column: span 4; border-top: 2px solid var(--ink); padding-top: 24px; }
.pillar p:not(.label) { margin-top: 20px; font-size: var(--t-md); line-height: 1.55; }
.facts { padding-block: clamp(64px, 8vw, 128px); }
.facts .grid > div { grid-column: span 6; }
.word-list, .plain-list, .tick-list, .chip-list { list-style: none; margin: 24px 0 0; padding: 0; }
.word-list li { font-family: var(--f-display); font-weight: 600; font-size: var(--t-xl); line-height: 1.3; }
:lang(ar) .word-list li { font-family: var(--f-ar); line-height: 1.6; }
.plain-list li { font-size: var(--t-md); padding-block: 14px; border-bottom: 1px solid var(--line); }
.svc-body, .proj-body { padding-block: clamp(56px, 7vw, 112px); }
.svc-body .grid, .proj-body .grid { row-gap: 48px; align-items: start; }
.prose { grid-column: 1 / span 6; display: grid; gap: 20px; font-size: var(--t-md); }
.prose h2.label { margin-top: 24px; font-size: var(--t-xs); }
:lang(ar) .prose h2.label { font-size: var(--t-sm); }
.svc-fig { grid-column: 8 / -1; margin: 0; }
.tick-list { margin-top: 0; }
.tick-list li { padding: 14px 0; border-bottom: 1px solid var(--line); padding-inline-start: 28px; position: relative; font-size: var(--t-base); }
.tick-list li::before { content: ""; position: absolute; inset-inline-start: 0; top: 24px; width: 14px; height: 2px; background: var(--orange); }
.other-svc { padding-block: 0 clamp(56px, 7vw, 96px); }
.chip-list { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.chip-list a { display: inline-block; padding: 10px 16px; border: 1px solid var(--line); font-size: var(--t-sm); transition: border-color .2s, background .2s; }
.chip-list a:hover { border-color: var(--ink); background: var(--paper); }
.proj-grid.all .proj:nth-child(2) { margin-top: 0; }
.proj-grid.all .proj:nth-child(3n+2) { margin-top: clamp(0px, 6vw, 80px); }
.proj .ph.type { aspect-ratio: 4 / 5; background: var(--navy); color: var(--white); display: flex; flex-direction: column; justify-content: space-between; padding: 28px; }
.proj .ph.type span { font-family: var(--f-display); font-weight: 600; font-size: var(--t-2xl); line-height: 1.05; }
:lang(ar) .proj .ph.type span { font-family: var(--f-ar); }
.proj .ph.type img { width: 40px; height: 40px; opacity: .9; }
.proj-hero { margin: 0; }
.proj-hero img { max-height: 72vh; }
.proj-body .prose { grid-column: 1 / span 5; }
.proj-body .grid > div:last-child { grid-column: 7 / -1; }
.headline-num { font-family: var(--f-display); font-weight: 600; font-size: var(--t-3xl); line-height: 1; color: var(--navy); }
.specs.light { margin: 16px 0 0; border-top-color: var(--ink); }
.specs.light dt { color: var(--muted); }
.specs.light dt, .specs.light dd { border-bottom-color: var(--line); }
.gallery { padding-bottom: clamp(56px, 7vw, 112px); }
.gallery .grid { row-gap: var(--gutter); }
.gallery figure { grid-column: span 4; margin: 0; }
.contact { padding-block: clamp(56px, 7vw, 112px); }
.contact .grid { row-gap: 56px; align-items: start; }
.contact-info { grid-column: 1 / span 5; display: grid; gap: 40px; }
.contact-info p:not(.label) { margin-top: 12px; }
.big-link { font-family: var(--f-display); font-weight: 600; font-size: var(--t-lg); line-height: 1.5; }
.big-link a:hover { color: var(--navy); }
.social-row { display: flex; gap: 20px; flex-wrap: wrap; }
.form { grid-column: 7 / -1; background: var(--paper); padding: clamp(24px, 4vw, 48px); display: grid; gap: 20px; }
.form h2 { font-size: var(--t-xl); }
.form label { display: grid; gap: 8px; font-size: var(--t-sm); font-weight: 500; }
.form input, .form select, .form textarea { font: inherit; font-size: var(--t-base); padding: 14px 16px; border: 1px solid #CFCCC6; background: var(--white); color: var(--ink); border-radius: 0; width: 100%; }
.form input:focus, .form select:focus, .form textarea:focus { outline: 3px solid var(--orange); outline-offset: 0; border-color: var(--ink); }
.form input:user-invalid { border-color: #B3261E; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form-error { color: #B3261E; font-size: var(--t-sm); font-weight: 500; }
.form-note { font-size: var(--t-xs); color: var(--muted); }
:lang(ar) .form-note { font-size: var(--t-sm); }
.form .btn { justify-self: start; }
@media (max-width: 960px) {
  .big-lead, .about-fig, .pillar, .facts .grid > div, .prose, .svc-fig, .proj-body .prose, .proj-body .grid > div:last-child, .gallery figure, .contact-info, .form { grid-column: 1 / -1; }
  .proj-grid.all .proj:nth-child(3n+2) { margin-top: 0; }
  .proj .ph.type { aspect-ratio: 3 / 2; }
}
@media (max-width: 560px) { .row2 { grid-template-columns: 1fr; } }

/* ---------- Calculator ---------- */
.calc { padding-block: clamp(48px, 6vw, 96px); }
.calc .grid { row-gap: 48px; align-items: start; }
.calc-form { grid-column: 1 / span 6; display: grid; gap: 16px; }
.calc-form fieldset { border: 0; border-top: 1px solid var(--line); margin: 0; padding: 28px 0 8px; display: grid; gap: 16px; min-width: 0; }
.calc-form legend { font-family: var(--f-display); font-weight: 600; font-size: var(--t-lg); padding: 0; margin-bottom: 8px; display: flex; gap: 16px; align-items: baseline; }
:lang(ar) .calc-form legend { font-family: var(--f-ar); }
.calc-form legend .n { font-size: var(--t-xs); color: var(--orange); font-feature-settings: "tnum"; }
.calc-form label { display: grid; gap: 8px; font-size: var(--t-sm); font-weight: 500; }
.calc-form input[type=number], .calc-form select { font: inherit; font-size: var(--t-base); padding: 13px 14px; border: 1px solid #CFCCC6; background: var(--white); color: var(--ink); border-radius: 0; width: 100%; }
.calc-form input:focus, .calc-form select:focus { outline: 3px solid var(--orange); outline-offset: 0; border-color: var(--ink); }
.calc-form .sub { font-weight: 500; margin-top: 8px; }
.row3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; align-items: end; }
.choices { display: flex; flex-wrap: wrap; gap: 10px; }
.choice { position: relative; display: inline-flex !important; }
.choice input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.choice span { display: inline-block; padding: 12px 18px; border: 1px solid #CFCCC6; font-size: var(--t-sm); font-weight: 500; transition: background .2s, color .2s, border-color .2s; }
.choice input:checked + span { background: var(--ink); color: var(--white); border-color: var(--ink); }
.choice input:focus-visible + span { outline: 3px solid var(--orange); outline-offset: 2px; }
.geo { justify-self: start; border: 0; background: none; font: inherit; font-size: var(--t-sm); cursor: pointer; color: var(--navy); padding: 4px 0; }
.geo-status { font-size: var(--t-xs); color: var(--muted); min-height: 1em; }
.calc-out { grid-column: 8 / -1; min-width: 0; position: sticky; top: 104px; background: var(--ink); color: var(--white); padding: clamp(24px, 3vw, 36px); display: grid; gap: 24px; }
.calc-out h2 { font-size: var(--t-lg); }
.calc-out .label { color: #A9A6A2; }
.calc-out .muted { color: #A9A6A2; font-size: var(--t-sm); }
.out-body { display: grid; gap: 24px; min-width: 0; }
.out-body > *, .calc-out > * { min-width: 0; }
.out-block { border-top: 1px solid #34312F; padding-top: 18px; }
.out-block .label { margin-bottom: 10px; }
.out-big { font-family: var(--f-display); font-weight: 600; font-size: var(--t-2xl); line-height: 1.1; }
.out-mid { font-family: var(--f-display); font-weight: 600; font-size: clamp(1.375rem, 1.1rem + 0.9vw, 1.875rem); line-height: 1.15; overflow-wrap: anywhere; }
.out-big small, .out-mid small, .kv small { font-family: var(--f-body); font-size: var(--t-xs); font-weight: 400; color: #A9A6A2; margin-inline-start: 4px; }
:lang(ar) .out-big small, :lang(ar) .out-mid small, :lang(ar) .kv small { font-family: var(--f-ar); font-size: var(--t-sm); }
.accent { color: var(--orange); }
.money { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; }
.kv { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px 16px; margin: 0; align-items: baseline; }
.kv dt { color: #C9C7C4; font-size: var(--t-sm); }
.kv dd { margin: 0; text-align: end; font-family: var(--f-display); font-weight: 600; font-size: var(--t-md); font-feature-settings: "tnum"; }
.mini-chart { margin: 16px 0 0; }
.mini-chart svg { width: 100%; max-width: 100%; height: auto; display: block; }
.mini-chart rect { fill: var(--orange); }
.mini-chart text { fill: #8D8D8D; font-size: 8px; text-anchor: middle; font-family: var(--f-body); }
.mini-chart figcaption { font-size: var(--t-xs); color: #A9A6A2; margin-top: 6px; padding: 0; }
.assump summary { cursor: pointer; font-size: var(--t-sm); font-weight: 500; color: #E6E4E1; }
.assump p { font-size: var(--t-xs); color: #A9A6A2; margin-top: 10px; }
.assump ul { list-style: none; padding: 0; margin: 10px 0 0; display: grid; gap: 6px; font-size: var(--t-xs); color: #C9C7C4; }
.assump li { display: flex; justify-content: space-between; gap: 12px; border-bottom: 1px solid #34312F; padding-bottom: 6px; }
:lang(ar) .assump p, :lang(ar) .assump ul { font-size: var(--t-sm); }
.disclaimer { font-size: var(--t-xs); color: #A9A6A2; }
:lang(ar) .disclaimer { font-size: var(--t-sm); }
.calc-out .btn { justify-self: start; }
@media (max-width: 960px) { .calc-form, .calc-out { grid-column: 1 / -1; } .calc-out { position: static; } }
@media (max-width: 560px) { .row3 { grid-template-columns: 1fr; } .money { grid-template-columns: 1fr; } }

/* ---------- School ---------- */
.school { padding-block: clamp(48px, 6vw, 96px); }
.school .grid { row-gap: 56px; }
.track { grid-column: span 6; }
.lesson-list { list-style: none; margin: 20px 0 0; padding: 0; border-top: 1px solid var(--ink); }
.lesson-list a { display: grid; gap: 10px; padding: 28px 0; border-bottom: 1px solid var(--line); position: relative; }
.lesson-list .meta { font-size: var(--t-xs); color: var(--muted); }
.lesson-list h3 { font-size: var(--t-lg); line-height: 1.25; padding-inline-end: 36px; }
:lang(ar) .lesson-list h3 { line-height: 1.5; }
.lesson-list p { color: var(--muted); }
.lesson-list .arrow { position: absolute; inset-inline-end: 0; top: 36px; }
.lesson-list a:hover h3 { color: var(--navy); }
.lesson { padding-block: clamp(48px, 6vw, 96px); }
.lesson .grid { row-gap: 48px; align-items: start; }
.lesson-text { grid-column: 1 / span 5; }
.review-note { font-size: var(--t-xs); color: var(--muted); border-inline-start: 3px solid var(--orange); padding-inline-start: 12px; }
.lesson-anim { grid-column: 7 / -1; margin: 0; position: sticky; top: 104px; background: var(--paper); padding: clamp(20px, 3vw, 32px); }
.lesson-anim figcaption { padding: 0; margin-top: 14px; }
.anim-stage .chart { width: 100%; height: auto; display: block; }
.anim-stage .tick { font-size: 11px; fill: var(--muted); text-anchor: middle; font-family: var(--f-body); }
.anim-stage .axis { stroke: var(--ink); stroke-width: 1; }
.anim-stage .pv { fill: rgba(242, 119, 34, .85); }
.anim-stage .load { fill: none; stroke: var(--ink); stroke-width: 2.5; }
.anim-stage .cursor { stroke: var(--navy); stroke-width: 2; }
.anim-stage .lbl { font-size: 12px; font-family: var(--f-body); font-weight: 500; fill: var(--ink); text-anchor: middle; }
.anim-stage .pv-l { fill: var(--white); }
.flows { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); margin-top: 18px; }
.flow { background: var(--white); padding: 14px; display: grid; gap: 6px; }
.flow span { font-size: var(--t-xs); color: var(--muted); }
:lang(ar) .flow span { font-size: var(--t-sm); }
.flow b { font-family: var(--f-display); font-size: var(--t-md); font-feature-settings: "tnum"; }
.flow b.on { color: #B3261E; }
.soc { display: block; height: 6px; background: var(--line); }
.soc i { display: block; height: 100%; background: var(--navy); transition: width .2s; }
.controls { display: flex; flex-wrap: wrap; gap: 16px 24px; align-items: end; margin-top: 18px; }
.controls label { display: grid; gap: 8px; font-size: var(--t-sm); font-weight: 500; flex: 1 1 220px; }
.controls output { font-family: var(--f-display); font-feature-settings: "tnum"; color: var(--navy); }
.controls input[type=range] { width: 100%; accent-color: var(--orange); }
.controls .btn { min-height: 44px; }
.hy-bar { position: relative; display: flex; height: 56px; background: var(--white); border: 1px solid var(--line); }
.hy-bar i { display: block; height: 100%; transition: width .25s var(--ease); }
.hy-bar .g { background: var(--ink); } .hy-bar .p { background: var(--orange); }
.hy-bar .c { background: repeating-linear-gradient(45deg, #CFCCC6 0 6px, #E9E7E3 6px 12px); }
.hy-bar .minmark { position: absolute; top: -8px; bottom: -8px; width: 2px; background: var(--navy); }
.hy-note { font-size: var(--t-xs); color: var(--navy); margin-top: 12px; }

/* ---------- Knowledge ---------- */
.knowledge { padding-block: clamp(40px, 5vw, 80px) clamp(56px, 7vw, 112px); }
.k-filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 32px; }
.chip { font: inherit; font-size: var(--t-sm); padding: 9px 16px; border: 1px solid #CFCCC6; background: var(--white); cursor: pointer; }
.chip.is-on { background: var(--ink); color: var(--white); border-color: var(--ink); }
.k-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--ink); }
.k-item { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 9fr); gap: var(--gutter); padding-block: 32px; border-bottom: 1px solid var(--line); }
.k-meta { display: grid; gap: 6px; align-content: start; font-size: var(--t-xs); color: var(--muted); }
.k-meta span:first-child { font-family: var(--f-display); text-transform: uppercase; letter-spacing: .1em; color: var(--navy); }
:lang(ar) .k-meta { font-size: var(--t-sm); } :lang(ar) .k-meta span:first-child { font-family: var(--f-ar); letter-spacing: 0; }
.k-body { display: grid; gap: 12px; max-width: 70ch; }
.k-body h3 { font-size: var(--t-lg); line-height: 1.3; }
:lang(ar) .k-body h3 { line-height: 1.55; }
.k-body p { color: #2C2A29; }
.k-body .link { justify-self: start; font-size: var(--t-sm); }
@media (max-width: 960px) { .track, .lesson-text, .lesson-anim { grid-column: 1 / -1; } .lesson-anim { position: static; } .k-item { grid-template-columns: 1fr; } }

/* ---------- Preview tag (removed for production) ---------- */
.preview-tag { position: fixed; inset-block-end: 16px; inset-inline-end: 16px; z-index: 60; background: var(--ink); color: var(--white); font-family: var(--f-display); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; padding: 8px 12px; border-inline-start: 3px solid var(--orange); }
:lang(ar) .preview-tag { font-family: var(--f-ar); font-size: 13px; letter-spacing: 0; }

/* ---------- Motion ---------- */
.reveal { opacity: 0; transform: translateY(12px); transition: opacity .6s var(--ease), transform .6s var(--ease); }
.reveal.is-in { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .hero-copy, .hero-figure, .feature-copy, .feature-media, .equipment .intro, .brands { grid-column: 1 / -1; }
  .hero-figure { margin-inline: 0 calc(-1 * var(--margin)); }
  .statement h2 { grid-column: 1 / -1; }
  .statement .cols { grid-column: 1 / -1; grid-template-columns: 1fr; }
  .svc-list a { grid-template-columns: 44px minmax(0, 1fr) 28px; }
  .svc-list p { grid-column: 2 / 3; }
  .svc-list .arrow { grid-row: 1; grid-column: 3; }
  .proj { grid-column: 1 / -1; }
  .proj:nth-child(2) { margin-top: 0; }
  .proj img { aspect-ratio: 3 / 2; }
  .steps { grid-template-columns: 1fr 1fr; row-gap: 48px; }
  .cta::before { width: 22%; }
  .f-brand, .f-col.wide, .f-col.contact { grid-column: 1 / -1; }
  .f-col { grid-column: span 6; }
}
@media (max-width: 560px) {
  .steps { grid-template-columns: 1fr; }
  .specs { grid-template-columns: 1fr; }
  .specs dt { border-bottom: 0; padding-bottom: 0; }
  .brands li { font-size: var(--t-md); }
  .cta::before { display: none; }
}

@media print {
  .site-header, .preview-tag, .cta::before, .feature .contour { display: none !important; }
  .feature, .cta, .site-footer { background: none; color: #000; }
  .reveal { opacity: 1; transform: none; }
}
