:root {
  --bg: #17140F;
  --bg-alt: #1F1B14;
  --panel: #221D15;
  --ink: #F2E9D8;
  --muted: #B8A98C;
  --amber: #E8A33D;
  --rust: #B8452F;
  --line: #3A3227;
  --shadow: 0 24px 60px -20px rgba(0, 0, 0, 0.55);
  --ease: cubic-bezier(.16, 1, .3, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; scroll-padding-top: 84px; }

body {
  background:
    radial-gradient(ellipse 900px 500px at 15% -10%, rgba(232, 163, 61, 0.09), transparent),
    radial-gradient(ellipse 700px 500px at 100% 20%, rgba(184, 69, 47, 0.07), transparent),
    var(--bg);
  background-attachment: fixed;
  color: var(--ink);
  font-family: 'Archivo', sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(242, 233, 216, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(242, 233, 216, 0.02) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, .7), transparent 75%);
  z-index: -1;
}

a { color: inherit; transition: color 0.15s ease; }
img { max-width: 100%; display: block; }
::selection { background: var(--amber); color: var(--bg); }
a:focus-visible, button:focus-visible { outline: 2px solid var(--amber); outline-offset: 3px; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; animation: none !important; }
}

.wrap { max-width: 960px; margin: 0 auto; padding: 0 28px; }

h1, h2, h3 {
  font-family: 'Big Shoulders Display', sans-serif;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.01em;
  line-height: 0.95;
}

/* SCROLL PROGRESS */
.scroll-progress {
  position: fixed;
  top: 0; left: 0;
  height: 3px;
  width: 0%;
  background: linear-gradient(90deg, var(--rust), var(--amber));
  z-index: 60;
  transition: width 0.1s ease-out;
}

/* NAV */
nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(23, 20, 15, 0.85);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid transparent;
  transition: background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}
nav.scrolled {
  background: rgba(23, 20, 15, 0.96);
  border-bottom-color: var(--line);
  box-shadow: 0 10px 30px -18px rgba(0, 0, 0, 0.6);
}
nav .wrap {
  display: flex; align-items: center; justify-content: space-between;
  padding-top: 16px; padding-bottom: 16px;
}
.brand {
  font-family: 'Big Shoulders Display', sans-serif;
  font-weight: 800; font-size: 22px; letter-spacing: 0.03em;
  text-decoration: none;
}
.brand span { color: var(--amber); }
.navlinks { display: flex; align-items: center; gap: 22px; }
.navlinks a {
  font-size: 14px; color: var(--muted); text-decoration: none; font-weight: 600;
  padding-bottom: 2px; border-bottom: 1px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
}
.navlinks a:hover { color: var(--amber); border-bottom-color: var(--amber); }
.navlinks a.nav-cta {
  color: var(--bg); background: var(--amber); border: none;
  padding: 8px 14px; font-weight: 700;
}
.navlinks a.nav-cta:hover { background: var(--ink); color: var(--bg); }

.menu {
  display: none;
  width: 40px; height: 40px;
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--ink);
  font-size: 1.1rem;
  cursor: pointer;
}

/* HERO */
.hero { padding: 72px 0 56px; border-bottom: 1px solid var(--line); }
.hero-top { display: flex; align-items: center; gap: 20px; margin-bottom: 36px; }
.avatar {
  width: 68px; height: 68px; border-radius: 50%;
  border: 2px solid var(--amber);
  overflow: hidden; flex-shrink: 0;
  background: var(--panel);
  box-shadow: 0 0 0 5px rgba(232, 163, 61, 0.12), 0 0 30px rgba(232, 163, 61, 0.15);
  animation: float 5s ease-in-out infinite;
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.hero-name { font-size: 15px; color: var(--muted); font-weight: 600; }
.hero-name b { color: var(--ink); display: block; font-size: 17px; }

.hero h1 { font-size: clamp(40px, 7vw, 80px); max-width: 11ch; }
.hero .accent { color: var(--amber); }
.hero p.lede { margin-top: 22px; max-width: 54ch; font-size: 18px; color: var(--muted); }

.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }

.stat-strip {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 0;
  margin-top: 48px; border-top: 1px solid var(--line);
}
.stat {
  padding: 20px 24px 0 0; margin-right: 24px;
  border-right: 1px solid var(--line);
  transition: transform 0.2s var(--ease);
}
.stat:last-child { border-right: none; margin-right: 0; }
.stat:hover { transform: translateY(-2px); }
.stat b {
  display: block; font-family: 'Big Shoulders Display', sans-serif;
  font-size: 34px; font-weight: 700; color: var(--amber); margin-bottom: 4px;
}
.stat span { font-size: 13px; color: var(--muted); }

/* SECTIONS */
.section { padding: 64px 0; border-bottom: 1px solid var(--line); }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 20px; margin-bottom: 32px; }
.section-head h2 { font-size: clamp(28px, 4vw, 40px); }
.section-num { font-family: 'Big Shoulders Display', sans-serif; font-size: 16px; color: var(--muted); font-weight: 600; }

