/* Fonts hosted with the site (no requests to Google) */
@font-face { font-family: "Barlow Condensed"; font-weight: 600; font-style: normal; font-display: swap; src: url("fonts/barlow-condensed-600.woff2") format("woff2"); }
@font-face { font-family: "Barlow Condensed"; font-weight: 700; font-style: normal; font-display: swap; src: url("fonts/barlow-condensed-700.woff2") format("woff2"); }
@font-face { font-family: "Barlow Condensed"; font-weight: 800; font-style: normal; font-display: swap; src: url("fonts/barlow-condensed-800.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 100 900; font-style: normal; font-display: swap; src: url("fonts/inter-variable.woff2") format("woff2"); }

:root {
  --navy: #0b2a3c;
  --navy-2: #12384f;
  --green: #009639;         /* verde del logo */
  --green-dark: #007a2f;
  --green-bright: #2ec266;  /* stesso verde, schiarito per i fondi scuri */
  --green-tint: #bfe6cb;
  --green-soft: #e8f6ec;
  --ink: #0f1d26;
  --muted: #5a6b76;
  --line: #e2e8ec;
  --soft: #f3f6f4;
  --white: #ffffff;
  --radius: 18px;
  --shadow: 0 20px 50px -20px rgba(11, 42, 60, .35);
  --head: "Barlow Condensed", "Arial Narrow", sans-serif;
  --body: "Inter", system-ui, -apple-system, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
  margin: 0;
  font-family: var(--body);
  color: var(--ink);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img, svg, iframe { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { font-family: var(--head); line-height: 1.02; margin: 0; letter-spacing: .005em; }
h2 { font-size: clamp(2.2rem, 4.5vw, 3.4rem); font-weight: 800; text-transform: uppercase; }
h3 { font-size: 1.55rem; font-weight: 700; }
p { margin: 0; }

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

.eyebrow {
  display: inline-flex; align-items: center; gap: .6rem;
  font-size: .78rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
  color: var(--green-dark); margin-bottom: 1rem;
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  padding: .95rem 1.5rem; border-radius: 999px;
  font-weight: 600; font-size: .98rem; text-decoration: none;
  border: 2px solid transparent; transition: transform .15s, background .2s, color .2s, border-color .2s;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }
.btn svg { width: 18px; height: 18px; fill: currentColor; }
.btn-primary { background: var(--green); color: var(--white); }
.btn-primary:hover { background: var(--green-dark); }
.btn-ghost { border-color: currentColor; color: var(--navy); }
.btn-ghost:hover { background: var(--navy); color: var(--white); border-color: var(--navy); }
.btn-call { background: var(--navy); color: var(--white); padding: .7rem 1.15rem; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .9); backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent; transition: border-color .2s;
}
.site-header.scrolled { border-color: var(--line); }
.header-inner { display: flex; align-items: center; gap: 2rem; height: 72px; }
.brand { display: flex; align-items: center; gap: .65rem; text-decoration: none; }
.brand-mark { width: auto; height: 64px; }
.nav { display: flex; gap: 1.8rem; margin-left: auto; }
.nav a { text-decoration: none; font-weight: 400; font-size: .76rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); transition: color .2s; }
.nav a:hover { color: var(--navy); }
.nav-toggle { display: none; }

/* Hero */
.hero {
  position: relative; overflow: hidden;
  /* Fill the first screen exactly (viewport minus the 72px header) */
  min-height: calc(100svh - 72px); display: flex; align-items: center;
  padding: clamp(1.5rem, 5vh, 4rem) 0;
  background:
    radial-gradient(900px 500px at 85% 10%, rgba(0, 150, 57, .12), transparent 60%),
    linear-gradient(180deg, #f3f9f5 0%, #fff 100%);
}
.hero-grid { display: grid; grid-template-columns: 1.2fr .8fr; gap: 3rem; align-items: center; }
.hero h1 {
  font-size: clamp(2.2rem, min(6vw, 8vh), 5.2rem); font-weight: 800; text-transform: uppercase; color: var(--navy);
}
.hero h1 span { color: var(--navy); background: linear-gradient(transparent 62%, var(--green-tint) 62%, var(--green-tint) 92%, transparent 92%); }
.lead { font-size: 1.15rem; color: var(--muted); margin: clamp(.8rem, 2.5vh, 1.5rem) 0 clamp(1.2rem, 3.5vh, 2rem); max-width: 34em; }
.hero-cta { display: flex; flex-wrap: wrap; gap: .8rem; }


.hero-card { position: relative; margin-bottom: 36px; }
.monitor {
  background: var(--navy); color: var(--white); border-radius: 24px; padding: 1.4rem;
  box-shadow: var(--shadow); transform: rotate(-1.5deg);
  background-image:
    linear-gradient(rgba(255,255,255,.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.04) 1px, transparent 1px);
  background-size: 24px 24px;
}
.monitor-top { display: flex; align-items: center; gap: .6rem; font-size: .82rem; color: rgba(255,255,255,.7); }
.monitor-top .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--green-bright); animation: pulse 1.2s infinite; }
.ecg { width: 100%; height: clamp(90px, 18vh, 160px); margin: 1rem 0; }
.ecg-line {
  fill: none; stroke: var(--green-bright); stroke-width: 3.5; stroke-linejoin: round; stroke-linecap: round;
  stroke-dasharray: 1600; stroke-dashoffset: 1600; animation: draw 3.2s linear infinite;
  filter: drop-shadow(0 0 6px rgba(46, 194, 102, .6));
}
.monitor-stats { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; }
.monitor-stats div { background: rgba(255,255,255,.07); border-radius: 12px; padding: .8rem 1rem; }
.monitor-stats small { display: block; font-size: .72rem; text-transform: uppercase; letter-spacing: .1em; color: rgba(255,255,255,.55); }
.monitor-stats b { display: block; font-family: var(--head); font-size: 1.3rem; font-weight: 700; white-space: nowrap; }
.hero-badge {
  position: absolute; left: -22px; bottom: -56px;
  background: var(--green); color: var(--white); border-radius: 16px; padding: .8rem 1.1rem;
  box-shadow: var(--shadow); transform: rotate(2deg);
  display: flex; flex-direction: column; line-height: 1.1;
}
.hero-badge b { font-family: var(--head); text-transform: uppercase; font-size: .9rem; letter-spacing: .08em; }
.hero-badge span { font-family: var(--head); font-size: 1.6rem; font-weight: 800; }

@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes pulse { 50% { opacity: .3; } }

/* Strip */
.strip { background: var(--navy); color: var(--white); }
.strip-grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.strip-grid div { padding: 1.6rem 1.4rem; border-left: 1px solid rgba(255,255,255,.1); }
.strip-grid div:first-child { border-left: 0; padding-left: 0; }
.strip-grid b { display: block; font-family: var(--head); font-size: 1.45rem; text-transform: uppercase; color: var(--green-bright); }
.strip-grid span { font-size: .9rem; color: rgba(255,255,255,.72); }

/* Sections */
.section { --pad: clamp(4rem, 8vw, 7rem); padding: var(--pad) 0; }
/* Jumping from the menu: land with the heading just below the header, not after the full section padding */
.section[id] { scroll-margin-top: calc(1.25rem - var(--pad)); }
.section-dark { background: var(--navy); color: var(--white); }
.section-dark .eyebrow { color: var(--green-bright); }
.section-soft { background: var(--soft); }
.section-head { max-width: 640px; margin: 0 auto 3rem; text-align: center; }
.section-head .eyebrow { justify-content: center; }
.section-head h2 { color: inherit; }
.section:not(.section-dark) .section-head h2 { color: var(--navy); }
.section-head p:not(.eyebrow) { color: var(--muted); margin-top: 1rem; font-size: 1.05rem; }
.section-head.left { text-align: left; margin: 0; }
.section-head.left .eyebrow { justify-content: flex-start; }

/* Cards */
.cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.4rem; }
.card {
  position: relative; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 2rem; transition: transform .2s, box-shadow .2s, border-color .2s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: transparent; }
