/* thatteos.com — thatteOS product site (Red / R)
   © Manish Jagdish Thatte
   Tokens: net/colour/palettes/tokens.json → brands.thatteos */

@import url("https://fonts.googleapis.com/css2?family=Literata:opsz,wght@7..72,400;7..72,600;7..72,700&family=Syne:wght@500;600;700;800&family=IBM+Plex+Mono:wght@400;500&display=swap");

:root {
  --paper: #FBF5F5;
  --paper-2: #F3E4E5;
  --card: #FFFFFF;
  --ink: #1A1414;
  --ink-2: #4A3838;
  --ink-3: #756060;
  --rule: #E8D5D6;
  --rule-2: #D4B8BA;
  --accent: #C6303C;
  --accent-hover: #9A2530;
  --accent-ink: #FFFBF5;
  --accent-text: #9A2530;
  --link: #9A2530;
  --theme: #C6303C;
  --scale-50: #FCEEEF;
  --scale-100: #F8D4D7;
  --scale-800: #4F1419;

  --measure: 66ch;
  --wide: 1080px;
  --radius: 12px;

  --display: "Syne", ui-sans-serif, sans-serif;
  --serif: "Literata", ui-serif, Georgia, serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;

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

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  margin: 0;
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  background:
    radial-gradient(ellipse 90% 55% at 12% -10%, rgba(198, 48, 60, 0.16), transparent 55%),
    radial-gradient(ellipse 70% 45% at 92% 8%, rgba(154, 37, 48, 0.10), transparent 50%),
    linear-gradient(180deg, var(--scale-50) 0%, var(--paper) 38%, var(--paper) 100%);
  background-attachment: fixed;
  min-height: 100vh;
}

img, svg { max-width: 100%; height: auto; display: block; }
a { color: var(--link); text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { color: var(--accent); text-decoration-thickness: 2px; }

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

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--ink); color: var(--paper);
  padding: .7rem 1.1rem; font-family: var(--display); font-weight: 600;
}
.skip-link:focus { left: 0; }

.wrap { width: min(100% - 2.25rem, var(--wide)); margin-inline: auto; }
.narrow { width: min(100% - 2.25rem, 720px); margin-inline: auto; }

/* ── Nav ─────────────────────────────────────────────────────────────────── */
.site-nav {
  position: sticky; top: 0; z-index: 40;
  backdrop-filter: blur(12px);
  background: color-mix(in srgb, var(--paper) 82%, transparent);
  border-bottom: 1px solid color-mix(in srgb, var(--rule) 70%, transparent);
}
.nav-inner {
  width: min(100% - 2.25rem, var(--wide));
  margin-inline: auto;
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; padding: .85rem 0;
}
.nav-brand {
  display: inline-flex; align-items: center; gap: .7rem;
  text-decoration: none; color: var(--ink);
}
.nav-brand img { width: 36px; height: 36px; border-radius: 8px; }
.nav-brand .wordmark {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
}
.nav-brand .wordmark span { color: var(--accent); }
.nav-links {
  display: flex; align-items: center; gap: 1.15rem;
  list-style: none; margin: 0; padding: 0;
  font-family: var(--display); font-size: .9rem; font-weight: 600;
}
.nav-links a { text-decoration: none; color: var(--ink-2); }
.nav-links a:hover { color: var(--accent); }
.nav-links .nav-cta {
  color: var(--accent-ink);
  background: var(--accent);
  padding: .45rem .9rem;
  border-radius: 999px;
}
.nav-links .nav-cta:hover { background: var(--accent-hover); color: var(--accent-ink); }
.nav-toggle {
  display: none; border: 0; background: transparent; padding: .4rem;
  cursor: pointer;
}
.nav-toggle span {
  display: block; width: 22px; height: 2px; margin: 5px 0;
  background: var(--ink); border-radius: 1px;
}
.nav-mobile {
  display: none; flex-direction: column; gap: .35rem;
  padding: 0 1.125rem 1rem;
  font-family: var(--display); font-weight: 600;
}
.nav-mobile.open { display: flex; }
.nav-mobile a {
  text-decoration: none; color: var(--ink);
  padding: .55rem .2rem; border-bottom: 1px solid var(--rule);
}
@media (max-width: 820px) {
  .nav-links { display: none; }
  .nav-toggle { display: block; }
}

