/* ============================================================
   OIR TECHNOLOGIES — Design System
   ============================================================ */

/* ---------- Fonts ---------- */
@import url('https://fonts.googleapis.com/css2?family=DM+Serif+Display:ital@0;1&family=Cormorant+Garamond:ital,wght@0,400;0,500;0,600;1,400;1,500&family=Inter:wght@400;500;600;700&display=swap');

/* ---------- Tokens ---------- */
:root {
  /* Brand color (tweakable) */
  --navy:        #07111F;
  --navy-2:      #10233F;
  --navy-3:      #19304f;
  --gold:        #C9A86A;
  --gold-soft:   #d9c096;
  --gold-deep:   #a8854a;
  --ivory:       #FAFAF8;
  --ivory-2:     #f1efe9;
  --gray:        #6B7280;
  --gray-light:  #9aa1ac;
  --line:        rgba(201, 168, 106, 0.18);
  --line-dark:   rgba(255,255,255,0.08);
  --line-light:  rgba(12, 22, 38, 0.08);

  /* Surfaces */
  --bg:          var(--ivory);
  --ink:         #0c1626;
  --ink-soft:    #3a4658;

  /* Type */
  --serif: "DM Serif Display", "Cormorant Garamond", Georgia, serif;
  --body:  "Inter", system-ui, -apple-system, sans-serif;
  --type-scale: 1;        /* tweakable multiplier */

  /* Spacing / rhythm */
  --space-unit: 1;        /* tweakable density multiplier */
  --section-y: calc(176px * var(--space-unit));
  --gutter: clamp(24px, 5vw, 80px);
  --maxw: 1240px;

  /* Radius (tweakable) */
  --radius: 18px;
  --radius-sm: 11px;
  --radius-lg: 26px;

  /* Shadows — soft, breathy, border-light */
  --shadow-card: 0 2px 4px rgba(12,22,38,.03), 0 24px 60px -34px rgba(12,22,38,.22);
  --shadow-float: 0 40px 90px -36px rgba(7,17,31,.5);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--body);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
::selection { background: var(--gold); color: var(--navy); }

/* ---------- Typography ---------- */
.serif { font-family: var(--serif); font-weight: 400; }
h1, h2, h3 { font-family: var(--serif); font-weight: 400; line-height: 1.04; letter-spacing: -0.01em; margin: 0; }

.display {
  font-family: var(--serif);
  font-size: calc(clamp(3rem, 6.4vw, 5.9rem) * var(--type-scale));
  line-height: 1.0;
  letter-spacing: -0.02em;
}
.h-xl { font-family: var(--serif); font-size: calc(clamp(2.6rem, 5vw, 4.4rem) * var(--type-scale)); line-height: 1.04; letter-spacing: -0.015em; }
.h-lg { font-family: var(--serif); font-size: calc(clamp(2.2rem, 3.9vw, 3.5rem) * var(--type-scale)); line-height: 1.06; letter-spacing: -0.012em; }
.h-md { font-family: var(--serif); font-size: calc(clamp(1.5rem, 2.2vw, 2.05rem) * var(--type-scale)); line-height: 1.12; }

.eyebrow {
  font-family: var(--body);
  font-weight: 600;
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold-deep);
}
.on-dark .eyebrow, .eyebrow.on-dark { color: var(--gold); }

.lead {
  font-size: calc(clamp(1.05rem, 1.5vw, 1.3rem) * var(--type-scale));
  line-height: 1.6;
  color: var(--ink-soft);
  font-weight: 400;
}
.muted { color: var(--gray); }
em.gold, .gold-text { color: var(--gold-deep); font-style: italic; }
.on-dark .gold-text { color: var(--gold); }

/* ---------- Layout ---------- */
.wrap { max-width: var(--maxw); margin: 0 auto; padding-inline: var(--gutter); }
.wrap-wide { max-width: 1440px; margin: 0 auto; padding-inline: var(--gutter); }
.section { padding-block: var(--section-y); }
.section-sm { padding-block: calc(90px * var(--space-unit)); }
.on-dark { background: var(--navy); color: var(--ivory); }
.on-dark .muted { color: var(--gray-light); }
.on-dark .lead { color: rgba(250,250,248,.74); }
.on-navy2 { background: var(--navy-2); color: var(--ivory); }
.on-ivory2 { background: var(--ivory-2); }

.eyebrow-center { text-align: center; }
.section-head { max-width: 800px; }
.section-head.center { margin-inline: auto; text-align: center; }
.section-head .eyebrow { display: block; margin-bottom: 24px; }
.section-head h2 { margin-bottom: 0; }

