/* RoamRock - one page site.
   Palette taken from the logo: near-black field, azure ring, white type. */

:root {
  --bg:        #04060a;
  --bg-alt:    #080c14;
  --panel:     #0d131d;
  --line:      #1b2634;
  --ink:       #eef4fa;
  --ink-muted: #93a6bb;
  --ink-faint: #67788c;
  --blue:      #2f9fe8;
  --blue-soft: #7cc6f5;
  --blue-deep: #1466a8;
  --maxw:      1100px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

a { color: var(--blue-soft); }

.skip {
  position: absolute;
  left: -9999px;
}
.skip:focus {
  left: 16px;
  top: 16px;
  z-index: 10;
  background: var(--blue);
  color: #00121f;
  padding: 10px 16px;
  border-radius: 8px;
}

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

.hero {
  position: relative;
  overflow: hidden;
  text-align: center;
  padding: 72px 0 84px;
  border-bottom: 1px solid var(--line);
}

/* The glow behind the logo, echoing the lit rim of the globe. */
.hero-glow {
  position: absolute;
  top: -30%;
  left: 50%;
  transform: translateX(-50%);
  width: min(1100px, 150vw);
  aspect-ratio: 1;
  background: radial-gradient(circle,
              rgba(47, 159, 232, 0.28) 0%,
              rgba(47, 159, 232, 0.10) 38%,
              rgba(4, 6, 10, 0) 68%);
  pointer-events: none;
}

.hero-inner { position: relative; }

.logo {
  width: 240px;
  height: auto;
  max-width: 64vw;
  /* The display assets are cut to a circular alpha: the source art is a circle
     on an opaque black square, and that square reads as a visible box against
     the hero glow. Do not swap these back for the uncropped file. */
  filter: drop-shadow(0 0 36px rgba(47, 159, 232, 0.3));
}

h1 {
  margin: 20px 0 4px;
  font-size: clamp(2.6rem, 8vw, 4.4rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.05;
}
.roam { color: #f4f8fc; }
.rock {
  background: linear-gradient(180deg, var(--blue-soft), var(--blue));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.tagline {
  margin: 0 0 22px;
  font-size: clamp(1rem, 3vw, 1.3rem);
  font-style: italic;
  color: var(--blue-soft);
  letter-spacing: 0.01em;
}

.lede {
  max-width: 60ch;
  margin: 0 auto 28px;
  color: var(--ink-muted);
  font-size: 1.05rem;
}

.cta {
  display: inline-block;
  padding: 13px 30px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--blue), var(--blue-deep));
  color: #f6fbff;
  font-weight: 600;
  text-decoration: none;
  box-shadow: 0 8px 28px rgba(20, 102, 168, 0.4);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.cta:hover,
.cta:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 12px 34px rgba(47, 159, 232, 0.5);
}

.cta-row {
  display: flex;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
}
.cta-ghost {
  background: transparent;
  color: var(--blue-soft);
  border: 1px solid rgba(124, 198, 245, 0.55);
  box-shadow: none;
}
.cta-ghost:hover,
.cta-ghost:focus-visible { background: rgba(47, 159, 232, 0.12); box-shadow: none; }

/* Section jump links under the hero CTAs. */
.jump {
  display: flex;
  justify-content: center;
  gap: 8px 22px;
  flex-wrap: wrap;
  margin-top: 26px;
}
.jump a {
  color: var(--ink-muted);
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid transparent;
}
.jump a:hover,
.jump a:focus-visible { color: var(--blue-soft); border-bottom-color: var(--blue-soft); }

/* ---------- Sections ---------- */

.section { padding: 72px 0; }
.section-alt { background: var(--bg-alt); border-block: 1px solid var(--line); }
.section-contact { text-align: center; }

h2 {
  margin: 0 0 8px;
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  font-weight: 700;
  letter-spacing: -0.01em;
}
h2::after {
  content: "";
  display: block;
  width: 56px;
  height: 3px;
  margin: 14px 0 34px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--blue), transparent);
}
.section-contact h2::after { margin-inline: auto; }

/* Small label above a section heading: whose work this is. */
.eyebrow {
  margin: 0 0 6px;
  color: var(--blue-soft);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

/* One line under a category heading, tucked up to the heading's rule. */
.section-intro {
  max-width: 62ch;
  margin: -16px 0 30px;
  color: var(--ink-muted);
}

.grid {
  display: grid;
  gap: 22px;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

/* ---------- Product cards ---------- */

.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 26px 24px;
  display: flex;
  flex-direction: column;
  transition: border-color 0.18s ease, transform 0.18s ease;
}
.card:hover {
  border-color: rgba(47, 159, 232, 0.55);
  transform: translateY(-3px);
}

/* A screenshot across the top of a card, bleeding to its edges. Optional:
   a card without one keeps its plain layout, badge in the head. Images are
   960x600 (16:10). A card with one carries its badge on the image instead,
   in a faded strip along the bottom, so the titles line up across a row. */
.card-media {
  position: relative;
  margin: -26px -24px 20px;
  border-radius: 13px 13px 0 0;
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}
.card-media img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  object-position: top;
}
.media-strip {
  position: absolute;
  inset: auto 0 0 0;
  display: flex;
  justify-content: flex-end;
  padding: 28px 12px 10px;
  background: linear-gradient(180deg, rgba(4, 6, 10, 0), rgba(4, 6, 10, 0.82));
  pointer-events: none;
}
.media-strip .badge {
  background: rgba(4, 6, 10, 0.55);
  border-color: rgba(124, 198, 245, 0.55);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}

