/* Keech Marketing — colors and fonts live here */
:root {
  --paper: #F4F1EA;
  --paper-2: #EAE6DB;
  --ink: #0E0E10;
  --muted: #5E5B55;
  --blue: #3D2BFF;
  --lime: #D4FF3A;
  --line: rgba(14, 14, 16, .14);
  --display: "Bricolage Grotesque", "Arial Black", system-ui, sans-serif;
  --body: "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Menlo, monospace;
  --pad: clamp(16px, 4vw, 56px);
  --max: 1320px;
  --ease: cubic-bezier(.2, .8, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; overflow-x: clip; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 17px/1.55 var(--body);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, p, ul, ol { margin: 0; padding: 0; }
ul, ol { list-style: none; }
h1, h2, h3 { font-family: var(--display); font-weight: 800; line-height: .95; letter-spacing: -.035em; text-wrap: balance; }
mark { background: none; color: inherit; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; border-radius: 6px; }
::selection { background: var(--lime); color: var(--ink); }

.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 10px 14px; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }

/* ---------- shared bits ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font: 500 12px/1 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--muted);
}
.eyebrow.light { color: rgba(255, 255, 255, .75); }
.dot { width: 9px; height: 9px; border-radius: 50%; background: var(--blue); box-shadow: 0 0 0 4px rgba(61, 43, 255, .18); }
.eyebrow.light .dot { background: var(--lime); box-shadow: 0 0 0 4px rgba(212, 255, 58, .22); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 26px; border-radius: 999px; border: 2px solid var(--ink);
  font: 600 16px/1 var(--body); cursor: pointer; white-space: nowrap;
  transition: transform .2s var(--ease), box-shadow .2s var(--ease), background .2s, color .2s;
}
.btn:hover { transform: translate(-2px, -3px); box-shadow: 4px 5px 0 var(--ink); }
.btn:active { transform: none; box-shadow: none; }
.btn-ink { background: var(--ink); color: var(--paper); }
.btn-ink:hover { box-shadow: 4px 5px 0 var(--blue); }
.btn-blue { background: var(--blue); color: #fff; }
.btn-ghost { background: transparent; }
.btn-lime { background: var(--lime); color: var(--ink); }
.btn-outline { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .5); font-family: var(--mono); font-size: 14px; font-weight: 500; }
.btn-outline small { font: 500 11px/1 var(--mono); letter-spacing: .1em; text-transform: uppercase; background: rgba(255, 255, 255, .16); padding: 6px 8px; border-radius: 999px; }
.btn-lime:hover, .btn-outline:hover { box-shadow: 4px 5px 0 rgba(0, 0, 0, .45); }

section { padding: clamp(72px, 10vw, 150px) var(--pad); }
.section-head { max-width: var(--max); margin: 0 auto clamp(40px, 6vw, 80px); }
.section-head h2 { font-size: clamp(38px, 6.4vw, 92px); margin-top: 20px; }
.section-sub { margin-top: 22px; max-width: 46ch; color: var(--muted); font-size: 18px; }

.reveal { opacity: 0; transform: translateY(36px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

/* ---------- nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px var(--pad);
  background: rgba(244, 241, 234, .82); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent; transition: border-color .3s;
}
.nav.scrolled { border-color: var(--line); }
.logo { display: inline-flex; align-items: center; gap: 11px; }
.logo-mark { width: 44px; height: 44px; flex: none; border-radius: 11px; box-shadow: 3px 3px 0 var(--ink); transition: transform .4s var(--ease), box-shadow .4s var(--ease); }
.logo:hover .logo-mark { transform: translate(-2px, -2px) rotate(-6deg); box-shadow: 5px 5px 0 var(--ink); }
.logo-text { display: grid; gap: 4px; }
.logo-text b { font: 800 25px/.82 var(--display); letter-spacing: -.02em; }
.logo-text em { font: 500 9.5px/1 var(--mono); font-style: normal; letter-spacing: .345em; text-transform: uppercase; color: var(--blue); }
.nav-links { display: flex; align-items: center; gap: clamp(16px, 2.6vw, 36px); font-weight: 500; font-size: 15px; }
.nav-links a:not(.btn) { position: relative; padding: 6px 0; }
.nav-links a:not(.btn)::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--blue); transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease); }
.nav-links a:not(.btn):hover::after { transform: scaleX(1); }
.nav-cta { min-height: 44px; padding: 0 20px; font-size: 15px; }
.menu-btn { display: none; width: 46px; height: 46px; border-radius: 50%; border: 2px solid var(--ink); background: none; cursor: pointer; position: relative; }
.menu-btn span { position: absolute; left: 12px; right: 12px; height: 2px; background: var(--ink); transition: transform .3s var(--ease), top .3s var(--ease); }
.menu-btn span:first-child { top: 17px; } .menu-btn span:last-child { top: 25px; }
.menu-btn[aria-expanded="true"] span:first-child { top: 21px; transform: rotate(45deg); }
.menu-btn[aria-expanded="true"] span:last-child { top: 21px; transform: rotate(-45deg); }

/* ---------- hero ---------- */
.hero {
  max-width: calc(var(--max) + var(--pad) * 2); margin: 0 auto;
  display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 64px); align-items: center;
  padding-top: clamp(40px, 6vw, 84px); padding-bottom: clamp(64px, 8vw, 120px);
}
.hero h1 { font-size: clamp(56px, 9.6vw, 148px); margin: 22px 0 28px; }
.hero h1 .line { display: block; overflow: hidden; padding-bottom: .08em; margin-bottom: -.08em; }
.hero h1 .line > span { display: inline-block; transform: translateY(110%); animation: rise .9s var(--ease) forwards; }
.hero h1 .line:nth-child(2) > span { animation-delay: .09s; }
.hero h1 .line:nth-child(3) > span { animation-delay: .18s; }
@keyframes rise { to { transform: none; } }
.hero mark, .contact mark {
  position: relative; display: inline-block; padding: 0 .12em; margin: 0 -.06em; z-index: 0;
}
.hero mark::before, .contact mark::before {
  content: ""; position: absolute; inset: .1em 0 .02em; z-index: -1; background: var(--lime); border-radius: .12em; transform: rotate(-1.6deg) scaleX(0); transform-origin: left;
  animation: swipe .7s var(--ease) .75s forwards;
}
.contact mark { color: var(--ink); }
.contact mark::before { animation: none; transform: rotate(-1.6deg); }
@keyframes swipe { to { transform: rotate(-1.6deg) scaleX(1); } }
.lede { font-size: clamp(17px, 1.5vw, 21px); max-width: 44ch; color: #33312d; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }

.hero-stack { position: relative; aspect-ratio: 1 / .92; }
.win {
  position: absolute; width: 82%; border-radius: 14px; overflow: hidden; background: #111;
  border: 2px solid var(--ink); box-shadow: 10px 12px 0 var(--ink);
  opacity: 0; animation: drop .9s var(--ease) forwards;
  transition: translate .5s var(--ease); will-change: translate;
}
.win img { width: 100%; }
.win-3 { top: 0; right: 0; rotate: 5deg; animation-delay: .25s; }
.win-2 { top: 23%; left: 0; rotate: -6deg; animation-delay: .4s; box-shadow: 10px 12px 0 var(--blue); }
.win-1 { bottom: 0; right: 4%; rotate: 2.5deg; animation-delay: .55s; }
@keyframes drop { from { opacity: 0; transform: translateY(60px) scale(.92); } to { opacity: 1; transform: none; } }
.bar { display: flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; background: var(--paper); border-bottom: 2px solid var(--ink); }
.bar i { width: 9px; height: 9px; border-radius: 50%; background: var(--ink); opacity: .85; }
.bar i:nth-child(1) { background: #FF5A4E; opacity: 1; } .bar i:nth-child(2) { background: #FFBD2E; opacity: 1; } .bar i:nth-child(3) { background: #2BC84A; opacity: 1; }
.bar .url { margin-left: 10px; font: 500 11px/1 var(--mono); color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.sticker { position: absolute; left: -2%; bottom: 6%; width: clamp(96px, 11vw, 150px); aspect-ratio: 1; border-radius: 50%; background: var(--lime); border: 2px solid var(--ink); display: grid; place-items: center; transition: translate .5s var(--ease); z-index: 3; }
.sticker-ring { position: absolute; inset: 0; animation: spin 16s linear infinite; }
.sticker-ring text { font: 500 15.5px var(--mono); letter-spacing: .12em; fill: var(--ink); }
.sticker-star { font-size: clamp(26px, 3vw, 40px); line-height: 1; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- marquee ---------- */
.marquee { background: var(--ink); color: var(--paper); overflow: hidden; padding: 20px 0; rotate: -1.2deg; margin: 0 -2vw; position: relative; z-index: 2; border-block: 2px solid var(--ink); }
.marquee-track { display: flex; align-items: center; gap: 34px; width: max-content; animation: slide 28s linear infinite; font: 800 clamp(24px, 3.4vw, 46px)/1 var(--display); letter-spacing: -.02em; text-transform: uppercase; }
.marquee-track b { color: var(--lime); font-weight: 400; }
.marquee-track span:nth-of-type(even) { color: transparent; -webkit-text-stroke: 1.5px var(--paper); }
@keyframes slide { to { transform: translateX(calc(-50% - 17px)); } }

/* ---------- work ---------- */
.case {
  max-width: var(--max); margin: 0 auto clamp(28px, 4vw, 48px);
  display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 64px); align-items: center;
  padding: clamp(20px, 3.4vw, 52px); border-radius: clamp(20px, 2.4vw, 34px); border: 2px solid var(--ink);
  background: var(--tint); position: relative;
}
.case-soill { --tint: #E7D2B4; --pop: #6B3F12; }
.case-stars { --tint: #F3C35A; --pop: #0E0E10; }
.case-keech { --tint: #FF5A45; --pop: #0E0E10; }
.case.flip { grid-template-columns: minmax(0, 1fr) minmax(0, 1.45fr); }
.case.flip .case-visual { order: 2; }
.case-visual { position: relative; padding-bottom: 5%; padding-right: 7%; }
.case.flip .case-visual { padding-right: 0; padding-left: 7%; }

.browser { border-radius: 14px; overflow: hidden; border: 2px solid var(--ink); background: #0b0b0b; box-shadow: 8px 10px 0 var(--ink); transition: transform .5s var(--ease), box-shadow .5s var(--ease); }
.case:hover .browser { transform: translate(-3px, -4px); box-shadow: 12px 15px 0 var(--ink); }
.screen { aspect-ratio: 16 / 10; overflow: hidden; container-type: size; }
.screen img { width: 100%; transition: transform var(--dur, 6s) cubic-bezier(.45, 0, .55, 1); will-change: transform; }
.browser:hover .screen img, .browser:focus-visible .screen img, .browser.play .screen img { transform: translateY(calc(-100% + 100cqh)); }

.phone { position: absolute; right: 0; bottom: 0; width: 21%; border-radius: clamp(12px, 1.6vw, 22px); overflow: hidden; border: 2px solid var(--ink); background: #000; box-shadow: 6px 7px 0 var(--ink); rotate: 4deg; transition: rotate .5s var(--ease), translate .5s var(--ease); aspect-ratio: 390 / 780; }
.phone img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.case.flip .phone { right: auto; left: 0; rotate: -4deg; }
.case:hover .phone { rotate: 0deg; translate: 0 -8px; }

.case-num { font: 500 13px/1 var(--mono); letter-spacing: .14em; display: inline-block; padding: 7px 10px; border: 2px solid var(--ink); border-radius: 999px; background: var(--paper); }
.case-info h3 { font-size: clamp(36px, 4.6vw, 68px); margin: 18px 0 10px; }
.case-type { font: 500 12px/1.4 var(--mono); letter-spacing: .1em; text-transform: uppercase; margin-bottom: 18px; opacity: .8; }
.case-info > p:not(.case-type) { font-size: 17px; max-width: 42ch; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.tags li { font: 500 12px/1 var(--mono); padding: 9px 12px; border-radius: 999px; background: rgba(14, 14, 16, .1); border: 1.5px solid rgba(14, 14, 16, .55); }

/* ---------- services ---------- */
.services { background: var(--ink); color: var(--paper); }
.services .eyebrow { color: rgba(244, 241, 234, .65); }
.services .dot { background: var(--lime); box-shadow: 0 0 0 4px rgba(212, 255, 58, .2); }
.svc-grid { max-width: var(--max); margin: 0 auto; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.svc { padding: 28px 24px 30px; border-radius: 22px; border: 1.5px solid rgba(244, 241, 234, .22); min-height: 280px; display: flex; flex-direction: column; transition: background .35s, color .35s, transform .35s var(--ease), border-color .35s, opacity .8s var(--ease); }
.svc-n { font: 500 13px/1 var(--mono); color: var(--lime); letter-spacing: .14em; transition: color .35s; }
.svc h3 { font-size: clamp(26px, 2.4vw, 34px); margin: auto 0 12px; padding-top: 48px; }
.svc p { font-size: 15.5px; opacity: .78; }
.svc:hover { background: var(--lime); color: var(--ink); border-color: var(--lime); transform: translateY(-8px) rotate(-1deg); }
.svc:nth-child(even):hover { background: var(--blue); color: #fff; border-color: var(--blue); transform: translateY(-8px) rotate(1deg); }
.svc:hover .svc-n { color: inherit; } .svc:hover p { opacity: 1; }

/* ---------- process ---------- */
.steps { max-width: var(--max); margin: 0 auto; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 2px solid var(--ink); }
.steps li { padding: 28px 24px 8px 0; position: relative; }
.steps li + li { padding-left: 24px; border-left: 2px solid var(--ink); }
.steps span { display: grid; place-items: center; width: 54px; height: 54px; border-radius: 50%; border: 2px solid var(--ink); font: 800 24px/1 var(--display); background: var(--paper); transition: background .3s, color .3s, transform .4s var(--ease); }
.steps li:hover span { background: var(--blue); color: #fff; transform: scale(1.12) rotate(-8deg); }
.steps h3 { font-size: clamp(28px, 2.8vw, 40px); margin: 36px 0 10px; }
.steps p { color: var(--muted); font-size: 16px; max-width: 26ch; }

/* ---------- contact ---------- */
.contact { padding-top: 0; }
.contact-card { max-width: var(--max); margin: 0 auto; background: var(--blue); color: #fff; border-radius: clamp(24px, 3vw, 44px); border: 2px solid var(--ink); padding: clamp(32px, 5.5vw, 84px) clamp(18px, 5vw, 76px); box-shadow: 10px 12px 0 var(--ink); position: relative; overflow: hidden; }
.contact-card::after { content: "✦"; position: absolute; right: -4%; top: -22%; font-size: clamp(220px, 34vw, 520px); line-height: 1; color: rgba(255, 255, 255, .08); animation: spin 40s linear infinite; pointer-events: none; }
.contact-card > * { position: relative; z-index: 1; }
.contact h2 { font-size: clamp(40px, 5.4vw, 84px); margin: 22px 0 24px; }
.contact-card > p:not(.eyebrow) { font-size: clamp(17px, 1.5vw, 20px); max-width: 44ch; opacity: .9; }
.contact-card { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: center; }
.contact-copy > p:not(.eyebrow) { font-size: clamp(17px, 1.5vw, 20px); max-width: 40ch; opacity: .9; }
.contact-form, .form-done { background: var(--paper); color: var(--ink); border: 2px solid var(--ink); border-radius: 24px; padding: clamp(20px, 2.6vw, 34px); box-shadow: 7px 8px 0 var(--ink); }
.contact-form { display: grid; gap: 16px; }
.contact-form label { display: grid; gap: 7px; font: 500 12px/1 var(--mono); letter-spacing: .1em; text-transform: uppercase; }
.contact-form label span { opacity: .55; }
.contact-form input, .contact-form textarea { width: 100%; font: 400 17px/1.4 var(--body); color: var(--ink); background: #fff; border: 2px solid var(--ink); border-radius: 12px; padding: 13px 14px; letter-spacing: 0; text-transform: none; resize: vertical; transition: box-shadow .2s var(--ease), transform .2s var(--ease); }
.contact-form input:focus, .contact-form textarea:focus { outline: none; box-shadow: 4px 4px 0 var(--blue); transform: translate(-1px, -1px); }
.contact-form .btn { width: 100%; margin-top: 4px; }
.contact-form .btn:disabled { opacity: .6; pointer-events: none; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-note { font-size: 14px; min-height: 1.4em; color: var(--muted); }
.form-note:empty { display: none; }
.form-done { text-align: left; }
.form-done[hidden], .contact-form[hidden] { display: none; }
.form-done span { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%; background: var(--lime); border: 2px solid var(--ink); font-size: 26px; }
.form-done h3 { font-size: clamp(30px, 3.4vw, 46px); margin: 22px 0 10px; }
.form-done p { color: var(--muted); }

/* ---------- footer ---------- */
.footer { max-width: calc(var(--max) + var(--pad) * 2); margin: 0 auto; padding: 34px var(--pad) 44px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px 32px; font-size: 14px; color: var(--muted); }
.footer nav { display: flex; flex-wrap: wrap; gap: 22px; }
.footer nav a:hover { color: var(--ink); }
.footer .logo { color: var(--ink); }

/* ---------- responsive ---------- */
@media (max-width: 1020px) {
  .svc-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .svc { min-height: 220px; }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .steps li:nth-child(3) { padding-left: 0; border-left: 0; }
  .steps li:nth-child(n+3) { border-top: 2px solid var(--ink); margin-top: 28px; }
}
@media (max-width: 860px) {
  .hero { grid-template-columns: minmax(0, 1fr); }
  .hero-stack { max-width: 560px; width: 100%; margin: 12px auto 0; }
  .case, .case.flip { grid-template-columns: minmax(0, 1fr); }
  .contact-card { grid-template-columns: minmax(0, 1fr); }
  .case.flip .case-visual { order: 0; }
  .menu-btn { display: block; }
  .nav-links {
    position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; align-items: stretch; gap: 0;
    background: var(--paper); border-bottom: 2px solid var(--ink); padding: 8px var(--pad) 20px;
    visibility: hidden; opacity: 0; transform: translateY(-8px); transition: opacity .25s, transform .25s var(--ease), visibility .25s;
  }
  .nav-links.open { visibility: visible; opacity: 1; transform: none; }
  .nav-links a:not(.btn) { font: 800 30px/1 var(--display); padding: 14px 0; border-bottom: 1px solid var(--line); }
  .nav-links a:not(.btn)::after { display: none; }
  .nav-cta { margin-top: 16px; min-height: 52px; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .svc-grid, .steps { grid-template-columns: minmax(0, 1fr); }
  .steps li, .steps li + li { padding-left: 0; border-left: 0; border-top: 0; margin-top: 0; padding-bottom: 24px; }
  .steps li + li { border-top: 2px solid var(--ink); }
  .steps h3 { margin-top: 20px; }
  .svc { min-height: 0; } .svc h3 { padding-top: 28px; }
  .win { box-shadow: 6px 7px 0 var(--ink); } .win-2 { box-shadow: 6px 7px 0 var(--blue); }
  .browser { box-shadow: 5px 6px 0 var(--ink); }
  .contact-card { box-shadow: 6px 7px 0 var(--ink); }
  .btn-outline { font-size: 13px; padding: 0 16px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .marquee-track, .sticker-ring, .contact-card::after { animation: none !important; }
  .reveal { opacity: 1; transform: none; }
  .browser:hover .screen img, .browser.play .screen img { transform: none; }
}