.grid { display: grid; gap: clamp(20px, 3vw, 40px); }
.cols-2 { grid-template-columns: repeat(2, 1fr); }
.cols-3 { grid-template-columns: repeat(3, 1fr); }
.cols-4 { grid-template-columns: repeat(4, 1fr); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 12px;
  font-family: var(--body); font-weight: 600; font-size: 0.84rem;
  letter-spacing: 0.12em; text-transform: uppercase;
  padding: 17px 30px; border: 1px solid transparent;
  border-radius: calc(var(--radius-sm) - 1px);
  transition: transform .25s cubic-bezier(.2,.7,.2,1), background .25s, color .25s, border-color .25s;
}
.btn .arr { transition: transform .3s cubic-bezier(.2,.7,.2,1); }
.btn:hover .arr { transform: translateX(5px); }
.btn-gold { background: var(--gold); color: var(--navy); }
.btn-gold:hover { background: var(--gold-soft); }
.btn-ghost { background: transparent; border-color: rgba(250,250,248,.28); color: var(--ivory); }
.btn-ghost:hover { border-color: var(--gold); color: var(--gold-soft); }
.btn-outline { background: transparent; border-color: var(--line); color: var(--ink); }
.btn-outline:hover { border-color: var(--gold-deep); color: var(--gold-deep); }
.btn-lg { padding: 21px 36px; font-size: 0.86rem; }

.link-gold {
  display: inline-flex; align-items: center; gap: 9px;
  font-weight: 600; font-size: 0.76rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--gold-deep);
}
.on-dark .link-gold { color: var(--gold); }
.link-gold .arr { transition: transform .3s cubic-bezier(.2,.7,.2,1); }
.link-gold:hover .arr { transform: translateX(5px); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 80;
  background: rgba(7,17,31,0); backdrop-filter: saturate(140%) blur(0px);
  transition: background .4s, backdrop-filter .4s, border-color .4s;
  border-bottom: 1px solid transparent;
}
.site-header.solid {
  background: rgba(7,17,31,.86); backdrop-filter: saturate(160%) blur(16px);
  border-bottom: 1px solid var(--line-dark);
}
.site-header.light-page { background: rgba(7,17,31,.92); }
.nav {
  display: flex; align-items: center; justify-content: space-between;
  height: 84px; color: var(--ivory);
}
.brand { display: flex; align-items: center; gap: 14px; }
.brand .mark { width: 30px; height: 30px; flex: none; filter: drop-shadow(0 0 5px rgba(201,168,106,.45)); }
.brand .brand-name { display: block; font-family: var(--serif); font-size: 1.7rem; letter-spacing: 0.2em; line-height: 1; }
.brand .brand-sub { display: block; font-size: 0.5rem; letter-spacing: 0.42em; text-transform: uppercase; color: var(--gold-soft); margin-top: 4px; }
.nav-links { display: flex; align-items: center; gap: 38px; }
.nav-links a {
  font-size: 0.8rem; font-weight: 500; letter-spacing: 0.13em; text-transform: uppercase;
  color: rgba(250,250,248,.82); position: relative; padding-block: 6px;
}
.nav-links a::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 1.5px; width: 0;
  background: var(--gold); transition: width .3s cubic-bezier(.2,.7,.2,1);
}
.nav-links a:hover, .nav-links a.active { color: var(--ivory); }
.nav-links a.active::after, .nav-links a:hover::after { width: 100%; }
.nav-cta { display: flex; align-items: center; gap: 18px; }
.nav-toggle { display: none; background: none; border: none; color: var(--ivory); padding: 8px; }

/* Mobile nav */
.mobile-menu {
  position: fixed; inset: 0; z-index: 90; background: var(--navy);
  transform: translateY(-100%); transition: transform .45s cubic-bezier(.6,.05,.1,1), visibility .45s;
  visibility: hidden;
  display: flex; flex-direction: column; padding: 28px var(--gutter);
}
.mobile-menu.open { transform: translateY(0); visibility: visible; }
.mobile-menu .mm-top { display: flex; justify-content: space-between; align-items: center; color: var(--ivory); }
.mobile-menu nav { display: flex; flex-direction: column; gap: 4px; margin-top: 48px; }
.mobile-menu nav a {
  font-family: var(--serif); font-size: 2rem; color: var(--ivory);
  padding-block: 12px; border-bottom: 1px solid var(--line-dark);
}
.mobile-menu nav a:hover { color: var(--gold); }
.mobile-menu .mm-cta { margin-top: auto; }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy); color: var(--ivory); padding-top: 80px; }
.footer-grid {
  display: grid; grid-template-columns: 1.6fr repeat(4, 1fr); gap: 40px;
  padding-bottom: 60px; border-bottom: 1px solid var(--line-dark);
}
.footer-brand .brand-name { font-family: var(--serif); font-size: 1.7rem; letter-spacing: 0.18em; }
.footer-brand .brand-sub { font-size: 0.5rem; letter-spacing: 0.42em; text-transform: uppercase; color: var(--gold-soft); margin: 4px 0 18px; }
.footer-brand p { color: var(--gray-light); font-size: 0.92rem; max-width: 240px; }
.footer-social { display: flex; gap: 14px; margin-top: 22px; }
.footer-social a { width: 38px; height: 38px; border: 1px solid var(--line-dark); border-radius: 50%; display: grid; place-items: center; color: var(--gray-light); transition: .25s; }
.footer-social a:hover { border-color: var(--gold); color: var(--gold); }
.footer-col h4 { font-family: var(--body); font-size: 0.72rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold-soft); margin: 0 0 18px; font-weight: 600; }
.footer-col a { display: block; color: rgba(250,250,248,.66); font-size: 0.92rem; padding-block: 6px; transition: .2s; }
.footer-col a:hover { color: var(--ivory); padding-left: 4px; }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; padding-block: 28px; color: var(--gray-light); font-size: 0.82rem; flex-wrap: wrap; gap: 12px; }

