/* ==========================================================================
   Opscadia — connect.css
   Pagina prodotto/download di Opscadia Connect (tema chiaro, come le legali).
   ========================================================================== */

*,
*::before,
*::after { box-sizing: border-box; }

:root {
  --purple:       #4f46e5;
  --purple-light: #6366f1;
  --indigo:       #4f46e5;
  --text:         #0f0e1a;
  --text-muted:   rgba(15,14,26,0.55);
  --surface:      rgba(0,0,0,0.03);
  --border:       rgba(0,0,0,0.09);
  --amber:        #b45309;
  --amber-bg:     #fff7ed;
  --amber-border: rgba(180,83,9,0.28);
  --container:    1220px;
}

html, body { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }

body {
  min-height: 100vh;
  background: #f7f7f9;
  background-image:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(79,70,229,0.08) 0%, transparent 60%),
    radial-gradient(ellipse 50% 30% at 85% 110%, rgba(79,70,229,0.05) 0%, transparent 55%),
    url("../images/connect/sfondo-connect.avif");
  background-repeat: no-repeat, no-repeat, no-repeat;
  background-position: 50% -10%, 85% 110%, top center;
  background-size: auto, auto, cover;
  background-attachment: fixed;
  color: var(--text);
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

main a { color: var(--purple); text-decoration: none; }
main a:hover { text-decoration: underline; }
button { font: inherit; }

/* ---------- Header light-theme overrides ---------- */
.site-header__inner {
  background: rgba(247,247,249,0.75) !important;
  border: 1px solid rgba(0,0,0,0.08) !important;
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
}
.site-header.is-scrolled .site-header__inner {
  background: rgba(247,247,249,0.9) !important;
  box-shadow: 0 8px 40px rgba(0,0,0,0.08) !important;
}
.site-header__inner .brand__name,
.site-header__inner .nav-link { color: var(--text) !important; }
.site-header__inner .btn--ghost {
  color: var(--text) !important;
  border-color: rgba(0,0,0,0.15) !important;
}
.site-header__inner .btn--ghost:hover { background: rgba(0,0,0,0.05) !important; }
.nav-link:hover { color: var(--text) !important; background: rgba(0,0,0,0.05) !important; }

/* ---------- Layout ---------- */
.cn-main { padding: 6rem 1.25rem 1.5rem; }
.cn-wrap { max-width: var(--container); margin: 0 auto; }

/* ---------- Hero ---------- */
.cn-hero { text-align: center; }
.cn-hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text);
  background: rgba(0,0,0,0.05);
  border: 1px solid rgba(0,0,0,0.12);
  padding: 0.3rem 0.75rem;
  border-radius: 9999px;
}
.cn-hero__title {
  font-size: clamp(2rem, 5vw, 3.1rem);
  font-weight: 800;
  font-style: italic;
  text-transform: uppercase;
  letter-spacing: -0.02em;
  line-height: 1.08;
  margin: 1.1rem 0 0.75rem;
}
.cn-hero__title span {
  display: inline-block;
  padding-right: 0.1em;
  margin-right: -0.1em;
  color: var(--indigo);
}
.cn-hero__sub {
  font-size: 1.075rem;
  color: var(--text-muted);
  max-width: 620px;
  margin: 0 auto;
}

