/* Pro-Review.ro — "banc de probă" theme.
   Spec-sheet grammar for an appliance-review publication: navy drench
   masthead, amber as the price/verdict signal, Archivo grotesque display
   over a system-stack body, tabular numerals in data. The three rising
   bars = "trepte" (power steps), the site mark. */

/* ---------- fonts ---------- */
/* Archivo variable, instanced to wdth 100–112 (the only widths used: default
   and 112%) with fonttools varLib.instancer — hermes ticket 77. /fonts/* is
   served immutable for a year (static/_headers): any change to a font file
   MUST ship under a new filename. */

@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 100 900;
  font-stretch: 100% 112%;
  font-display: swap;
  src: url(/fonts/archivo-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 100 900;
  font-stretch: 100% 112%;
  font-display: swap;
  src: url(/fonts/archivo-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ---------- tokens ---------- */

:root {
  --brand-deep: oklch(0.32 0.05 255);
  --brand-shade: oklch(0.27 0.045 255);
  --brand: oklch(0.45 0.08 252);
  --accent: oklch(0.79 0.13 75);
  --accent-deep: oklch(0.56 0.11 62);
  --accent-text: oklch(0.47 0.1 55);
  --accent-wash: oklch(0.965 0.02 85);
  --accent-line: oklch(0.88 0.06 85);

  --paper: oklch(0.978 0.004 250);
  --card: oklch(1 0 0);
  --ink: oklch(0.27 0.02 255);
  --ink-soft: oklch(0.44 0.018 255);
  --line: oklch(0.89 0.01 250);
  --line-strong: oklch(0.76 0.025 252);
  --wash: oklch(0.962 0.008 250);

  /* text on the brand-deep drench */
  --on-brand: oklch(0.965 0.008 250);
  --on-brand-soft: oklch(0.84 0.03 250);
  --on-brand-line: oklch(0.44 0.05 253);

  --font-display: "Archivo", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-text: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --text-xs: 0.8125rem;
  --text-sm: 0.9375rem;
  --text-body: 1.0625rem;
  --text-lg: 1.1875rem;
  --text-h3: 1.3125rem;
  --text-h2: clamp(1.4375rem, 1.15rem + 1.4vw, 1.875rem);
  --text-h1: clamp(1.875rem, 1.3rem + 2.8vw, 2.75rem);

  --space-xs: 0.625rem;
  --space-sm: 1rem;
  --space-md: 1.5rem;
  --space-lg: 2.5rem;
  --space-xl: clamp(3rem, 3vw + 2rem, 4.5rem);

  --measure: 42rem;
  --wide: 64rem;
  --gutter: 1.25rem;
  --radius: 4px;

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------- base ---------- */

* { box-sizing: border-box; }

html {
  background: var(--paper);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-text);
  font-size: var(--text-body);
  line-height: 1.65;
  font-kerning: normal;
  overflow-x: clip;
  -webkit-text-size-adjust: 100%;
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.16;
  color: var(--brand-deep);
  text-wrap: balance;
  margin: 0;
  letter-spacing: -0.015em;
}

p { margin: 0 0 1em; }

a { color: var(--brand); }

a:hover { color: var(--brand-deep); }

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

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

.skip-link {
  position: absolute;
  left: var(--gutter);
  top: -3rem;
  z-index: 10;
  background: var(--accent);
  color: var(--brand-shade);
  font-weight: 600;
  padding: 0.5rem 1rem;
  text-decoration: none;
  transition: top 0.15s var(--ease-out);
}

.skip-link:focus { top: 0.5rem; }

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

.wrap-wide { max-width: var(--wide); }

/* bar-rule: hairline divider carrying the three-step site mark */
.bar-rule {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  border: 0;
  margin: var(--space-lg) 0;
}

.bar-rule::before,
.bar-rule::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}

.bar-rule svg { display: block; color: var(--accent-deep); }

/* ---------- header (drenched) ---------- */

.site-header {
  background: var(--brand-deep);
  color: var(--on-brand);
  border-bottom: 3px solid var(--accent);
}

.masthead {
  max-width: var(--wide);
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.375rem 1.5rem;
  padding-top: clamp(1.125rem, 2.5vw, 1.75rem);
  padding-bottom: clamp(0.875rem, 2vw, 1.375rem);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  color: var(--on-brand);
  text-decoration: none;
}

.brand-mark { flex: none; translate: 0 1px; }

.brand-mark rect { transition: translate 0.35s var(--ease-out); }

.brand:hover .brand-mark rect:nth-child(1) { translate: 0 -2px; }
.brand:hover .brand-mark rect:nth-child(2) { translate: 0 -3px; }
.brand:hover .brand-mark rect:nth-child(3) { translate: 0 -4px; }

.brand-word {
  font-family: var(--font-display);
  font-weight: 800;
  font-stretch: 112%;
  font-size: clamp(1.375rem, 1.1rem + 1.3vw, 1.75rem);
  letter-spacing: 0.015em;
  text-transform: uppercase;
  line-height: 1;
}

.brand-word .tld { color: var(--accent); }

.tagline {
  margin: 0;
  color: var(--on-brand-soft);
  font-size: var(--text-sm);
}

.site-nav {
  border-top: 1px solid var(--on-brand-line);
}

.site-nav .wrap {
  max-width: var(--wide);
  display: flex;
  gap: 1.75rem;
  overflow-x: auto;
  scrollbar-width: none;
}

.site-nav .wrap::-webkit-scrollbar { display: none; }

.site-nav a {
  flex: none;
  color: var(--on-brand);
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 600;
  text-decoration: none;
  padding: 0.625rem 0 calc(0.625rem - 2px);
  border-bottom: 2px solid transparent;
  transition: border-color 0.15s var(--ease-out), color 0.15s var(--ease-out);
}

.site-nav a:hover {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

@media (max-width: 40rem) {
  .masthead .tagline { display: none; }
}

/* ---------- article ---------- */

.site-main { padding: var(--space-xl) 0; }

/* pages that end in the drenched closing band meet the footer flush */
.site-main:has(.closing-band) { padding-bottom: 0; }

.cat-chip {
  display: inline-block;
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--brand);
  background: var(--card);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  padding: 0.1875rem 0.625rem;
  text-decoration: none;
  margin-bottom: var(--space-sm);
  transition: border-color 0.15s var(--ease-out), color 0.15s var(--ease-out);
}

.cat-chip:hover { border-color: var(--brand); color: var(--brand-deep); }

.article-header h1 { font-size: var(--text-h1); }

.article-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.375rem 0.625rem;
  margin: var(--space-sm) 0 0;
  color: var(--ink-soft);
  font-size: var(--text-sm);
}

