/* ============================================================
   Ordina la Stampa — quote request console
   Visual system: ink console + CMYK signal accents
   ============================================================ */

:root {
  --ink-900: #0b0e14;
  --ink-850: #11151f;
  --ink-800: #161b27;
  --ink-700: #1f2636;
  --ink-600: #2b3346;
  --line: #303a50;
  --line-soft: #232b3d;
  --paper: #f4f1ea;
  --paper-2: #ece7db;
  --txt: #e9ecf3;
  --txt-dim: #aab3c5;
  --txt-faint: #7b8499;

  --cyan: #1fb6d6;
  --magenta: #e0457b;
  --yellow: #f2c14e;
  --key: #8a7cff;

  --accent: var(--cyan);
  --accent-warm: var(--yellow);

  --radius-s: 8px;
  --radius: 14px;
  --radius-l: 22px;
  --gap: clamp(16px, 2.4vw, 28px);
  --maxw: 1180px;

  --shadow-1: 0 1px 0 rgba(255,255,255,.04) inset, 0 18px 44px -28px rgba(0,0,0,.8);
  --shadow-2: 0 30px 80px -40px rgba(0,0,0,.85);
  --font: "Segoe UI", Roboto, "Helvetica Neue", Arial, system-ui, sans-serif;
  --mono: "SFMono-Regular", "Cascadia Code", "Roboto Mono", Consolas, monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  background:
    radial-gradient(900px 600px at 88% -8%, rgba(31,182,214,.10), transparent 60%),
    radial-gradient(800px 500px at 4% 4%, rgba(138,124,255,.10), transparent 55%),
    var(--ink-900);
  color: var(--txt);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }

.wrap { width: min(100% - 40px, var(--maxw)); margin-inline: auto; }

.eyebrow {
  font-family: var(--mono);
  font-size: .74rem;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.eyebrow::before {
  content: "";
  width: 22px; height: 1px;
  background: var(--accent);
  display: inline-block;
}

h1, h2, h3 { line-height: 1.12; font-weight: 700; letter-spacing: -.02em; margin: 0; }
h2.section-title { font-size: clamp(1.7rem, 3.6vw, 2.7rem); }
.lead { color: var(--txt-dim); font-size: 1.05rem; max-width: 60ch; }

/* ===== Scroll progress ===== */
.scroll-progress {
  position: fixed;
  top: 0; left: 0;
  height: 3px;
  width: 0%;
  background: linear-gradient(90deg, var(--cyan), var(--magenta), var(--yellow));
  z-index: 1200;
  transition: width .08s linear;
}

/* ===== Command-style nav ===== */
.topbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  backdrop-filter: blur(12px);
  background: rgba(11,14,20,.72);
  border-bottom: 1px solid var(--line-soft);
}
.nav {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 12px 0;
}
.brand { display: flex; align-items: center; gap: 11px; font-weight: 700; letter-spacing: -.01em; }
.brand .mark {
  width: 34px; height: 34px;
  border-radius: 9px;
  background: conic-gradient(from 210deg, var(--cyan), var(--magenta), var(--yellow), var(--cyan));
  display: grid; place-items: center;
  font-family: var(--mono); font-weight: 700; color: #0b0e14;
  font-size: .92rem;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.18);
}
.brand small { display: block; font-size: .66rem; color: var(--txt-faint); font-weight: 500; letter-spacing: .14em; text-transform: uppercase; }

.cmdbar {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--mono);
  font-size: .82rem;
  color: var(--txt-dim);
  background: var(--ink-800);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 7px 12px;
  min-width: 230px;
}
.cmdbar .slash { color: var(--accent); }
.cmdbar .cmd-hint { margin-left: auto; font-size: .68rem; color: var(--txt-faint); border: 1px solid var(--line); border-radius: 5px; padding: 1px 6px; }

