/* Hidragen Technologies Private Limited
   One page, no build step. Tokens first, then layout.
   Light is the default. Dark follows the reader's system setting.
   Radius: 14px everywhere. The accent marks and tints; it never carries
   small text on paper, because amber on white cannot pass AA. */

/* ---------- fonts (self-hosted, latin subset) ---------- */
@font-face {
  font-family: 'Geist';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/geist-400.woff2') format('woff2');
}
@font-face {
  font-family: 'Geist';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/geist-500.woff2') format('woff2');
}
@font-face {
  font-family: 'Geist';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/fonts/geist-600.woff2') format('woff2');
}
@font-face {
  font-family: 'Geist';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/fonts/geist-700.woff2') format('woff2');
}
@font-face {
  font-family: 'Geist Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/geist-mono-400.woff2') format('woff2');
}
@font-face {
  font-family: 'Geist Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/geist-mono-500.woff2') format('woff2');
}

/* ---------- tokens: light is the default ---------- */
:root {
  --paper: #fcfcfb;
  --surface: #ffffff;
  --surface-2: #f4f4f1;
  --line: #e4e4de;
  --line-strong: #d4d4cc;
  --ink: #111113;
  --muted: #5c5c66;
  --accent: #e39a00;
  --accent-tint: rgb(227 154 0 / 0.1);
  --on-ink: #fcfcfb;
  --shadow: 0 1px 2px rgb(17 17 19 / 0.04), 0 12px 32px -16px rgb(17 17 19 / 0.14);

  --radius: 14px;
  --gutter: clamp(1.25rem, 5vw, 4rem);
  --section-y: clamp(4.25rem, 9vw, 7.5rem);
  --max: 1180px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #0c0c0e;
    --surface: #141417;
    --surface-2: #1a1a1f;
    --line: #27272b;
    --line-strong: #35353b;
    --ink: #f7f7f8;
    --muted: #a0a0aa;
    --accent: #f5b301;
    --accent-tint: rgb(245 179 1 / 0.11);
    --on-ink: #0c0c0e;
    --shadow: 0 16px 40px -20px rgb(0 0 0 / 0.7);
  }
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: 'Geist', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: inherit;
}

h1,
h2,
h3 {
  margin: 0;
  letter-spacing: -0.028em;
  line-height: 1.1;
  font-weight: 600;
}

p {
  margin: 0;
  max-width: 64ch;
}

