/* ==========================================================
   OUTDOOR — Global Styles
   Reset · Fonts · Typography · Base components
   ========================================================== */

/* --- Google Fonts: Playfair Display (serif) + JetBrains Mono --- */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,700;0,900;1,700&family=JetBrains+Mono:wght@400;500;700&display=swap');

/* --- FK Grotesk (self-hosted) --- */
@font-face {
  font-family: 'FK Grotesk';
  src: url('../assets/fonts/FKGroteskTrial-Thin.otf') format('opentype');
  font-weight: 100; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'FK Grotesk';
  src: url('../assets/fonts/FKGroteskTrial-Light.otf') format('opentype');
  font-weight: 300; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'FK Grotesk';
  src: url('../assets/fonts/FKGroteskTrial-Regular.otf') format('opentype');
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'FK Grotesk';
  src: url('../assets/fonts/FKGroteskTrial-Italic.otf') format('opentype');
  font-weight: 400; font-style: italic; font-display: swap;
}
@font-face {
  font-family: 'FK Grotesk';
  src: url('../assets/fonts/FKGroteskTrial-Medium.otf') format('opentype');
  font-weight: 500; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'FK Grotesk';
  src: url('../assets/fonts/FKGroteskTrial-Bold.otf') format('opentype');
  font-weight: 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'FK Grotesk';
  src: url('../assets/fonts/FKGroteskTrial-BoldItalic.otf') format('opentype');
  font-weight: 700; font-style: italic; font-display: swap;
}
@font-face {
  font-family: 'FK Grotesk';
  src: url('../assets/fonts/FKGroteskTrial-Black.otf') format('opentype');
  font-weight: 900; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'FK Grotesk';
  src: url('../assets/fonts/FKGroteskTrial-BlackItalic.otf') format('opentype');
  font-weight: 900; font-style: italic; font-display: swap;
}

/* --- Reset --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font);
  font-weight: 400;
  background: var(--bg);
  color: var(--text-body);
  line-height: 1.6;
  overflow-x: hidden;
  transition: background var(--t-slow), color var(--t-slow);
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font-family: var(--font); cursor: pointer; border: none; background: none; }
ul, ol { list-style: none; }
input, textarea { font-family: var(--font); }

/* --- Grain overlay --- */
.grain {
  position: fixed; inset: 0; z-index: 9999;
  pointer-events: none;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 180px 180px;
}
[data-theme="light"] .grain { opacity: 0.022; }

/* --- Layout utility --- */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: clamp(20px, 5vw, 60px);
}

/* --- Typography --- */
.label {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--orange);
  margin-bottom: var(--s4);
}

h1, h2, h3, h4 {
  font-weight: 900;
  color: var(--text-primary);
  line-height: 1.05;
  letter-spacing: -0.03em;
}

h1 { font-size: clamp(52px, 8vw, 100px); }
h2 { font-size: clamp(36px, 5vw, 64px); }
h3 { font-size: clamp(24px, 3vw, 36px); }

p { color: var(--text-body); line-height: 1.65; }

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--s2);
  padding: 12px 24px;
  border-radius: var(--r-full);
  font-family: var(--font);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.01em;
  transition: all var(--t-base);
  white-space: nowrap;
  cursor: pointer;
  border: none;
  text-decoration: none;
}
.btn-primary {
  background: var(--orange);
  color: #fff;
}
.btn-primary:hover {
  background: #e84500;
  transform: translateY(-1px);
  box-shadow: 0 8px 24px var(--orange-glow);
}
.btn-primary:active { transform: translateY(0); }
.btn-ghost {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border);
}
.btn-ghost:hover {
  background: var(--hover);
  border-color: var(--text-hint);
}
.btn-lg { padding: 16px 32px; font-size: 15px; }

