/* ─── RESET & CUSTOM PROPERTIES ─────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --brand: #164f96;
  --deep:  #0b1a30;
  --glow:  #00f2fe;
  --white: #ffffff;

  --font-head: 'Montserrat', sans-serif;
  --font-body: 'Inter', sans-serif;

  --radius-card: 28px;
  --glass-bg:     rgba(255,255,255,0.05);
  --glass-border: 1px solid rgba(255,255,255,0.18);

  --aurora: radial-gradient(ellipse 80% 60% at 20% 30%, rgba(22,79,150,0.55) 0%, transparent 65%),
            radial-gradient(ellipse 60% 50% at 80% 70%, rgba(0,242,254,0.18) 0%, transparent 65%),
            radial-gradient(ellipse 70% 70% at 55% 10%, rgba(22,79,150,0.35) 0%, transparent 70%),
            radial-gradient(ellipse 50% 40% at 10% 80%, rgba(0,242,254,0.10) 0%, transparent 60%),
            #0b1a30;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--deep);
  color: var(--white);
  line-height: 1.6;
}

/* ─── UTILITY ────────────────────────────────────────────────────────── */
.container {
  width: min(1200px, 92%);
  margin-inline: auto;
}

/* Placeholder media boxes */
.media-box {
  background: rgba(255,255,255,0.08);
  border: 2px dashed rgba(255,255,255,0.22);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: rgba(255,255,255,0.45);
  text-transform: uppercase;
  text-align: center;
  padding: 1rem;
}

/* Glass card recipe */
.card-glass {
  background: var(--glass-bg);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: var(--glass-border);
  border-radius: var(--radius-card);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.75rem;
  border-radius: 50px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  border: none;
  text-decoration: none;
  transition: opacity .2s, transform .2s;
}
.btn:hover { opacity: .85; transform: translateY(-2px); }

.btn-primary {
  background: var(--glow);
  color: var(--deep);
}
.btn-glass {
  background: var(--glass-bg);
  border: var(--glass-border);
  color: var(--white);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.btn-outline {
  background: transparent;
  border: 1.5px solid var(--glow);
  color: var(--glow);
}

/* Section label */
.section-label {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--glow);
  background: rgba(0,242,254,0.08);
  border: 1px solid rgba(0,242,254,0.25);
  border-radius: 50px;
  padding: 0.3rem 1rem;
  margin-bottom: 1rem;
}

.section-label--clean {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: none;
  border: none;
  border-radius: 0;
  padding: 0;
}

.section-label--clean::before {
  content: '';
  display: inline-block;
  width: 24px;
  height: 2px;
  background: var(--glow);
  flex-shrink: 0;
}

.section-title {
  font-family: var(--font-head);
  font-weight: 800;
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  line-height: 1.2;
  margin-bottom: 1rem;
}

.section-sub {
  color: rgba(255,255,255,0.55);
  font-size: 1rem;
  max-width: 56ch;
}

/* ─── HEADER / FOOTER ───────────────────────────────────────────────── */
/* Migrati a css/cobalto.css + partials/header.html + partials/footer.html */

/* ─── HERO ───────────────────────────────────────────────────────────── */
/* SEZIONE: HERO */
.hero {
  min-height: 100vh;
  background: linear-gradient(135deg, #0b1a30 0%, #164f96 100%);
  padding-block: clamp(5rem, 12vw, 9rem);
  overflow: hidden;
  display: flex;
  align-items: center;
}

.hero-inner {
  display: flex;
  align-items: center;
}

#typewriter-target::after {
  content: '|';
  display: inline-block;
  color: #00f2fe;
  font-weight: 300;
  margin-left: 2px;
  animation: blink 0.75s step-end infinite;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0; }
}

@media (max-width: 768px) {
  .hero-inner { flex-direction: column; }
}

.hero-eyebrow {
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: rgba(255,255,255,0.55);
  margin-bottom: 1.25rem;
}

.eyebrow-brand {
  color: #00f2fe;
  font-weight: 700;
}

.hero-title {
  font-family: var(--font-head);
  font-weight: 900;
  font-size: clamp(2.4rem, 4vw, 4rem);
  line-height: 1.07;
  margin-bottom: 1.5rem;
}
.hero-title em {
  font-style: normal;
  color: var(--glow);
}

/* ─── HERO --RSW (scoped a realizzazione-sito-web.html via .hero--rsw) ── */
/* .hero-stack avvolge hero + "Il Problema": .hero-stack-bg è sticky e resta
   fissa dietro a entrambe le sezioni (che diventano trasparenti), poi si
   stacca naturalmente quando "Come Lavoriamo" (fuori da .hero-stack, con
   sfondo opaco) la ricopre nello scroll. */