/* ---------- Download card ---------- */
.cn-dl {
  margin: 2.25rem auto 0;
  max-width: 640px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 1.25rem;
  padding: 1.75rem;
  box-shadow: 0 12px 32px rgba(99,102,241,0.07);
  text-align: center;
}
/* Bottone — adattato da Uiverse.io (SendMessage button) */
.cn-dl__btn {
  --primary: #ff5569;
  --neutral-1: #f7f8f7;
  --neutral-2: #e7e7e7;

  cursor: pointer;
  border-radius: 9999px;
  text-decoration: none;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.3);
  border: none;
  box-shadow: 0 0.5px 0.5px 1px rgba(255, 255, 255, 0.2),
    0 10px 20px rgba(0, 0, 0, 0.2), 0 4px 5px 0px rgba(0, 0, 0, 0.05);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  position: relative;
  transition: all 0.3s ease;
  min-width: 260px;
  padding: 1rem 1.75rem;
  font-family: inherit;
  font-size: 1.075rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #2d2d2d;
}
.cn-dl__btn:hover {
  text-decoration: none;
  transform: scale(1.02);
  box-shadow: 0 0 1px 2px rgba(255, 255, 255, 0.3),
    0 15px 30px rgba(0, 0, 0, 0.3), 0 10px 3px -3px rgba(0, 0, 0, 0.04);
}
.cn-dl__btn:active {
  transform: scale(1);
  box-shadow: 0 0 1px 2px rgba(255, 255, 255, 0.3),
    0 10px 3px -3px rgba(0, 0, 0, 0.2);
}
.cn-dl__btn::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  border: 2.5px solid transparent;
  background: linear-gradient(var(--neutral-1), var(--neutral-2)) padding-box,
    linear-gradient(to bottom, rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0.45)) border-box;
  z-index: 0;
  transition: all 0.4s ease;
}
.cn-dl__btn:hover::after {
  transform: scale(1.05, 1.15);
  box-shadow: inset 0 -1px 3px 0 rgba(255, 255, 255, 1);
}
.cn-dl__btn::before {
  content: "";
  position: absolute;
  inset: 5px 5px 5px 5px;
  background: linear-gradient(to top, var(--neutral-1), var(--neutral-2));
  border-radius: 9999px;
  filter: blur(0.5px);
  z-index: 0;
}
.cn-dl__outline {
  position: absolute;
  border-radius: inherit;
  overflow: hidden;
  z-index: 1;
  opacity: 0;
  transition: opacity 0.4s ease;
  inset: -2px -3.5px;
}
.cn-dl__outline::before {
  content: "";
  position: absolute;
  inset: -100%;
  background: conic-gradient(from 180deg, transparent 60%, white 80%, transparent 100%);
  animation: cn-dl-spin 2s linear infinite;
  animation-play-state: paused;
}
@keyframes cn-dl-spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}
.cn-dl__btn:hover .cn-dl__outline { opacity: 1; }
.cn-dl__btn:hover .cn-dl__outline::before { animation-play-state: running; }
.cn-dl__icon {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: scale(1.25);
  transition: transform 0.3s ease;
}
.cn-dl__icon svg { overflow: visible; color: rgba(45, 45, 45, 1); }
.cn-dl__btn:hover .cn-dl__icon { transform: scale(1.05); }
.cn-dl__label {
  position: relative;
  z-index: 2;
  background-image: linear-gradient(135deg, rgba(25, 25, 25, 1), rgba(75, 75, 75, 1));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  transition: transform 0.25s ease;
  user-select: none;
}
.cn-dl__btn:hover .cn-dl__label { transform: scale(0.975); color: transparent; }
.cn-dl__meta {
  margin: 0.85rem 0 0;
  font-size: clamp(0.6rem, 1.9vw, 0.85rem);
  color: var(--text-muted);
  white-space: nowrap;
}
@media (max-width: 480px) {
  .cn-dl__meta { white-space: normal; }
}
.cn-dl__meta strong { color: var(--text); font-weight: 600; }
.cn-dl__meta--crosslink { margin-top: 0.9rem; }
.cn-dl__note {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 0.4rem;
  max-width: 620px;
  margin: 0.6rem auto 0;
  font-size: 0.8125rem;
  line-height: 1.5;
  color: var(--text-muted);
  text-align: left;
}
@media (min-width: 640px) {
  .cn-dl__note { white-space: nowrap; max-width: none; }
}
.cn-dl__note svg { flex: none; margin-top: 0.15rem; }

@media (max-width: 480px) {
  .cn-dl { padding: 1.35rem 1.1rem; }
  .cn-dl__btn { min-width: 0; width: 100%; padding: 0.85rem 1.1rem; gap: 0.4rem; }
  .cn-dl__icon svg { width: 15px; height: 15px; }
  .cn-dl__label { font-size: 0.8rem; line-height: 1.25; }
  .cn-dl__note { font-size: 0.775rem; max-width: 100%; }
}

