/* Omeoray Ltd — company site
   One stylesheet. Warm off-white, near-black, one electric blue.
   Light by default, dark when the viewer's system asks for it. */

:root {
  --bg: #faf8f4;
  --panel: #fffefb;
  --ink: #121110;
  --ink-soft: #55524c;
  --ink-faint: #736f67;
  --line: #e4ded3;
  --line-strong: #d2cabb;
  --accent: #1b3cff;
  --accent-wash: rgba(27, 60, 255, 0.05);
  --radius: 10px;
  --mono: ui-monospace, SFMono-Regular, Menlo, "Cascadia Mono", "Liberation Mono",
    Consolas, monospace;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0d0d0c;
    --panel: #151513;
    --ink: #f5f2ec;
    --ink-soft: #a8a49c;
    --ink-faint: #8a857b;
    --line: #272521;
    --line-strong: #3a3732;
    --accent: #6b89ff;
    --accent-wash: rgba(107, 137, 255, 0.07);
  }
}

:root[data-theme="dark"] {
  --bg: #0d0d0c;
  --panel: #151513;
  --ink: #f5f2ec;
  --ink-soft: #a8a49c;
  --ink-faint: #8a857b;
  --line: #272521;
  --line-strong: #3a3732;
  --accent: #6b89ff;
  --accent-wash: rgba(107, 137, 255, 0.07);
}

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

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

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

.shell {
  width: 100%;
  max-width: 50rem;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- small interface type ---------- */

.meta {
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

/* ---------- the Omeoray mark ---------- */

/* Black artwork on transparent, so dark mode is one exact inversion
   rather than a second export. */
.mark {
  display: block;
  flex: none;
  width: 22px;
  height: 22px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .mark {
    filter: invert(1);
  }
}

:root[data-theme="dark"] .mark {
  filter: invert(1);
}

/* ---------- header ---------- */

.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 26px 0 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: inherit;
  text-decoration: none;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.top nav a {
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 0.95rem;
  transition: color 140ms ease;
}

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

/* ---------- hero ---------- */

.hero {
  padding: 92px 0 0;
}

/* a thin framing bar, the way a portfolio index labels its own page */
.hero-bar {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.hero .mark {
  width: 58px;
  height: 58px;
  margin: 42px 0 28px;
}

.hero h1 {
  margin: 0 0 20px;
  font-size: clamp(2.4rem, 8.5vw, 3.9rem);
  line-height: 1.02;
  letter-spacing: -0.04em;
  font-weight: 600;
  max-width: 20ch;
}

.hero p {
  margin: 0;
  max-width: 34rem;
  color: var(--ink-soft);
  font-size: 1.12rem;
}

/* ---------- work ---------- */

.work {
  padding: 88px 0 0;
}

.work-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin: 0 0 2px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line-strong);
}

.work-head h2 {
  margin: 0;
  font: inherit;
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

.projects {
  list-style: none;
  margin: 0;
  padding: 0;
}

.panel {
  position: relative;
  padding: 30px 24px 30px 20px;
  border-bottom: 1px solid var(--line);
  transition: background-color 180ms ease;
}

/* the closing rule belongs to the footer, not the last panel */
.panel:last-child {
  border-bottom: 0;
}

/* the left rule is the activation cue — drawn, not laid out, so nothing shifts */
.panel::before {
  content: "";
  position: absolute;
  top: -1px;
  bottom: -1px;
  left: 0;
  width: 2px;
  background: var(--accent);
  transform: scaleY(0);
  transform-origin: 50% 0;
  transition: transform 180ms ease;
}

.panel:hover,
.panel:focus-within {
  background: var(--accent-wash);
}

.panel:hover::before,
.panel:focus-within::before {
  transform: scaleY(1);
}

.panel-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.panel-index {
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  color: var(--ink-faint);
  transition: color 180ms ease;
}

.panel:hover .panel-index,
.panel:focus-within .panel-index {
  color: var(--accent);
}

.panel-platform {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

.panel-body {
  display: flex;
  align-items: flex-start;
  gap: 22px;
}

.panel-art {
  width: 72px;
  height: 72px;
  flex: none;
  position: relative;
  border-radius: 16px;
  overflow: hidden;
}

.panel-art img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.panel-art::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.16);
}

.panel-text {
  min-width: 0;
}

.panel-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 8px;
  font-size: 1.3rem;
  letter-spacing: -0.022em;
  font-weight: 600;
}