.nav-links { display: flex; gap: 4px; }
.nav-links a {
  font-family: var(--mono);
  font-size: .82rem;
  color: var(--txt-dim);
  padding: 7px 11px;
  border-radius: 8px;
  transition: background .18s, color .18s;
}
.nav-links a::before { content: "/"; color: var(--txt-faint); margin-right: 2px; }
.nav-links a:hover { background: var(--ink-800); color: var(--txt); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  font-weight: 600;
  border-radius: 10px;
  padding: 11px 18px;
  border: 1px solid transparent;
  cursor: pointer;
  font-size: .94rem;
  transition: transform .15s, box-shadow .2s, background .2s, border-color .2s;
  font-family: var(--font);
}
.btn-primary { background: linear-gradient(180deg, #2bc4e6, #1597b3); color: #04161c; box-shadow: 0 10px 28px -14px rgba(31,182,214,.9); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 16px 34px -14px rgba(31,182,214,.95); }
.btn-ghost { background: var(--ink-800); border-color: var(--line); color: var(--txt); }
.btn-ghost:hover { border-color: var(--accent); color: #fff; }
.btn-block { width: 100%; }

.nav .btn { padding: 9px 15px; }
.nav-toggle { display: none; }

/* ===== HERO: quote request console ===== */
.hero { padding: clamp(34px, 6vw, 70px) 0 40px; }
.console {
  display: grid;
  grid: none / 1.05fr .95fr;
  gap: var(--gap);
  align-items: stretch;
}
.console-head { max-width: 640px; }
.console-head h1 { font-size: clamp(2.1rem, 5.2vw, 3.5rem); margin-bottom: 16px; }
.console-head h1 .hl { color: var(--accent); }
.console-head .lead { margin-bottom: 24px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 26px; }

.hero-meta { display: flex; flex-wrap: wrap; gap: 10px; }
.tag {
  font-family: var(--mono);
  font-size: .74rem;
  color: var(--txt-dim);
  border: 1px solid var(--line);
  background: var(--ink-850);
  padding: 6px 11px;
  border-radius: 999px;
}
.tag b { color: var(--accent-warm); font-weight: 600; }

/* console panel (interactive builder) */
.panel {
  background: linear-gradient(180deg, var(--ink-800), var(--ink-850));
  border: 1px solid var(--line);
  border-radius: var(--radius-l);
  box-shadow: var(--shadow-2);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.panel-bar {
  display: flex; align-items: center; gap: 8px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line-soft);
  background: var(--ink-800);
  font-family: var(--mono); font-size: .78rem; color: var(--txt-faint);
}
.dot { width: 10px; height: 10px; border-radius: 50%; }
.dot.c { background: var(--cyan); } .dot.m { background: var(--magenta); } .dot.y { background: var(--yellow); }
.panel-bar .path { margin-left: 8px; }
.panel-body { padding: clamp(16px, 2vw, 22px); display: grid; gap: 18px; }

.field-label { font-family: var(--mono); font-size: .72rem; text-transform: uppercase; letter-spacing: .14em; color: var(--txt-faint); margin-bottom: 9px; display: block; }

/* segmented control */
.segmented {
  display: inline-flex;
  background: var(--ink-700);
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 4px;
  gap: 4px;
  flex-wrap: wrap;
}
.segmented button {
  font-family: var(--font);
  border: none;
  background: transparent;
  color: var(--txt-dim);
  padding: 8px 14px;
  border-radius: 8px;
  cursor: pointer;
  font-size: .86rem;
  font-weight: 600;
  transition: background .18s, color .18s;
}
.segmented button[aria-pressed="true"] {
  background: linear-gradient(180deg, var(--ink-600), var(--ink-700));
  color: #fff;
  box-shadow: 0 1px 0 rgba(255,255,255,.06) inset, 0 6px 16px -10px rgba(0,0,0,.8);
}
.segmented button:hover { color: var(--txt); }

/* chips */
.chips { display: flex; flex-wrap: wrap; gap: 9px; }
.chip {
  font-family: var(--font);
  font-size: .86rem;
  font-weight: 600;
  color: var(--txt-dim);
  background: var(--ink-700);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 14px;
  cursor: pointer;
  transition: all .18s;
  display: inline-flex; align-items: center; gap: 7px;
}
.chip::before {
  content: "+";
  font-family: var(--mono);
  color: var(--txt-faint);
  transition: transform .18s, color .18s;
}
.chip:hover { border-color: var(--accent); color: var(--txt); }
.chip[aria-pressed="true"] {
  background: linear-gradient(180deg, rgba(31,182,214,.22), rgba(31,182,214,.10));
  border-color: var(--accent);
  color: #eafaff;
}
.chip[aria-pressed="true"]::before { content: "✓"; color: var(--accent); transform: rotate(0deg); }

.hint-row { font-size: .8rem; color: var(--txt-faint); }

/* ===== generic section ===== */
section { padding: clamp(48px, 7vw, 92px) 0; position: relative; }
.section-head { max-width: 720px; margin-bottom: 38px; }
.section-head .lead { margin-top: 12px; }

.sec-index {
  font-family: var(--mono);
  font-size: .72rem;
  color: var(--txt-faint);
  letter-spacing: .1em;
}

/* product chips section */
.product-grid {
  display: grid;
  grid: none / 1.4fr 1fr;
  gap: var(--gap);
  align-items: start;
}
.product-card {
  background: var(--ink-850);
  border: 1px solid var(--line);
  border-radius: var(--radius-l);
  padding: clamp(18px, 2.4vw, 28px);
}
.product-card .cat-tabs { margin-bottom: 20px; }
.catalog { display: grid; gap: 18px; }
.catalog-group h3 { font-size: 1.02rem; margin-bottom: 12px; color: var(--txt); }
.product-aside {
  border-radius: var(--radius-l);
  overflow: hidden;
  border: 1px solid var(--line);
  position: relative;
  min-height: 320px;
}
.product-aside img { width: 100%; height: 100%; object-fit: cover; }

/* ===== signature: spec summary ===== */
.summary-section { background: linear-gradient(180deg, var(--ink-850), var(--ink-900)); border-block: 1px solid var(--line-soft); }
.summary-grid {
  display: grid;
  grid: none / 1fr 1.15fr;
  gap: var(--gap);
  align-items: stretch;
}
.summary-visual { border-radius: var(--radius-l); overflow: hidden; border: 1px solid var(--line); min-height: 360px; position: relative; }
.summary-visual img { width: 100%; height: 100%; object-fit: cover; }
.summary-visual .overlay {
  position: absolute; inset: auto 16px 16px 16px;
  background: rgba(11,14,20,.78);
  backdrop-filter: blur(6px);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px 16px;
  font-family: var(--mono); font-size: .78rem; color: var(--txt-dim);
}

.receipt {
  background: var(--paper);
  color: #1a1d24;
  border-radius: var(--radius-l);
  padding: clamp(20px, 2.6vw, 30px);
  box-shadow: var(--shadow-2);
  position: relative;
}
.receipt::after {
  content: "";
  position: absolute; left: 0; right: 0; bottom: -1px; height: 14px;
  background: radial-gradient(circle at 8px -2px, transparent 7px, var(--ink-900) 8px) repeat-x;
  background-size: 16px 14px;
}
.receipt-head { display: flex; align-items: baseline; justify-content: space-between; border-bottom: 2px dashed #c9c1b0; padding-bottom: 14px; margin-bottom: 14px; }
.receipt-head h3 { font-family: var(--mono); font-size: 1rem; letter-spacing: .02em; }
.receipt-head span { font-family: var(--mono); font-size: .76rem; color: #6b6357; }
.receipt-rows { display: grid; gap: 11px; font-family: var(--mono); font-size: .9rem; }
.receipt-row { display: flex; justify-content: space-between; gap: 14px; align-items: baseline; }
.receipt-row .k { color: #5c554a; }
.receipt-row .v { font-weight: 600; text-align: right; color: #1a1d24; }
.receipt-row .v.empty { color: #a59c8b; font-weight: 500; font-style: italic; }
.receipt-list { margin: 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; max-width: 60%; }
.receipt-list li { background: #e4ddcd; border-radius: 6px; padding: 2px 9px; font-size: .78rem; font-weight: 600; }
.receipt-foot { border-top: 2px dashed #c9c1b0; margin-top: 16px; padding-top: 14px; font-family: var(--mono); font-size: .78rem; color: #6b6357; }
.receipt-cta { margin-top: 18px; }
.receipt .btn-primary { color: #04161c; }

/* ===== bento ===== */
.bento {
  display: grid;
  grid: auto-flow minmax(150px, auto) / repeat(4, 1fr);
  gap: 16px;
}
.bento-cell {
  background: var(--ink-850);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  position: relative;
  overflow: hidden;
  transition: border-color .2s, transform .2s;
}
.bento-cell:hover { border-color: var(--accent); transform: translateY(-3px); }
.bento-cell h3 { font-size: 1.08rem; margin-bottom: 8px; }
.bento-cell p { color: var(--txt-dim); font-size: .92rem; margin: 0; }
.bento-cell .ix { font-family: var(--mono); font-size: .72rem; color: var(--accent); margin-bottom: 12px; display: block; }
.bento-wide { grid-column: span 2; }
.bento-tall { grid-row: span 2; }
.bento-img { padding: 0; }
.bento-img img { width: 100%; height: 100%; object-fit: cover; }
.bento-feature { grid-column: span 2; background: linear-gradient(150deg, rgba(31,182,214,.14), rgba(138,124,255,.10)); }

/* ===== preparation guide (tabs) ===== */
.prep-grid { display: grid; grid: none / 1fr 1fr; gap: var(--gap); align-items: center; }
.prep-visual { border-radius: var(--radius-l); overflow: hidden; border: 1px solid var(--line); min-height: 340px; position: relative; }
.prep-visual img { width: 100%; height: 100%; object-fit: cover; }
.prep-panel { display: grid; gap: 18px; }
.prep-tabs { margin-bottom: 6px; }
.prep-content { display: grid; gap: 16px; }
.step {
  display: grid; grid: none / auto 1fr; gap: 16px;
  align-items: start;
  padding: 16px 18px;
  background: var(--ink-850);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.step .num {
  width: 34px; height: 34px; border-radius: 9px;
  display: grid; place-items: center;
  font-family: var(--mono); font-weight: 700;
  background: var(--ink-700); border: 1px solid var(--line); color: var(--accent);
}
.step h4 { margin: 0 0 4px; font-size: 1rem; }
.step p { margin: 0; color: var(--txt-dim); font-size: .9rem; }
.prep-pane[hidden] { display: none; }

/* ===== FAQ accordion ===== */
.faq-grid { display: grid; grid: none / .8fr 1.2fr; gap: var(--gap); align-items: start; }
.faq-list { display: grid; gap: 12px; }
.faq-item { border: 1px solid var(--line); border-radius: var(--radius); background: var(--ink-850); overflow: hidden; }
.faq-q {
  width: 100%; text-align: left;
  background: transparent; border: none; cursor: pointer;
  color: var(--txt);
  font-size: 1.02rem; font-weight: 600;
  padding: 18px 20px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  font-family: var(--font);
}
.faq-q .icon { font-family: var(--mono); color: var(--accent); transition: transform .25s; flex: none; }
.faq-q[aria-expanded="true"] .icon { transform: rotate(45deg); }
.faq-a { max-height: 0; overflow: hidden; transition: max-height .3s ease; }
.faq-a-inner { padding: 0 20px 18px; color: var(--txt-dim); font-size: .94rem; }

/* ===== contact ===== */
.contact-section { background: linear-gradient(180deg, var(--ink-900), var(--ink-850)); border-top: 1px solid var(--line-soft); }
.contact-grid { display: grid; grid: none / 1fr 1fr; gap: var(--gap); align-items: stretch; }
.contact-info { display: grid; gap: 18px; align-content: start; }
.info-card { background: var(--ink-850); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; }
.info-card .field-label { margin-bottom: 6px; }
.info-card p, .info-card a { margin: 0; color: var(--txt); font-size: .98rem; }
.info-card a:hover { color: var(--accent); }
.contact-visual { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); min-height: 180px; }
.contact-visual img { width: 100%; height: 100%; object-fit: cover; }

form.quote-form { background: var(--ink-850); border: 1px solid var(--line); border-radius: var(--radius-l); padding: clamp(20px, 2.6vw, 30px); display: grid; gap: 16px; }
.form-row { display: grid; grid: none / 1fr 1fr; gap: 14px; }
.input-group { display: grid; gap: 7px; }
.input-group label { font-family: var(--mono); font-size: .72rem; text-transform: uppercase; letter-spacing: .12em; color: var(--txt-faint); }
.input-group input, .input-group textarea, .input-group select {
  background: var(--ink-800);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px 14px;
  color: var(--txt);
  font-family: var(--font);
  font-size: .95rem;
  transition: border-color .18s, box-shadow .18s;
}
.input-group input:focus, .input-group textarea:focus, .input-group select:focus {
  outline: none; border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(31,182,214,.18);
}
.input-group textarea { resize: vertical; min-height: 110px; }
.form-note { font-size: .78rem; color: var(--txt-faint); }
.form-status { font-size: .9rem; font-weight: 600; min-height: 1.2em; }
.form-status.ok { color: var(--cyan); }
.consent { display: flex; gap: 10px; align-items: start; font-size: .82rem; color: var(--txt-dim); }
.consent input { margin-top: 3px; }

/* ===== sticky CTA ===== */
.sticky-cta {
  position: fixed;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%) translateY(140%);
  z-index: 1100;
  display: flex; align-items: center; gap: 16px;
  background: rgba(17,21,31,.92);
  backdrop-filter: blur(12px);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 10px 12px 10px 18px;
  box-shadow: var(--shadow-2);
  transition: transform .35s cubic-bezier(.2,.8,.2,1);
  max-width: calc(100% - 28px);
}
.sticky-cta.show { transform: translateX(-50%) translateY(0); }
.sticky-cta .sc-text { font-size: .88rem; color: var(--txt-dim); }
.sticky-cta .sc-text b { color: var(--txt); display: block; font-size: .96rem; }

/* ===== footer ===== */
footer { background: var(--ink-900); border-top: 1px solid var(--line-soft); padding: 54px 0 28px; }
.foot-grid { display: grid; grid: none / 1.4fr 1fr 1fr; gap: var(--gap); margin-bottom: 34px; }
.foot-brand p { color: var(--txt-dim); font-size: .92rem; max-width: 40ch; }
.foot-col h4 { font-family: var(--mono); font-size: .74rem; text-transform: uppercase; letter-spacing: .14em; color: var(--txt-faint); margin-bottom: 14px; }
.foot-col a, .foot-col p { display: block; color: var(--txt-dim); font-size: .9rem; margin-bottom: 9px; }
.foot-col a:hover { color: var(--accent); }
.legal-bar { border-top: 1px solid var(--line-soft); padding-top: 22px; display: flex; flex-wrap: wrap; gap: 8px 22px; align-items: center; font-size: .8rem; color: var(--txt-faint); }
.legal-bar .ids { font-family: var(--mono); }
.legal-bar a { color: var(--txt-faint); }
.legal-bar a:hover { color: var(--accent); }

/* ===== legal pages ===== */
.legal-page { padding-top: 40px; }
.legal-hero { padding: 40px 0 10px; }
.legal-content { max-width: 80ch; }
.legal-content h2 { font-size: 1.35rem; margin: 34px 0 12px; }
.legal-content h3 { font-size: 1.05rem; margin: 22px 0 8px; }
.legal-content p, .legal-content li { color: var(--txt-dim); }
.legal-content ul { padding-left: 20px; }
.legal-content li { margin-bottom: 7px; }
.legal-content a { color: var(--accent); }
.legal-toc { background: var(--ink-850); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 22px; margin-bottom: 30px; }
.legal-toc h4 { font-family: var(--mono); font-size: .74rem; text-transform: uppercase; letter-spacing: .12em; color: var(--txt-faint); margin: 0 0 12px; }
.legal-toc a { color: var(--txt-dim); }
.legal-toc a:hover { color: var(--accent); }

/* ===== reveal ===== */
.reveal { opacity: 1; }
@media (prefers-reduced-motion: no-preference) {
  .reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
  .reveal.in { opacity: 1; transform: none; }
}

/* ===== responsive ===== */
@media (max-width: 960px) {
  .console, .product-grid, .summary-grid, .prep-grid, .faq-grid, .contact-grid { grid: none / 1fr; }
  .bento { grid: auto-flow minmax(150px, auto) / repeat(2, 1fr); }
  .bento-wide, .bento-feature { grid-column: span 2; }
  .foot-grid { grid: none / 1fr 1fr; }
}
@media (max-width: 720px) {
  .nav-links, .cmdbar { display: none; }
  .nav-toggle { display: inline-flex; margin-left: auto; }
  .nav-links.open { display: flex; position: absolute; top: 60px; left: 12px; right: 12px; flex-direction: column; background: var(--ink-800); border: 1px solid var(--line); border-radius: 12px; padding: 10px; }
  .form-row { grid: none / 1fr; }
  .foot-grid { grid: none / 1fr; }
  .receipt-list { max-width: 100%; }
  .sticky-cta .sc-text { display: none; }
}