.card h3 { color: var(--navy); margin-bottom: .7rem; }
.card > p { color: var(--muted); }
.card-feature { background: var(--navy); color: var(--white); border-color: var(--navy); }
.card-feature h3 { color: var(--white); }
.card-feature > p { color: rgba(255,255,255,.75); }
.checks { list-style: none; padding: 0; margin: 1.4rem 0 0; display: grid; gap: .55rem; }
.checks li { display: flex; gap: .7rem; align-items: flex-start; font-size: .95rem; }
.checks li::before {
  content: ""; flex: none; width: 20px; height: 20px; margin-top: 2px; border-radius: 50%;
  background: var(--green) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5.5 10.5l3 3 6-7' fill='none' stroke='%23ffffff' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/100% no-repeat;
}

.teams {
  margin-top: 1.4rem; display: flex; align-items: center; justify-content: space-between; gap: 1.5rem;
  padding: 1.8rem 2rem; border-radius: var(--radius);
  background: linear-gradient(110deg, var(--green) 0%, #00b347 100%); color: var(--white);
}
.teams h3 { font-size: 1.8rem; text-transform: uppercase; }
.teams p { margin-top: .3rem; }
.teams .btn-primary { background: var(--navy); color: var(--white); }
.teams .btn-primary:hover { background: var(--navy-2); }

/* Steps */
.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.4rem; counter-reset: s; }
.steps li { position: relative; padding: 1.8rem 1.6rem; border-radius: var(--radius); background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.1); }
.step-n { display: block; font-family: var(--head); font-size: 3.4rem; font-weight: 800; line-height: 1; color: var(--green-bright); margin-bottom: .8rem; }
.steps h3 { text-transform: uppercase; margin-bottom: .5rem; }
.steps p { color: rgba(255,255,255,.72); font-size: .95rem; }
.steps a { color: var(--green-bright); font-weight: 600; text-decoration: none; }