/* ---------- Sezioni ---------- */
.cn-section { margin-top: 3.25rem; }
.cn-section__title {
  font-size: 1.5rem;
  font-weight: 800;
  font-style: italic;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  margin: 0 0 1.1rem;
  text-align: center;
}
.cn-section__lead {
  color: var(--text-muted);
  margin: -0.5rem auto 1.5rem;
  text-align: center;
  max-width: 620px;
}

/* ---------- Diagramma flusso: card a griglia ---------- */
.cn-flow-grid {
  display: flex;
  align-items: stretch;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1.5rem;
  padding: 0 clamp(0.5rem, 2vw, 1rem);
}
.cn-flow-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.65rem;
  max-width: 240px;
  padding: 1.5rem 1.25rem;
  border-radius: 1.1rem;
  border: 1px solid var(--border);
  background: #ffffff;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.cn-flow-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 28px rgba(99,102,241,0.12);
}
.cn-flow-card--local { border-color: var(--border); }
.cn-flow-card--cloud { border-color: var(--border); }
.cn-flow-card--you    { border-color: var(--border); }
.cn-flow-card__ic-wrap { display: flex; }
.cn-flow-card__ic {
  width: 64px;
  height: 64px;
  border-radius: 9999px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.cn-flow-card__ic--local,
.cn-flow-card__ic--cloud,
.cn-flow-card__ic--you   { color: var(--text); background: transparent; }
.cn-flow-card h3 { margin: 0; font-size: 0.95rem; color: var(--text); }
.cn-flow-card small { display: block; color: var(--text-muted); font-size: 0.775rem; }
.cn-flow-card p {
  margin: 0;
  font-size: 0.825rem;
  line-height: 1.45;
  color: var(--text-muted);
}
.cn-flow__zone {
  display: inline-block;
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 0.2rem 0.55rem;
  border-radius: 9999px;
}
.cn-flow__zone--local,
.cn-flow__zone--cloud,
.cn-flow__zone--you   { color: var(--text-muted); background: rgba(0,0,0,0.06); }
.cn-flow-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  opacity: 0.55;
  flex: 0 0 auto;
}
.cn-card {
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.cn-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 34px rgba(99,102,241,0.14);
}

/* ---------- Card grid ---------- */
.cn-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}
@media (max-width: 860px) {
  .cn-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .cn-grid { grid-template-columns: 1fr; }
}
.cn-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 1rem;
  padding: 1.35rem;
}
.cn-card__ic {
  width: 2.4rem;
  height: 2.4rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.7rem;
  color: var(--text);
  background: rgba(0,0,0,0.05);
  margin-bottom: 0.75rem;
}
.cn-card h3 { font-size: 1.02rem; margin: 0 0 0.35rem; }
.cn-card p { margin: 0; color: var(--text-muted); font-size: 0.925rem; }

/* ---------- Installazione: 4 slide grandi ---------- */
.cn-bento { display: flex; align-items: stretch; gap: 1.25rem; }
.cn-bento__col { display: flex; flex-direction: column; gap: 1.25rem; flex: 1 1 40%; }
.cn-bento__card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 1rem;
  padding: 1.5rem 1.6rem;
  box-shadow: 0 20px 60px rgba(99,102,241,0.08);
  transition: box-shadow 0.25s ease;
}
.cn-bento__card:hover { box-shadow: 0 24px 70px rgba(99,102,241,0.14); }
.cn-bento__card--lg { flex: 1 1 60%; }
.cn-bento__num {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  margin-bottom: 1.1rem;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--purple);
  background: transparent;
  border: 2px solid var(--purple);
  border-radius: 0.7rem;
}
.cn-bento__card h3 { margin: 0 0 0.5rem; font-size: 1.15rem; }
.cn-bento__card p { margin: 0.6rem 0; color: var(--text-muted); }
.cn-bento__card strong { color: var(--text); }
.cn-bento__card ul, .cn-bento__card ol { margin: 0.4rem 0; padding-left: 1.2rem; color: var(--text-muted); }
.cn-bento__card li { margin: 0.25rem 0; }
.cn-bento__card code {
  font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  font-size: 0.85em;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 0.35rem;
  padding: 0.05rem 0.35rem;
}
.cn-bento__img {
  display: block;
  max-width: 320px;
  width: 100%;
  border-radius: 0.6rem;
  border: 1px solid var(--border);
  margin: 0.75rem auto 0;
}
.cn-bento__shots {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin: 0.9rem 0;
}
.cn-bento__shots figure { margin: 0; width: 220px; text-align: center; }
.cn-bento__shots img {
  display: block;
  width: 100%;
  border-radius: 0.6rem;
  border: 1px solid var(--border);
}
.cn-bento__shots figcaption {
  margin-top: 0.4rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}