/* ── Type ────────────────────────────────────────────────────────────────── */
h1, h2, h3 {
  font-family: var(--display);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.03em;
  margin: 0 0 .55em;
}
h1 { font-size: clamp(2.2rem, 5.5vw, 3.5rem); }
h2 { font-size: clamp(1.45rem, 3vw, 2rem); }
h3 { font-size: clamp(1.1rem, 2vw, 1.3rem); font-weight: 650; }
p { margin: 0 0 1.1em; max-width: var(--measure); }
.lede {
  font-size: clamp(1.08rem, 2vw, 1.28rem);
  color: var(--ink-2);
  line-height: 1.55;
  max-width: 42rem;
}
.eyebrow {
  display: inline-block;
  font-family: var(--display);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent-text);
  margin-bottom: .85rem;
}
.muted { color: var(--ink-3); }
.prose h2 { margin-top: 2.2em; }
.prose h3 { margin-top: 1.6em; }
.prose ul, .prose ol { padding-left: 1.2em; max-width: var(--measure); }
.prose li { margin-bottom: .45em; }
.prose code, .inline-code {
  font-family: var(--mono);
  font-size: .88em;
  background: var(--paper-2);
  padding: .1em .35em;
  border-radius: 4px;
}
.prose pre {
  font-family: var(--mono);
  font-size: .85rem;
  line-height: 1.5;
  background: var(--ink);
  color: #F7E8EA;
  padding: 1.1rem 1.2rem;
  border-radius: var(--radius);
  overflow-x: auto;
  max-width: 100%;
}
.prose pre code { background: transparent; padding: 0; color: inherit; }
.prose table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 1.4em;
  font-size: .95rem;
}
.prose th, .prose td {
  text-align: left;
  vertical-align: top;
  padding: .55rem .65rem;
  border-bottom: 1px solid var(--rule);
}
.prose th { font-family: var(--display); font-weight: 650; color: var(--ink-2); }

.note {
  background: color-mix(in srgb, var(--accent) 8%, var(--paper));
  border-left: 3px solid var(--accent);
  padding: 1rem 1.15rem;
  margin: 0 0 1.5em;
  border-radius: 0 var(--radius) var(--radius) 0;
}
.note p:last-child { margin-bottom: 0; }

/* ── Hero ────────────────────────────────────────────────────────────────── */
.hero {
  padding: clamp(3.5rem, 10vw, 6.5rem) 0 clamp(3rem, 7vw, 5rem);
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: -20% 40% auto -15%;
  height: 70%;
  background:
    radial-gradient(circle at 30% 40%, rgba(198, 48, 60, 0.22), transparent 55%),
    radial-gradient(circle at 70% 20%, rgba(154, 37, 48, 0.12), transparent 50%);
  pointer-events: none;
  animation: glow-drift 14s var(--ease) infinite alternate;
}
@keyframes glow-drift {
  from { transform: translate3d(0, 0, 0) scale(1); opacity: .9; }
  to { transform: translate3d(4%, 3%, 0) scale(1.08); opacity: 1; }
}
.hero-inner { position: relative; }
.brand-lockup {
  display: flex; align-items: center; gap: 1rem;
  margin-bottom: 1.5rem;
  animation: rise .8s var(--ease) both;
}
.brand-lockup img {
  width: clamp(64px, 10vw, 88px);
  height: auto;
  border-radius: 18px;
  box-shadow: 0 18px 40px -24px rgba(198, 48, 60, 0.55);
}
.brand-name {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(2.6rem, 7vw, 4.2rem);
  letter-spacing: -0.04em;
  line-height: 1;
  margin: 0;
}
.brand-name span { color: var(--accent); }
.hero h1 {
  max-width: 14ch;
  margin-bottom: .7em;
  animation: rise .9s var(--ease) .08s both;
}
.hero .lede { animation: rise .9s var(--ease) .14s both; }
.cta-row {
  display: flex; flex-wrap: wrap; gap: .75rem 1rem;
  margin-top: 1.75rem;
  animation: rise .9s var(--ease) .2s both;
}
@keyframes rise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--display);
  font-weight: 700;
  font-size: .95rem;
  text-decoration: none;
  padding: .7rem 1.2rem;
  border-radius: 999px;
  border: 1.5px solid transparent;
  transition: background .2s var(--ease), color .2s var(--ease), border-color .2s var(--ease);
}
.btn-primary {
  background: var(--accent);
  color: var(--accent-ink);
}
.btn-primary:hover { background: var(--accent-hover); color: var(--accent-ink); }
.btn-ghost {
  background: transparent;
  color: var(--accent-text);
  border-color: color-mix(in srgb, var(--accent) 45%, var(--rule));
}
.btn-ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 6%, transparent);
}

