/* =================================================================
   KNOWLEDGE CHAMBERS — knowledgechambers.com
   Editorial streetwear personal brand. Design system + components.
   ================================================================= */

/* ---------- Tokens ---------- */
:root {
  --bg:        #0b0b0c;
  --bg-2:      #121214;
  --surface:   #17171a;
  --surface-2: #1e1e22;
  --text:      #ecebe6;
  --muted:     #9c988e;
  --muted-2:   #6f6c66;
  --accent:    #e3392e;   /* Pieces red */
  --accent-2:  #ff5a4d;
  --line:      rgba(255,255,255,.12);
  --line-soft: rgba(255,255,255,.07);

  --font-display: "Anton", "Arial Narrow", system-ui, sans-serif;
  --font-serif:   "Fraunces", Georgia, "Times New Roman", serif;
  --font-body:    "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --wrap: 1280px;
  --gut: clamp(20px, 5vw, 64px);
  --radius: 14px;

  --ease: cubic-bezier(.22, 1, .36, 1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: none; background: none; color: inherit; }
ul { list-style: none; }
::selection { background: var(--accent); color: #fff; }

/* ---------- Typography ---------- */
h1, h2, h3 { font-family: var(--font-display); font-weight: 400; line-height: .94; letter-spacing: .01em; text-transform: uppercase; }
.serif { font-family: var(--font-serif); text-transform: none; font-weight: 300; font-style: italic; letter-spacing: -.01em; }

.kicker {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  gap: .7em;
}
.kicker::before { content: ""; width: 28px; height: 1px; background: var(--accent); display: inline-block; }

.lead { font-size: clamp(18px, 2.4vw, 23px); line-height: 1.5; color: var(--text); font-weight: 300; }
.prose p { color: #cfccc4; margin-bottom: 1.25em; max-width: 64ch; }
.prose p:last-child { margin-bottom: 0; }
.muted { color: var(--muted); }

/* ---------- Layout ---------- */
.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gut); }
.section { padding-block: clamp(72px, 11vw, 150px); }
.section--tight { padding-block: clamp(56px, 8vw, 100px); }
.divider { height: 1px; background: var(--line-soft); border: 0; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .6em;
  padding: 15px 30px;
  font-size: 13px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
  border-radius: 100px;
  transition: transform .35s var(--ease), background .35s var(--ease), color .35s var(--ease), border-color .35s var(--ease);
  will-change: transform;
}
.btn:hover { transform: translateY(-2px); }
.btn--solid { background: var(--text); color: #0b0b0c; }
.btn--solid:hover { background: #fff; }
.btn--accent { background: var(--accent); color: #fff; }
.btn--accent:hover { background: var(--accent-2); }
.btn--ghost { border: 1px solid var(--line); color: var(--text); }
.btn--ghost:hover { border-color: var(--text); background: rgba(255,255,255,.05); }
.btn .arrow { transition: transform .35s var(--ease); }
.btn:hover .arrow { transform: translateX(4px); }

/* ---------- Header / Nav ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px var(--gut);
  transition: background .4s var(--ease), padding .4s var(--ease), border-color .4s var(--ease);
  border-bottom: 1px solid transparent;
}
.site-header.is-stuck {
  background: rgba(11,11,12,.82);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom-color: var(--line-soft);
  padding-block: 13px;
}
.brand { font-family: var(--font-display); font-size: 21px; letter-spacing: .04em; text-transform: uppercase; line-height: 1; display: flex; align-items: baseline; gap: .5ch; }
.brand .dot { color: var(--accent); }
.nav { display: flex; align-items: center; gap: 22px; }
.nav a {
  font-size: 13px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: var(--muted);
  position: relative; padding-block: 4px; transition: color .3s var(--ease);
}
.nav a::after { content: ""; position: absolute; left: 0; bottom: 0; width: 0; height: 1px; background: var(--accent); transition: width .3s var(--ease); }
.nav a:hover, .nav a[aria-current="page"] { color: var(--text); }
.nav a:hover::after, .nav a[aria-current="page"]::after { width: 100%; }
.nav .btn { padding: 11px 22px; }

.nav-toggle { display: none; width: 44px; height: 44px; flex-direction: column; align-items: center; justify-content: center; gap: 6px; z-index: 110; }
.nav-toggle span { width: 24px; height: 2px; background: var(--text); transition: transform .35s var(--ease), opacity .25s var(--ease); }
.nav-toggle.is-open span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.nav-toggle.is-open span:nth-child(2) { opacity: 0; }
.nav-toggle.is-open span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

@media (max-width: 1024px) {
  .nav-toggle { display: flex; }
  .nav {
    position: fixed; inset: 0; flex-direction: column; justify-content: center; gap: 26px;
    background: rgba(8,8,9,.97); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
    transform: translateX(100%); visibility: hidden;
    transition: transform .5s var(--ease), visibility .5s var(--ease);
  }
  .nav.is-open { transform: translateX(0); visibility: visible; }
  .nav a { font-size: 24px; color: var(--text); }
  .nav .btn { margin-top: 10px; font-size: 14px; padding: 15px 32px; }
}

/* ---------- Hero ---------- */
.hero { position: relative; min-height: 100vh; min-height: 100svh; display: flex; align-items: flex-end; overflow: hidden; }
.hero__media { position: absolute; inset: 0; z-index: 0; }
.hero__media img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 25%; filter: grayscale(.32) contrast(1.05) brightness(.6); }
.hero__media::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(11,11,12,.75) 0%, rgba(11,11,12,.34) 30%, rgba(11,11,12,.5) 58%, rgba(11,11,12,.98) 100%),
    linear-gradient(90deg, rgba(11,11,12,.68) 0%, rgba(11,11,12,.18) 46%, transparent 74%);
}
.hero__inner { position: relative; z-index: 1; width: 100%; padding-bottom: clamp(40px, 7vw, 90px); padding-top: 120px; }
.hero__title {
  font-size: clamp(58px, 16.5vw, 240px);
  line-height: .82; letter-spacing: -.01em; margin: 14px 0 0;
}
.hero__title span { display: block; }
.hero__title .ln-2 { color: transparent; -webkit-text-stroke: 1.4px rgba(236,235,230,.85); text-stroke: 1.4px rgba(236,235,230,.85); }
.hero__roles {
  display: flex; flex-wrap: wrap; gap: 10px 14px; margin-top: 26px; max-width: 640px;
}
.hero__roles li { font-size: 13px; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); display: flex; align-items: center; gap: 14px; }
.hero__roles li:not(:last-child)::after { content: "/"; color: var(--accent); }
.hero__cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 36px; }
.scroll-hint { position: absolute; right: var(--gut); bottom: clamp(40px, 7vw, 90px); z-index: 1; writing-mode: vertical-rl; font-size: 11px; letter-spacing: .3em; text-transform: uppercase; color: var(--muted); display: flex; align-items: center; gap: 14px; }
.scroll-hint::after { content: ""; width: 1px; height: 56px; background: linear-gradient(var(--accent), transparent); animation: scroll-pulse 2.4s var(--ease) infinite; }
@keyframes scroll-pulse { 0%,100% { opacity: .3; transform: scaleY(.6); transform-origin: top; } 50% { opacity: 1; transform: scaleY(1); } }
@media (max-width: 860px) { .scroll-hint { display: none; } }