/* --- Header --- */
.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  height: var(--nav-h);
  display: flex; align-items: center;
  transition: background var(--t-base), border-color var(--t-base);
  border-bottom: 1px solid transparent;
}
.site-header.scrolled {
  background: rgba(10,10,10,0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-color: var(--border);
}
[data-theme="light"] .site-header.scrolled {
  background: rgba(245,240,232,0.85);
}
.nav-inner {
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: clamp(20px, 5vw, 60px);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logo-link { display: flex; align-items: center; gap: 10px; }
.logo-img { height: 32px; width: auto; object-fit: contain; }
.logo-wordmark {
  font-size: 17px;
  font-weight: 900;
  letter-spacing: -0.03em;
  color: var(--text-primary);
  line-height: 1;
  white-space: nowrap;
}
.logo-o { color: var(--orange); }
.nav-right {
  display: flex;
  align-items: center;
  gap: var(--s5);
}
.nav-link {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-body);
  transition: color var(--t-fast);
}
.nav-link:hover { color: var(--text-primary); }

/* Theme toggle */
.theme-toggle {
  width: 36px; height: 36px;
  border-radius: var(--r-full);
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-body);
  display: flex; align-items: center; justify-content: center;
  font-size: 16px;
  transition: all var(--t-fast);
  cursor: pointer;
  flex-shrink: 0;
}
.theme-toggle:hover {
  background: var(--hover);
  color: var(--text-primary);
  border-color: var(--text-hint);
}
.toggle-icon { line-height: 1; }
[data-theme="dark"] .toggle-icon.moon { display: none; }
[data-theme="dark"] .toggle-icon.sun  { display: block; }
[data-theme="light"] .toggle-icon.sun  { display: none; }
[data-theme="light"] .toggle-icon.moon { display: block; }

/* --- Divider line --- */
.section-rule {
  width: 100%; height: 1px;
  background: var(--border);
  border: none;
}

/* --- Footer --- */
.site-footer {
  border-top: 1px solid var(--border);
  padding: var(--s8) 0 var(--s6);
}
.footer-inner {
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: clamp(20px, 5vw, 60px);
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--s8);
  flex-wrap: wrap;
}
.footer-logo { height: 28px; width: auto; margin-bottom: var(--s4); }
.footer-tagline {
  font-size: 13px;
  color: var(--text-hint);
  line-height: 1.5;
  max-width: 220px;
}
.footer-links {
  display: flex;
  gap: var(--s8);
  flex-wrap: wrap;
}
.footer-nav {
  display: flex;
  flex-direction: column;
  gap: var(--s3);
}
.footer-nav a {
  font-size: 14px;
  color: var(--text-body);
  transition: color var(--t-fast);
}
.footer-nav a:hover { color: var(--text-primary); }
.footer-social {
  display: flex;
  align-items: center;
  gap: var(--s4);
}
.social-link {
  display: flex; align-items: center; justify-content: center;
  width: 36px; height: 36px;
  border-radius: var(--r-full);
  border: 1px solid var(--border);
  color: var(--text-hint);
  transition: all var(--t-fast);
}
.social-link:hover {
  border-color: var(--orange);
  color: var(--orange);
  background: var(--orange-tint);
}
.footer-bottom {
  max-width: var(--max-w);
  margin-inline: auto;
  padding: var(--s5) clamp(20px, 5vw, 60px) 0;
  margin-top: var(--s7);
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--s3);
}
.footer-bottom p {
  font-size: 12px;
  color: var(--text-hint);
}

/* --- Scroll reveal base --- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity var(--t-slow), transform var(--t-slow);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}
.reveal-delay-1 { transition-delay: 100ms; }
.reveal-delay-2 { transition-delay: 200ms; }
.reveal-delay-3 { transition-delay: 320ms; }
.reveal-delay-4 { transition-delay: 440ms; }

/* Nav icon — always visible, inherits link colour */
.nav-icon { display: inline-flex; align-items: center; }

/* Nav icon button — circular bordered button, mirrors .theme-toggle */
.nav-icon-btn {
  width: 36px; height: 36px;
  border-radius: var(--r-full);
  border: 1px solid rgba(255, 78, 0, 0.45);
  background: var(--orange-tint);
  color: var(--orange);
  display: flex; align-items: center; justify-content: center;
  transition: all var(--t-fast);
  cursor: pointer;
  flex-shrink: 0;
  text-decoration: none;
}
.nav-icon-btn:hover {
  background: rgba(255, 78, 0, 0.18);
  color: var(--orange);
  border-color: var(--orange);
  box-shadow: 0 0 0 3px rgba(255, 78, 0, 0.12);
}

/* --- Mobile nav adjustments --- */
@media (max-width: 600px) {
  .nav-right { gap: var(--s3); }
  .btn-primary { padding: 10px 18px; font-size: 13px; }
}