.article-meta .dot {
  width: 4px;
  height: 4px;
  background: var(--accent-deep);
  rotate: 45deg;
}

.verified {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--accent-text);
  background: var(--accent-wash);
  border: 1px solid var(--accent-line);
  border-radius: var(--radius);
  padding: 0.125rem 0.5rem;
}

.verified svg { display: block; }

.intro {
  font-size: var(--text-lg);
  line-height: 1.6;
  color: var(--ink-soft);
  margin: var(--space-md) 0 0;
  text-wrap: pretty;
}

/* ---------- review body (markdown content) ---------- */

.review-body h2 {
  font-size: var(--text-h2);
  border-top: 1px solid var(--line);
  padding-top: var(--space-md);
  margin: var(--space-lg) 0 var(--space-sm);
}

/* collapsed H2 table of contents (layouts/partials/toc.html, ticket 80).
   Selectors hang off .toc so frozen pages, which never get one, keep
   their exact rendering. */
.review-body .toc {
  margin: var(--space-md) 0;
  background: var(--card);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  font-size: var(--text-sm);
}

.review-body .toc summary {
  cursor: pointer;
  padding: 0.625rem 1rem;
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--brand-deep);
}

.review-body .toc summary::marker { color: var(--accent-deep); }

.review-body .toc .toc-count { color: var(--ink-soft); font-weight: 400; }