/* ---------- Section heading ---------- */
.shead { display: flex; align-items: flex-end; justify-content: space-between; gap: 30px; flex-wrap: wrap; margin-bottom: clamp(36px, 5vw, 64px); }
.shead__title { font-size: clamp(40px, 7vw, 92px); }
.shead p { max-width: 42ch; color: var(--muted); }

/* page hero (interior) */
.page-hero { padding-top: clamp(130px, 18vw, 190px); padding-bottom: clamp(30px, 5vw, 56px); }
.page-hero h1 { font-size: clamp(52px, 12vw, 150px); }
.page-hero .kicker { margin-bottom: 22px; }

/* ---------- Feature split ---------- */
.split { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(30px, 6vw, 88px); align-items: center; }
.split--rev .split__media { order: 2; }
.split__media { position: relative; border-radius: var(--radius); overflow: hidden; }
.split__media img { width: 100%; aspect-ratio: 4/5; object-fit: cover; transition: transform 1.4s var(--ease); }
.split__media:hover img { transform: scale(1.04); }
.split__media .tag { position: absolute; left: 16px; bottom: 16px; font-size: 11px; letter-spacing: .2em; text-transform: uppercase; background: rgba(11,11,12,.7); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); padding: 8px 14px; border-radius: 100px; border: 1px solid var(--line-soft); }
@media (max-width: 820px) {
  .split { grid-template-columns: 1fr; }
  .split--rev .split__media { order: 0; }
  .split__media img { aspect-ratio: 3/4; }
}

