/* Frantic Infotech LLC — site styles. Direction: the dark room (soot and lime, Newsreader). */

:root {
  --bg: #0f0f0f;
  --surface: #1a1a1a;
  --ink: #f4f4f1;
  --muted: #9a9a96;
  --accent: #dafa9c;
  --accent-ink: #0f0f0f;
  --field-1: #ffffff;  --field-1-ink: #0f0f0f;

  --font-display: "Newsreader", Georgia, "Times New Roman", serif;
  --font-text: "Newsreader", Georgia, "Times New Roman", serif;

  --step-small: clamp(0.8125rem, 0.79rem + 0.1vw, 0.875rem);
  --step-body: clamp(1.125rem, 1.05rem + 0.3vw, 1.3125rem);
  --step-lead: clamp(1.25rem, 1.1rem + 0.7vw, 1.625rem);
  --step-head: clamp(2rem, 1.3rem + 3.2vw, 4rem);

  --margin: clamp(1.25rem, 2.8vw, 2.5rem);
  --gutter: clamp(1rem, 2vw, 2rem);
  --section: clamp(7rem, 14vw, 14rem);
  --radius: 0px;

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.76, 0, 0.24, 1);
  --ease-soft: cubic-bezier(0.33, 1, 0.68, 1);
  --t-press: 140ms;
  --t-hover: 180ms;
  --t-ui: 240ms;
  --t-reveal: 800ms;
}

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; background: var(--bg); }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--font-text); font-size: var(--step-body); line-height: 1.6; font-kerning: normal; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; font-optical-sizing: auto; }
h1, h2, h3, h4, p, figure, blockquote, ul, ol, dl, dd { margin: 0; }
ul[class], ol[class] { padding: 0; list-style: none; }
img, video, svg, canvas { display: block; max-width: 100%; }
img, video { height: auto; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; padding: 0; cursor: pointer; }
a { color: inherit; }
:target { scroll-margin-top: 4rem; }
::selection { background: var(--accent); color: var(--accent-ink); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

h1, h2, h3 { font-family: var(--font-display); font-weight: 400; text-wrap: balance; hyphens: none; }
p { max-width: 62ch; text-wrap: pretty; }
p + p { margin-top: 0.9em; }
.nums { font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }

.button { display: inline-flex; align-items: center; justify-content: center; min-height: 3rem; padding: 0 1.5rem; background: var(--accent); color: var(--accent-ink); border-radius: var(--radius); text-decoration: none; white-space: nowrap; font-weight: 500; transition: transform var(--t-press) var(--ease-out), background-color var(--t-hover) ease; }
.button:active { transform: scale(0.97); }
.link { text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 0.22em; text-decoration-thickness: 0.06em; transition: text-decoration-color var(--t-hover) ease; }
@media (hover: hover) and (pointer: fine) {
  .button:hover { background-color: #e8ffb8; }
  .link:hover { text-decoration-color: currentColor; }
}

/* ---------- hero: two tones, control that reads the page ---------- */
.hero { display: grid; grid-template-columns: 1fr 1fr; min-height: 100svh; position: relative; }
.hero-left { position: relative; background: var(--bg); padding: 40px; display: flex; flex-direction: column; justify-content: flex-end; min-height: 100svh; }
.hero-right { background: var(--surface); display: grid; place-items: center; padding: 40px; }
.mark { position: absolute; top: 40px; left: 40px; z-index: 2; display: inline-flex; align-items: baseline; gap: 10px; text-decoration: none; font-size: 16px; }
.mark svg { width: 28px; height: 28px; align-self: center; }
.toplink { position: absolute; top: 40px; right: 40px; font-size: 16px; z-index: 2; }
.hero h1 { font-size: clamp(26px, 2.1vw, 32px); font-weight: 500; line-height: 1.15; letter-spacing: -0.01em; max-width: 24ch; }
.hero-support { margin-top: 14px; font-size: 16px; line-height: 1.5; color: var(--ink); max-width: 44ch; }
.hero .button { margin-top: 28px; align-self: flex-start; }

/* the live fragment */
[data-ui].liveline { width: min(450px, 100%); aspect-ratio: 1; background: #0b0b0b; color: #f4f4f1; border: 1px solid #2a2a2a; border-radius: 6px; padding: 22px; display: flex; flex-direction: column; font-family: var(--font-text); }
[data-ui].liveline .ll-head { display: flex; justify-content: space-between; align-items: center; font-size: 15px; padding-bottom: 14px; border-bottom: 1px solid #262626; }
[data-ui].liveline .ll-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); display: inline-block; margin-right: 8px; animation: ll-pulse 1.6s ease-in-out infinite; }
[data-ui].liveline .ll-rows { flex: 1; display: flex; flex-direction: column; justify-content: space-evenly; }
[data-ui].liveline .ll-row { display: grid; grid-template-columns: 1fr auto; align-items: baseline; gap: 12px; padding: 6px 0; border-bottom: 1px solid #1c1c1c; }
[data-ui].liveline .ll-row:last-child { border-bottom: 0; }
[data-ui].liveline .ll-label { font-size: 13px; color: #9a9a96; }
[data-ui].liveline .ll-value { font-size: 24px; font-variant-numeric: tabular-nums; letter-spacing: -0.01em; transition: color var(--t-hover) ease; }
[data-ui].liveline .ll-value.is-hot { color: var(--accent); }
[data-ui].liveline .ll-big .ll-value { font-size: 44px; line-height: 1; font-weight: 300; }
[data-ui].liveline .ll-foot { font-size: 13px; color: #9a9a96; padding-top: 12px; border-top: 1px solid #262626; }
@keyframes ll-pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.35; } }

/* ---------- work: one strip per project ---------- */
.work { padding: calc(var(--section) / 2) var(--margin); display: grid; grid-template-columns: 13% 1fr; column-gap: var(--gutter); }
.work-rail { position: sticky; top: 40px; align-self: start; }
.work-rail h2 { font-size: 30px; font-weight: 400; line-height: 1.1; }
.work-filters { margin-top: 18px; display: flex; flex-direction: column; gap: 6px; font-size: 16px; }
.work-filters button { color: var(--muted); text-align: left; transition: color var(--t-hover) ease; }
.work-filters button[aria-pressed="true"] { color: var(--ink); }
.work-list { display: flex; flex-direction: column; gap: 45px; min-width: 0; }
.strip { transition: opacity var(--t-ui) ease; }
.strip.is-hidden { display: none; }
.work-list:hover .strip:not(:hover) { opacity: 0.4; }
.frames { display: flex; gap: 8px; height: 238px; overflow: hidden; }
.frames > * { flex: 0 0 auto; height: 190px; zoom: 1.25; }
.strip-caption { display: grid; grid-template-columns: 1fr auto 1fr; font-size: 16px; margin-top: 10px; color: var(--ink); }
.strip-caption .c { text-align: center; color: var(--muted); }
.strip-caption .r { text-align: right; color: var(--muted); }

/* interface fragments (the product's own conventions apply inside) */
[data-ui].frame { background: #161616; color: #f4f4f1; border: 1px solid #262626; border-radius: 6px; overflow: hidden; font-size: 12px; line-height: 1.3; font-family: var(--font-text); }
[data-ui].frame .bar { display: flex; justify-content: space-between; align-items: center; padding: 8px 10px; background: #1f1f1f; font-size: 11px; color: #9a9a96; }
[data-ui].frame .bar b { color: #f4f4f1; font-weight: 500; }
[data-ui].frame .row { display: grid; grid-template-columns: 1fr auto; gap: 10px; padding: 6px 10px; border-top: 1px solid #222; font-variant-numeric: tabular-nums; }
[data-ui].frame .row.sel { background: #222; }
[data-ui].frame .row small { display: block; color: #9a9a96; font-size: 10px; }
[data-ui].frame .up { color: #b6f06a; }
[data-ui].frame .dn { color: #ff8a80; }
[data-ui].frame .chain { display: grid; grid-template-columns: repeat(5, auto); gap: 4px 12px; padding: 6px 10px; font-size: 11px; font-variant-numeric: tabular-nums; border-top: 1px solid #222; }
[data-ui].frame .chain .h { color: #9a9a96; font-size: 10px; }
[data-ui].frame .chain .k { color: #f4f4f1; background: #262626; padding: 0 4px; }
[data-ui].frame svg.chart { width: 100%; height: 150px; }
[data-ui].frame .ticket { padding: 8px 10px; display: grid; gap: 6px; }
[data-ui].frame .ticket .seg { display: grid; grid-template-columns: 1fr 1fr; background: #222; }
[data-ui].frame .ticket .seg span { text-align: center; padding: 5px; color: #9a9a96; }
[data-ui].frame .ticket .seg span.on { background: #b6f06a; color: #0f0f0f; }
[data-ui].frame .ticket .fld { display: flex; justify-content: space-between; padding: 6px 8px; background: #202020; }
[data-ui].frame .ticket .go { background: #b6f06a; color: #0f0f0f; text-align: center; padding: 7px; font-weight: 500; }
[data-ui].frame .score { padding: 10px; }
[data-ui].frame .score .big { font-size: 26px; line-height: 1; letter-spacing: -0.02em; }
[data-ui].frame .score .vs { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 8px; }
[data-ui].frame .score .live { color: #b6f06a; font-size: 10px; }
[data-ui].frame .rate { display: grid; grid-template-columns: 1fr auto auto; gap: 6px 10px; padding: 6px 10px; border-top: 1px solid #222; align-items: center; }
[data-ui].frame .rate .pill { background: #2b3a1b; color: #d9ffa6; padding: 2px 7px; text-align: center; min-width: 40px; }
[data-ui].frame .rate .pill.pk { background: #3a2222; color: #ffc4be; }
[data-ui].frame .para { padding: 8px 10px; font-size: 11.5px; color: #e6e6e2; }
[data-ui].frame .para em { color: #9a9a96; font-style: normal; font-size: 10px; display: block; margin-bottom: 4px; }
[data-ui].frame .week { display: grid; grid-template-columns: repeat(7, 1fr); gap: 3px; padding: 8px; }
[data-ui].frame .week div { background: #222; padding: 6px 2px; text-align: center; font-size: 10px; }
[data-ui].frame .week div.q { background: #b6f06a; color: #0f0f0f; }
[data-ui].frame .week div.l { background: #3b4f22; }
[data-ui].frame .week div.r { background: #1a1a1a; color: #9a9a96; }
[data-ui].frame .feel { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; padding: 6px 10px 10px; }
[data-ui].frame .feel span { background: #222; text-align: center; padding: 8px 0; font-size: 10px; }
[data-ui].frame .feel span.on { background: #b6f06a; color: #0f0f0f; }
[data-ui].frame .msg { margin: 6px 10px; padding: 7px 9px; background: #222; max-width: 85%; font-size: 11.5px; }
[data-ui].frame .msg.me { background: #2b3a1b; margin-left: auto; }
[data-ui].frame .msg small { display: block; color: #c2c2bd; font-size: 9.5px; margin-top: 3px; }

/* ---------- about: side facts, wide paragraph ---------- */
.about { padding: calc(var(--section) / 2) var(--margin); }
.about-row { display: grid; grid-template-columns: 34% 1fr; }
.facts { display: flex; flex-direction: column; gap: 20px; width: 180px; font-size: 16px; }
.facts dt { color: var(--muted); }
.facts dd { color: var(--ink); margin-top: 2px; }
.about-para { font-size: clamp(20px, 1.7vw, 26px); line-height: 1.35; max-width: none; width: 90%; }
.about-row + .about-row { margin-top: 120px; }
.record-word { font-size: 16px; }
.record { display: grid; grid-template-columns: repeat(2, minmax(0, 260px)); column-gap: clamp(24px, 4vw, 64px); }
.record ul { font-size: 16px; }
.record li { display: flex; justify-content: space-between; gap: 12px; padding-bottom: 10px; }
.record li span:last-child { color: var(--muted); }

/* ---------- contact: one field ---------- */
.contact { padding: 200px var(--margin) 160px; }
.contact-col { width: min(520px, 100%); margin-left: clamp(0px, 34%, calc(100% - 520px)); }
.contact-prompt { font-size: clamp(22px, 2.1vw, 30px); font-weight: 500; line-height: 1.25; max-width: none; }
.contact-prompt span { display: block; }
.contact-prompt .soft { color: var(--muted); }
.contact-form { position: relative; margin-top: 28px; }
.contact-form input { width: 100%; height: 64px; padding: 0 64px 0 18px; background: var(--field-1); color: var(--field-1-ink); border: 0; border-radius: var(--radius); font-size: 17px; }
.contact-form input::placeholder { color: #6a6a66; }
.contact-form input:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.contact-form button { position: absolute; top: 10px; right: 8px; width: 44px; height: 44px; background: var(--accent-ink); color: var(--accent); border-radius: 50%; display: grid; place-items: center; transition: transform var(--t-press) var(--ease-out); }
.contact-form button:active { transform: scale(0.94); }
.contact-form button svg { width: 18px; height: 18px; }
.contact-next { margin-top: 16px; font-size: 16px; color: var(--muted); }
.contact-rows { margin-top: 72px; display: grid; gap: 14px; font-size: 16px; }
.contact-rows div { display: grid; grid-template-columns: 90px 1fr; gap: 12px; }
.contact-rows dt { color: var(--muted); }
.contact-rows dd a { text-decoration: none; }
.todo { color: var(--accent); }

/* ---------- footer: name across the last photograph ---------- */
.footer { position: relative; height: 100svh; overflow: hidden; color: #f4f4f1; }
.footer img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 35%; filter: brightness(0.62); }
.footer-top { position: absolute; top: 32px; left: 32px; right: 32px; display: flex; justify-content: space-between; font-size: 16px; }
.footer-top ul { display: flex; flex-direction: column; gap: 4px; }
.footer-top address { font-style: normal; text-align: right; max-width: 25%; }
.footer-bottom { position: absolute; left: 0; right: 0; bottom: 0; padding: 0 0 20px; }
.wordmark { font-weight: 300; font-size: 12.1vw; line-height: 0.85; letter-spacing: -0.045em; white-space: nowrap; padding: 0 1.5vw; text-align: left; }
.legal { font-size: 16px; padding: 14px 32px 0; max-width: none; color: #d6d6d2; }
.legal a { text-underline-offset: 0.2em; }

/* ---------- text pages (privacy, terms) ---------- */
.doc { padding: 120px var(--margin) 160px; max-width: 68ch; margin-left: 34%; }
.doc h1 { font-size: clamp(32px, 3.4vw, 48px); font-weight: 300; line-height: 1.05; letter-spacing: -0.03em; }
.doc .dated { margin-top: 16px; font-size: 15px; color: var(--muted); }
.doc h2 { font-size: clamp(22px, 2vw, 28px); font-weight: 500; margin-top: 56px; line-height: 1.2; }
.doc p, .doc li { margin-top: 14px; }
.doc ul { padding-left: 1.2em; }
.doc li + li { margin-top: 8px; }
.doc .back { display: inline-block; margin-top: 64px; }
.doc-top { position: absolute; top: 40px; left: 40px; right: 40px; display: flex; justify-content: space-between; font-size: 15px; }
.doc-top .mark { position: static; }

/* ---------- motion (content stays visible without script) ---------- */
.lines .line { display: block; overflow: hidden; padding-bottom: 0.08em; margin-bottom: -0.08em; }
.lines [data-line] { display: block; }
@media (prefers-reduced-motion: no-preference) {
  .js [data-rise] { opacity: 0; transform: translateY(18px); animation: ad-rise var(--t-reveal) var(--ease-out) forwards; animation-delay: calc(var(--i, 0) * 90ms + 420ms); }
  .js .lines [data-line] { transform: translateY(105%); animation: ad-line 900ms var(--ease-out) forwards; animation-delay: calc(var(--i, 0) * 110ms + 150ms); }
  .js [data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity 700ms var(--ease-out), transform 900ms var(--ease-out); transition-delay: calc(var(--i, 0) * 80ms); }
  .js [data-reveal].is-in { opacity: 1; transform: none; }
  .js .footer img { transform: scale(1.06); transition: transform 2400ms var(--ease-soft); }
  .js .footer.is-in img { transform: scale(1); }
  @supports (animation-timeline: view()) {
    .footer img { animation: drift linear both; animation-timeline: view(); animation-range: entry 0% exit 100%; }
    @keyframes drift { from { object-position: 50% 30%; } to { object-position: 50% 42%; } }
  }
}
@keyframes ad-rise { to { opacity: 1; transform: none; } }
@keyframes ad-line { to { transform: none; } }
@media (prefers-reduced-motion: reduce) {
  [data-ui].liveline .ll-dot { animation: none; }
}

/* ---------- phone ---------- */
@media (max-width: 760px) {
  .hero { grid-template-columns: 1fr; }
  .hero-right { order: -1; min-height: 58svh; padding: 72px 20px 24px; }
  .hero-left { min-height: 42svh; padding: 32px 20px 40px; }
  .mark { top: 20px; left: 20px; z-index: 2; }
  .toplink { top: 24px; right: 20px; }
  [data-ui].liveline { width: 78vw; padding: 16px; }
  [data-ui].liveline .ll-value { font-size: 20px; }
  [data-ui].liveline .ll-big .ll-value { font-size: 36px; }
  .hero h1 { font-size: 6.4vw; }
  .hero-support { font-size: 16px; }

  .work { grid-template-columns: 1fr; padding-inline: 20px; }
  .work-rail { position: static; display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 28px; }
  .work-filters { flex-direction: row; gap: 16px; margin-top: 0; }
  .work-list:hover .strip:not(:hover) { opacity: 1; }
  .frames { height: 120px; overflow-x: auto; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
  .frames::-webkit-scrollbar { display: none; }
  .frames > * { height: 190px; scroll-snap-align: start; zoom: 0.632; }
  .strip-caption { grid-template-columns: 1fr 1fr; }
  .strip-caption .c { display: none; }

  .about { padding-inline: 20px; }
  .about-row { grid-template-columns: 1fr; }
  .about-para { font-size: 19px; width: 100%; }
  .facts { order: 2; width: 100%; display: grid; grid-template-columns: 1fr 1fr; font-size: 14px; margin-top: 32px; }
  .about-row + .about-row { margin-top: 56px; }
  .record-word { color: var(--ink); margin-bottom: 12px; }
  .record { grid-template-columns: 1fr; row-gap: 40px; }

  .contact { padding: 120px 20px 100px; }
  .contact-col { margin-left: 0; width: 100%; }
  .contact-prompt { font-size: 22px; }
  .contact-form input { height: 60px; }
  .contact-form button { top: 8px; }
  .contact-rows div { grid-template-columns: 1fr; gap: 2px; }
  .contact-rows { gap: 20px; }

  .footer { height: 88svh; }
  .footer img { object-position: 60% 40%; }
  .footer-top { flex-direction: column; gap: 20px; left: 20px; right: 20px; }
  .footer-top address { text-align: left; max-width: none; }
  .wordmark { font-size: 11.6vw; }
  .legal { padding: 12px 20px 0; font-size: 14px; }

  .doc { margin-left: 0; padding: 110px 20px 120px; }
  .doc-top { left: 20px; right: 20px; top: 24px; }
}