/* the arrow is the reveal: it slides in, it does not fade in from nowhere */
.panel-arrow {
  color: var(--accent);
  opacity: 0;
  transform: translateX(-6px);
  transition: opacity 180ms ease, transform 180ms ease;
}

.panel-arrow svg {
  display: block;
  width: 15px;
  height: 15px;
}

.panel:hover .panel-arrow,
.panel:focus-within .panel-arrow {
  opacity: 1;
  transform: none;
}

.panel-text p {
  margin: 0 0 18px;
  color: var(--ink-soft);
  max-width: 38rem;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 !important;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 13px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--panel);
  color: var(--ink);
  font-size: 0.9rem;
  font-weight: 500;
  text-decoration: none;
  transition: border-color 140ms ease, color 140ms ease;
}

.btn:hover,
.btn:focus-visible {
  border-color: var(--accent);
  color: var(--accent);
}

.btn svg {
  width: 12px;
  height: 12px;
  flex: none;
}

/* ---------- contact ---------- */

.contact {
  padding: 92px 0 0;
}

.contact h1 {
  margin: 34px 0 18px;
  font-size: clamp(2.2rem, 7.5vw, 3.2rem);
  letter-spacing: -0.04em;
  line-height: 1.04;
  font-weight: 600;
}

.contact > p {
  margin: 0 0 36px;
  max-width: 32rem;
  color: var(--ink-soft);
  font-size: 1.12rem;
}

.mailto {
  display: inline-block;
  font-size: clamp(1.2rem, 5vw, 1.7rem);
  font-weight: 600;
  letter-spacing: -0.025em;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 2px solid var(--accent);
  padding-bottom: 3px;
  transition: color 140ms ease;
  overflow-wrap: anywhere;
}

.mailto:hover,
.mailto:focus-visible {
  color: var(--accent);
}

.copy-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 20px;
  min-height: 34px;
}

.copy {
  appearance: none;
  font: inherit;
  font-size: 0.88rem;
  cursor: pointer;
  padding: 7px 13px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--panel);
  color: var(--ink-soft);
  transition: border-color 140ms ease, color 140ms ease;
}

.copy:hover,
.copy:focus-visible {
  border-color: var(--accent);
  color: var(--accent);
}

.copy-note {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  opacity: 0;
  transition: opacity 160ms ease;
}

.copy-note.is-shown {
  opacity: 1;
}

/* ---------- footer ---------- */

footer {
  margin-top: 92px;
  padding: 26px 0 48px;
  border-top: 1px solid var(--line-strong);
  color: var(--ink-faint);
  font-size: 0.84rem;
}

footer p {
  margin: 0 0 5px;
}

footer a {
  color: var(--ink-soft);
  text-decoration: none;
  transition: color 140ms ease;
}

footer a:hover,
footer a:focus-visible {
  color: var(--accent);
}

/* ---------- scroll reveal (only ever applied when JS runs) ---------- */

.js .reveal {
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 420ms ease, transform 420ms ease;
}

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

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

/* ---------- narrow ---------- */

@media (max-width: 34rem) {
  .shell {
    padding: 0 16px;
  }

  .panel {
    padding: 26px 0 26px 16px;
  }

  .panel-body {
    gap: 16px;
  }

  .panel-art {
    width: 56px;
    height: 56px;
    border-radius: 13px;
  }

  .hero {
    padding-top: 64px;
  }

  .hero .mark {
    margin: 34px 0 24px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }

  .js .reveal {
    opacity: 1;
    transform: none;
  }

  .panel::before {
    transition: none;
  }
}

/* Floating navigation and a quiet reading-progress edge. */
html { scroll-behavior: smooth; scroll-padding-top: 110px; }
.top {
  position: sticky;
  top: 16px;
  z-index: 10;
  margin-top: 20px;
  padding: 14px 20px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg);
  background: color-mix(in srgb, var(--bg) 90%, transparent);
  backdrop-filter: blur(18px);
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.04);
  overflow: hidden;
}
.top::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--accent);
  transform: scaleX(var(--progress, 0));
  transform-origin: left;
  pointer-events: none;
}
.top nav { display: flex; gap: 20px; }
.top nav a[aria-current] { color: var(--accent); }
.panel { scroll-margin-top: 110px; }