/* ---------- Stats / facts strip ---------- */
.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line-soft); border: 1px solid var(--line-soft); border-radius: var(--radius); overflow: hidden; }
.facts li { background: var(--bg); padding: clamp(24px, 4vw, 42px); }
.facts .n { font-family: var(--font-display); font-size: clamp(34px, 5vw, 60px); line-height: 1; }
.facts .l { color: var(--muted); font-size: 13px; letter-spacing: .1em; text-transform: uppercase; margin-top: 12px; }
@media (max-width: 680px) { .facts { grid-template-columns: 1fr; } }

/* ---------- Pull quote ---------- */
.pullquote { text-align: center; max-width: 22ch; margin-inline: auto; }
.pullquote q { font-family: var(--font-serif); font-style: italic; font-weight: 300; font-size: clamp(28px, 5.2vw, 60px); line-height: 1.12; quotes: "“" "”"; }
.pullquote .by { display: block; margin-top: 26px; font-family: var(--font-body); font-size: 13px; letter-spacing: .2em; text-transform: uppercase; color: var(--accent); }

/* ---------- Gallery preview (home) ---------- */
.strip { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(240px, 30vw); gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 10px; scrollbar-width: thin; }
.strip::-webkit-scrollbar { height: 6px; }
.strip::-webkit-scrollbar-thumb { background: var(--line); border-radius: 100px; }
.strip a { scroll-snap-align: start; border-radius: var(--radius); overflow: hidden; position: relative; }
.strip img { width: 100%; aspect-ratio: 3/4; object-fit: cover; transition: transform 1.2s var(--ease), filter .5s var(--ease); filter: grayscale(.1); }
.strip a:hover img { transform: scale(1.05); filter: grayscale(0); }

/* ---------- Masonry gallery ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 38px; }
.filters button { padding: 9px 20px; border-radius: 100px; border: 1px solid var(--line); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); transition: all .3s var(--ease); }
.filters button:hover { color: var(--text); border-color: var(--muted); }
.filters button.is-active { background: var(--text); color: #0b0b0c; border-color: var(--text); }

.masonry { columns: 4 280px; column-gap: 16px; }
.masonry .cell { break-inside: avoid; margin-bottom: 16px; border-radius: var(--radius); overflow: hidden; position: relative; cursor: zoom-in; background: var(--surface); }
.masonry .cell img { width: 100%; transition: transform 1.1s var(--ease), filter .5s var(--ease); filter: grayscale(.12); }
.masonry .cell:hover img { transform: scale(1.04); filter: grayscale(0); }
.masonry .cell::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(11,11,12,.5), transparent 45%); opacity: 0; transition: opacity .4s var(--ease); }
.masonry .cell:hover::after { opacity: 1; }
.masonry .cell .cap { position: absolute; left: 14px; bottom: 12px; right: 14px; z-index: 2; font-size: 12px; letter-spacing: .04em; color: var(--text); opacity: 0; transform: translateY(8px); transition: all .4s var(--ease); }
.masonry .cell:hover .cap { opacity: 1; transform: translateY(0); }
.masonry .cell.is-hidden { display: none; }
@media (max-width: 820px) { .masonry { columns: 2; } }
@media (max-width: 540px) { .masonry { columns: 1; } }

/* ---------- Lightbox ---------- */
.lightbox { position: fixed; inset: 0; z-index: 200; background: rgba(6,6,7,.94); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); display: flex; align-items: center; justify-content: center; opacity: 0; visibility: hidden; transition: opacity .4s var(--ease), visibility .4s; padding: 4vw; }
.lightbox.is-open { opacity: 1; visibility: visible; }
.lightbox img { max-width: 92vw; max-height: 86vh; width: auto; border-radius: 8px; box-shadow: 0 30px 80px rgba(0,0,0,.6); }
.lightbox__cap { position: absolute; bottom: 22px; left: 0; right: 0; text-align: center; color: var(--muted); font-size: 13px; letter-spacing: .04em; padding-inline: 20px; }
.lb-btn { position: absolute; top: 50%; transform: translateY(-50%); width: 56px; height: 56px; border-radius: 100px; background: rgba(255,255,255,.08); border: 1px solid var(--line); display: flex; align-items: center; justify-content: center; font-size: 22px; transition: background .3s var(--ease); }
.lb-btn:hover { background: rgba(255,255,255,.18); }
.lb-prev { left: 3vw; } .lb-next { right: 3vw; }
.lb-close { top: 4vw; right: 4vw; transform: none; width: 48px; height: 48px; font-size: 18px; }
@media (max-width: 680px) { .lb-prev { left: 8px; } .lb-next { right: 8px; } .lb-btn { width: 48px; height: 48px; } }