.review-body .toc ul { margin: 0; padding: 0 1rem 0.75rem 2.25rem; }

.review-body .toc li { margin-bottom: 0.25rem; }

.review-body .toc ~ h2 { scroll-margin-top: var(--space-sm); }

.review-body h3 {
  font-size: var(--text-h3);
  margin: var(--space-md) 0 var(--space-xs);
}

.review-body p, .review-body li { text-wrap: pretty; }

.review-body ul, .review-body ol { margin: 0 0 1em; padding-left: 1.5rem; }

.review-body li { margin-bottom: 0.375rem; }

.review-body li::marker { color: var(--accent-deep); }

.review-body img {
  margin: var(--space-md) auto;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.review-body blockquote {
  margin: var(--space-md) 0;
  padding: 0.75rem 1.125rem;
  background: var(--wash);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--ink-soft);
}

.review-body blockquote p:last-child { margin-bottom: 0; }

.review-body hr {
  border: 0;
  height: 1px;
  background: var(--line);
  margin: var(--space-lg) 0;
}

/* comparison / spec tables */
.review-body table {
  width: 100%;
  border-collapse: collapse;
  margin: var(--space-md) 0;
  font-size: var(--text-sm);
  font-variant-numeric: tabular-nums;
  background: var(--card);
  border: 1px solid var(--line-strong);
}

/* the lead comparison table is the verdict module — amber top rule */
.review-body > table:first-of-type { border-top: 3px solid var(--accent); }

.review-body th {
  font-family: var(--font-display);
  background: var(--brand-deep);
  color: var(--on-brand);
  text-align: left;
  font-weight: 600;
  padding: 0.625rem 0.75rem;
}

.review-body td {
  padding: 0.625rem 0.75rem;
  border-top: 1px solid var(--line);
  vertical-align: top;
}

.review-body td:first-child { font-weight: 600; }

@media (max-width: 44rem) {
  .review-body table { display: block; overflow-x: auto; }
}

/* store links (affiliate/merchant, classed by the link render hook) */
a.store-link::after {
  content: "";
  display: inline-block;
  width: 0.6em;
  height: 0.6em;
  margin-left: 0.2em;
  background: currentColor;
  -webkit-mask: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 12 12"><path d="M3.5 1h7.5v7.5h-2V4.4L2.4 11 1 9.6 7.6 3H3.5z" fill="black"/></svg>') center / contain no-repeat;
  mask: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 12 12"><path d="M3.5 1h7.5v7.5h-2V4.4L2.4 11 1 9.6 7.6 3H3.5z" fill="black"/></svg>') center / contain no-repeat;
}

/* price rows: a paragraph that opens bold and carries a store link
   (new pipeline: "Preț: ~502 RON (emag.ro)"; legacy: bold CTA sentence) */
.review-body p:has(> strong:first-child):has(a.store-link) {
  background: var(--accent-wash);
  border: 1px solid var(--accent-line);
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  margin: var(--space-sm) 0 var(--space-md);
}

.review-body p:has(> strong:first-child):has(a.store-link) > strong:first-child {
  color: var(--accent-text);
}

/* legacy affiliate call-out (kept for any inline HTML remnants) */
.review-body .affiliate,
.affiliate {
  background: var(--accent-wash);
  border: 1px solid var(--accent-line);
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  margin: var(--space-sm) 0;
  font-size: var(--text-sm);
}

.affiliate strong { color: var(--accent-text); }

/* ---------- alternatives: opinion page -> comparison pages ---------- */

