/* ═══════════════════════════════════════════════════════
   fibtec.css — fibtec.co.uk design system
   Identity: Architectural precision · warm paper & clay
   Palette: adopted from pyvar.com's design system (portal/pyvar.css)
     for brand consistency across Fibtec's products — light paper
     background + clay/terracotta accent, replacing the previous
     obsidian & aged-gold dark theme.

   Variable NAMES are kept as --gold/--gold2/--gold3/--gold-line even
   though they now hold clay/terracotta values, not literal gold — a
   deliberate minimal-diff choice so this reskin doesn't require
   touching every rule across 5 HTML files that references them.
   Typography (serif/sans/mono) is unchanged; only colour changes.
═══════════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;0,600;1,300;1,400;1,500&family=Outfit:wght@300;400;500;600&family=IBM+Plex+Mono:wght@400;500&display=swap');

:root {
  --bg:    #faf9f5;
  --bg2:   #f3f1ea;
  --bg3:   #edeae1;
  --bg4:   #e5e1d5;
  --border: rgba(31,30,29,0.08);
  --border2:rgba(31,30,29,0.14);
  --border3:rgba(31,30,29,0.20);
  --text:  #1f1e1d;
  --text2: #6b6862;
  --dim:   #6b6862;
  --gold:  #a84a2e;
  --gold2: #b04d32;
  --gold3: rgba(168,74,46,0.10);
  --gold-line: rgba(168,74,46,0.20);
  --blue:  #4c6b7a;
  --blue2: rgba(76,107,122,0.10);
  --amber: #8a5d0f;
  --red:   #b23b32;
  --serif: 'Cormorant Garamond', Georgia, serif;
  --sans:  'Outfit', system-ui, sans-serif;
  --mono:  'IBM Plex Mono', Consolas, monospace;
  --radius: 3px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
::selection { background: rgba(168,74,46,0.15); }
a { color: inherit; text-decoration: none; }

/* ── Layout ── */
.container { max-width: 1160px; margin: 0 auto; padding: 0 36px; }

/* ── Nav ── */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  height: 62px; display: flex; align-items: center;
  padding: 0 36px; gap: 24px;
  background: rgba(250,249,245,0.92);
  backdrop-filter: blur(18px) saturate(1.3);
  border-bottom: 1px solid var(--border);
}
.nav-logo { display: flex; align-items: center; gap: 11px; }
.brand-logo { height: 26px; width: auto; display: block; }
.brand-logo--lg { height: 40px; }
.nav-links { display: flex; gap: 2px; flex: 1; }
.nav-links a {
  font-size: 13px; color: var(--text2); padding: 6px 13px;
  border-radius: var(--radius); transition: color .2s, background .2s;
}
.nav-links a:hover { color: var(--text); background: rgba(31,30,29,0.04); }
.nav-links a.active { color: var(--gold); }
.nav-right { display: flex; align-items: center; gap: 12px; margin-left: auto; }
.nav-cta {
  font-family: var(--mono); font-size: 11px; font-weight: 500;
  letter-spacing: .06em; text-transform: uppercase;
  color: var(--bg); background: var(--gold);
  padding: 9px 22px; border-radius: 2px; transition: background .2s;
}
.nav-cta:hover { background: var(--gold2); }

/* ── Typography ── */
.eyebrow {
  font-family: var(--mono); font-size: 10px; font-weight: 500;
  letter-spacing: .16em; text-transform: uppercase; color: var(--gold);
  display: flex; align-items: center; gap: 12px; margin-bottom: 18px;
}
.eyebrow::before { content: ''; width: 28px; height: 1px; background: var(--gold); flex-shrink: 0; }
.h1 {
  font-family: var(--serif);
  font-size: clamp(44px, 5.5vw, 78px);
  font-weight: 300; line-height: 1.07;
  letter-spacing: -.025em; color: var(--text);
}
.h1 em { font-style: italic; color: var(--gold); }
.h2 {
  font-family: var(--serif);
  font-size: clamp(30px, 3.5vw, 48px);
  font-weight: 300; line-height: 1.14;
  letter-spacing: -.02em; color: var(--text);
}
.h2 em { font-style: italic; color: var(--gold); }
.h3 { font-family: var(--serif); font-size: clamp(20px,2vw,28px); font-weight: 400; color: var(--text); letter-spacing: -.01em; }
.body-lg { font-size: 17px; font-weight: 300; color: var(--text2); line-height: 1.75; }
.body-md { font-size: 14px; font-weight: 300; color: var(--text2); line-height: 1.7; }
.body-sm { font-size: 13px; font-weight: 300; color: var(--text2); line-height: 1.65; }