/* ---------- Social row ---------- */
.socials { display: flex; flex-wrap: wrap; gap: 14px; }
.social-card { display: flex; align-items: center; gap: 16px; padding: 18px 22px; border: 1px solid var(--line); border-radius: var(--radius); flex: 1 1 240px; transition: border-color .35s var(--ease), background .35s var(--ease), transform .35s var(--ease); }
.social-card:hover { border-color: var(--text); background: var(--surface); transform: translateY(-3px); }
.social-card .ico { width: 42px; height: 42px; flex: none; border-radius: 12px; background: var(--surface-2); display: grid; place-items: center; }
.social-card .ico svg { width: 22px; height: 22px; fill: var(--text); }
.social-card .h { font-weight: 600; letter-spacing: .02em; }
.social-card .p { font-size: 13px; color: var(--muted); }

/* ---------- Contact / cards ---------- */
.card { background: var(--surface); border: 1px solid var(--line-soft); border-radius: var(--radius); padding: clamp(26px, 4vw, 44px); }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
@media (max-width: 820px) { .contact-grid { grid-template-columns: 1fr; } }
.field-label { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); display: block; margin-bottom: 8px; }
.contact-line { display: flex; flex-direction: column; gap: 4px; padding: 18px 0; border-bottom: 1px solid var(--line-soft); }
.contact-line:last-child { border-bottom: 0; }
.contact-line a { font-size: clamp(20px, 3vw, 28px); font-family: var(--font-display); text-transform: none; letter-spacing: .01em; overflow-wrap: anywhere; transition: color .3s var(--ease); }
.contact-line a:hover { color: var(--accent); }

/* Form */
.form { display: grid; gap: 18px; }
.form .row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 560px) { .form .row { grid-template-columns: 1fr; } }
.input, .textarea, select.input {
  width: 100%; background: var(--bg-2); border: 1px solid var(--line); border-radius: 10px;
  padding: 14px 16px; color: var(--text); font: inherit; transition: border-color .3s var(--ease), background .3s var(--ease);
}
.input:focus, .textarea:focus, select.input:focus { outline: none; border-color: var(--accent); background: var(--surface); }
.textarea { resize: vertical; min-height: 130px; }
.input::placeholder, .textarea::placeholder { color: var(--muted-2); }