.alternatives {
  background: var(--accent-wash);
  border: 1px solid var(--accent-line);
  border-left: 4px solid var(--accent);
  border-radius: var(--radius);
  padding: 0.875rem 1.125rem;
  margin: var(--space-md) 0;
}

.alternatives-title {
  margin: 0 0 0.5rem;
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--accent-text);
}

.alternatives ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.375rem;
}

.alternatives a {
  font-weight: 600;
  color: var(--brand);
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

.alternatives a::after { content: " →"; }

/* ---------- closing band (drenched): related reviews ---------- */

.closing-band {
  margin-top: var(--space-xl);
  background: var(--brand-deep);
  color: var(--on-brand);
  border-top: 3px solid var(--accent);
  padding: var(--space-xl) 0;
}

.closing-band h2 {
  color: var(--on-brand);
  font-size: var(--text-h2);
  margin-bottom: var(--space-md);
}

.closing-band .wrap { max-width: var(--wide); }

.related-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: var(--space-sm);
}

@media (min-width: 44rem) {
  .related-list { grid-template-columns: 1fr 1fr; }
}

.related-list a {
  display: grid;
  grid-template-columns: 4.5rem 1fr;
  gap: var(--space-sm);
  align-items: center;
  color: var(--on-brand);
  text-decoration: none;
  border: 1px solid var(--on-brand-line);
  border-radius: var(--radius);
  padding: 0.625rem;
  transition: border-color 0.2s var(--ease-out), background-color 0.2s var(--ease-out);
}

.related-list a:hover {
  border-color: var(--accent);
  background: var(--brand-shade);
  color: var(--on-brand);
}

.related-list img {
  width: 4.5rem;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 2px;
  background: var(--card);
}

.related-list a:not(:has(img)) { grid-template-columns: 1fr; }

.related-list .related-title {
  font-weight: 600;
  font-size: var(--text-body);
  line-height: 1.3;
}

.hub-cta {
  display: inline-block;
  margin-top: var(--space-sm);
  color: var(--accent);
  font-family: var(--font-display);
  font-weight: 700;
  text-decoration: none;
  border-bottom: 1px solid var(--accent);
  padding-bottom: 2px;
}

.hub-cta:hover { color: var(--on-brand); border-bottom-color: var(--on-brand); }

/* ---------- home & hub grids ---------- */

.hub-header h1 { font-size: var(--text-h1); }

.hub-header .intro { margin-top: var(--space-sm); max-width: var(--measure); }

.hub-count {
  margin: var(--space-sm) 0 0;
  color: var(--ink-soft);
  font-size: var(--text-sm);
  font-variant-numeric: tabular-nums;
}

.section-head {
  font-size: var(--text-h2);
  margin: var(--space-xl) 0 var(--space-md);
}

/* featured (latest) review */
.feature {
  display: grid;
  margin-top: var(--space-lg);
  background: var(--card);
  border: 1px solid var(--line-strong);
  border-top: 3px solid var(--accent);
  overflow: hidden;
  text-decoration: none;
  color: var(--ink);
  transition: border-color 0.2s var(--ease-out), box-shadow 0.2s var(--ease-out);
}

.feature:hover {
  border-color: var(--brand);
  box-shadow: 0 14px 32px -20px oklch(0.32 0.05 255 / 0.5);
}

@media (min-width: 44rem) {
  .feature { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
}

.feature img {
  width: 100%;
  height: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.feature-body {
  padding: clamp(1rem, 2.5vw, 1.75rem);
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
  justify-content: center;
}

.feature-flag {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--accent-text);
}

.feature-title {
  font-size: clamp(1.375rem, 1.1rem + 1.3vw, 1.75rem);
  color: var(--brand-deep);
}

.feature:hover .feature-title { color: var(--brand); }

.feature-summary {
  margin: 0;
  color: var(--ink-soft);
  font-size: var(--text-sm);
  line-height: 1.55;
}

.feature-meta {
  color: var(--ink-soft);
  font-size: var(--text-xs);
  font-variant-numeric: tabular-nums;
}

/* review cards */
.hub-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr));
  gap: var(--space-md) var(--space-sm);
  list-style: none;
  margin: var(--space-lg) 0 0;
  padding: 0;
}