/* FLAGSHIP */
.flagship {
  background: var(--panel);
  border: 1px solid var(--line);
  border-left: 3px solid var(--amber);
  padding: 36px;
  box-shadow: var(--shadow);
  transition: border-left-width 0.2s ease, transform 0.2s ease;
}
.flagship:hover { border-left-width: 6px; transform: translateX(2px); }
.flagship-top {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 20px;
  align-items: flex-start; margin-bottom: 20px;
}
.flagship-title { font-size: clamp(30px, 5vw, 46px); color: var(--ink); }
.role-tag {
  font-size: 13px; font-weight: 700; color: var(--bg);
  background: var(--amber); padding: 6px 12px; white-space: nowrap; align-self: flex-start;
}
.flagship p.desc { max-width: 62ch; color: var(--muted); font-size: 16px; margin-bottom: 28px; }

.linkrow { display: flex; flex-wrap: wrap; gap: 12px; }
.btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 12px 20px;
  text-decoration: none; font-weight: 700; font-size: 14px;
  border: 1px solid var(--ink);
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.15s ease;
}
.btn-primary { background: var(--amber); border-color: var(--amber); color: var(--bg); }
.btn-ghost { color: var(--ink); }
.btn-primary:hover { background: var(--ink); border-color: var(--ink); transform: translateY(-1px); }
.btn-ghost:hover { background: var(--ink); color: var(--bg); transform: translateY(-1px); }
.btn .arrow { display: inline-block; transition: transform 0.2s ease; }
.btn:hover .arrow { transform: translateX(3px); }

/* COLLAB GRID */
.collab-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px;
  background: var(--line); border: 1px solid var(--line);
}
.collab-card {
  background: var(--bg); padding: 26px 22px;
  display: flex; flex-direction: column; gap: 10px;
  min-height: 150px;
  border-top: 2px solid transparent;
  transition: background 0.2s ease, border-color 0.2s ease;
}
.collab-card:hover { background: var(--panel); border-top-color: var(--amber); }
.collab-card h3 { font-size: 22px; color: var(--ink); font-weight: 700; }
.collab-card p { font-size: 14px; color: var(--muted); flex-grow: 1; }
.collab-card a {
  font-size: 13px; font-weight: 700; color: var(--amber); text-decoration: none;
  width: fit-content; border-bottom: 1px solid transparent;
}
.collab-card a:hover { border-bottom-color: var(--amber); }

/* SERVICES */
.service-list { border-top: 1px solid var(--line); }
.service-row {
  display: grid; grid-template-columns: 70px 1fr 1.4fr; gap: 20px;
  padding: 22px 4px; border-bottom: 1px solid var(--line);
  align-items: baseline;
  transition: padding-left 0.2s ease, background 0.2s ease;
}
.service-row:hover { padding-left: 14px; background: rgba(232, 163, 61, 0.03); }
.service-row .idx { font-family: 'Big Shoulders Display'; font-size: 16px; color: var(--rust); font-weight: 700; }
.service-row h3 { font-size: 20px; color: var(--ink); text-transform: none; font-weight: 700; }
.service-row p { font-size: 14px; color: var(--muted); max-width: 48ch; }

/* FOOTER */
footer { padding: 56px 0 88px; }
footer .foot-top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 32px; margin-bottom: 40px; }
footer h2 { font-size: clamp(32px, 6vw, 54px); max-width: 12ch; }
.foot-links { display: flex; flex-direction: column; gap: 10px; }
.foot-links a {
  font-size: 16px; font-weight: 600; text-decoration: none; color: var(--muted);
  display: flex; align-items: center; gap: 8px;
  transition: color 0.15s ease, transform 0.15s ease;
}
.foot-links a:hover { color: var(--amber); transform: translateX(3px); }
.foot-links svg { width: 16px; height: 16px; flex-shrink: 0; }
footer .fine { font-size: 13px; color: var(--muted); border-top: 1px solid var(--line); padding-top: 24px; }

/* BACK TO TOP */
.to-top {
  position: fixed; right: 20px; bottom: 20px;
  width: 42px; height: 42px;
  display: flex; align-items: center; justify-content: center;
  background: var(--panel); border: 1px solid var(--line); color: var(--amber);
  text-decoration: none; font-size: 18px;
  opacity: 0; pointer-events: none; transform: translateY(8px);
  transition: opacity 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
  z-index: 40;
}
.to-top.visible { opacity: 1; pointer-events: auto; transform: translateY(0); }
.to-top:hover { border-color: var(--amber); }

/* REVEAL ANIMATION */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
}

@media (max-width: 900px) {
  .stat-strip { grid-template-columns: 1fr; }
  .stat { border-right: none; border-bottom: 1px solid var(--line); padding-bottom: 16px; margin-bottom: 16px; }
  .collab-grid { grid-template-columns: 1fr; }
  .service-row { grid-template-columns: 1fr; gap: 6px; }
  footer .foot-top { flex-direction: column; }
}

@media (max-width: 700px) {
  .menu {
    display: flex; align-items: center; justify-content: center;
  }
  .navlinks {
    position: absolute; left: 18px; right: 18px; top: 62px;
    display: none; flex-direction: column; align-items: stretch; gap: 4px;
    padding: 12px; border: 1px solid var(--line);
    background: rgba(23, 20, 15, 0.98);
    box-shadow: var(--shadow);
  }
  .navlinks.open { display: flex; }
  .navlinks a { padding: 11px 12px; }
  .navlinks a:hover { background: rgba(255, 255, 255, 0.04); }
  .navlinks a.nav-cta { text-align: center; }
}