.card-head {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.card h3, .tenet h3 {
  margin: 0;
  font-size: 1.3rem;
  font-weight: 700;
}

.badge {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 4px 10px;
  border-radius: 999px;
  color: var(--blue-soft);
  background: rgba(47, 159, 232, 0.12);
  border: 1px solid rgba(47, 159, 232, 0.35);
}

.card-kicker {
  margin: 6px 0 14px;
  color: var(--blue-soft);
  font-size: 0.92rem;
  font-weight: 600;
}

.card p, .tenet p { color: var(--ink-muted); margin: 0 0 12px; }
.card p:last-child, .tenet p:last-child { margin-bottom: 0; }

.fineprint {
  font-size: 0.88rem;
  color: var(--ink-faint);
  border-top: 1px solid var(--line);
  padding-top: 12px;
}

/* Pinned to the card's foot so links line up across a row. */
.card-link {
  margin-top: auto;
  padding-top: 14px;
  font-weight: 600;
  text-decoration: none;
}
.card-link::after { content: " \2192"; }
.card-link + .card-link { margin-top: 0; padding-top: 6px; }
.card-link:hover,
.card-link:focus-visible { text-decoration: underline; }

/* ---------- Tenets ---------- */

.tenet h3 { color: var(--ink); margin-bottom: 8px; }

/* Capabilities: five short blocks, narrower than the cards. */
.grid-cap { grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 26px; }

/* Four cards: two by two, so none is left alone on a row at the 1100px width. */
.grid-2x2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 400px), 1fr)); }

.icp-links {
  display: flex;
  gap: 10px 28px;
  flex-wrap: wrap;
  margin: 30px 0 0;
  font-weight: 600;
}
.icp-links a { text-decoration: none; }
.icp-links a::after { content: " \2192"; }
.icp-links a:hover,
.icp-links a:focus-visible { text-decoration: underline; }

.work-cta { margin-top: 40px; text-align: center; }
.fineprint-plain { margin: 14px 0 0; color: var(--ink-faint); font-size: 0.92rem; }

/* ---------- Article pages (e.g. icp/) ---------- */

.article { max-width: 760px; }
.article-head { padding: 56px 0 8px; }
.article-head .back { font-size: 0.92rem; text-decoration: none; }
.article-head .back::before { content: "\2190 "; }
.article-head h1 { font-size: clamp(2rem, 6vw, 2.8rem); margin: 18px 0 10px; }
.article h2 { font-size: clamp(1.35rem, 3.4vw, 1.7rem); margin-top: 48px; }
.article h2::after { margin: 12px 0 20px; }
.article h3 { margin: 28px 0 8px; font-size: 1.1rem; }
.article p, .article li { color: var(--ink-muted); }
.article strong { color: var(--ink); }
.article code {
  font-family: Consolas, "Cascadia Mono", ui-monospace, monospace;
  font-size: 0.9em;
  color: var(--ink);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 1px 5px;
}
.article pre {
  overflow-x: auto;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 16px 18px;
  line-height: 1.5;
}
.article pre code { background: none; border: 0; padding: 0; font-size: 0.88rem; }
.article table { width: 100%; border-collapse: collapse; margin: 8px 0 18px; font-size: 0.92rem; }
.article th, .article td { text-align: left; padding: 9px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
.article th { color: var(--ink); }
.article td { color: var(--ink-muted); }
.table-scroll { overflow-x: auto; }
.callout {
  border-left: 3px solid var(--blue);
  background: rgba(47, 159, 232, 0.08);
  padding: 12px 16px;
  border-radius: 0 8px 8px 0;
}
.article .callout p { margin: 0; }

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

footer {
  border-top: 1px solid var(--line);
  padding: 28px 0;
  color: var(--ink-faint);
  font-size: 0.9rem;
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
footer p { margin: 0; }
.footer-tag { font-style: italic; color: var(--blue-deep); }
.footer-icp a { color: var(--ink-muted); text-decoration: none; }
.footer-icp a:hover,
.footer-icp a:focus-visible { color: var(--blue-soft); text-decoration: underline; }

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

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

@media (max-width: 640px) {
  .section { padding: 56px 0; }
  .hero { padding: 48px 0 60px; }
  .footer-inner { justify-content: center; text-align: center; }
}

/* ---------- Case-study pages (work/*.html) ----------
   A slim header bar for subpages, plus the case-study layout. Builds on
   .article above; nothing here changes the home page. */

.site-bar { border-bottom: 1px solid var(--line); background: var(--bg-alt); }
.site-bar-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px 20px;
  flex-wrap: wrap;
  padding-block: 12px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  text-decoration: none;
}
.brand img { width: 36px; height: 36px; }
.site-bar .back { font-size: 0.92rem; font-weight: 600; text-decoration: none; }
.site-bar .back::before { content: "\2190\00a0"; }
.site-bar .back:hover,
.site-bar .back:focus-visible { text-decoration: underline; }

.case { padding-bottom: 72px; }
.case .article-head { padding-top: 44px; }
.case .article-head .eyebrow { margin-bottom: 0; }
.case .article-head h1 { margin-top: 8px; }
.case .lede { margin: 0 0 8px; max-width: none; }
.case .card-kicker { margin: 0 0 6px; }
.case-shot {
  margin: 28px 0 0;
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  background: var(--panel);
}
.case-shot img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 10; }
.case ul { padding-left: 1.2em; }
.case li { margin-bottom: 8px; }
.case .fineprint { margin-top: 18px; }
.case-cta { justify-content: flex-start; margin-top: 36px; }
