/* TonikaOS – sito di presentazione. Colori e font del marchio (vedi CLAUDE.md, sezione Grafica). */
:root {
  --bg: #f7f5f0;
  --ink: #16161a;
  --accent: #c2410c;
  --accent-dark: #9a3412;
  --muted: #4a4a52;
  --line: #e2ded5;
  --card: #ffffff;
  --tonal: #fde7dc;
  --radius: 20px;
  --title: 'Bricolage Grotesque', Inter, system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 17px/1.6 Inter, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
a:hover { color: var(--accent); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3 { font-family: var(--title); line-height: 1.1; margin: 0; letter-spacing: -0.01em; }
p { margin: 0; }

.wrap { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 10; }
.skip:focus { left: 8px; }

.eyebrow { font-size: 14px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent-dark); margin-bottom: 14px; }
.lead { font-size: 19px; color: var(--muted); max-width: 600px; }
.h-big { font-size: clamp(32px, 4.4vw, 52px); max-width: 820px; margin-bottom: 48px; }

/* Bottoni */
.btn { display: inline-flex; align-items: center; justify-content: center; text-decoration: none; font-weight: 600; font-size: 17px; padding: 15px 26px; border-radius: 999px; border: 1.5px solid transparent; transition: background-color .15s, color .15s, border-color .15s; }
.btn-sm { font-size: 15px; padding: 10px 18px; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-dark); color: #fff; }
.btn-outline { border-color: var(--ink); }
.btn-outline:hover { background: var(--ink); color: var(--bg); }
.btn-light { background: #fff; color: var(--ink); }
.btn-light:hover { background: var(--bg); color: var(--ink); }
.btn-ghost { border-color: rgba(255,255,255,.7); color: #fff; }
.btn-ghost:hover { background: rgba(255,255,255,.12); color: #fff; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.actions.center { justify-content: center; }

/* Header */
.top { position: sticky; top: 0; z-index: 5; background: rgba(247,245,240,.92); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.top-in { display: flex; align-items: center; gap: 24px; min-height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--title); font-weight: 700; font-size: 21px; }
.top nav { margin-left: auto; }
.top nav ul { display: flex; gap: 26px; list-style: none; margin: 0; padding: 0; }
.top nav a { text-decoration: none; font-weight: 500; font-size: 15px; }

/* Apertura */
.hero { padding: 72px 0 88px; overflow: hidden; }
.hero-in { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 56px; align-items: center; }
.hero h1 { font-size: clamp(40px, 5.6vw, 70px); line-height: 1.02; letter-spacing: -0.02em; margin-bottom: 24px; }
.hero-facts { display: flex; flex-wrap: wrap; gap: 28px; list-style: none; padding: 0; margin: 40px 0 0; color: var(--muted); font-size: 15px; }
.hero-facts strong { display: block; font-family: var(--title); font-size: 30px; color: var(--ink); line-height: 1.1; }
.hero-shot { position: relative; margin: 0; padding-bottom: 40px; }
.phone { position: absolute; right: -12px; bottom: 0; width: 26%; border-radius: 22px; border: 6px solid var(--ink); box-shadow: 0 24px 50px rgba(22,22,26,.25); }

.browser { background: var(--card); border-radius: 14px; overflow: hidden; border: 1px solid var(--line); box-shadow: 0 30px 60px -20px rgba(22,22,26,.22); }
.browser-bar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; background: #efece5; border-bottom: 1px solid var(--line); }
.browser-bar i { width: 11px; height: 11px; border-radius: 50%; background: #d6d1c6; }
.browser-bar span { margin-left: 12px; font-size: 12px; color: var(--muted); background: #fff; border-radius: 999px; padding: 2px 12px; }

/* Fascia scura */
.band-dark { background: var(--ink); color: var(--bg); padding: 80px 0; }
.band-dark h2 { font-size: clamp(28px, 3.6vw, 42px); margin-bottom: 40px; max-width: 760px; }
.band-dark h3 { font-size: 22px; margin-bottom: 10px; color: #fdba74; }
.band-dark p { color: #c9c6be; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px; }

/* Sezioni */
.section { padding: 104px 0; }
.section.alt { background: #efece5; }

.feature { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 64px; align-items: center; margin-bottom: 112px; }
.feature:last-child { margin-bottom: 0; }
.feature.reverse .feature-text { order: 2; }
.feature h3 { font-size: clamp(28px, 3vw, 38px); margin: 14px 0 14px; }
.feature-text > p { color: var(--muted); font-size: 18px; }
.tag { display: inline-block; background: var(--tonal); color: var(--accent-dark); font-weight: 600; font-size: 14px; padding: 5px 14px; border-radius: 999px; }
.checks { list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 10px; }
.checks li { position: relative; padding-left: 32px; }
.checks li::before { content: ''; position: absolute; left: 0; top: 4px; width: 20px; height: 20px; border-radius: 50%; background: var(--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M6 10.5l2.5 2.5L14 7.5' stroke='white' stroke-width='2' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/20px no-repeat; }

/* Illustrazioni dell'interfaccia */
.mock { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; box-shadow: 0 30px 60px -24px rgba(22,22,26,.2); font-size: 15px; }
.mock-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 20px; }
.mock-head b { font-family: var(--title); font-size: 22px; }
.mock-head span { color: var(--muted); font-size: 14px; }
.mock-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.mock-chips span { border: 1px solid var(--line); border-radius: 8px; padding: 6px 14px; }
.mock-chips .on { background: var(--tonal); border-color: transparent; color: var(--accent-dark); font-weight: 600; }
.mock-slots { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.mock-slots span { text-align: center; padding: 10px 0; border-radius: 10px; border: 1px solid var(--line); font-weight: 500; }
.mock-slots .busy { background: #f1eee8; color: #9a978f; text-decoration: line-through; border-color: transparent; }
.mock-slots .sel { background: var(--accent); color: #fff; border-color: var(--accent); }
.mock-sum { display: flex; justify-content: space-between; margin: 22px 0 14px; padding-top: 16px; border-top: 1px solid var(--line); color: var(--muted); }
.mock-sum b { color: var(--ink); font-size: 18px; }
.mock-btn { background: var(--accent); color: #fff; text-align: center; font-weight: 600; padding: 13px; border-radius: 999px; }

.mock-agenda { list-style: none; padding: 0; margin: 0; }
.mock-agenda li { display: grid; grid-template-columns: 56px 1fr auto; gap: 14px; align-items: center; padding: 14px 0; border-top: 1px solid var(--line); }
.mock-agenda time { font-weight: 600; font-variant-numeric: tabular-nums; }
.mock-agenda small { display: block; color: var(--muted); }
.mock-agenda em { font-style: normal; font-size: 13px; font-weight: 600; padding: 4px 12px; border-radius: 999px; background: #f1eee8; color: var(--muted); white-space: nowrap; }
.mock-agenda em.ok { background: #dcfce7; color: #166534; }
.mock-agenda em.warn { background: #fef3c7; color: #92400e; }

.cal { display: grid; grid-template-columns: 34px repeat(3, 1fr); grid-template-rows: 30px repeat(6, 46px); gap: 4px; font-size: 13px; }
.cal-h { grid-row: 1; font-weight: 600; text-align: center; align-self: center; }
.cal-t { grid-column: 1; color: var(--muted); font-size: 12px; border-top: 1px solid var(--line); padding-top: 2px; }
.ev { border-radius: 8px; padding: 6px 8px; font-weight: 600; line-height: 1.25; overflow: hidden; }
.ev.prova { background: var(--tonal); color: var(--accent-dark); border-left: 4px solid var(--accent); }
.ev.lez { background: #dbeafe; color: #1e3a8a; border-left: 4px solid #2563eb; }
.ev.evento { background: var(--ink); color: var(--bg); }
.ev.blocco { background: repeating-linear-gradient(45deg, #ece9e2, #ece9e2 6px, #e2ded5 6px, #e2ded5 12px); color: var(--muted); }

/* Schede funzionalità */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 20px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; }
.card h3 { font-size: 21px; margin-bottom: 10px; }
.card p { color: var(--muted); font-size: 16px; }
.gallery { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; margin-top: 56px; }
.gallery figure { margin: 0; }
.gallery img { border-radius: 14px; border: 1px solid var(--line); }
.gallery figcaption { margin-top: 10px; font-size: 15px; color: var(--muted); font-weight: 500; }

/* Demo */
.demo { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 64px; align-items: start; }
.demo .h-big { margin-bottom: 20px; }
.note { margin-top: 24px; font-size: 15px; color: var(--muted); max-width: 560px; }
.roles { background: var(--ink); color: var(--bg); border-radius: var(--radius); padding: 32px; }
.roles h3 { font-size: 24px; margin-bottom: 8px; }
.roles ul { list-style: none; padding: 0; margin: 0; }
.roles li { padding: 16px 0; border-top: 1px solid #2e2e34; display: grid; gap: 4px; }
.roles li:first-child { border-top: 0; }
.role { font-weight: 600; color: #fdba74; }
.roles code { font-size: 15px; word-break: break-all; }
.roles small { color: #b9b6ae; font-size: 14px; }
.pw { margin-top: 12px; padding-top: 16px; border-top: 1px solid #2e2e34; font-size: 15px; color: #c9c6be; }
.pw a { color: #fff; }

/* Installazione */
.steps .num { display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--accent); color: #fff; font-family: var(--title); font-weight: 700; font-size: 20px; margin-bottom: 18px; }
.steps h3 { font-size: 22px; margin-bottom: 10px; }
.steps p { color: var(--muted); }
.next { margin-top: 56px; padding: 28px 32px; border: 1.5px dashed #c9c4b8; border-radius: var(--radius); }
.next h3 { font-size: 21px; margin-bottom: 8px; }
.next p { color: var(--muted); }

/* Chiamata finale */
.cta { background: var(--accent); color: #fff; text-align: center; }
.cta-in { max-width: 760px; }
.cta h2 { font-size: clamp(30px, 4vw, 48px); margin-bottom: 16px; }
.cta p { font-size: 19px; color: #ffedd5; }

.foot { padding: 32px 0; font-size: 14px; color: var(--muted); }
.foot-in { display: flex; flex-wrap: wrap; gap: 12px 28px; justify-content: space-between; }

/* Tablet e smartphone */
@media (max-width: 980px) {
  .top nav { display: none; }
  .top .btn { margin-left: auto; }
  .hero { padding-top: 48px; }
  .hero-in, .feature, .demo { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .feature.reverse .feature-text { order: 0; }
  .feature { margin-bottom: 80px; }
  .grid-3 { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .section { padding: 72px 0; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .wrap { padding: 0 18px; }
  .gallery { grid-template-columns: minmax(0, 1fr); }
  .phone { width: 34%; right: -4px; border-width: 4px; border-radius: 16px; }
  .mock { padding: 20px; }
  .mock-slots { grid-template-columns: repeat(3, 1fr); }
  .btn { width: 100%; }
  .top .btn { width: auto; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
