/* ==========================================================================
   Oops Lab — oopslab.ai
   White ground, charcoal type, cool gray surfaces, one cobalt accent.
   Type: Inter throughout. No build step, no JavaScript.
   ========================================================================== */

:root {
  --bg:          #FFFFFF;
  --surface:     #F5F7FA;
  --surface-2:   #EDF0F4;
  --line:        #E3E7EC;
  --line-strong: #C9D0D8;

  --text:        #1F2328;
  --text-2:      #4A5160;
  --text-3:      #5F6672;

  --blue:        #1D4ED8;
  --blue-deep:   #1E40AF;
  --blue-tint:   #E8EFFD;

  --dark:        #1F2328;
  --on-dark:     #F3F4F6;
  --on-dark-2:   #B4BAC4;
  --on-dark-line: rgba(243, 244, 246, 0.16);
  --on-dark-blue: #9DBBFF;

  --sans: "Inter", ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;

  --w-page: 1200px;
  --w-text: 720px;
  --pad: clamp(20px, 4vw, 40px);
  --radius: 6px;
}

/* --------------------------------------------------------------------------
   Base
   -------------------------------------------------------------------------- */

*, *::before, *::after { box-sizing: border-box; }

html {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
}

body { margin: 0; }

img, svg { max-width: 100%; display: block; }

a {
  color: var(--blue);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
a:hover { color: var(--blue-deep); }

:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 3px;
  border-radius: 3px;
}

::selection { background: var(--blue-tint); color: var(--text); }

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

h1, h2, h3, h4 { margin: 0; font-weight: 600; letter-spacing: -0.01em; }

ul, ol { margin: 0; padding: 0; }

.wrap {
  max-width: var(--w-page);
  margin: 0 auto;
  padding-left: var(--pad);
  padding-right: var(--pad);
}

[id] { scroll-margin-top: 88px; }

.skip-link {
  position: absolute;
  left: -9999px;
  top: 12px;
  z-index: 100;
  background: var(--dark);
  color: var(--on-dark);
  padding: 12px 16px;
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--radius);
}
.skip-link:focus { left: 12px; }

/* --------------------------------------------------------------------------
   Type helpers
   -------------------------------------------------------------------------- */

.kicker {
  margin: 0 0 14px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.3;
  color: var(--blue);
}

.h2 {
  font-size: clamp(28px, 3vw, 40px);
  line-height: 1.15;
  letter-spacing: -0.02em;
  max-width: 24ch;
  text-wrap: balance;
}

.h3 {
  font-size: 21px;
  line-height: 1.3;
  letter-spacing: -0.012em;
}

.lede {
  font-size: clamp(17px, 1.25vw, 19px);
  line-height: 1.55;
  color: var(--text-2);
  max-width: 60ch;
}

.section { padding: clamp(56px, 7vw, 96px) 0; }