/* ---------- Cards & components ---------- */
.card {
  background: #fff; border: 1px solid rgba(12,22,38,.05); border-radius: var(--radius);
  box-shadow: var(--shadow-card); overflow: hidden;
}
.feature {
  display: flex; flex-direction: column; gap: 14px;
}
.feature .ic { color: var(--gold-deep); }
.on-dark .feature .ic { color: var(--gold); }
.feature h3 { font-family: var(--body); font-weight: 600; font-size: 1.06rem; letter-spacing: 0; }
.on-dark .feature h3 { color: var(--ivory); }
.feature p { color: var(--gray); font-size: 0.95rem; margin: 0; }
.on-dark .feature p { color: var(--gray-light); }

.divided > * { padding: 0 clamp(16px, 2.5vw, 34px); border-left: 1px solid var(--line); }
.divided > *:first-child { padding-left: 0; border-left: none; }
.on-dark .divided > * { border-color: var(--line-dark); }

/* Product chips/filters */
.filters { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.chip {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 12px 22px; border: 1px solid rgba(12,22,38,.07); border-radius: 100px;
  background: #fff; font-size: 0.85rem; font-weight: 500; color: var(--ink-soft);
  transition: .22s;
}
.chip:hover { border-color: var(--gold); color: var(--ink); }
.chip.active { background: var(--navy); color: var(--ivory); border-color: var(--navy); }
.chip .ic { width: 16px; height: 16px; }

/* Product card */
.product-card {
  background: #fff; border: 1px solid rgba(12,22,38,.045); border-radius: var(--radius-lg);
  overflow: hidden; box-shadow: var(--shadow-card);
  transition: transform .5s cubic-bezier(.2,.7,.2,1), box-shadow .5s;
  display: flex; flex-direction: column;
}
.product-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-float); }
.product-card .pc-visual { aspect-ratio: 4/3; position: relative; overflow: hidden; }
.product-card .pc-body { padding: 32px 30px 34px; display: flex; flex-direction: column; gap: 12px; flex: 1; }
.product-card .pc-cat { font-size: 0.68rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold-deep); font-weight: 600; }
.product-card h3 { font-size: 1.6rem; }
.product-card p { color: var(--gray); font-size: 0.96rem; margin: 0; flex: 1; line-height: 1.6; }
.product-card .link-gold { margin-top: 12px; }

/* badge icon disc */
.disc {
  width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center;
  background: var(--navy); color: var(--gold); flex: none;
}
.disc.gold { background: var(--gold); color: var(--navy); }

/* Reveal — DISABLED hiding for reliability. Content is always visible.
   A gentle, opacity-safe transform settle plays on .in (never hides content,
   even if frozen by a capture/print context). */
@media (prefers-reduced-motion: no-preference) {
  .anim .reveal.in { animation: oirRise .7s cubic-bezier(.2,.7,.2,1) both; }
  .anim .reveal.in.d1 { animation-delay: .06s; }
  .anim .reveal.in.d2 { animation-delay: .12s; }
  .anim .reveal.in.d3 { animation-delay: .18s; }
  .anim .reveal.in.d4 { animation-delay: .24s; }
}
@keyframes oirRise { from { transform: translateY(16px); } to { transform: none; } }

/* Decorative starburst */
.starburst { color: var(--gold); }

/* CTA band */
.cta-band { position: relative; overflow: hidden; }
.cta-band .glow {
  position: absolute; border: 1px solid var(--line); border-radius: 50%;
  pointer-events: none;
}

/* Stat */
.stat .num { font-family: var(--serif); font-size: clamp(2.4rem, 4vw, 3.4rem); color: var(--gold); line-height: 1; }
.stat .lbl { color: var(--gray-light); font-size: 0.9rem; margin-top: 8px; }