.version-chip {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  margin-top: 1.5rem;
  font-family: var(--mono);
  font-size: .8rem;
  color: var(--ink-3);
  animation: rise .9s var(--ease) .28s both;
}
.version-chip i {
  width: .55rem; height: .55rem; border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 20%, transparent);
}

/* ── Sections ────────────────────────────────────────────────────────────── */
.page-head { padding: clamp(2.5rem, 7vw, 4rem) 0 0; }
.section { padding: clamp(2.5rem, 6vw, 4.5rem) 0; }
.section-tight { padding: clamp(1.75rem, 4vw, 2.75rem) 0; }
.section-rule {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--rule-2), transparent);
  border: 0; margin: 0;
}

.split {
  display: grid;
  gap: 1.75rem 2.5rem;
}
@media (min-width: 820px) {
  .split-2 { grid-template-columns: 1fr 1fr; }
}

.stack-list {
  list-style: none; margin: 0; padding: 0;
  max-width: 40rem;
}
.stack-list li {
  padding: 1rem 0;
  border-bottom: 1px solid var(--rule);
}
.stack-list li:first-child { border-top: 1px solid var(--rule); }
.stack-list strong {
  font-family: var(--display);
  display: block;
  margin-bottom: .2rem;
}
.stack-list a { text-decoration: none; }
.stack-list a:hover { text-decoration: underline; }

.phase {
  padding: 1.15rem 0;
  border-bottom: 1px solid var(--rule);
  max-width: 42rem;
}
.phase:first-of-type { border-top: 1px solid var(--rule); }
.phase .status {
  font-family: var(--display);
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--accent-text);
  margin-bottom: .35rem;
}
.phase .status.is-later { color: var(--ink-3); }

.shell-preview {
  margin-top: 1.5rem;
  background: #1A1414;
  color: #F7E8EA;
  border-radius: var(--radius);
  padding: 1.15rem 1.25rem;
  font-family: var(--mono);
  font-size: .86rem;
  line-height: 1.55;
  box-shadow: 0 24px 48px -28px rgba(26, 20, 20, 0.55);
  max-width: 40rem;
}
.shell-preview .prompt { color: #E0757E; }
.shell-preview .dim { color: #A8888A; }

/* ── Footer ──────────────────────────────────────────────────────────────── */
.site-footer {
  margin-top: clamp(2rem, 5vw, 3.5rem);
  border-top: 1px solid var(--rule);
  background: color-mix(in srgb, var(--paper-2) 70%, var(--paper));
  padding: 2.5rem 0 2rem;
  font-size: .92rem;
  color: var(--ink-2);
}
.footer-grid {
  display: grid;
  gap: 1.75rem;
}
@media (min-width: 720px) {
  .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; }
}
.site-footer h2 {
  font-size: .78rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: .8rem;
}
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: .4rem; }
.site-footer a { text-decoration: none; color: var(--ink-2); }
.site-footer a:hover { color: var(--accent); }
.footer-brand {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--ink);
  margin-bottom: .5rem;
}
.footer-brand span { color: var(--accent); }
.footer-meta {
  margin-top: 2rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--rule);
  color: var(--ink-3);
  font-size: .85rem;
}
.footer-meta p { margin: 0 0 .4em; max-width: none; }
