/* ═══════════════════════════════════════
   LAYOUT — Nav · Sections · Grids
═══════════════════════════════════════ */

/* ── NAV ── */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 500;
  display: flex; justify-content: space-between; align-items: center;
  padding: 1rem 1.5rem;
  background: rgba(6,30,41,0.96);
  border-bottom: 1px solid var(--border-gold);
  backdrop-filter: blur(12px);
  transition: background var(--trans);
}
[data-theme="light"] nav { background: rgba(243,239,233,0.96); }

.nav-brand { display: flex; align-items: center; gap: 0.7rem; }
.nav-logo-img {
  height: 36px; width: auto; object-fit: contain;
  mix-blend-mode: multiply;
  filter: none;
}
[data-theme="light"] .nav-logo-img { filter: none; }

.nav-brand-text {
  font-family: 'DisplaySerif', serif;
  font-size: 0.9rem; letter-spacing: 0.07em; color: var(--gold); line-height: 1.1;
}
.nav-brand-sub {
  font-size: 0.5rem; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--teal); opacity: 0.7; margin-top: 0.15rem;
}

.nav-links { display: flex; gap: 0; list-style: none; }
.nav-links a {
  font-size: 0.62rem; font-weight: 400;
  letter-spacing: 0.15em; text-transform: uppercase;
  color: var(--teal); text-decoration: none;
  opacity: 0.85; transition: opacity 0.2s, color 0.2s;
  padding: 0.5rem 0.85rem;
}
.nav-links a:hover { opacity: 1; color: var(--text); }
/* Light mode: full opacity so teal meets AA on sand bg */
[data-theme="light"] .nav-links a { opacity: 1; }

/* nav controls (lang + theme) */
.nav-controls { display: flex; align-items: center; gap: 0.5rem; }
.nav-hamburger {
  display: none; background: none; border: none; cursor: pointer;
  flex-direction: column; gap: 4px; padding: 6px;
}
.nav-hamburger span { display: block; width: 20px; height: 1.5px; background: var(--teal); }

/* lang switcher */
.lang-btn {
  font-size: 0.58rem; font-weight: 500; letter-spacing: 0.2em; text-transform: uppercase;
  background: transparent; border: 1px solid var(--border-gold); color: var(--gold);
  padding: 0.35rem 0.65rem; cursor: pointer;
  transition: background var(--trans), color var(--trans);
}
.lang-btn:hover, .lang-btn.active { background: var(--gold); color: var(--bg2); }

/* theme toggle */
.theme-btn {
  background: transparent; border: 1px solid var(--border-gold);
  color: var(--gold); padding: 0.35rem 0.6rem; cursor: pointer;
  font-size: 0.85rem; line-height: 1;
  transition: background var(--trans);
}
.theme-btn:hover { background: var(--border-gold); }

/* ── SECTIONS ── */
section { padding: 5rem 1.5rem; }
.inner  { max-width: 1100px; margin: 0 auto; }

.sec-label {
  display: inline-flex; align-items: center; gap: 0.6rem;
  font-size: 0.58rem; font-weight: 500;
  letter-spacing: 0.42em; text-transform: uppercase;
  color: var(--gold); opacity: 0.75; margin-bottom: 1rem;
}
.sec-title {
  font-family: 'DisplaySerif', serif;
  font-size: clamp(1.8rem, 5vw, 3rem);
  font-weight: 400; color: var(--text);
  line-height: 1.15; margin-bottom: 1.5rem;
}
.sec-body {
  font-size: 0.88rem; line-height: 1.9;
  color: var(--text); opacity: 0.6; max-width: 560px;
}

/* ── CONTEXT GRID ── */
.context-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; }
.ctx-visual   { position: relative; height: 380px; }
.ctx-box      {
  position: absolute;
  border: 1px solid var(--border);
  background: var(--surface);
}
.ctx-main  { inset: 0; display: flex; flex-direction: column; justify-content: flex-end; padding: 2rem; }
.ctx-quote {
  font-family: 'DisplaySerif', serif;
  font-size: 1.05rem; font-style: italic; color: var(--teal); opacity: 0.82; line-height: 1.6;
}
.ctx-mark {
  font-family: 'DisplaySerif', serif;
  font-size: 3.5rem; line-height: 0.6; color: var(--gold); opacity: 0.22;
  display: block; margin-bottom: 1rem;
}
.ctx-float {
  bottom: -1.5rem; right: -1.5rem; width: 160px; padding: 1.5rem;
  background: rgba(165,141,102,0.1); border-color: var(--border-gold);
}
.ctx-float-num { font-family: 'DisplaySerif', serif; font-size: 2.4rem; color: var(--gold); line-height: 1; }
.ctx-float-lbl { font-size: 0.55rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--teal); opacity: 0.6; margin-top: 0.4rem; }

/* ── INFO GRID ── */
.info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 5rem; align-items: start; }

/* ── FOOTER ── */
footer { padding: 2rem 1.5rem; border-top: 1px solid var(--border); }
.footer-inner {
  max-width: 1100px; margin: 0 auto;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 1rem;
}
.footer-brand { font-family: 'DisplaySerif', serif; font-size: 0.9rem; color: var(--gold); opacity: 0.65; }
.footer-org   { font-size: 0.58rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--teal); opacity: 0.35; margin-top: 0.25rem; }
.footer-logos { display: flex; align-items: center; gap: 1.5rem; }
.footer-logo-img { height: 38px; width: auto; object-fit: contain; opacity: 0.5; }
.footer-arabic   { font-family: 'ArabicNaskh', serif; font-size: 1.1rem; color: var(--teal); opacity: 0.22; }

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-links.open {
    display: flex; flex-direction: column;
    position: fixed; top: 60px; left: 0; right: 0;
    background: var(--bg); padding: 1.5rem; gap: 0.5rem;
    border-bottom: 1px solid var(--border-gold); z-index: 499;
  }
  .nav-links.open a { padding: 0.75rem 1rem; font-size: 0.72rem; }
  .nav-hamburger { display: flex; }
  .context-grid  { grid-template-columns: 1fr; }
  .ctx-visual    { height: 220px; margin-top: 1rem; }
  .ctx-float     { display: none; }
  .info-grid     { grid-template-columns: 1fr; }
  .footer-inner  { flex-direction: column; text-align: center; }
  .footer-logos  { justify-content: center; }
  section { padding: 4rem 1.2rem; }
}
