:root {
  --brand: #183d43;
  --accent: #267769;
  --ink: #172724;
  --f-border: #d7dfdc;
  --f-paper: #f5f7f6;
  --f-muted: #455c55;
  --f-gutter: clamp(16px, 4vw, 56px);
  color-scheme: light;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  color: var(--ink);
  background: #fff;
  font: 400 1rem/1.55 "Inter", "Noto Sans Arabic", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  -webkit-text-size-adjust: 100%;
}
body:lang(ar), [lang="ar"] {
  font-family: "Noto Sans Arabic", "Segoe UI", Tahoma, Arial, sans-serif;
}
a { color: var(--brand); text-underline-offset: .18em; }
button, input, select { font: inherit; }
button, select { cursor: pointer; }
:where(a, button, input, select, summary):focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
}
.f-wrap {
  width: min(calc(100% - var(--f-gutter) * 2), 1340px);
  margin-inline: auto;
  min-width: 0;
}
.f-wrap .f-wrap { width: 100%; }
.f-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  padding-block: 15px;
  border-block-end: 1px solid var(--f-border);
}
.f-head > .f-wrap, .f-foot > .f-wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 12px 24px;
}
.f-head > nav, .f-head nav.f-lang {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px 14px;
}
.f-head > nav a, .f-head > .f-wrap > nav a {
  color: var(--ink);
  text-decoration: none;
}
.f-head > nav a:hover, .f-head > .f-wrap > nav a:hover { text-decoration: underline; }
.f-brand {
  display: inline-flex;
  align-items: center;
  gap: .65rem;
  color: var(--brand);
  font-size: clamp(1.05rem, 2vw, 1.35rem);
  font-weight: 750;
  line-height: 1.15;
  letter-spacing: -.025em;
  text-decoration: none;
}
.f-brand img { display: block; width: auto; max-width: 190px; max-height: 38px; }
.f-lang { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: .875rem; }
.f-lang a, .f-lang select {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 5px 8px;
  min-height: 32px;
  color: var(--ink);
  border: 1px solid transparent;
  border-radius: 4px;
  background: #fff;
  text-decoration: none;
}
.f-lang a:hover, .f-lang a[aria-current], .f-lang select {
  border-color: var(--f-border);
  background: var(--f-paper);
}
.f-breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .4rem .6rem;
  margin-block: 15px 10px;
  color: var(--f-muted);
  font-size: .875rem;
  overflow-wrap: anywhere;
}
.f-breadcrumb a { color: var(--f-muted); }
.f-hero {
  margin-block: clamp(24px, 4vw, 52px) clamp(22px, 3.5vw, 42px);
  border-block-end: 1px solid var(--f-border);
  padding-block-end: clamp(20px, 3vw, 38px);
}
.f-kicker {
  display: block;
  margin: 0 0 .65rem;
  color: var(--brand);
  font-size: .875rem;
  line-height: 1.4;
  font-weight: 700;
  letter-spacing: .02em;
}
.f-hero h1, .f-detail h1 {
  max-width: 28ch;
  margin: 0;
  color: var(--ink);
  font-size: clamp(2rem, 4.8vw, 4rem);
  font-weight: 650;
  line-height: 1.08;
  letter-spacing: -.045em;
  overflow-wrap: break-word;
  text-wrap: balance;
}
.f-hero > p:not(.f-kicker), .f-hero > div > p:not(.f-kicker) { max-width: 75ch; }
.f-hero h1 + p { margin-block: .9rem 0; }
.f-layout { display: grid; gap: clamp(16px, 2vw, 32px); align-items: start; }
.f-layout > *, .f-product > * { min-width: 0; }
.f-filters, .f-tags {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
  margin-block: 14px;
}
.f-filters a, .f-filters button, .f-tags a {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: .45rem;
  max-width: 100%;
  min-height: 40px;
  padding: 7px 12px;
  border: 1px solid var(--f-border);
  border-radius: 5px;
  color: var(--ink);
  background: #fff;
  font-size: .9375rem;
  line-height: 1.35;
  text-align: start;
  text-decoration: none;
  overflow-wrap: anywhere;
}
.f-filters a:hover, .f-filters button:hover, .f-tags a:hover, .f-pages a:hover {
  border-color: var(--brand);
  background: var(--f-paper);
}
.f-filters :is(a, button)[aria-current], .f-filters .active, .f-tags a[aria-current] {
  border-color: var(--brand);
  color: #fff;
  background: var(--brand);
}
.f-search {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: 7px;
  margin-block: 16px;
  max-width: 50rem;
}
.f-search label:not(:has(input)) { flex: 0 0 100%; font-weight: 600; }
.f-search input, .f-search label:has(input) {
  flex: 1 1 15rem;
  min-width: min(100%, 8rem);
}
.f-search input { padding: 10px 13px; min-height: 44px; border: 1px solid #97a8a2; border-radius: 5px; color: var(--ink); background: #fff; }
.f-search input::placeholder { color: #5a6863; opacity: 1; }
.f-button, .f-search button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  max-width: 100%;
  min-height: 44px;
  padding: 9px 18px;
  border: 1px solid var(--brand);
  border-radius: 5px;
  color: #fff;
  background: var(--brand);
  font-size: 1rem;
  font-weight: 650;
  text-align: center;
  text-decoration: none;
}
.f-button:hover, .f-search button:hover { filter: brightness(.88); }
.f-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr));
  gap: clamp(12px, 1.8vw, 25px);
  margin-block: 14px 24px;
  padding: 0;
  list-style: none;
}
.f-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  height: 100%;
  overflow: hidden;
  border: 1px solid var(--f-border);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  text-decoration: none;
  transition: border-color .14s ease, box-shadow .14s ease;
}
.f-card:hover, .f-card:focus-within {
  border-color: #869e93;
  box-shadow: 0 2px 8px rgb(28 61 51 / 8%);
}
.f-card > a { display: flex; flex-direction: column; flex: 1; min-width: 0; color: inherit; text-decoration: none; }
.f-thumb, .f-photo {
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #fff;
  margin: 0;
}
.f-thumb { width: 100%; aspect-ratio: 4/3; border-block-end: 1px solid #edf1ef; padding: clamp(10px, 1.5vw, 22px); }
.f-thumb img, img.f-thumb, .f-photo img, img.f-photo { display: block; width: 100%; height: 100%; object-fit: contain; }
.f-tile { display: block; min-width: 0; padding: 14px 15px 16px; }
.f-tile h2, .f-tile h3, .f-card h2, .f-card h3 {
  margin: 0 0 7px;
  font-size: clamp(.99rem, 1.4vw, 1.12rem);
  line-height: 1.35;
  font-weight: 650;
  overflow-wrap: anywhere;
}
.f-tile p, .f-card p { margin-block: .35rem; }
.f-card > :is(h2,h3,p,.f-ref):not(.f-thumb), .f-card > a > :is(h2,h3,p,.f-ref):not(.f-thumb) { margin-inline: 15px; }
.f-card > :is(h2,h3):first-of-type, .f-card > a > :is(h2,h3):first-of-type { margin-block-start: 12px; }
.f-card > :last-child:not(a):not(.f-tile), .f-card > a > :last-child:not(.f-tile) { margin-block-end: 12px; }
.f-ref { display: block; color: var(--f-muted); font-size: .875rem; font-variant-numeric: tabular-nums; }
.f-product { display: grid; align-items: start; gap: clamp(20px, 4.5vw, 64px); margin-block: clamp(22px, 4vw, 42px); }
.f-photo { width: 100%; aspect-ratio: 1/1; border: 1px solid var(--f-border); border-radius: 8px; padding: clamp(16px, 3vw, 42px); }
.f-photo a { display: grid; place-items: center; width: 100%; height: 100%; }
.f-detail { min-width: 0; }
.f-detail h1 { font-size: clamp(1.75rem, 3.6vw, 3.1rem); max-width: 33ch; }
.f-detail p { max-width: 68ch; }
.f-detail dl { margin-block: 16px; }
.f-detail dl > div { display: grid; grid-template-columns: minmax(7rem, .6fr) 1fr; gap: 10px; padding-block: 9px; border-block-end: 1px solid var(--f-border); }
.f-detail dt { color: var(--f-muted); }
.f-detail dd { margin: 0; }
.f-detail ul { padding-inline-start: 1.25rem; }
.f-detail li { margin-block: .4rem; }
.f-note {
  margin-block: 15px;
  padding: 11px 14px;
  border-inline-start: 3px solid var(--accent);
  color: var(--ink);
  background: var(--f-paper);
  font-size: .9375rem;
}
.f-missing {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  min-height: 5rem;
  padding: 12px;
  color: var(--f-muted);
  background: var(--f-paper);
  font-size: .9375rem;
  text-align: center;
}
.f-source, .f-source a { color: var(--brand); text-underline-offset: .18em; }
.f-pages { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 8px; margin: 22px 0 40px; font-variant-numeric: tabular-nums; }
.f-pages a { display: inline-flex; align-items: center; min-height: 40px; padding: 7px 14px; border: 1px solid var(--f-border); border-radius: 5px; text-decoration: none; }
.f-pages [aria-current] { font-weight: 700; }
.f-foot { margin-block-start: 42px; padding-block: 22px; border-block-start: 1px solid var(--f-border); color: var(--f-muted); font-size: .9375rem; }
.f-foot a { color: var(--brand); }
.f-skip:not(:focus) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.f-skip:focus { position: fixed; z-index: 100; inset-block-start: 8px; inset-inline-start: 8px; padding: 10px 16px; background: #fff; color: var(--brand); }
[dir="rtl"] :is(.f-brand, .f-kicker, .f-hero h1, .f-detail h1) { letter-spacing: 0; }
[dir="rtl"] :is(.f-hero h1, .f-detail h1) { line-height: 1.35; }
@media (min-width: 800px) {
  .f-product:has(> .f-photo, > figure) { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
}
@media (min-width: 1024px) {
  .f-layout:has(> .f-filters) { grid-template-columns: minmax(170px, 220px) minmax(0, 1fr); }
  .f-layout > .f-filters { align-items: stretch; flex-direction: column; margin-block: 14px; }
}
@media (max-width: 650px) {
  .f-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .f-tile { padding: 10px; }
  .f-card > :is(h2,h3,p,.f-ref), .f-card > a > :is(h2,h3,p,.f-ref) { margin-inline: 10px; }
  .f-lang { gap: 2px; }
  .f-head { gap: 8px 16px; }
  .f-thumb { padding: 9px; }
  .f-photo { max-width: 500px; max-height: 66vh; }
}
@media (max-width: 350px) {
  .f-grid { grid-template-columns: 1fr; }
  .f-search { flex-direction: column; }
  .f-search input, .f-search label:has(input) { flex-basis: auto; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: 0s !important; animation-duration: 0s !important; }
}
@media print {
  .f-head, .f-filters, .f-search, .f-pages, .f-foot, .f-button, .f-lang { display: none !important; }
  .f-wrap { width: 100%; }
  .f-product, .f-card { break-inside: avoid; }
  .f-card { box-shadow: none; }
}
.f-nav { display:flex; align-items:center; gap:clamp(10px,3vw,32px); }
.f-nav > a { font-size:.9rem; }
details.f-lang { position:relative; display:block; }
.f-lang summary { cursor:pointer; padding:6px 8px; }
.f-lang[open] nav { position:absolute; inset-inline-end:0; top:100%; display:grid; z-index:3; min-width:136px; border:1px solid var(--f-border); background:#fff; box-shadow:0 6px 18px #18272016; border-radius:5px; padding:5px; }
.f-filters nav { display:flex; flex-wrap:wrap; gap:5px; }
.f-filters h2 { font-size:1rem; margin:4px 0; }
.f-filters small { opacity:.85; font-variant-numeric:tabular-nums; }
.f-search div { display:flex; flex-wrap:wrap; width:100%; gap:6px; }
.f-search input { min-width:0; width:100%; }
.f-search button { background:var(--brand); color:white; border-color:var(--brand); }
.f-count { color:var(--f-muted); font-size:.9rem; margin-top:10px; }
.f-tech { max-width:68rem; border-block:1px solid var(--f-border); padding-block:20px; }
.f-tech ul { padding-inline-start:1.3rem; margin-block:0 14px; }
.f-tech li { margin-block:.35rem; }
.f-tile .f-ref { margin-bottom:.45rem; }
.f-related { margin-block:32px; }
@media (min-width:1024px){ .f-filters nav { flex-direction:column; } .f-filters nav a { justify-content:space-between; } }
@media (max-width:650px){ .f-filters { display:block; } .f-nav { flex-wrap:wrap; } .f-hero { margin-block:18px; } .f-nav > a { max-width:18ch; } }