/* ---------- Tweaks panel ---------- */
#oirTweakFab {
  position: fixed; right: 22px; bottom: 22px; z-index: 200;
  width: 50px; height: 50px; border-radius: 50%; border: 1px solid var(--line-dark);
  background: var(--navy); color: var(--gold);
  display: grid; place-items: center; box-shadow: 0 14px 34px -12px rgba(7,17,31,.6);
  transition: transform .25s, background .25s;
}
#oirTweakFab:hover { transform: rotate(35deg) scale(1.05); }
#oirTweakPanel {
  position: fixed; right: 22px; bottom: 84px; z-index: 200; width: 304px;
  background: #fff; border: 1px solid var(--line-light); border-radius: 16px;
  box-shadow: var(--shadow-float); overflow: hidden;
  opacity: 0; visibility: hidden; transform: translateY(12px) scale(.98);
  transition: opacity .25s, transform .25s, visibility .25s;
}
#oirTweakPanel.open { opacity: 1; visibility: visible; transform: none; }
.tw-head { display: flex; justify-content: space-between; align-items: center;
  padding: 16px 18px; background: var(--navy); color: var(--ivory);
  font-family: var(--body); font-weight: 600; font-size: 0.82rem; letter-spacing: 0.1em; text-transform: uppercase; }
.tw-head button { background: none; border: none; color: var(--gray-light); padding: 0; }
.tw-head button:hover { color: var(--ivory); }
.tw-body { padding: 18px; display: flex; flex-direction: column; gap: 18px; }
.tw-group label { display: flex; justify-content: space-between; font-size: 0.7rem; font-weight: 600;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--gray); margin-bottom: 10px; }
.tw-group label em { font-style: normal; color: var(--gold-deep); }
.tw-swatches { display: flex; gap: 10px; }
.tw-swatches button { width: 34px; height: 34px; border-radius: 9px; border: 2px solid transparent;
  cursor: pointer; box-shadow: inset 0 0 0 1px rgba(0,0,0,.08); transition: .2s; }
.tw-swatches button.on { border-color: var(--gold-deep); transform: scale(1.06); }
.tw-seg { display: flex; gap: 6px; background: var(--ivory-2); padding: 4px; border-radius: 10px; }
.tw-seg button { flex: 1; padding: 8px 4px; border: none; background: transparent; border-radius: 7px;
  font-family: var(--body); font-size: 0.74rem; font-weight: 600; color: var(--gray); cursor: pointer; transition: .2s; }
.tw-seg button.on { background: #fff; color: var(--ink); box-shadow: 0 2px 8px -4px rgba(12,22,38,.3); }
.tw-group input[type=range] { -webkit-appearance: none; width: 100%; height: 4px; border-radius: 4px; background: var(--ivory-2); }
.tw-group input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 18px; height: 18px;
  border-radius: 50%; background: var(--gold); border: 2px solid #fff; box-shadow: 0 2px 6px rgba(12,22,38,.25); cursor: pointer; }
.tw-reset { padding: 11px; border: 1px solid var(--line-light); background: #fff; border-radius: 9px;
  font-family: var(--body); font-size: 0.76rem; font-weight: 600; color: var(--gray); cursor: pointer; }
.tw-reset:hover { border-color: var(--gold-deep); color: var(--gold-deep); }
@media (max-width: 620px) { #oirTweakPanel { width: calc(100vw - 32px); right: 16px; } }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  :root { --section-y: calc(112px * var(--space-unit)); }
  .nav-links, .nav-cta .btn { display: none; }
  .nav-toggle { display: inline-flex; }
  .cols-4 { grid-template-columns: repeat(2, 1fr); }
  .cols-3 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .divided > * { border-left: none; padding-inline: 0; }
}
@media (max-width: 620px) {
  body { font-size: 16px; }
  .cols-2, .cols-4 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  .nav { height: 70px; }
}

/* ---------- Transparency / illustrative labels ---------- */
.illus-note { display: inline-flex; align-items: center; gap: 8px; font-size: 0.78rem; color: var(--gray);
  letter-spacing: 0.01em; line-height: 1.5; margin-top: 14px; }
.illus-note::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--gold-deep); flex: none; }
.on-dark .illus-note, .screens .illus-note { color: var(--gray-light); }
.on-dark .illus-note::before, .screens .illus-note::before { background: var(--gold); }

.footer-transparency { padding-block: 24px 0; color: var(--gray-light); font-size: 0.8rem; line-height: 1.65; max-width: 780px; }
.footer-transparency a { color: var(--gold-soft); text-decoration: underline; text-underline-offset: 2px; }
.footer-transparency a:hover { color: var(--gold); }