.section-head { margin-bottom: clamp(32px, 4vw, 48px); }
.section-head .lede { margin-top: 16px; }

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  font-family: var(--sans);
  font-size: 15.5px;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  text-align: center;
  white-space: nowrap;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.btn--primary { background: var(--blue); color: #fff; border-color: var(--blue); }
.btn--primary:hover { background: var(--blue-deep); border-color: var(--blue-deep); color: #fff; }
.btn--secondary { background: transparent; color: var(--text); border-color: var(--line-strong); }
.btn--secondary:hover { border-color: var(--text); color: var(--text); }
.btn--on-dark { background: #fff; color: var(--dark); border-color: #fff; }
.btn--on-dark:hover { background: var(--surface-2); border-color: var(--surface-2); color: var(--dark); }
.btn--small { min-height: 44px; padding: 0 16px; font-size: 14.5px; }

/* --------------------------------------------------------------------------
   Header
   -------------------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid var(--line);
}
.site-header__inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 8px 32px;
  min-height: 64px;
  padding-top: 8px;
  padding-bottom: 8px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 44px;
  color: var(--text);
  text-decoration: none;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1;
}
.brand__mark { flex: none; }
.brand:hover { color: var(--text); }

.site-nav__list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0 4px;
}
.site-nav__list a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 12px;
  border-radius: var(--radius);
  color: var(--text-2);
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
}
.site-nav__list a:hover { color: var(--text); background: var(--surface); }

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero { padding: clamp(48px, 6vw, 88px) 0 clamp(48px, 6vw, 80px); }

.hero__title {
  font-size: clamp(36px, 4.8vw, 62px);
  font-weight: 600;
  line-height: 1.06;
  letter-spacing: -0.028em;
  max-width: 18ch;
  margin: 0 0 22px;
  text-wrap: balance;
}
.hero__lede { max-width: 56ch; margin-bottom: 28px; }

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
  margin-bottom: 14px;
}
.hero__note { font-size: 14.5px; color: var(--text-3); }
.hero__note a { color: var(--text-2); }

/* Example workflow diagram */

.flow {
  margin: clamp(40px, 5vw, 64px) 0 0;
  padding: 22px 24px 24px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.flow__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 14px;
  margin-bottom: 18px;
  font-size: 14px;
  line-height: 1.4;
  color: var(--text-3);
}
.flow__label { font-weight: 600; color: var(--text); }

.flow__nodes {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 28px;
}
.flow__node {
  position: relative;
  padding: 14px 16px 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.flow__node + .flow__node::before {
  content: "";
  position: absolute;
  left: -29px;
  top: 50%;
  width: 28px;
  height: 1px;
  background: var(--line-strong);
}
.flow__node + .flow__node::after {
  content: "";
  position: absolute;
  left: -6px;
  top: 50%;
  width: 6px;
  height: 6px;
  margin-top: -3px;
  border-radius: 50%;
  background: var(--line-strong);
}
.flow__node--agent { border-color: var(--blue); box-shadow: inset 0 0 0 1px var(--blue); }
.flow__k {
  display: block;
  margin-bottom: 6px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-3);
}
.flow__node--agent .flow__k { color: var(--blue); }
.flow__v {
  display: block;
  font-size: 15px;
  line-height: 1.45;
  color: var(--text);
}

/* --------------------------------------------------------------------------
   Services (structured rows)
   -------------------------------------------------------------------------- */

.services { border-top: 1px solid var(--line); }

.service-rows { border-top: 1px solid var(--line); }
.service {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 4fr) minmax(0, 4fr);
  gap: 20px 40px;
  padding: 32px 0;
  border-bottom: 1px solid var(--line);
}
.service__num {
  display: block;
  margin-bottom: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--blue);
  font-variant-numeric: tabular-nums;
}
.service__title {
  font-size: clamp(20px, 1.8vw, 24px);
  line-height: 1.25;
  letter-spacing: -0.015em;
}
.service__desc { color: var(--text-2); font-size: 16px; }
.service__examples { list-style: none; }
.service__examples li {
  position: relative;
  padding: 5px 0 5px 18px;
  font-size: 15px;
  line-height: 1.45;
  color: var(--text-2);
}
.service__examples li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 14px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--blue);
}
.services__after {
  margin-top: 24px;
  font-size: 15px;
  color: var(--text-3);
  max-width: 72ch;
}
.services__after strong { color: var(--text); font-weight: 600; }

/* --------------------------------------------------------------------------
   Process (gray band, four columns)
   -------------------------------------------------------------------------- */

.process { background: var(--surface); }
.process .section-head { margin-bottom: 36px; }
.steps {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 32px;
}
.steps li {
  border-top: 2px solid var(--line-strong);
  padding-top: 16px;
}
.steps__num {
  display: block;
  margin-bottom: 10px;
  font-size: 13px;
  font-weight: 600;
  color: var(--blue);
}
.steps h3 {
  font-size: 18px;
  line-height: 1.3;
  margin-bottom: 8px;
}
.steps p { color: var(--text-2); font-size: 15.5px; }

/* --------------------------------------------------------------------------
   Work
   -------------------------------------------------------------------------- */

.work__grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: start;
}
.work .section-head { margin-bottom: 0; }