/* ---------- CTA band ---------- */
.cta-band { position: relative; border-radius: var(--radius); overflow: hidden; isolation: isolate; }
.cta-band__bg { position: absolute; inset: 0; z-index: -1; }
.cta-band__bg img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(.35) brightness(.5); }
.cta-band__inner { padding: clamp(48px, 8vw, 110px) var(--gut); text-align: center; }
.cta-band h2 { font-size: clamp(38px, 7vw, 88px); }
.cta-band p { color: #d7d4cc; max-width: 48ch; margin: 18px auto 32px; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line-soft); padding-block: clamp(56px, 8vw, 90px); background: var(--bg-2); }
.footer-top { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; }
.footer-brand .brand { font-size: 40px; }
.footer-brand p { color: var(--muted); margin-top: 16px; max-width: 38ch; }
.footer-col h4 { font-family: var(--font-body); font-size: 12px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted-2); margin-bottom: 18px; }
.footer-col a { display: block; padding: 7px 0; color: var(--muted); transition: color .3s var(--ease); font-size: 15px; }
.footer-col a:hover { color: var(--text); }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; margin-top: clamp(40px, 6vw, 70px); padding-top: 28px; border-top: 1px solid var(--line-soft); color: var(--muted-2); font-size: 13px; }
.footer-bottom .pills { display: flex; gap: 8px; flex-wrap: wrap; }
.footer-bottom .pills a { padding: 6px 12px; border: 1px solid var(--line); border-radius: 100px; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); transition: all .3s var(--ease); }
.footer-bottom .pills a:hover { color: var(--text); border-color: var(--text); }
@media (max-width: 820px) { .footer-top { grid-template-columns: 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }
@media (max-width: 520px) { .footer-top { grid-template-columns: 1fr; } }

/* ---------- Reveal animation ---------- */
[data-reveal] { opacity: 0; transform: translateY(26px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
[data-reveal].is-in { opacity: 1; transform: none; }
[data-reveal][data-delay="1"] { transition-delay: .08s; }
[data-reveal][data-delay="2"] { transition-delay: .16s; }
[data-reveal][data-delay="3"] { transition-delay: .24s; }

/* ---------- Marquee ---------- */
.marquee { overflow: hidden; border-block: 1px solid var(--line-soft); padding-block: 18px; }
.marquee__track { display: flex; gap: 48px; width: max-content; animation: marquee 28s linear infinite; }
.marquee span { font-family: var(--font-display); font-size: clamp(26px, 4vw, 46px); text-transform: uppercase; color: var(--muted-2); display: inline-flex; align-items: center; gap: 48px; white-space: nowrap; }
.marquee span::after { content: "✦"; color: var(--accent); font-family: var(--font-body); }
@keyframes marquee { to { transform: translateX(-50%); } }
.marquee:hover .marquee__track { animation-play-state: paused; }

/* ---------- Utility ---------- */
.center { text-align: center; }
.mt-s { margin-top: 18px; } .mt-m { margin-top: 32px; } .mt-l { margin-top: 56px; }
.maxr { max-width: 760px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(30px, 6vw, 80px); }
@media (max-width: 820px) { .grid-2 { grid-template-columns: 1fr; } }
.skip-link { position: absolute; left: -999px; top: 8px; background: var(--accent); color: #fff; padding: 10px 16px; border-radius: 8px; z-index: 999; }
.skip-link:focus { left: 8px; }

/* ---------- Keyboard focus ---------- */
a:focus-visible, button:focus-visible, .btn:focus-visible, .nav a:focus-visible,
.social-card:focus-visible, .filters button:focus-visible, .svc:focus-visible,
.lb-btn:focus-visible, .masonry .cell:focus-visible, select:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

/* ---------- Services / cards grid ---------- */
.cards-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
@media (max-width: 860px) { .cards-3 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .cards-3 { grid-template-columns: 1fr; } }
.svc { background: var(--surface); border: 1px solid var(--line-soft); border-radius: var(--radius); padding: clamp(24px, 3vw, 34px); transition: border-color .35s var(--ease), transform .35s var(--ease); }
.svc:hover { border-color: var(--line); transform: translateY(-3px); }
.svc .num { font-family: var(--font-body); font-size: 12px; letter-spacing: .2em; color: var(--accent); }
.svc h3 { font-family: var(--font-display); font-size: clamp(22px, 2.6vw, 30px); text-transform: none; line-height: 1.05; margin: 14px 0 10px; }
.svc p { color: var(--muted); font-size: 15px; }

/* ---------- Services list ---------- */
.svc-list { display: grid; gap: 1px; background: var(--line-soft); border: 1px solid var(--line-soft); border-radius: var(--radius); overflow: hidden; }
.svc-list li { background: var(--bg); padding: 15px 22px; font-size: 15px; display: flex; align-items: center; gap: 14px; }
.svc-list li::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); flex: none; }

/* form success note */
.form-note { background: rgba(227,57,46,.12); border: 1px solid rgba(227,57,46,.4); color: #ffd7d3; border-radius: 10px; padding: 14px 16px; font-size: 14px; }
