/* ==========================================================================
   KALIBRO — design system
   Concetto: strumento di calibrazione. Quadrante, tacche, ago, zone colorate
   (generico → in calibrazione → calibrato) come metafora ricorrente.
   ========================================================================== */

@import url('/assets/font/font.css');

:root{
  /* colore */
  --ink:        #1B1F1B;
  --ink-soft:   #4A5049;
  --paper:      #E9E8DD;
  --paper-2:    #E0DFD1;
  --panel:      #1B1F1B;
  --panel-2:    #262B24;
  --brass:      #B5822E;
  --brass-lt:   #D8A94C;
  --green:      #4B7A57;
  --green-lt:   #6E9B79;
  --red:        #A8503D;
  --line:       #C6C2AE;
  --line-dark:  #3A3F37;
  --paper-rgb:  233,232,221;

  /* tipografia */
  --f-display: 'Space Grotesk', 'IBM Plex Sans', sans-serif;
  --f-body:    'IBM Plex Sans', sans-serif;
  --f-mono:    'IBM Plex Mono', monospace;

  --radius: 3px;
}

*,*::before,*::after{ box-sizing:border-box; }
html{ scroll-behavior:smooth; }
body{
  margin:0;
  background:var(--paper);
  color:var(--ink);
  font-family:var(--f-body);
  font-size:16px;
  line-height:1.55;
  -webkit-font-smoothing:antialiased;
}
img,svg{ display:block; max-width:100%; }
a{ color:inherit; }
h1,h2,h3,h4{ font-family:var(--f-display); font-weight:700; line-height:1.08; margin:0 0 .5em; letter-spacing:-0.01em; }
p{ margin:0 0 1em; color:var(--ink-soft); }
ul{ margin:0; padding:0; }
button{ font-family:inherit; }

.wrap{ max-width:1180px; margin:0 auto; padding:0 28px; }
.wrap--narrow{ max-width:820px; }

/* ---------- eyebrow / mono label (readout dello strumento) ---------- */
.eyebrow{
  font-family:var(--f-mono);
  font-size:12px;
  letter-spacing:.14em;
  text-transform:uppercase;
  color:var(--brass);
  display:flex;
  align-items:center;
  gap:.6em;
  margin-bottom:14px;
}
.eyebrow::before{
  content:"";
  width:18px; height:1px;
  background:var(--brass);
  display:inline-block;
}
.on-dark .eyebrow{ color:var(--brass-lt); }