/* Bring */
.bring-grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: 4rem; align-items: start; }
.section-head.left p:not(.eyebrow) { margin-top: 1rem; }
.note { margin-top: 1.5rem !important; padding: 1rem 1.2rem; border-left: 3px solid var(--green); background: var(--soft); border-radius: 0 12px 12px 0; color: var(--ink) !important; font-size: .95rem !important; }
.tabs { background: var(--white); border: 1px solid var(--line); border-radius: 22px; padding: .6rem; box-shadow: 0 20px 40px -30px rgba(11,42,60,.4); }
.tab-list { display: grid; grid-template-columns: 1fr 1fr; gap: .4rem; background: var(--soft); padding: .35rem; border-radius: 16px; }
.tab-list button {
  font: inherit; font-weight: 600; border: 0; cursor: pointer; padding: .8rem; border-radius: 12px;
  background: transparent; color: var(--muted); transition: background .2s, color .2s;
}
.tab-list button[aria-selected="true"] { background: var(--navy); color: var(--white); }
.tab-panel { padding: 1.2rem 1.4rem 1rem; }
.bring { list-style: none; margin: 0; padding: 0; }
.bring li { padding: .95rem 0 .95rem 2.4rem; border-bottom: 1px solid var(--line); position: relative; color: var(--muted); }
.bring li:last-child { border-bottom: 0; }
.bring li b { color: var(--ink); font-weight: 600; }
.bring li::before {
  content: ""; position: absolute; left: 0; top: 1.05rem; width: 22px; height: 22px; border-radius: 7px;
  border: 2px solid var(--green);
}

/* FAQ */
.faq-wrap { max-width: 820px; }
.faq { display: grid; gap: .8rem; }
.faq details { background: var(--white); border-radius: 16px; border: 1px solid var(--line); }
.faq summary {
  cursor: pointer; list-style: none; padding: 1.2rem 1.5rem; font-weight: 600; font-size: 1.05rem;
  display: flex; justify-content: space-between; align-items: center; gap: 1rem; color: var(--navy);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; flex: none; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center;
  background: var(--soft); color: var(--navy); font-size: 1.3rem; font-weight: 500; transition: transform .2s, background .2s;
}
.faq details[open] summary::after { transform: rotate(45deg); background: var(--green); color: var(--white); }
.faq details p { padding: 0 1.5rem 1.3rem; color: var(--muted); }
.faq a { color: var(--navy); font-weight: 600; }

/* Contact */
.contact-grid { display: grid; grid-template-columns: 1fr 1.15fr; gap: 3rem; align-items: start; }
.contact-info h2 { color: var(--navy); }
.contact-lead { color: var(--muted); font-size: 1.05rem; margin: 1rem 0 1.8rem; max-width: 30em; }
.info { margin: 0; display: grid; gap: 1.2rem; }
.info div { display: grid; grid-template-columns: 110px 1fr; gap: 1rem; padding-bottom: 1.2rem; border-bottom: 1px solid var(--line); }
.info dt { font-size: .78rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); padding-top: .2rem; }
.info dd { margin: 0; font-size: 1.05rem; }
.info dd a { font-weight: 600; color: var(--navy); text-decoration: none; font-size: 1.25rem; }
.info small { color: var(--muted); font-size: .85rem; }
.hours { list-style: none; margin: 0; padding: 0; display: grid; gap: .45rem; }
.hours li { display: flex; justify-content: space-between; gap: 1rem; padding: .35rem .7rem; margin-inline: -.7rem; border-radius: 10px; }
.hours li span:last-child { text-align: right; font-weight: 500; }
.hours li.today { background: var(--green-soft); }
.hours li.today span:first-child::after { content: " · oggi"; color: var(--green-dark); font-weight: 600; font-size: .85rem; }
.contact-cta { display: flex; flex-wrap: wrap; gap: .8rem; }

/* Legal page */
/* Arriving at privacy.html#cookie from another page: jump straight to the section */
html:has(.legal) { scroll-behavior: auto; }
.legal-back { margin-left: auto; }
.legal { max-width: 760px; padding-block: clamp(2.5rem, 6vw, 4.5rem); }
.legal h1 { font-size: clamp(2.4rem, 5vw, 3.6rem); font-weight: 800; text-transform: uppercase; color: var(--navy); }
.legal-date { color: var(--muted); font-size: .9rem; margin-top: .8rem; }
.legal h2 { font-size: 1.7rem; font-weight: 700; color: var(--navy); margin-top: 2.6rem; scroll-margin-top: 90px; }
.legal p, .legal ul { color: var(--ink); margin: .8rem 0 0; }
.legal ul { padding-left: 1.2rem; }
.legal li { margin-top: .4rem; }
.legal a { color: var(--green-dark); font-weight: 500; }