.wrap {
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section {
  padding-block: var(--section-y);
  border-top: 1px solid var(--line);
  scroll-margin-top: 68px;
}

.section h2 {
  font-size: clamp(1.8rem, 3.6vw, 2.8rem);
  margin-bottom: 0.85rem;
}

.lede {
  color: var(--muted);
  font-size: clamp(1rem, 1.4vw, 1.1rem);
  max-width: 58ch;
}

/* the only small-caps label on the page, and it appears twice */
.eyebrow {
  font-family: 'Geist Mono', ui-monospace, monospace;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 1rem;
}

.skip {
  position: absolute;
  left: -9999px;
}
.skip:focus {
  left: 1rem;
  top: 1rem;
  z-index: 100;
  background: var(--ink);
  color: var(--on-ink);
  padding: 0.6rem 1rem;
  border-radius: var(--radius);
}

/* ---------- navigation: one line, 68px ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  height: 68px;
  display: flex;
  align-items: center;
  background: color-mix(in srgb, var(--paper) 86%, transparent);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.nav .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  width: 100%;
}

/* The supplied mark carries a tagline line that turns to mush below 40px.
   The box clips it and keeps the wordmark crisp. */
.brand {
  display: block;
  height: 25px;
  width: 99px;
  overflow: hidden;
  flex: none;
}

.brand img {
  height: 42px;
  width: 99px;
}

/* the wordmark is drawn for dark backgrounds */
.brand img,
.footer-mark img {
  filter: brightness(0.5) saturate(1.6);
}

@media (prefers-color-scheme: dark) {
  .brand img,
  .footer-mark img {
    filter: none;
  }
}

.nav ul {
  display: flex;
  gap: clamp(0.9rem, 2.2vw, 1.9rem);
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 0.9rem;
  color: var(--muted);
  white-space: nowrap;
  align-items: center;
}

.nav a {
  text-decoration: none;
  transition: color 0.2s var(--ease);
}

.nav a:hover,
.nav a:focus-visible {
  color: var(--ink);
}

.nav .btn {
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
}

@media (max-width: 780px) {
  .nav ul li:not(:last-child) {
    display: none;
  }
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.82rem 1.45rem;
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
  white-space: nowrap;
  border: 1px solid transparent;
  transition:
    transform 0.15s var(--ease),
    background 0.2s var(--ease),
    border-color 0.2s var(--ease);
}

.btn:active {
  transform: translateY(1px);
}

/* ink on paper, paper on ink: passes AA in both themes with no thinking */
.btn-primary {
  background: var(--ink);
  color: var(--on-ink);
}

.btn-primary:hover {
  background: color-mix(in srgb, var(--ink) 84%, var(--muted));
}

.btn-ghost {
  border-color: var(--line-strong);
  color: var(--ink);
  background: var(--surface);
}

.btn-ghost:hover {
  border-color: var(--muted);
}

/* ---------- hero ---------- */
.hero {
  padding-top: clamp(3.5rem, 9vw, 7rem);
  padding-bottom: clamp(4rem, 9vw, 7rem);
}

.hero h1 {
  font-size: clamp(2.3rem, 6.2vw, 4.6rem);
  font-weight: 600;
  max-width: 18ch;
}

/* the second half of the claim is the differentiator, so it is marked */
.hero .hl {
  box-shadow: inset 0 -0.14em 0 var(--accent);
}

.hero p {
  margin-top: 1.75rem;
  color: var(--muted);
  font-size: clamp(1.05rem, 1.6vw, 1.22rem);
  max-width: 54ch;
}

.hero-actions {
  margin-top: 2.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
}

/* a strip of plain facts, under the hero, never inside it */
.marks {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}

.marks .wrap {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0 1.5rem;
}

@media (min-width: 880px) {
  .marks .wrap {
    grid-template-columns: repeat(4, 1fr);
  }
}

.mark {
  padding-block: 1.6rem;
}

.mark b {
  display: block;
  font-size: 1.02rem;
  font-weight: 600;
}

.mark span {
  color: var(--muted);
  font-size: 0.88rem;
}

/* ---------- a 2 by 2 cell block ---------- */
.grid-4 {
  margin-top: 3rem;
  display: grid;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  grid-template-columns: 1fr;
}

@media (min-width: 820px) {
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

.cell {
  background: var(--surface);
  padding: clamp(1.5rem, 3vw, 2.4rem);
}

/* two of the four carry a tint, so the block is not four white boxes */
.cell-accent {
  background: linear-gradient(145deg, var(--accent-tint), transparent 64%), var(--surface-2);
}

.cell h3 {
  font-size: 1.28rem;
  margin-bottom: 0.7rem;
}

.cell p {
  color: var(--muted);
}

.tags {
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.tags li {
  font-family: 'Geist Mono', ui-monospace, monospace;
  font-size: 0.72rem;
  color: var(--muted);
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  padding: 0.2rem 0.6rem;
}

/* ---------- a statement beside its supporting points ---------- */
.split {
  margin-top: 3rem;
  display: grid;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}

@media (min-width: 900px) {
  .split {
    grid-template-columns: 1fr 1fr;
  }
}

.statement {
  font-size: clamp(1.4rem, 2.6vw, 2rem);
  font-weight: 600;
  letter-spacing: -0.028em;
  line-height: 1.25;
  max-width: 20ch;
}

.points {
  display: grid;
  gap: 1.7rem;
}

.point h3 {
  font-size: 1.05rem;
  margin-bottom: 0.4rem;
}

.point p {
  color: var(--muted);
}

/* ---------- work: one wide card, then two pairs ---------- */
.work {
  margin-top: 3rem;
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
}

@media (min-width: 900px) {
  .work {
    grid-template-columns: repeat(2, 1fr);
  }

  .work > article:first-child {
    grid-column: 1 / -1;
  }
}

.case {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.5rem, 3vw, 2.4rem);
  box-shadow: var(--shadow);
}

.work > article:first-child {
  background: linear-gradient(135deg, var(--accent-tint), transparent 52%), var(--surface);
}

.case h3 {
  font-size: 1.3rem;
  margin-bottom: 0.65rem;
}

.case p {
  color: var(--muted);
}

/* ---------- technology: grouped rows plus a logo strip ---------- */
.tech {
  margin-top: 3rem;
}

.tech-row {
  display: grid;
  gap: 0.35rem 3rem;
  padding-block: 1.3rem;
  border-top: 1px solid var(--line);
  align-items: baseline;
}

.tech-row:last-of-type {
  border-bottom: 1px solid var(--line);
}

@media (min-width: 720px) {
  .tech-row {
    grid-template-columns: 13rem 1fr;
  }
}

.tech-row dt {
  font-weight: 600;
  font-size: 0.98rem;
}

.tech-row dd {
  margin: 0;
  color: var(--muted);
}

.logos {
  margin-top: 2.75rem;
  display: flex;
  flex-wrap: wrap;
  gap: clamp(1.5rem, 3.4vw, 2.75rem);
  align-items: center;
}

.logos img {
  height: 32px;
  width: auto;
  opacity: 0.6;
  transition: opacity 0.2s var(--ease);
}

.logos img:hover {
  opacity: 1;
}

/* ---------- engage: three stacked offers ---------- */
.offers {
  margin-top: 3rem;
}

.offer {
  display: grid;
  gap: 0.5rem 3rem;
  padding-block: 1.9rem;
  border-top: 1px solid var(--line);
  align-items: start;
}

.offer:last-child {
  border-bottom: 1px solid var(--line);
}

@media (min-width: 760px) {
  .offer {
    grid-template-columns: 16rem 1fr;
  }
}

.offer h3 {
  font-size: 1.12rem;
}

.offer p {
  color: var(--muted);
}

/* ---------- company: fact grid ---------- */
.facts {
  margin-top: 3rem;
  display: grid;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  grid-template-columns: 1fr;
}

@media (min-width: 640px) {
  .facts {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1000px) {
  .facts {
    grid-template-columns: repeat(4, 1fr);
  }
}

.fact {
  background: var(--surface);
  padding: 1.7rem;
}

.fact dt {
  font-size: 0.78rem;
  color: var(--muted);
  margin-bottom: 0.45rem;
}

.fact dd {
  margin: 0;
  font-size: 0.97rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  overflow-wrap: anywhere;
}

/* ---------- contact ---------- */
.contact .wrap {
  display: grid;
  gap: 1.4rem;
  justify-items: start;
}

.contact a.mail {
  font-size: clamp(1.3rem, 3.6vw, 2.2rem);
  font-weight: 600;
  letter-spacing: -0.028em;
  text-decoration: none;
  overflow-wrap: anywhere;
  box-shadow: inset 0 -0.1em 0 var(--accent);
}

.contact a.mail:hover {
  box-shadow:
    inset 0 -0.45em 0 var(--accent-tint),
    inset 0 -0.1em 0 var(--accent);
}

/* ---------- footer ---------- */
footer {
  border-top: 1px solid var(--line);
  padding-block: 2.5rem;
  color: var(--muted);
  font-size: 0.875rem;
}

footer .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
  justify-content: space-between;
}

.footer-mark {
  display: block;
  height: 22px;
  width: 86px;
  overflow: hidden;
  opacity: 0.85;
}

.footer-mark img {
  height: 37px;
  width: 86px;
}

/* ---------- reveal on scroll (IntersectionObserver driven) ----------
   The hidden start state is gated on the `js` class, which the page sets
   in the head. With JavaScript off the class never lands, so the content
   is simply visible. Hiding it by default would blank the page. */
@media (prefers-reduced-motion: no-preference) {
  html.js .reveal {
    opacity: 0;
    transform: translateY(20px);
    transition:
      opacity 0.6s var(--ease),
      transform 0.6s var(--ease);
  }

  html.js .reveal.is-in {
    opacity: 1;
    transform: none;
  }
}

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