.section-head + .hub-grid { margin-top: 0; }

.hub-grid .card {
  background: var(--card);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  overflow: hidden;
  transition: translate 0.25s var(--ease-out), box-shadow 0.25s var(--ease-out), border-color 0.25s var(--ease-out);
}

.hub-grid .card:hover {
  translate: 0 -3px;
  border-color: var(--brand);
  box-shadow: 0 10px 24px -14px oklch(0.32 0.05 255 / 0.45);
}

.hub-grid .card > a {
  display: flex;
  flex-direction: column;
  height: 100%;
  color: var(--brand-deep);
  text-decoration: none;
}

.hub-grid .card > a:hover { color: var(--brand); }

.hub-grid img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-bottom: 1px solid var(--line);
}

.card-body {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
  padding: 0.75rem 0.875rem 0.875rem;
}

.card-cat {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--accent-text);
}

.hub-grid h2, .hub-grid h3 {
  font-size: var(--text-body);
  font-weight: 650;
  line-height: 1.3;
  color: inherit;
}

.card-meta {
  margin-top: auto;
  color: var(--ink-soft);
  font-size: var(--text-xs);
  font-variant-numeric: tabular-nums;
}

/* category tiles */
.cat-tiles {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(12rem, 1fr));
  gap: var(--space-sm);
}

.cat-tiles a {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  background: var(--card);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  padding: 0.875rem 1rem;
  text-decoration: none;
  transition: border-color 0.2s var(--ease-out), translate 0.2s var(--ease-out);
}

.cat-tiles a:hover { border-color: var(--brand); translate: 0 -2px; }

.cat-name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--text-body);
  color: var(--brand-deep);
  line-height: 1.25;
}

.cat-tiles a:hover .cat-name { color: var(--brand); }

.cat-count {
  color: var(--ink-soft);
  font-size: var(--text-xs);
  font-variant-numeric: tabular-nums;
}

/* ---------- boilerplate pages ---------- */

.boilerplate h1 { font-size: var(--text-h1); margin-bottom: var(--space-md); }

.boilerplate h2 { font-size: var(--text-h2); margin: var(--space-lg) 0 var(--space-sm); }

.boilerplate { padding-bottom: var(--space-xl); }

/* ---------- footer (drenched) ---------- */

.site-footer {
  background: var(--brand-shade);
  color: var(--on-brand-soft);
  padding: var(--space-lg) 0;
  font-size: var(--text-sm);
}

body:has(.closing-band) .site-footer {
  border-top: 1px solid var(--on-brand-line);
}

.site-footer .wrap { max-width: var(--wide); }

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-display);
  font-weight: 800;
  font-stretch: 112%;
  text-transform: uppercase;
  letter-spacing: 0.015em;
  color: var(--on-brand);
  text-decoration: none;
  margin-bottom: var(--space-sm);
}

.footer-brand .tld { color: var(--accent); }

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
}

.footer-nav a {
  color: var(--on-brand);
  text-decoration: none;
  border-bottom: 1px solid transparent;
}

.footer-nav a:hover { color: var(--accent); border-bottom-color: var(--accent); }

.ai-note {
  margin: var(--space-md) 0;
  padding: 0.875rem 1.125rem;
  border: 1px solid var(--on-brand-line);
  border-radius: var(--radius);
  color: var(--on-brand-soft);
  max-width: 34rem;
  text-wrap: pretty;
}

.ai-note strong { color: var(--accent); font-weight: 700; }

.ai-note a { color: var(--on-brand); }

.ai-note a:hover { color: var(--accent); }

.copyright { margin: 0; color: var(--on-brand-soft); }

/* ---------- motion ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