.case {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(20px, 2.5vw, 32px);
}
.case__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 6px 16px;
  margin-bottom: 8px;
}
.case__label { font-size: 13px; font-weight: 600; color: var(--blue); }
.case__link { font-size: 14.5px; color: var(--text-2); }
.case__name { font-size: 26px; line-height: 1.2; letter-spacing: -0.02em; margin-bottom: 8px; }
.case__desc { color: var(--text-2); font-size: 16px; margin-bottom: 22px; }
.case__list {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.case__list li {
  background: #fff;
  padding: 14px 16px;
  font-size: 14.5px;
  line-height: 1.45;
  color: var(--text-2);
}
.case__list strong {
  display: block;
  margin-bottom: 2px;
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
}

/* --------------------------------------------------------------------------
   Founders
   -------------------------------------------------------------------------- */

.founders { border-top: 1px solid var(--line); }
.founders__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
}
.founder {
  border-top: 2px solid var(--text);
  padding-top: 18px;
}
.founder__name { margin-bottom: 2px; }
.founder__role { margin-bottom: 12px; font-size: 14.5px; color: var(--text-3); }
.founder__bio { color: var(--text-2); font-size: 16px; max-width: 52ch; margin-bottom: 12px; }
.founder__links {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0 20px;
  font-size: 15px;
}
.founder__links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--text);
  font-weight: 500;
  text-decoration-color: var(--line-strong);
}
.founder__links a:hover { color: var(--blue); text-decoration-color: currentColor; }

/* --------------------------------------------------------------------------
   FAQ
   -------------------------------------------------------------------------- */

.faq { border-top: 1px solid var(--line); }
.faq__grid {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 8fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: start;
}
.faq .section-head { margin-bottom: 0; }

.faq__list { border-top: 1px solid var(--line); }
.faq__item { border-bottom: 1px solid var(--line); }
.faq__item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 56px;
  padding: 14px 0;
  cursor: pointer;
  list-style: none;
  font-size: 17.5px;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: -0.01em;
  color: var(--text);
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after {
  content: "+";
  flex: none;
  width: 24px;
  font-size: 22px;
  font-weight: 400;
  line-height: 1;
  text-align: center;
  color: var(--blue);
}
.faq__item[open] summary::after { content: "\2212"; }
.faq__item summary:hover { color: var(--blue); }
.faq__item summary:focus-visible { outline-offset: 0; }
.faq__body {
  padding: 0 0 20px;
  color: var(--text-2);
  font-size: 16px;
  max-width: 64ch;
}

/* --------------------------------------------------------------------------
   Contact (charcoal band)
   -------------------------------------------------------------------------- */