/* ---------- bottoni ---------- */
.btn{
  display:inline-flex; align-items:center; justify-content:center; gap:.5em;
  font-family:var(--f-body); font-weight:600; font-size:15px;
  padding:14px 26px;
  border-radius:var(--radius);
  border:1px solid transparent;
  cursor:pointer;
  text-decoration:none;
  transition:transform .15s ease, background .15s ease, border-color .15s ease;
}
.btn:focus-visible{ outline:2px solid var(--brass); outline-offset:3px; }
.btn-primary{ background:var(--brass); color:#1B1F1B; }
.btn-primary:hover{ background:var(--brass-lt); transform:translateY(-1px); }
.btn-ghost{ background:transparent; color:var(--ink); border-color:var(--ink); }
.btn-ghost:hover{ background:rgba(27,31,27,.06); }
.on-dark .btn-ghost{ color:var(--paper); border-color:var(--line-dark); }
.on-dark .btn-ghost:hover{ background:rgba(233,232,221,.08); }
.btn-block{ width:100%; }

/* ---------- nav ---------- */
.nav{
  position:sticky; top:0; z-index:40;
  background:rgba(233,232,221,.92);
  backdrop-filter:blur(6px);
  border-bottom:1px solid var(--line);
}
.nav .wrap{ display:flex; align-items:center; justify-content:space-between; height:74px; }
.brand{
  font-family:var(--f-display); font-weight:700; font-size:20px;
  letter-spacing:.02em;
  display:flex; align-items:center; gap:10px;
  text-decoration:none; color:var(--ink);
}
.brand .dot{ width:8px; height:8px; border-radius:50%; background:var(--brass); }
.nav-links{ display:flex; align-items:center; gap:32px; list-style:none; }
.nav-links a{ text-decoration:none; font-size:14.5px; color:var(--ink-soft); }
.nav-links a:hover{ color:var(--ink); }
.nav-cta{ display:flex; align-items:center; gap:14px; }
.nav-links, .nav-only-desktop{ }
@media(max-width:760px){
  .nav-links{ display:none; }
}

/* ---------- hero ---------- */
.hero{
  background:var(--panel);
  color:var(--paper);
  padding:76px 0 64px;
  position:relative;
  overflow:hidden;
}
.hero .wrap{
  display:grid;
  grid-template-columns:1.05fr .95fr;
  gap:56px;
  align-items:center;
}
.hero h1{
  font-size:clamp(34px,4.6vw,58px);
  color:var(--paper);
}
.hero h1 em{ font-style:normal; color:var(--brass-lt); }
.hero .lede{ font-size:18px; color:#C7C7BB; max-width:46ch; }
.hero-cta{ display:flex; gap:14px; margin-top:30px; flex-wrap:wrap; }
.hero-note{
  margin-top:22px; font-family:var(--f-mono); font-size:12.5px;
  color:#8B9186; letter-spacing:.03em;
}

/* ---------- quadrante SVG ---------- */
.gauge-wrap{ display:flex; flex-direction:column; align-items:center; }
.gauge{ width:100%; max-width:360px; }
.gauge .tick{ stroke:#8B9186; stroke-width:1.4; }
.gauge .needle{
  stroke:var(--paper); stroke-width:3; stroke-linecap:round;
  transform-origin:100px 100px;
  transform:rotate(-90deg);
  transition:transform 1.1s cubic-bezier(.2,.9,.2,1);
}
.gauge .pivot{ fill:var(--paper); }
.gauge .zone-a{ stroke:var(--red); }
.gauge .zone-b{ stroke:var(--brass); }
.gauge .zone-c{ stroke:var(--green); }
.gauge-legend{
  display:flex; justify-content:space-between; width:100%; max-width:360px;
  font-family:var(--f-mono); font-size:11px; letter-spacing:.06em;
  text-transform:uppercase; color:#8B9186; margin-top:2px;
}
.gauge-legend span:last-child{ color:var(--green-lt); }
@media (prefers-reduced-motion: reduce){
  .gauge .needle{ transition:none; }
}

/* ---------- sezioni chiare ---------- */
.section{ padding:84px 0; }
.section-head{ max-width:640px; margin-bottom:48px; }
.section-head h2{ font-size:clamp(26px,3.2vw,38px); }
.section--tight{ padding:64px 0; }
.hr{ border:none; border-top:1px solid var(--line); }

/* ---------- griglia differenziatori ---------- */
.grid-3{ display:grid; grid-template-columns:repeat(3,1fr); gap:1px; background:var(--line); border:1px solid var(--line); }
.grid-3 .cell{ background:var(--paper); padding:32px 28px; }
.cell .num{ font-family:var(--f-mono); font-size:13px; color:var(--brass); margin-bottom:14px; display:block; }
.cell h3{ font-size:20px; margin-bottom:10px; }
.cell p{ font-size:14.5px; margin:0; }
@media(max-width:820px){ .grid-3{ grid-template-columns:1fr; } }

/* ---------- come funziona ---------- */
.steps{ display:grid; grid-template-columns:repeat(4,1fr); gap:28px; }
.step .num{
  font-family:var(--f-mono); font-size:13px; color:var(--brass);
  border:1px solid var(--line); border-radius:50%;
  width:34px; height:34px; display:flex; align-items:center; justify-content:center;
  margin-bottom:16px;
}
.step h4{ font-family:var(--f-body); font-weight:600; font-size:16px; margin:0 0 6px; }
.step p{ font-size:14px; margin:0; }
@media(max-width:900px){ .steps{ grid-template-columns:1fr 1fr; } }
@media(max-width:560px){ .steps{ grid-template-columns:1fr; } }

/* ---------- confronto tabella semplice ---------- */
.compare{ width:100%; border-collapse:collapse; font-size:14.5px; }
.compare th,.compare td{ padding:16px 18px; text-align:left; border-bottom:1px solid var(--line); vertical-align:top; }
.compare thead th{ font-family:var(--f-mono); font-size:11.5px; letter-spacing:.08em; text-transform:uppercase; color:var(--ink-soft); border-bottom:2px solid var(--ink); }
.compare td.no{ color:var(--ink-soft); }
.compare td.yes{ color:var(--green); font-weight:600; }

/* ---------- pricing ---------- */
.plans{ display:grid; grid-template-columns:1fr 1fr; gap:24px; }
.plan{
  border:1px solid var(--line);
  background:var(--paper-2);
  padding:34px 30px;
  border-radius:var(--radius);
  position:relative;
}
.plan--highlight{ background:var(--panel); color:var(--paper); border-color:var(--panel); }
.plan-badge{
  position:absolute; top:-13px; left:30px;
  background:var(--brass); color:#1B1F1B;
  font-family:var(--f-mono); font-size:11px; letter-spacing:.06em; text-transform:uppercase;
  padding:5px 10px; border-radius:2px;
}
.plan h3{ font-size:18px; margin-bottom:4px; }
.plan .price{ font-family:var(--f-display); font-size:44px; font-weight:700; margin:14px 0 2px; }
.plan .price small{ font-family:var(--f-body); font-size:14px; font-weight:500; color:var(--ink-soft); }
.plan--highlight .price small{ color:#9CA398; }
.plan .price-note{ font-family:var(--f-mono); font-size:12.5px; color:var(--green); margin-bottom:22px; }
.plan ul{ list-style:none; margin:22px 0 26px; display:grid; gap:10px; font-size:14.5px; }
.plan ul li{ display:flex; gap:10px; align-items:flex-start; }
.plan ul li::before{ content:"—"; color:var(--brass); flex:none; }
@media(max-width:760px){ .plans{ grid-template-columns:1fr; } }

.guarantee{
  display:flex; gap:16px; align-items:flex-start;
  border:1px dashed var(--line);
  padding:20px 22px; margin-top:36px; max-width:640px;
  font-size:14.5px;
}
.guarantee .g-icon{ font-family:var(--f-mono); color:var(--green); font-size:20px; flex:none; }

.table-wrap{ overflow-x:auto; border:1px solid var(--line); }
.receive-table{ width:100%; border-collapse:collapse; min-width:520px; }
.receive-table th,.receive-table td{ padding:14px 20px; border-bottom:1px solid var(--line); text-align:left; font-size:14.5px; }
.receive-table thead th{ background:var(--paper-2); font-family:var(--f-mono); font-size:11.5px; text-transform:uppercase; letter-spacing:.06em; }
.receive-table td.center, .receive-table th.center{ text-align:center; }
.check{ color:var(--green); font-weight:700; }

/* ---------- FAQ ---------- */
.faq-list{ border-top:1px solid var(--line); }
.faq-item{ border-bottom:1px solid var(--line); }
.faq-item summary{
  cursor:pointer; list-style:none; padding:20px 4px;
  display:flex; justify-content:space-between; align-items:center; gap:20px;
  font-family:var(--f-body); font-weight:600; font-size:15.5px;
}
.faq-item summary::-webkit-details-marker{ display:none; }
.faq-item summary .plus{ font-family:var(--f-mono); color:var(--brass); font-size:18px; transition:transform .2s ease; flex:none; }
.faq-item[open] summary .plus{ transform:rotate(45deg); }
.faq-item .faq-a{ padding:0 4px 22px; max-width:70ch; font-size:14.5px; color:var(--ink-soft); }

/* ---------- footer ---------- */
.footer{ background:var(--panel); color:#9CA398; padding:48px 0 36px; }
.footer .wrap{ display:flex; justify-content:space-between; align-items:center; flex-wrap:wrap; gap:16px; }
.footer .brand{ color:var(--paper); }
.footer small{ font-family:var(--f-mono); font-size:12px; letter-spacing:.03em; }
.footer-links{ display:flex; gap:22px; list-style:none; font-size:13.5px; }
.footer-links a{ text-decoration:none; color:#9CA398; }
.footer-links a:hover{ color:var(--paper); }

/* ---------- banda CTA finale ---------- */
.cta-band{ background:var(--brass); color:#1B1F1B; padding:56px 0; text-align:center; }
.cta-band h2{ font-size:clamp(24px,3vw,34px); }
.cta-band .btn-ghost{ border-color:#1B1F1B; }

/* ---------- QUIZ ---------- */
.quiz-shell{ background:var(--panel); color:var(--paper); min-height:calc(100vh - 74px); padding:56px 0 80px; }
.quiz-head{ display:flex; flex-direction:column; align-items:center; text-align:center; margin-bottom:40px; }
.quiz-gauge{ width:220px; margin-bottom:8px; }
.quiz-progress-label{ font-family:var(--f-mono); font-size:12px; letter-spacing:.08em; color:#9CA398; text-transform:uppercase; }

.quiz-card{
  max-width:640px; margin:0 auto;
  background:var(--panel-2);
  border:1px solid var(--line-dark);
  border-radius:var(--radius);
  padding:40px 40px 34px;
}
.quiz-step{ display:none; }
.quiz-step.active{ display:block; animation:fadein .35s ease; }
@keyframes fadein{ from{opacity:0; transform:translateY(6px);} to{opacity:1; transform:translateY(0);} }

.quiz-card h2{ font-size:24px; color:var(--paper); margin-bottom:6px; }
.quiz-card .q-sub{ color:#9CA398; font-size:14.5px; margin-bottom:28px; }

.opt-list{ list-style:none; display:grid; gap:12px; }
.opt{
  display:block; cursor:pointer;
  border:1px solid var(--line-dark);
  border-radius:var(--radius);
  padding:18px 20px;
  transition:border-color .15s ease, background .15s ease;
}
.opt:hover{ border-color:var(--brass); }
.opt input{ position:absolute; opacity:0; pointer-events:none; }
.opt .opt-title{ font-weight:600; font-size:15.5px; color:var(--paper); display:block; }
.opt .opt-desc{ font-size:13.5px; color:#9CA398; margin-top:4px; }
.opt.selected{ border-color:var(--brass); background:rgba(181,130,46,.12); }

.quiz-nav{ display:flex; justify-content:space-between; align-items:center; margin-top:32px; }
.quiz-nav .btn-ghost{ color:var(--paper); border-color:var(--line-dark); }
.step-count{ font-family:var(--f-mono); font-size:12.5px; color:#9CA398; }

.result-code{
  font-family:var(--f-mono); font-size:13px; letter-spacing:.08em;
  color:var(--green-lt); border:1px solid var(--line-dark);
  display:inline-block; padding:6px 12px; border-radius:2px; margin-bottom:18px;
}
.result-card{ display:grid; gap:18px; }
.result-summary{ display:flex; gap:16px; flex-wrap:wrap; margin:6px 0 4px; }
.result-summary .chip{
  font-family:var(--f-mono); font-size:12px; text-transform:uppercase; letter-spacing:.05em;
  border:1px solid var(--line-dark); padding:6px 12px; border-radius:20px; color:#C7C7BB;
}

@media(max-width:640px){
  .quiz-card{ padding:28px 22px; }
  .hero .wrap{ grid-template-columns:1fr; }
  .hero .gauge-wrap{ order:-1; margin-bottom:8px; }
  .plans{ grid-template-columns:1fr; }
}

/* ---------- SCHEDA DI ALLENAMENTO ---------- */
.program-shell{ background:var(--panel); color:var(--paper); padding:56px 0 80px; }
.program-head{ max-width:760px; margin-bottom:40px; }
.program-head .eyebrow{ justify-content:flex-start; }
.program-head h1{ font-size:clamp(24px,3.4vw,36px); color:var(--paper); }
.program-meta{ display:flex; gap:12px; flex-wrap:wrap; margin-top:16px; }
.program-meta .chip{ font-family:var(--f-mono); font-size:12px; text-transform:uppercase; letter-spacing:.05em; border:1px solid var(--line-dark); padding:6px 12px; border-radius:20px; color:#C7C7BB; }

.workout-day{ margin-bottom:40px; border:1px solid var(--line-dark); border-radius:var(--radius); overflow:hidden; }
.workout-day-head{ padding:18px 24px; border-bottom:1px solid var(--line-dark); background:var(--panel-2); }
.workout-day-head h3{ color:var(--paper); font-size:18px; margin:0 0 4px; }
.workout-day-head p{ color:#9CA398; font-size:13.5px; margin:0; }
.workout-table{ width:100%; border-collapse:collapse; }
.workout-table th, .workout-table td{ padding:13px 20px; border-bottom:1px solid var(--line-dark); text-align:left; font-size:14px; color:#C7C7BB; }
.workout-table tbody tr:last-child td{ border-bottom:none; }
.workout-table thead th{ font-family:var(--f-mono); font-size:11px; text-transform:uppercase; letter-spacing:.05em; color:#9CA398; }
.workout-table td:first-child{ color:var(--paper); font-weight:500; }
.workout-table td.num, .workout-table th.num{ font-family:var(--f-mono); white-space:nowrap; }

.progression-box{
  border:1px dashed var(--line-dark); border-radius:var(--radius);
  padding:22px 24px; margin:8px 0 40px; max-width:760px;
}
.progression-box h3{ color:var(--paper); font-size:15px; margin:0 0 8px; }
.progression-box p{ color:#9CA398; font-size:14px; margin:0; }

.nutrition-box{
  background:var(--panel-2); border-radius:var(--radius);
  padding:24px 26px; max-width:760px; margin-bottom:40px;
}
.nutrition-box h3{ color:var(--paper); font-size:15px; margin:0 0 10px; }
.nutrition-box ul{ list-style:none; display:grid; gap:8px; font-size:14px; color:#C7C7BB; margin:0; }
.nutrition-box li::before{ content:"—"; color:var(--brass); margin-right:8px; }

/* ---------- CALCOLATORE NUTRIZIONALE ---------- */
.calc-form{ display:grid; grid-template-columns:repeat(2,1fr); gap:18px 20px; max-width:640px; margin-bottom:8px; }
.calc-field{ display:flex; flex-direction:column; gap:6px; }
.calc-field.full{ grid-column:1 / -1; }
.calc-field label{ font-family:var(--f-mono); font-size:11px; text-transform:uppercase; letter-spacing:.05em; color:#9CA398; }
.calc-field input, .calc-field select{
  background:var(--panel-2); border:1px solid var(--line-dark); color:var(--paper);
  padding:11px 14px; border-radius:var(--radius); font-family:var(--f-body); font-size:14.5px;
}
.calc-field input:focus, .calc-field select:focus{ outline:none; border-color:var(--brass); }
.calc-results{ display:none; max-width:760px; margin-top:32px; }
.calc-results.show{ display:block; }
.result-stat-row{ display:grid; grid-template-columns:repeat(3,1fr); gap:16px; margin-bottom:28px; }
.result-stat{ background:var(--panel-2); border-radius:var(--radius); padding:18px 20px; }
.result-stat .stat-label{ font-family:var(--f-mono); font-size:11px; text-transform:uppercase; color:#9CA398; margin-bottom:6px; }
.result-stat .stat-value{ font-family:var(--f-display); font-size:24px; font-weight:700; color:var(--paper); }
.result-stat .stat-sub{ font-size:12px; color:#9CA398; margin-top:4px; }
.macro-table{ width:100%; border-collapse:collapse; margin-bottom:8px; }
.macro-table th, .macro-table td{ padding:12px 16px; border-bottom:1px solid var(--line-dark); text-align:left; font-size:14px; color:#C7C7BB; }
.macro-table thead th{ font-family:var(--f-mono); font-size:11px; text-transform:uppercase; color:#9CA398; }
.macro-table td:first-child{ color:var(--paper); font-weight:500; }
.calc-note{ border:1px dashed var(--line-dark); border-radius:var(--radius); padding:16px 18px; font-size:13.5px; color:#9CA398; margin-top:16px; max-width:760px; }
@media(max-width:640px){ .calc-form{ grid-template-columns:1fr; } .result-stat-row{ grid-template-columns:1fr; } }

/* ---------- GLOSSARIO / TECNICHE ---------- */
.glossary-item{ border-bottom:1px solid var(--line-dark); padding:26px 0; max-width:760px; }
.glossary-item:first-child{ padding-top:0; }
.glossary-item h3{ color:var(--paper); font-size:17px; margin:0 0 8px; }
.glossary-item p{ color:#C7C7BB; font-size:14.5px; margin:0; }
.glossary-scale{ display:flex; flex-direction:column; gap:7px; margin-top:14px; }
.glossary-scale div{ display:flex; gap:14px; font-size:13.5px; color:#9CA398; }
.glossary-scale strong{ color:var(--brass-lt); font-family:var(--f-mono); min-width:64px; }

/* ---------- CHECK-IN (misure + foto) ---------- */
.checkin-grid{ display:grid; grid-template-columns:repeat(3,1fr); gap:16px 20px; max-width:640px; margin-bottom:28px; }
.photo-upload-row{ display:grid; grid-template-columns:repeat(3,1fr); gap:16px; max-width:640px; margin-bottom:28px; }
.photo-slot{
  border:1px dashed var(--line-dark); border-radius:var(--radius); aspect-ratio:3/4;
  display:flex; flex-direction:column; align-items:center; justify-content:center;
  position:relative; overflow:hidden; cursor:pointer; background:var(--panel-2);
}
.photo-slot img{ position:absolute; inset:0; width:100%; height:100%; object-fit:cover; }
.photo-slot .ph-label{ font-family:var(--f-mono); font-size:11px; text-transform:uppercase; color:#9CA398; letter-spacing:.05em; text-align:center; padding:0 8px; }
.photo-slot input[type=file]{ position:absolute; inset:0; opacity:0; cursor:pointer; width:100%; height:100%; }
.checkin-history{ margin-top:44px; max-width:760px; }
.checkin-entry{ display:flex; gap:20px; align-items:center; border:1px solid var(--line-dark); border-radius:var(--radius); padding:16px 20px; margin-bottom:12px; flex-wrap:wrap; }
.checkin-entry .ce-date{ font-family:var(--f-mono); font-size:12px; color:#9CA398; min-width:78px; }
.checkin-entry .ce-stats{ display:flex; gap:16px; flex-wrap:wrap; font-size:13.5px; color:#C7C7BB; flex:1; }
.checkin-entry .ce-stats b{ color:var(--paper); }
.ce-delta{ font-family:var(--f-mono); font-size:11.5px; margin-left:4px; }
.ce-delta.down{ color:var(--green-lt); }
.ce-delta.up{ color:var(--red); }
.checkin-entry .ce-thumbs{ display:flex; gap:6px; }
.checkin-entry .ce-thumbs img{ width:32px; height:42px; object-fit:cover; border-radius:2px; }
.checkin-empty{ color:#9CA398; font-size:14px; }