/* ── Buttons ── */
.btn-gold {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--mono); font-size: 11px; font-weight: 500;
  letter-spacing: .08em; text-transform: uppercase;
  color: var(--bg); background: var(--gold);
  padding: 13px 28px; border-radius: 2px; transition: background .2s, transform .15s;
}
.btn-gold:hover { background: var(--gold2); transform: translateY(-1px); }
.btn-outline {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--mono); font-size: 11px; font-weight: 500;
  letter-spacing: .08em; text-transform: uppercase;
  color: var(--text2); border: 1px solid var(--border3);
  padding: 13px 28px; border-radius: 2px; transition: all .2s;
}
.btn-outline:hover { color: var(--text); border-color: var(--text2); transform: translateY(-1px); }

/* ── Sections ── */
.section { padding: 96px 0; }
.section-dark { background: var(--bg2); }
.divider { border: none; border-top: 1px solid var(--border); }

/* ── Page hero ── */
.page-hero {
  padding: 136px 0 72px;
  border-bottom: 1px solid var(--border);
  position: relative; overflow: hidden;
}
.hero-glow {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse 65% 70% at 65% 50%, rgba(168,74,46,0.05) 0%, transparent 70%);
  pointer-events: none;
}
.hero-grid-lines {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(168,74,46,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(168,74,46,0.03) 1px, transparent 1px);
  background-size: 52px 52px;
  mask-image: radial-gradient(ellipse 120% 100% at 100% 50%, black 10%, transparent 70%);
}

/* ── Reveal ── */
.reveal { opacity: 0; transform: translateY(20px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
.d1 { transition-delay: .08s; }
.d2 { transition-delay: .16s; }
.d3 { transition-delay: .24s; }

/* ── Grid helpers ── */
.grid-ruled {
  display: grid; gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

/* ── Footer ── */
.footer {
  background: var(--bg2); border-top: 1px solid var(--border);
  padding: 60px 0 32px;
}
.footer-inner {
  display: grid; grid-template-columns: 260px 1fr;
  gap: 80px; margin-bottom: 52px;
}
.footer-tagline { font-size: 13px; font-weight: 300; color: var(--text2); line-height: 1.65; margin: 14px 0 18px; max-width: 220px; }
.footer-contact { font-family: var(--mono); font-size: 11px; color: var(--dim); display: flex; flex-direction: column; gap: 6px; }
.footer-contact a { color: var(--text2); transition: color .2s; }
.footer-contact a:hover { color: var(--gold); }
.footer-nav { display: grid; grid-template-columns: repeat(3, 1fr); gap: 36px; }
.footer-col-title { font-family: var(--mono); font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); margin-bottom: 18px; }
.footer-col-links { display: flex; flex-direction: column; gap: 10px; }
.footer-col-links a { font-size: 13px; font-weight: 300; color: var(--text2); transition: color .2s; }
.footer-col-links a:hover { color: var(--text); }
.footer-bottom {
  border-top: 1px solid var(--border); padding-top: 26px;
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px;
}
.footer-copy { font-family: var(--mono); font-size: 10px; color: var(--dim); letter-spacing: .04em; }
.footer-legal { display: flex; gap: 24px; }
.footer-legal a { font-family: var(--mono); font-size: 10px; letter-spacing: .06em; text-transform: uppercase; color: var(--dim); transition: color .2s; }
.footer-legal a:hover { color: var(--text2); }

/* ── Responsive ── */
@media (max-width: 1024px) {
  .footer-inner { grid-template-columns: 1fr; gap: 40px; }
  .footer-nav { grid-template-columns: 1fr 1fr; gap: 28px; }
}
@media (max-width: 768px) {
  .container { padding: 0 20px; }
  .nav { padding: 0 20px; }
  .nav-links { display: none; }
  .section { padding: 64px 0; }
  .footer-nav { grid-template-columns: 1fr 1fr; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
}