/* Product satellites: real anchor links, usable without JavaScript. */
.orbit {
  position: relative;
  width: 280px;
  height: 240px;
  margin: 32px auto 38px;
  display: grid;
  place-items: center;
}
.orbit-ring {
  position: absolute;
  width: 200px;
  height: 200px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
}
.orbit-ring::before {
  content: "";
  position: absolute;
  inset: 22px;
  border: 1px dashed var(--line);
  border-radius: 50%;
}
.orbit-ring::after {
  content: "";
  position: absolute;
  inset: -10px;
  border: 1px solid transparent;
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: bearing 24s linear infinite;
}
.hero .orbit .mark { width: 68px; height: 68px; margin: 0; }
.orbit-product {
  position: absolute;
  display: grid;
  justify-items: center;
  gap: 6px;
  color: var(--ink-soft);
  text-decoration: none;
  font-family: var(--mono);
  font-size: 11px;
  transition: transform 200ms ease, color 200ms ease;
}
.orbit-product img {
  border-radius: 14px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.12);
  border: 3px solid var(--bg);
}
.orbit-one { top: 0; left: 40px; }
.orbit-two { right: 0; top: 88px; }
.orbit-three { bottom: -8px; left: 48px; }
.orbit-product:hover, .orbit-product:focus-visible { transform: translateY(-5px); color: var(--accent); }
@keyframes bearing { to { transform: rotate(360deg); } }

/* Light follows the pointer; keyboard focus gets the same illuminated surface. */
.panel::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(240px circle at var(--pointer-x, 50%) var(--pointer-y, 50%), var(--accent-wash), transparent);
  pointer-events: none;
  opacity: 0;
  transition: opacity 220ms ease;
}
.panel:hover::after, .panel:focus-within::after { opacity: 1; }
.panel-art { transition: transform 220ms ease, box-shadow 220ms ease; }
.panel:hover .panel-art, .panel:focus-within .panel-art {
  transform: translateY(-4px) rotate(-3deg);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.12);
}
@media (max-width: 34rem) {
  .top { padding: 12px 16px; gap: 10px; }
  .top nav { gap: 14px; }
  .top nav a { font-size: 0.85rem; }
  .brand { gap: 6px; font-size: 0.95rem; }
  .hero { padding-top: 48px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .orbit-ring::after { animation: none; }
  .orbit-product:hover, .orbit-product:focus-visible,
  .panel:hover .panel-art, .panel:focus-within .panel-art { transform: none; }
}

/* ---------- blog ---------- */

.skip {
  position: absolute;
  left: 16px;
  top: -60px;
  z-index: 20;
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
  text-decoration: none;
}
.skip:focus { top: 12px; }

.top nav a[aria-current="page"] { color: var(--accent); }

.blog-head,
.post-head {
  padding: 92px 0 0;
}

.blog-head h1,
.post-head h1 {
  margin: 34px 0 18px;
  font-size: clamp(2.1rem, 7vw, 3.1rem);
  line-height: 1.06;
  letter-spacing: -0.04em;
  font-weight: 600;
}

.blog-head > p,
.dek {
  margin: 0;
  max-width: 36rem;
  color: var(--ink-soft);
  font-size: 1.15rem;
}

.byline {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  margin: 22px 0 0;
}

/* the index: one row per post, the same ruled rhythm as the products list */
.posts {
  list-style: none;
  margin: 56px 0 0;
  padding: 0;
  border-top: 1px solid var(--line-strong);
}

.post-card {
  position: relative;
  padding: 28px 0;
  border-bottom: 1px solid var(--line);
}

.post-card a {
  color: inherit;
  text-decoration: none;
}

.post-card a::after {
  content: "";
  position: absolute;
  inset: 0;
}

.post-card img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  margin-bottom: 20px;
  transition: transform 220ms ease;
}

.post-card:hover img,
.post-card:focus-within img {
  transform: translateY(-3px);
}

.post-card h2 {
  margin: 8px 0 8px;
  font-size: 1.45rem;
  line-height: 1.2;
  letter-spacing: -0.025em;
  font-weight: 600;
  transition: color 140ms ease;
}

.post-card:hover h2,
.post-card:focus-within h2 {
  color: var(--accent);
}

.post-card p {
  margin: 0;
  color: var(--ink-soft);
}

/* ---------- a post ---------- */

.post-figure {
  margin: 44px 0;
}

.post-figure img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 14px;
  border: 1px solid var(--line);
}

.post-figure figcaption {
  margin-top: 10px;
  color: var(--ink-faint);
  font-size: 0.86rem;
}

.post-figure.wide {
  margin-left: -24px;
  margin-right: -24px;
}