/* Footer */
.site-footer { background: var(--navy); color: rgba(255,255,255,.7); padding: 3rem 0; font-size: .9rem; }
.footer-inner { display: flex; justify-content: space-between; align-items: center; gap: 2rem; flex-wrap: wrap; }
.brand-footer .brand-mark { height: 72px; background: var(--white); border-radius: 14px; padding: 6px; }
.footer-company { text-align: right; line-height: 1.8; }
.footer-company b { color: var(--white); font-weight: 500; }
.site-footer a:not(.brand) { color: rgba(255,255,255,.85); transition: color .2s; }
.site-footer a:not(.brand):hover { color: var(--green-bright); }
.footer-bottom {
  display: flex; justify-content: space-between; gap: .6rem 2rem; flex-wrap: wrap;
  margin-top: 2rem; padding-top: 1.4rem; border-top: 1px solid rgba(255,255,255,.12); font-size: .82rem;
}

/* Floating call (mobile) */
.fab-call {
  display: none; position: fixed; right: 16px; bottom: 16px; z-index: 60;
  align-items: center; gap: .5rem; padding: .9rem 1.3rem; border-radius: 999px;
  background: var(--green); color: var(--white); font-weight: 700; text-decoration: none;
  box-shadow: 0 12px 30px -8px rgba(11,42,60,.55);
}
.fab-call svg { width: 20px; height: 20px; fill: currentColor; }

/* Reveal */
.reveal { opacity: 0; translate: 0 16px; transition: opacity .4s ease, translate .4s ease, transform .2s, box-shadow .2s, border-color .2s; }
.reveal.in { opacity: 1; translate: none; }

/* Responsive */
@media (max-width: 980px) {
  .hero-grid, .bring-grid, .contact-grid { grid-template-columns: 1fr; }
  .hero-card { max-width: 520px; margin: 1rem auto 0; width: 100%; }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .strip-grid { grid-template-columns: repeat(2, 1fr); }
  .strip-grid div:nth-child(3) { border-left: 0; padding-left: 0; }
  .strip-grid div { border-top: 1px solid rgba(255,255,255,.1); }
  .strip-grid div:nth-child(-n+2) { border-top: 0; }
  .bring-grid { gap: 2rem; }
}

@media (max-width: 820px) {
  .header-call { display: none; }
  .nav-toggle {
    display: grid; gap: 6px; margin-left: auto; width: 44px; height: 44px; place-content: center;
    background: var(--soft); border: 0; border-radius: 12px; cursor: pointer;
  }
  .nav-toggle span { width: 20px; height: 2px; background: var(--navy); transition: transform .25s; }
  .nav-toggle[aria-expanded="true"] span:first-child { transform: translateY(4px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:last-child { transform: translateY(-4px) rotate(-45deg); }
  .nav {
    position: absolute; top: 72px; left: 0; right: 0; flex-direction: column; gap: 0;
    background: var(--white); border-bottom: 1px solid var(--line); padding: .5rem 20px 1rem;
    transform: translateY(-8px); opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s;
  }
  .nav.open { opacity: 1; transform: none; pointer-events: auto; }
  .nav a { padding: .9rem 0; border-bottom: 1px solid var(--line); font-size: .85rem; color: var(--navy); }
  .nav a:last-child { border-bottom: 0; }
  .cards { grid-template-columns: 1fr; }
  .teams { flex-direction: column; align-items: flex-start; }
  .fab-call { display: inline-flex; }
  .footer-company { text-align: left; }
  .site-footer { padding-bottom: 6rem; }
}

@media (max-width: 560px) {
  .wrap { width: calc(100% - 32px); }
  .steps, .strip-grid { grid-template-columns: 1fr; }
  .strip-grid div { border-left: 0 !important; padding-left: 0 !important; padding-block: 1.1rem; border-top: 1px solid rgba(255,255,255,.1) !important; }
  .strip-grid div:first-child { border-top: 0 !important; }
  .hero-cta .btn { width: 100%; }
  .hero-badge { position: static; flex-direction: row; align-items: baseline; gap: .6rem; width: fit-content; margin: 1.2rem auto 0; transform: none; }
  .ecg { height: 120px; }
  .card { padding: 1.6rem; }
  .info div { grid-template-columns: 1fr; gap: .3rem; }
  .tab-panel { padding: 1rem .8rem .6rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .ecg-line { animation: none; stroke-dashoffset: 0; }
  .monitor-top .dot { animation: none; }
  .reveal { opacity: 1; translate: none; transition: none; }
}