.hero-stack { position: relative; }

.hero-stack-bg {
  position: sticky;
  top: 0;
  height: 100dvh;
  margin-bottom: -100dvh;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  background-color: var(--deep);
}

.hero--rsw { position: relative; z-index: 1; overflow: hidden; background: transparent; }

.hero-stack-bg .hero-aurora {
  position: absolute;
  inset: -10px;
  pointer-events: none;
  z-index: 0;
  opacity: 0.5;
  filter: blur(10px);
  background-image:
    repeating-linear-gradient(100deg, #ffffff 0%, #ffffff 7%, transparent 10%, transparent 12%, #ffffff 16%),
    repeating-linear-gradient(100deg, #164f96 10%, #2f6fc4 15%, #1c3f72 20%, #00f2fe 25%, #164f96 30%);
  background-size: 300%, 200%;
  background-position: 50% 50%, 50% 50%;
  animation: hero-aurora-move 60s linear infinite;
  will-change: background-position;
  mask-image: radial-gradient(ellipse at 50% 0%, black 10%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at 50% 0%, black 10%, transparent 70%);
}

.hero-stack-bg .hero-aurora::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: inherit;
  background-size: 200%, 100%;
  background-attachment: fixed;
  mix-blend-mode: difference;
}

@keyframes hero-aurora-move {
  from { background-position: 50% 50%, 50% 50%; }
  to   { background-position: 350% 50%, 350% 50%; }
}

@media (prefers-reduced-motion: reduce) {
  .hero-stack-bg .hero-aurora, .hero-stack-bg .hero-aurora::after { animation: none; }
}

.hero--rsw .rsw-hero-inner { position: relative; z-index: 1; }

.hero--rsw .rsw-hero-title .word { display: inline-block; overflow: hidden; vertical-align: top; }
.hero--rsw .rsw-hero-title .word-inner {
  display: inline-block;
  transform: translateY(115%);
  animation: word-reveal 0.6s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}
@keyframes word-reveal { to { transform: translateY(0); } }
@media (prefers-reduced-motion: reduce) {
  .hero--rsw .rsw-hero-title .word-inner { animation: none; transform: none; }
}
.hero--rsw .rsw-hero-title .word-inner { animation-delay: 0.05s; }
.hero--rsw .rsw-hero-title .word:nth-child(2)  .word-inner { animation-delay: 0.08s; }
.hero--rsw .rsw-hero-title .word:nth-child(3)  .word-inner { animation-delay: 0.11s; }
.hero--rsw .rsw-hero-title .word:nth-child(4)  .word-inner { animation-delay: 0.14s; }
.hero--rsw .rsw-hero-title .word:nth-child(5)  .word-inner { animation-delay: 0.17s; }
.hero--rsw .rsw-hero-title .word:nth-child(6)  .word-inner { animation-delay: 0.20s; }
.hero--rsw .rsw-hero-title .word:nth-child(7)  .word-inner { animation-delay: 0.23s; }
.hero--rsw .rsw-hero-title .word:nth-child(8)  .word-inner { animation-delay: 0.26s; }
.hero--rsw .rsw-hero-title .word:nth-child(9)  .word-inner { animation-delay: 0.29s; }
.hero--rsw .rsw-hero-title .word:nth-child(10) .word-inner { animation-delay: 0.32s; }
.hero--rsw .rsw-hero-title .word:nth-child(11) .word-inner { animation-delay: 0.35s; }
.hero--rsw .rsw-hero-title .word:nth-child(12) .word-inner { animation-delay: 0.38s; }
.hero--rsw .rsw-hero-title .word:nth-child(13) .word-inner { animation-delay: 0.41s; }
.hero--rsw .rsw-hero-title .word:nth-child(14) .word-inner { animation-delay: 0.44s; }

.hero--rsw .eyebrow,
.hero--rsw .rsw-hero-desc,
.hero--rsw .hero-actions,
.hero--rsw .rsw-hero-right {
  opacity: 0;
  animation: hero-fade-up 0.6s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes hero-fade-up {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes hero-fade-scale {
  from { opacity: 0; transform: scale(0.96); }
  to   { opacity: 1; transform: scale(1); }
}

.hero--rsw .eyebrow        { animation-delay: 0s; }
.hero--rsw .rsw-hero-desc  { animation-delay: 1.0s; }
.hero--rsw .hero-actions   { animation-delay: 1.15s; }

.hero--rsw .hero-actions .btn:nth-child(2),
.hero--rsw .hero-actions a:nth-child(2) {
  animation: hero-fade-up 0.5s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  animation-delay: 1.23s;
  opacity: 0;
}

.hero--rsw .rsw-hero-right {
  opacity: 0;
  animation: hero-fade-scale 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  animation-delay: 0.2s;
}

@media (prefers-reduced-motion: reduce) {
  .hero--rsw .eyebrow,
  .hero--rsw .rsw-hero-desc,
  .hero--rsw .hero-actions,
  .hero--rsw .hero-actions .btn:nth-child(2),
  .hero--rsw .hero-actions a:nth-child(2),
  .hero--rsw .rsw-hero-right {
    animation: none;
    opacity: 1;
    transform: none;
  }
}

.rsw-problem .rsw-problem-card p {
  color: #e6ecf7;
}

.hero-desc {
  color: rgba(255,255,255,0.62);
  font-size: 1.05rem;
  margin-bottom: 2rem;
  max-width: 48ch;
}

.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; }

.hero-visual .media-box {
  height: 380px;
  font-size: 0.85rem;
  border-radius: 28px;
}

/* ─── SERVIZI ────────────────────────────────────────────────────────── */
/* SEZIONE: SERVIZI */

.services-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 100vh;
  background: #0b1a30;
}

/* SINISTRA: card che scorrono */
.services-cards {
  padding: 10vh 5vw 10vh 8vw;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.service-card {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 4rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  opacity: 0.3;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.service-card.active {
  opacity: 1;
  transform: translateY(0);
}

.service-card:last-child {
  border-bottom: none;
}

.service-eyebrow {
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #00f2fe;
  margin-bottom: 1.2rem;
  display: block;
}

.service-title {
  font-family: 'Montserrat', sans-serif;
  font-size: clamp(1.8rem, 3vw, 2.8rem);
  font-weight: 800;
  color: #ffffff;
  line-height: 1.2;
  margin-bottom: 1.5rem;
}

.service-desc {
  font-family: 'Inter', sans-serif;
  font-size: 1rem;
  color: rgba(255,255,255,0.6);
  line-height: 1.75;
  max-width: 480px;
  margin-bottom: 2rem;
}

.service-cta {
  display: inline-block;
  padding: 0.8rem 1.8rem;
  border: 1.5px solid #00f2fe;
  border-radius: 100px;
  color: #00f2fe;
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  letter-spacing: 0.03em;
  align-self: flex-start;
  transition: background 0.2s ease, color 0.2s ease;
}

.service-cta:hover {
  background: #00f2fe;
  color: #0b1a30;
}

/* DESTRA: visual sticky */
.services-visual {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.service-visual-panel {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.6s ease;
  pointer-events: none;
}

.service-visual-panel.active {
  opacity: 1;
  pointer-events: auto;
}

.visual-placeholder {
  min-width: 340px;
  min-height: 420px;
  border-radius: 24px;
  border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.03);
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(10px);
  overflow: visible;
}

.visual-number {
  font-family: 'Montserrat', sans-serif;
  font-size: 6rem;
  font-weight: 900;
  color: rgba(255,255,255,0.06);
  line-height: 1;
  user-select: none;
}

.service-visual-panel[data-visual="1"] .visual-placeholder {
  background: linear-gradient(135deg, rgba(0,242,254,0.08), rgba(22,79,150,0.15));
}
.service-visual-panel[data-visual="2"] .visual-placeholder {
  background: linear-gradient(135deg, rgba(22,79,150,0.15), rgba(0,242,254,0.05));
}
.service-visual-panel[data-visual="3"] .visual-placeholder {
  background: transparent;
  border: none;
}
.service-visual-panel[data-visual="4"] .visual-placeholder {
  background: transparent;
  border: none;
}

@media (max-width: 768px) {
  .services-split {
    grid-template-columns: 1fr;
  }
  .services-visual {
    display: none;
  }
  .services-cards {
    padding: 6vh 6vw;
  }
  .service-card {
    min-height: auto;
    padding: 3rem 0;
    opacity: 1;
    transform: none;
  }
}

/* ─── METODO (sezione index) — sostituita da homepage-cobalto.css ───── */

/* ─── SOFTWARE (sezione index) — sostituita da homepage-cobalto.css ─── */
/* .video-placeholder/.video-play-btn/.video-label restano: usate da altre pagine */
.video-placeholder {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 20px;
  border: 1px solid rgba(0,242,254,0.15);
  background: rgba(255,255,255,0.02);
  backdrop-filter: blur(12px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.2rem;
  position: relative;
  overflow: hidden;
  transition: border-color 0.3s ease;
}

.video-placeholder::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(0,242,254,0.05) 0%, rgba(22,79,150,0.1) 100%);
  pointer-events: none;
}

.video-placeholder:hover {
  border-color: rgba(0,242,254,0.35);
}

.video-play-btn {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  border: 2px solid rgba(0,242,254,0.4);
  background: rgba(0,242,254,0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease, transform 0.2s ease;
}

.video-placeholder:hover .video-play-btn {
  background: rgba(0,242,254,0.18);
  transform: scale(1.08);
}

.video-label {
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
  color: rgba(255,255,255,0.3);
  text-align: center;
  line-height: 1.5;
  margin: 0;
}


/* ─── PORTFOLIO / BRAND ──────────────────────────────────────────────── */
/* SEZIONE: PORTFOLIO / BRAND */
.portfolio {
  padding-block: clamp(4rem, 8vw, 7rem);
  background: rgba(255,255,255,0.015);
}

.portfolio-head {
  text-align: center;
  margin-bottom: 3rem;
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 3rem;
}

.portfolio-item {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  cursor: none;
}

.portfolio-img-wrap {
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: 16px;
  overflow: hidden;
  transition: transform 0.4s ease;
}

.portfolio-item:hover .portfolio-img-wrap {
  transform: scale(1.03);
}

.portfolio-media {
  width: 100%;
  height: 100%;
  border-radius: 16px;
  overflow: hidden;
  background: #0b1a30;
}

.portfolio-media video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.portfolio-item:hover .portfolio-media video {
  transform: scale(1.03);
}

.portfolio-tooltip {
  position: fixed;
  pointer-events: none;
  z-index: 9999;
  background: rgba(11,26,48,0.92);
  border: 1px solid rgba(0,242,254,0.25);
  backdrop-filter: blur(12px);
  border-radius: 10px;
  padding: 0.65rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  opacity: 0;
  transform: translate(16px, 16px) scale(0.95);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.portfolio-tooltip.visible {
  opacity: 1;
  transform: translate(16px, 16px) scale(1);
}

.tooltip-tipo {
  font-family: 'Inter', sans-serif;
  font-size: 0.75rem;
  font-weight: 600;
  color: #00f2fe;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.tooltip-cliente {
  font-family: 'Montserrat', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: #ffffff;
}

@media (max-width: 768px) {
  .portfolio-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }
  .portfolio-tooltip {
    display: none;
  }
  .portfolio-item {
    cursor: default;
  }
}

/* ─── CTA FINALE ─────────────────────────────────────────────────────── */
/* SEZIONE: CTA FINALE */
.cta-final {
  background: var(--aurora);
  padding-block: clamp(5rem, 10vw, 8rem);
  text-align: center;
}

.cta-final h2 {
  font-family: var(--font-display, var(--font-head));
  font-weight: 500;
  font-size: clamp(2rem, 4.5vw, 3.5rem);
  letter-spacing: -.03em;
  margin-bottom: 1.25rem;
}

.cta-final p {
  color: rgba(255,255,255,0.6);
  font-size: 1.05rem;
  max-width: 50ch;
  margin-inline: auto;
  margin-bottom: 2.25rem;
}

.cta-actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* ─── FOOTER — migrata a css/cobalto.css + partials/footer.html ───── */

/* ─── RESPONSIVE ─────────────────────────────────────────────────────── */
@media (max-width: 900px) {
  .hero-inner        { grid-template-columns: 1fr; }
  .hero-visual       { order: -1; }
  .hero-visual .media-box { height: 260px; }
}

/* ─── SERVICE ANIMATION 01 — WEB DESIGN ─── */

.service-visual-panel[data-visual="1"] .visual-placeholder {
  position: relative;
  background: transparent;
  border: none;
}

.svc-container {
  position: relative;
  width: 460px;
  height: 600px;
  border-radius: 16px;
  overflow: hidden;
}

.seo-container {
  position: relative;
  width: 460px;
  height: 560px;
  border-radius: 16px;
  overflow: hidden;
}

.ads-container {
  position: relative;
  width: 460px;
  height: 560px;
  border-radius: 16px;
  overflow: hidden;
}

.sa01-stage {
  position: absolute;
  inset: 0;
  background: #f8fafc;
  border-radius: 24px;
  overflow: hidden;
}

/* SVG connector lines */
.sa01-svg-lines {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.sa01-line {
  stroke: #cbd5e1;
  stroke-width: 1.5;
  fill: none;
  stroke-linecap: round;
  stroke-dasharray: 85;
  stroke-dashoffset: 85;
}

.sa01-line-2 {
  stroke-dasharray: 50;
  stroke-dashoffset: 50;
}

/* BROWSER */
.sa01-browser {
  position: absolute;
  top: 88px;
  left: 8px;
  width: 140px;
  height: 110px;
  background: #fff;
  border-radius: 7px;
  box-shadow: 0 3px 14px rgba(0,0,0,0.13), 0 0 0 1px rgba(0,0,0,0.06);
  overflow: hidden;
  opacity: 0;
}

.sa01-browser-chrome {
  height: 22px;
  background: #f0f0f0;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 0 8px;
}

.sa01-dots-row {
  display: flex;
  gap: 4px;
  align-items: center;
}

.sa01-dot-r, .sa01-dot-y, .sa01-dot-g {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}
.sa01-dot-r { background: #ff5f57; }
.sa01-dot-y { background: #febc2e; }
.sa01-dot-g { background: #28c840; }

.sa01-url-bar {
  flex: 1;
  height: 9px;
  background: #dde1e7;
  border-radius: 4px;
}

.sa01-browser-content { padding: 8px 7px; }

.sa01-sk-nav {
  height: 6px;
  width: 90%;
  background: #e5e7eb;
  border-radius: 3px;
  opacity: 0;
}

.sa01-sk-hero-block { margin-top: 10px; }

.sa01-sk-line {
  height: 7px;
  background: #e5e7eb;
  border-radius: 3px;
  opacity: 0;
}
.sa01-sk-line--long  { width: 80%; }
.sa01-sk-line--short { width: 50%; margin-top: 5px; }

.sa01-sk-cta {
  width: 44px;
  height: 12px;
  background: #164f96;
  border-radius: 6px;
  margin-top: 8px;
  opacity: 0;
}

/* NOTIFICATION CARDS */
.sa01-notif {
  position: absolute;
  left: 195px;
  width: 128px;
  background: #fff;
  border-radius: 9px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.12), 0 0 0 1px rgba(0,0,0,0.04);
  padding: 7px 8px;
  display: flex;
  align-items: center;
  gap: 5px;
  opacity: 0;
}
.sa01-notif-1 { top: 68px;  }
.sa01-notif-2 { top: 130px; }
.sa01-notif-3 { top: 192px; }

.sa01-status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}
.sa01-status-green  { background: #22c55e; }
.sa01-status-orange { background: #f97316; }

.sa01-notif-icon { font-size: 12px; flex-shrink: 0; line-height: 1; }

.sa01-notif-body {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}
.sa01-notif-body strong {
  font-family: 'Inter', sans-serif;
  font-size: 9.5px;
  font-weight: 700;
  color: #111827;
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sa01-notif-body span {
  font-family: 'Inter', sans-serif;
  font-size: 8px;
  color: #9ca3af;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* CALENDAR */
.sa01-calendar {
  position: absolute;
  bottom: 18px;
  left: 18px;
  right: 18px;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.1), 0 0 0 1px rgba(0,0,0,0.04);
  padding: 10px 12px;
  opacity: 0;
}

.sa01-cal-head {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
  margin-bottom: 6px;
}
.sa01-cal-head span {
  font-family: 'Inter', sans-serif;
  font-size: 9px;
  font-weight: 600;
  color: #9ca3af;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.sa01-cal-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
}

.sa01-cal-cell {
  height: 18px;
  border-radius: 3px;
  background: #f3f4f6;
}
.sa01-cell-blue   { background: rgba(0,120,255,0.15); border: 1px solid rgba(0,120,255,0.4);   transform: scale(0); opacity: 0; }
.sa01-cell-green  { background: rgba(0,180,100,0.15); border: 1px solid rgba(0,180,100,0.4);   transform: scale(0); opacity: 0; }
.sa01-cell-purple { background: rgba(140,80,255,0.15); border: 1px solid rgba(140,80,255,0.4); transform: scale(0); opacity: 0; }

.sa01-cal-tagline {
  font-family: 'Inter', sans-serif;
  font-size: 10px;
  font-weight: 600;
  color: #00f2fe;
  text-align: center;
  margin-top: 8px;
  letter-spacing: 0.03em;
  opacity: 0;
}

/* ── KEYFRAMES ── */
@keyframes sa01-browserIn {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes sa01-fadeUp {
  from { opacity: 0; transform: translateY(5px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes sa01-drawLine { to { stroke-dashoffset: 0; } }
@keyframes sa01-notifIn {
  from { opacity: 0; transform: translateX(8px); }
  to   { opacity: 1; transform: translateX(0); }
}
@keyframes sa01-cellIn {
  from { opacity: 0; transform: scale(0); }
  to   { opacity: 1; transform: scale(1); }
}
@keyframes sa01-fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes sa01-stageOut { to { opacity: 0; } }
@keyframes sa01-pulseGreen {
  0%, 100% { box-shadow: 0 0 0 0 rgba(34,197,94,0.5); }
  50%       { box-shadow: 0 0 0 3px rgba(34,197,94,0); }
}
@keyframes sa01-pulseOrange {
  0%, 100% { box-shadow: 0 0 0 0 rgba(249,115,22,0.5); }
  50%       { box-shadow: 0 0 0 3px rgba(249,115,22,0); }
}

/* ── PHASE 1 ── */
.sa01-phase-1 .sa01-browser         { animation: sa01-browserIn 0.4s ease           forwards; }
.sa01-phase-1 .sa01-sk-nav          { animation: sa01-fadeUp    0.4s ease 0.45s      forwards; }
.sa01-phase-1 .sa01-sk-line--long   { animation: sa01-fadeUp    0.4s ease 0.85s      forwards; }
.sa01-phase-1 .sa01-sk-line--short  { animation: sa01-fadeUp    0.4s ease 1.1s       forwards; }
.sa01-phase-1 .sa01-sk-cta          { animation: sa01-fadeUp    0.4s ease 1.5s       forwards; }

/* ── PHASE 2 ── */
.sa01-phase-2 .sa01-browser  { opacity: 1; }
.sa01-phase-2 .sa01-sk-nav   { opacity: 1; }
.sa01-phase-2 .sa01-sk-line  { opacity: 1; }
.sa01-phase-2 .sa01-sk-cta   { opacity: 1; }

.sa01-phase-2 .sa01-line-1   { animation: sa01-drawLine 0.9s ease          forwards; }
.sa01-phase-2 .sa01-line-2   { animation: sa01-drawLine 0.5s ease 0.3s     forwards; }
.sa01-phase-2 .sa01-line-3   { animation: sa01-drawLine 0.9s ease 0.55s    forwards; }

.sa01-phase-2 .sa01-notif-1  { animation: sa01-notifIn  0.4s ease 0.5s     forwards; }
.sa01-phase-2 .sa01-notif-2  { animation: sa01-notifIn  0.4s ease 1.8s     forwards; }
.sa01-phase-2 .sa01-notif-3  { animation: sa01-notifIn  0.4s ease 3.0s     forwards; }

.sa01-phase-2 .sa01-notif-1 .sa01-status-green  { animation: sa01-pulseGreen  1.5s ease 0.9s infinite; }
.sa01-phase-2 .sa01-notif-2 .sa01-status-orange { animation: sa01-pulseOrange 1.5s ease 2.2s infinite; }
.sa01-phase-2 .sa01-notif-3 .sa01-status-green  { animation: sa01-pulseGreen  1.5s ease 3.4s infinite; }

/* ── PHASE 3 ── */
.sa01-phase-3 .sa01-calendar      { animation: sa01-fadeIn 0.4s ease forwards; }

.sa01-phase-3 .sa01-c0 { animation: sa01-cellIn 0.25s ease 0.10s both; }
.sa01-phase-3 .sa01-c1 { animation: sa01-cellIn 0.25s ease 0.30s both; }
.sa01-phase-3 .sa01-c2 { animation: sa01-cellIn 0.25s ease 0.50s both; }
.sa01-phase-3 .sa01-c3 { animation: sa01-cellIn 0.25s ease 0.70s both; }
.sa01-phase-3 .sa01-c4 { animation: sa01-cellIn 0.25s ease 0.90s both; }
.sa01-phase-3 .sa01-c5 { animation: sa01-cellIn 0.25s ease 1.10s both; }
.sa01-phase-3 .sa01-c6 { animation: sa01-cellIn 0.25s ease 1.30s both; }
.sa01-phase-3 .sa01-c7 { animation: sa01-cellIn 0.25s ease 1.50s both; }
.sa01-phase-3 .sa01-c8 { animation: sa01-cellIn 0.25s ease 1.70s both; }

.sa01-phase-3 .sa01-cal-tagline    { animation: sa01-fadeIn 0.5s ease 2.1s forwards; }

/* ── EXIT ── */
.sa01-stage.sa01-exit { animation: sa01-stageOut 0.4s ease forwards; }

/* ── REDUCED MOTION ── */
@media (prefers-reduced-motion: reduce) {
  .sa01-stage * { animation: none !important; transition: none !important; }
  .sa01-stage.sa01-phase-2 .sa01-browser,
  .sa01-stage.sa01-phase-2 .sa01-sk-nav,
  .sa01-stage.sa01-phase-2 .sa01-sk-line,
  .sa01-stage.sa01-phase-2 .sa01-sk-cta,
  .sa01-stage.sa01-phase-2 .sa01-notif { opacity: 1 !important; transform: none !important; }
  .sa01-stage.sa01-phase-2 .sa01-line  { stroke-dashoffset: 0 !important; }
}

/* ─── IL NOSTRO METODO — TIMELINE (realizzazione-sito-web.html) ────────
   Prefisso "rsw-metodo-" scelto apposta per non toccare .metodo-* più
   sopra in questo stesso file (sezione a card orizzontali di index.html):
   nomi diversi, stesso file, nessuna delle due si sovrascrive.

   Sezione volutamente CHIARA (unica su questa pagina, che è scura
   ovunque altrove): riferimento adpweb.it/sito-web/, "come funziona".
   Sfondo opaco + position:relative/z-index:1 per coprire il canvas
   fisso #rsw-background-aurora dietro a tutte le sezioni della pagina
   (stesso accorgimento già usato per .hp-portfolio, altra sezione
   chiara su questa pagina). .section-label/.section-title/.section-sub
   sono globali e pensati per sfondi scuri: qui sotto scoped a colori
   scuri leggibili, senza toccare le regole globali.

   Nessuna dipendenza esterna: il riempimento della linea (in px) e
   l'accensione dei pallini sono calcolati nello STESSO scroll+rAF
   handler in js/metodo-timeline.js — un pallino si accende quando
   l'altezza corrente della linea raggiunge la sua posizione verticale,
   nessun IntersectionObserver separato. Il markup (numeri, titoli,
   testi, placeholder immagine) è HTML statico già nel DOM al
   caricamento — JS aggiunge solo classi/stili decorativi sopra un
   layout già completo, e imposta via JS solo top/height della linea
   (dipendono dall'altezza reale delle card, non prevedibile in CSS
   puro) — la posizione ORIZZONTALE resta invece pura CSS. */
.rsw-metodo {
  --rsw-metodo-accent: #2563eb;
  position: relative;
  z-index: 1;
  background: #f8fafc;
  padding-block: clamp(5rem, 9vw, 8rem);
}

.rsw-metodo-head {
  text-align: center;
  max-width: 640px;
  margin-inline: auto;
  margin-bottom: clamp(3rem, 6vw, 4.5rem);
}

.rsw-metodo-head .section-title {
  color: var(--deep);
}

.rsw-metodo-head .section-sub {
  color: rgba(11,26,48,0.6);
  margin-inline: auto;
}

.rsw-metodo-timeline {
  position: relative;
  max-width: 980px;
  margin-inline: auto;
}

/* Posizione ORIZZONTALE (50%, centro): pura CSS, stabile perché il
   flex a 3 colonne sotto (testo / linea-col / immagine) è simmetrico
   su ogni step, con o senza --flip. Posizione VERTICALE (top/height):
   impostata via JS in metodo-timeline.js, tra il centro del primo e
   quello dell'ultimo pallino — dipende dall'altezza reale delle card,
   non calcolabile in CSS puro. top:0/bottom:0 qui sotto è solo un
   fallback ragionevole finché JS non gira. */
.rsw-metodo-line {
  position: absolute;
  top: 0;
  bottom: 0;
  left: calc(50% - 1px);
  width: 2px;
  background: rgba(11,26,48,0.12);
  border-radius: 2px;
  overflow: hidden;
}

.rsw-metodo-line-fill {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 0; /* impostata in px da metodo-timeline.js a ogni scroll */
  background: var(--rsw-metodo-accent);
  border-radius: 2px;
}

.rsw-metodo-steps {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: clamp(3rem, 6vw, 5rem);
}

.rsw-metodo-step {
  position: relative;
}

/* Blocco a tre colonne: testo — linea/pallino — immagine. DOM sempre in
   quest'ordine; sugli step pari (.rsw-metodo-step--flip) si alterna SOLO
   visivamente via row-reverse — con 3 elementi, l'elemento centrale
   (la linea/pallino) resta centrale anche invertito, sono solo testo e
   immagine a scambiarsi lato. align-items:stretch (default flex) fa sì
   che .rsw-metodo-line-col si estenda per tutta l'altezza della riga,
   che a sua volta è definita dal blocco più alto (di norma l'immagine):
   è quello che permette al pallino (position:absolute; top:50%) di
   restare centrato sull'immagine invece che allineato in alto. */
.rsw-metodo-content {
  display: flex;
  align-items: stretch;
  gap: clamp(1.75rem, 4vw, 3rem);
  opacity: 0.5;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.rsw-metodo-step--flip .rsw-metodo-content {
  flex-direction: row-reverse;
}

.rsw-metodo-line-col {
  position: relative;
  flex: 0 0 56px;
  width: 56px;
}

.rsw-metodo-marker {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 1;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 1.05rem;
  background: #ffffff;
  border: 1px solid rgba(11,26,48,0.15);
  color: rgba(11,26,48,0.35);
  transition: background 0.4s ease, border-color 0.4s ease, color 0.4s ease,
              transform 0.4s ease, box-shadow 0.4s ease;
}

.rsw-metodo-step.is-active .rsw-metodo-marker {
  background: var(--rsw-metodo-accent);
  border-color: var(--rsw-metodo-accent);
  color: var(--white);
  transform: translate(-50%, -50%) scale(1.1);
  box-shadow: 0 0 0 8px rgba(37,99,235,0.14), 0 8px 20px -4px rgba(37,99,235,0.45);
}

.rsw-metodo-step.is-active .rsw-metodo-content {
  opacity: 1;
  transform: translateY(0);
}

.rsw-metodo-text {
  flex: 1 1 50%;
  min-width: 0;
}

.rsw-metodo-title {
  font-family: var(--font-head);
  font-weight: 800;
  font-size: clamp(1.2rem, 2vw, 1.5rem);
  line-height: 1.3;
  color: var(--deep);
  margin-bottom: 0.6rem;
}

.rsw-metodo-desc {
  font-family: var(--font-body);
  font-size: 0.98rem;
  line-height: 1.7;
  color: rgba(11,26,48,0.62);
}

.rsw-metodo-tagline {
  display: inline-flex;
  align-items: center;
  margin-top: 1rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--rsw-metodo-accent);
  text-decoration: none;
  border-bottom: 1px solid rgba(37,99,235,0.3);
  padding-bottom: 0.2rem;
  transition: border-color 0.2s ease, gap 0.2s ease;
}

.rsw-metodo-tagline:hover {
  border-bottom-color: var(--rsw-metodo-accent);
}

.rsw-metodo-media {
  position: relative;
  flex: 1 1 50%;
  min-width: 0;
}

.metodo-img-placeholder {
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(11,26,48,0.4);
}

.rsw-metodo-badge {
  position: absolute;
  left: 1rem;
  bottom: 1rem;
  background: rgba(11,26,48,0.85);
  color: #ffffff;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.78rem;
  letter-spacing: 0.02em;
  padding: 0.4rem 0.9rem;
  border-radius: 50px;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

@media (max-width: 767px) {
  .rsw-metodo-timeline { max-width: 100%; }

  /* Stessa logica di sempre (linea/pallino colonna centrale, testo e
     immagine ai lati), ma con l'immagine nascosta sotto restano solo
     due colonne visibili: forziamo row-reverse su OGNI step, --flip
     compreso, così il pallino sta sempre a sinistra e il testo sempre
     a destra — un ordine unico e prevedibile, invece di alternare
     lato ad ogni step come su desktop (qui non avrebbe senso: la
     colonna immagine, che decide il lato, è display:none). */
  .rsw-metodo-content,
  .rsw-metodo-step--flip .rsw-metodo-content {
    flex-direction: row-reverse !important;
    gap: 1rem;
  }

  .rsw-metodo-line-col { flex: 0 0 40px; width: 40px; }
  .rsw-metodo-marker { width: 40px; height: 40px; font-size: 0.9rem; }
  .rsw-metodo-line { left: 19px; }

  /* Immagine nascosta di default: non ancora foto reali, sovrapporre
     il testo vero a un box grigio con scritto "[FOTO STEP X]"
     comprometterebbe la leggibilità richiesta. Con foto reali si può
     rivalutare uno sfondo sfumato/scurito dietro alla card di testo. */
  .rsw-metodo-media { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .rsw-metodo-line-fill { height: 100% !important; }
  .rsw-metodo-marker,
  .rsw-metodo-content { transition: none !important; }
  .rsw-metodo-marker {
    background: var(--rsw-metodo-accent) !important;
    border-color: var(--rsw-metodo-accent) !important;
    color: var(--white) !important;
    /* niente "none": il pallino è centrato via position:absolute +
       questo stesso transform, va mantenuto anche disattivando le
       transizioni — solo lo scale(1.1) di stato attivo viene tolto. */
    transform: translate(-50%, -50%) !important;
    box-shadow: none !important;
  }
  .rsw-metodo-content {
    opacity: 1 !important;
    transform: none !important;
  }
}