.facts {
  position: relative;
  margin: 0 0 48px;
  padding: 24px 24px 22px 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
}

.facts::before {
  content: "";
  position: absolute;
  top: 18px;
  bottom: 18px;
  left: -1px;
  width: 2px;
  background: var(--accent);
}

.facts h2 {
  margin: 0 0 12px !important;
}

.facts ul {
  margin: 0;
  padding-left: 1.1em;
}

.facts li {
  margin: 0 0 6px;
  color: var(--ink-soft);
}

.facts li strong {
  color: var(--ink);
  font-weight: 600;
}

.prose {
  max-width: 40rem;
}

.prose p,
.prose li {
  color: var(--ink-soft);
}

.prose p {
  margin: 0 0 20px;
}

.prose strong {
  color: var(--ink);
  font-weight: 600;
}

.prose a {
  color: var(--ink);
  text-decoration-color: var(--accent);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
  transition: color 140ms ease;
}

.prose a:hover,
.prose a:focus-visible {
  color: var(--accent);
}

.prose h2 {
  margin: 64px 0 18px;
  font-size: 1.6rem;
  line-height: 1.2;
  letter-spacing: -0.03em;
  font-weight: 600;
}

.prose h3 {
  margin: 40px 0 10px;
  font-size: 1.18rem;
  letter-spacing: -0.018em;
  font-weight: 600;
}

.prose ul {
  margin: 0 0 22px;
  padding-left: 1.2em;
}

.prose li {
  margin: 0 0 8px;
}

.prose code {
  font-family: var(--mono);
  font-size: 0.86em;
  padding: 2px 6px;
  border-radius: 6px;
  background: var(--accent-wash);
  border: 1px solid var(--line);
  color: var(--ink);
  overflow-wrap: anywhere;
}

.lede {
  font-size: 1.15rem;
  color: var(--ink) !important;
}

/* vibes, drawn the way the app draws them */
.prose .vibes {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 4px 0 24px;
  padding: 0;
  list-style: none;
}

.prose .vibes li {
  margin: 0;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--ink);
  background: color-mix(in srgb, var(--vibe) 16%, var(--panel));
  border: 1px solid color-mix(in srgb, var(--vibe) 34%, transparent);
  transition: transform 160ms ease;
}

.prose .vibes li:hover {
  transform: translateY(-2px) rotate(-2deg);
}

/* the comparison: scrolls inside itself on a phone, never the page */
.table-wrap {
  margin: 0 0 14px;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
}

.compare {
  width: 100%;
  min-width: 40rem;
  border-collapse: collapse;
  font-size: 0.9rem;
  line-height: 1.45;
}

.compare caption {
  caption-side: bottom;
  padding: 12px 16px;
  text-align: left;
  color: var(--ink-faint);
  font-size: 0.82rem;
  border-top: 1px solid var(--line);
}

.compare th,
.compare td {
  padding: 12px 14px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--line);
  color: var(--ink-soft);
}

.compare thead th {
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

.compare tbody th {
  color: var(--ink);
  font-weight: 600;
  width: 22%;
}

.compare tbody tr:last-child > * {
  border-bottom: 0;
}

.compare .ours {
  background: var(--accent-wash);
  color: var(--ink);
  font-weight: 500;
}

.compare thead .ours {
  color: var(--accent);
}

.faq h3 {
  margin-top: 28px;
}

.cta {
  margin: 30px 0 0;
}

.post-foot {
  margin-top: 64px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.post-foot a {
  color: var(--ink-soft);
  text-decoration: none;
}

.post-foot a:hover,
.post-foot a:focus-visible {
  color: var(--accent);
}

@media (max-width: 34rem) {
  .blog-head,
  .post-head {
    padding-top: 56px;
  }

  .post-figure.wide {
    margin-left: -16px;
    margin-right: -16px;
  }

  .post-figure.wide img {
    border-radius: 0;
    border-left: 0;
    border-right: 0;
  }

  .post-figure.wide figcaption {
    padding: 0 16px;
  }

  /* diagrams stay legible on a phone: they scroll sideways inside themselves */
  .post-figure.diagram .scroller {
    overflow-x: auto;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
  }

  .post-figure.diagram .scroller img {
    width: 780px;
    max-width: none;
    border: 0;
  }

  .facts {
    padding: 20px 18px 18px 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .post-card:hover img,
  .post-card:focus-within img,
  .prose .vibes li:hover {
    transform: none;
  }
}