.cn-bento__ok {
  margin: 0.9rem 0 0;
  padding: 0.9rem 1rem;
  background: rgba(34,197,94,0.08);
  border: 1px solid rgba(34,197,94,0.25);
  border-radius: 0.6rem;
}
.cn-bento__ok b { color: #15803d; }
@media (max-width: 720px) {
  .cn-bento { flex-direction: column; }
  .cn-bento__card--lg { flex: 1 1 auto; }
}

/* ---------- FAQ (stesso modello accordion di pricing.html) ---------- */
.faq__list {
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
}
.faq__item { border-bottom: 1px solid var(--border); }
.faq__item:first-child { border-top: 1px solid var(--border); }
.faq__q {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text);
  padding: 1.125rem 0;
  margin: 0;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  line-height: 1.45;
  list-style: none;
  user-select: none;
}
.faq__q::after {
  content: '';
  flex: none;
  width: 1.25rem;
  height: 1.25rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='rgba(124,58,237,0.6)' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-size: contain;
  background-position: center;
  transition: transform 0.22s ease;
  opacity: 0.7;
}
.faq__item.is-open .faq__q::after { transform: rotate(180deg); opacity: 1; }
.faq__item.is-open .faq__q { color: var(--purple); }

@keyframes faq-open {
  from { opacity: 0; filter: blur(8px); transform: translateY(-5px); }
  to   { opacity: 1; filter: blur(0);   transform: translateY(0); }
}
@keyframes faq-close {
  from { opacity: 1; filter: blur(0);   transform: translateY(0); }
  to   { opacity: 0; filter: blur(8px); transform: translateY(-5px); }
}
.faq__a {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.7;
  margin: 0;
  padding: 0 0 1.25rem;
  display: none;
}
.faq__item.is-open .faq__a {
  display: block;
  animation: faq-open 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}
.faq__item.is-closing .faq__a {
  display: block;
  animation: faq-close 0.22s ease forwards;
}
.faq__a a { color: var(--purple); text-decoration: none; }
.faq__a a:hover { text-decoration: underline; }
.faq__a strong { color: var(--text); font-weight: 600; }
.faq__a code {
  font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  font-size: 0.85em;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 0.35rem;
  padding: 0.05rem 0.35rem;
}

/* ---------- Back link ---------- */
.cn-back { text-align: center; margin-top: 1.5rem; }
.cn-back a {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  color: var(--text);
}
.cn-back a:hover { text-decoration: none; color: var(--purple); }

@media (max-width: 720px) {
  .cn-flow-grid { flex-direction: column; align-items: center; }
  .cn-flow-card { max-width: 320px; width: 100%; }
  .cn-flow-arrow { transform: rotate(90deg); }
}

/* ---------- Footer ----------
   .final-footer è position:absolute in styles.css (pensato per la scena
   finale della home): su una pagina normale va riportato nel flusso, altrimenti
   si ancora all'initial containing block e finisce a metà pagina. */
.final-footer {
  position: static;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 3rem;
  padding: 1.5rem 1.25rem;
  border-top: 1px solid var(--border);
  font-size: 0.8125rem;
  color: var(--text-muted);
}
.final-footer__sep { opacity: 0.5; }
.final-footer__link { color: var(--text-muted); text-decoration: none; transition: color 0.2s; }
.final-footer__link:hover { color: var(--text); text-decoration: none; }