.contact { background: var(--dark); color: var(--on-dark); }
.contact .kicker { color: var(--on-dark-blue); }
.contact .lede { color: var(--on-dark-2); }
.contact__grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: clamp(32px, 6vw, 96px);
  align-items: start;
}
.contact__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
  margin-top: 28px;
}
.contact__email {
  font-size: 16px;
  font-weight: 500;
  color: var(--on-dark);
  text-decoration-color: var(--on-dark-blue);
  overflow-wrap: anywhere;
}
.contact__email:hover { color: #fff; }
.contact__note { margin-top: 14px; font-size: 14.5px; color: var(--on-dark-2); }

.contact__aside h3 {
  font-size: 14px;
  font-weight: 600;
  color: var(--on-dark-2);
  margin-bottom: 10px;
}
.contact__aside ul { padding-left: 18px; color: var(--on-dark); font-size: 15.5px; }
.contact__aside li { margin: 4px 0; }
.contact__aside ul + h3 { margin-top: 28px; }
.contact__aside a { color: var(--on-dark); text-decoration-color: var(--on-dark-blue); }
.contact__aside a:hover { color: #fff; }

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */

.site-footer {
  border-top: 1px solid var(--line);
  font-size: 14.5px;
  color: var(--text-3);
}
.site-footer__inner {
  display: grid;
  grid-template-columns: minmax(0, 5fr) repeat(3, minmax(0, 2fr));
  gap: 32px;
  padding-top: 40px;
  padding-bottom: 32px;
}
.site-footer .brand { margin-bottom: 10px; }
.site-footer__tagline { max-width: 34ch; }
.site-footer__k {
  margin: 0 0 6px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text);
}
.site-footer ul { list-style: none; }
.site-footer a {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  color: var(--text-2);
  text-decoration: none;
}
.site-footer a:hover { color: var(--blue); text-decoration: underline; }
.site-footer__fine {
  padding-top: 16px;
  padding-bottom: 24px;
  border-top: 1px solid var(--line);
  font-size: 13.5px;
}

/* --------------------------------------------------------------------------
   Legal pages (privacy.html, terms.html)
   -------------------------------------------------------------------------- */

.legal {
  max-width: var(--w-text);
  margin: 0 auto;
  padding: clamp(48px, 6vw, 80px) var(--pad) clamp(64px, 8vw, 104px);
}
.legal__title {
  font-size: clamp(32px, 4vw, 46px);
  line-height: 1.12;
  letter-spacing: -0.025em;
  margin: 0 0 18px;
}
.legal__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 24px;
  font-size: 14px;
  color: var(--text-3);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 12px 0;
  margin-bottom: 32px;
}
.legal__meta strong { color: var(--text); font-weight: 600; }
.legal__section {
  padding: 20px 0 10px;
  border-bottom: 1px solid var(--line);
}
.legal__section:last-child { border-bottom: 0; }
.legal__section h2 {
  font-size: 22px;
  letter-spacing: -0.015em;
  margin: 4px 0 12px;
}
.legal__section h3 {
  font-size: 17px;
  font-weight: 600;
  color: var(--text);
  margin: 20px 0 6px;
}
.legal__section p,
.legal__section li {
  font-size: 16px;
  line-height: 1.65;
  color: var(--text-2);
}
.legal__section p { margin: 0 0 14px; }
.legal__section ul { margin: 0 0 18px; padding-left: 22px; }
.legal__section ul ul { margin: 6px 0 0; }
.legal__section li { margin: 4px 0; }
.legal__section strong { color: var(--text); font-weight: 600; }
.legal__signoff {
  font-size: 14px;
  line-height: 1.7;
  color: var(--text-3);
  margin-top: 20px;
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

/* --------------------------------------------------------------------------
   404
   -------------------------------------------------------------------------- */

.notfound {
  max-width: var(--w-text);
  margin: 0 auto;
  padding: clamp(72px, 10vw, 128px) var(--pad) clamp(72px, 10vw, 128px);
}
.notfound__title {
  font-size: clamp(34px, 4.6vw, 54px);
  line-height: 1.1;
  letter-spacing: -0.025em;
  margin: 0 0 18px;
}
.notfound p { color: var(--text-2); max-width: 50ch; }
.notfound .btn { margin-top: 20px; }

/* --------------------------------------------------------------------------
   Motion
   -------------------------------------------------------------------------- */

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

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 1024px) {
  .service { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
  .service__examples { grid-column: 2; }
  .steps { grid-template-columns: 1fr 1fr; gap: 28px 32px; }
}

@media (max-width: 900px) {
  .work__grid,
  .faq__grid,
  .contact__grid { grid-template-columns: minmax(0, 1fr); }
  .work .section-head,
  .faq .section-head { margin-bottom: 28px; }
  .founders__grid { grid-template-columns: 1fr; gap: 32px; }
  .site-footer__inner { grid-template-columns: 1fr 1fr; }
}

/* Header: brand and email button share the top row; nav sits on one row
   beneath. The header stops being sticky so it does not eat phone screens. */
@media (max-width: 720px) {
  html { scroll-padding-top: 16px; }
  [id] { scroll-margin-top: 16px; }
  .site-header { position: static; }
  .site-header__inner {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 2px 16px;
    padding-top: 8px;
    padding-bottom: 6px;
  }
  .site-header__inner > .brand { grid-row: 1; grid-column: 1; }
  .site-header__inner > .btn { grid-row: 1; grid-column: 2; }
  .site-nav { grid-row: 2; grid-column: 1 / -1; margin-left: -12px; }
  .site-nav__list { justify-content: flex-start; gap: 0; }

  .flow { padding: 18px 16px 16px; }
  .flow__nodes { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .flow__node + .flow__node::before { left: 20px; top: -21px; width: 1px; height: 20px; }
  .flow__node + .flow__node::after { left: 18px; top: -4px; margin-top: 0; }

  .service { grid-template-columns: minmax(0, 1fr); gap: 12px; padding: 26px 0; }
  .service__examples { grid-column: auto; }
}

@media (max-width: 560px) {
  html { font-size: 16px; }
  .site-nav { margin-left: -10px; }
  .site-nav__list a { padding: 0 10px; font-size: 14.5px; }
  .hero__actions .btn { width: 100%; }
  .steps { grid-template-columns: 1fr; gap: 22px; }
  .case__list { grid-template-columns: minmax(0, 1fr); }
  .site-footer__inner { grid-template-columns: 1fr; gap: 22px; }
}

@media (max-width: 360px) {
  .site-nav { margin-left: -8px; }
  .site-nav__list a { padding: 0 8px; font-size: 14px; }
}
