/* ============================================================
   Rotaract Club Capo d'Orlando — Stylesheet
   Palette ispirata al brand Rotary/Rotaract (blu reale, azzurro,
   oro, magenta). I colori sono variabili: modificali qui sotto.
   ============================================================ */

:root {
  /* Brand — colori del logo ufficiale Rotaract Capo d'Orlando (ciliegia #D81B5B) */
  --royal: #A81049;     /* ciliegia scuro — colore primario (titoli, pulsanti, link) */
  --azure: #D81B5B;     /* ciliegia — colore brand */
  --sky: #F2609A;       /* rosa soft — accenti/focus */
  --gold: #F7A81B;      /* oro Rotary — accento */
  --cranberry: #D81B5B; /* ciliegia — accento */

  /* Neutri (caldi, in tono col brand) */
  --ink: #24101B;
  --muted: #7A6570;
  --bg: #ffffff;
  --surface: #FCF4F7;
  --surface-2: #F7E7EE;
  --border: #F0DBE5;
  --white: #ffffff;

  /* Gradienti */
  --grad-brand: linear-gradient(120deg, #A81049 0%, #D81B5B 52%, #F2609A 115%);
  --grad-hero: radial-gradient(1200px 700px at 80% -10%, rgba(242,96,154,.28), transparent 60%),
               radial-gradient(900px 600px at 6% 8%, rgba(247,168,27,.16), transparent 55%),
               linear-gradient(180deg, #2A0A1C 0%, #6E0F3A 52%, #A81049 100%);

  /* Misure */
  --maxw: 1140px;
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 18px 40px -18px rgba(16, 46, 100, .30);
  --shadow-soft: 0 10px 30px -16px rgba(16, 46, 100, .28);
  --header-h: 72px;

  --font-head: 'Poppins', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
}

/* ---------- Reset di base ---------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { font-family: var(--font-head); line-height: 1.12; margin: 0 0 .5em; letter-spacing: -.02em; }
h1 { font-size: clamp(2.2rem, 5.2vw, 3.6rem); font-weight: 700; }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.5rem); font-weight: 700; }
h3 { font-size: 1.2rem; font-weight: 600; }
p { margin: 0 0 1rem; }

.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: 22px; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 200;
  background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 10px;
  transition: top .2s ease;
}
.skip-link:focus { top: 12px; }

:focus-visible { outline: 3px solid var(--sky); outline-offset: 2px; border-radius: 6px; }

/* ---------- Bottoni ---------- */
.btn {
  --btn-bg: var(--royal);
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  font-family: var(--font-head); font-weight: 600; font-size: 1rem;
  padding: 13px 26px; border-radius: 999px; border: 2px solid transparent;
  cursor: pointer; transition: transform .18s ease, box-shadow .18s ease, background .18s ease, color .18s ease;
  background: var(--btn-bg); color: #fff; white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 14px 26px -12px rgba(16,46,100,.55); }
.btn:active { transform: translateY(0); }
.btn-sm { padding: 9px 18px; font-size: .92rem; }
.btn-block { width: 100%; }
.btn-accent { --btn-bg: var(--gold); color: #1c1300; }
.btn-accent:hover { box-shadow: 0 14px 26px -12px rgba(247,168,27,.65); }
.btn-ghost { background: transparent; border-color: rgba(255,255,255,.55); color: #fff; }
.btn-ghost:hover { background: rgba(255,255,255,.12); box-shadow: none; }

.grad-text {
  background: linear-gradient(100deg, var(--gold), var(--cranberry));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255,.82);
  backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); }
.brand { display: inline-flex; align-items: center; gap: 12px; }
.brand-logo { height: 46px; width: auto; display: block; }
@media (max-width: 560px) { .brand-logo { height: 38px; } }
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-text strong { font-family: var(--font-head); font-weight: 700; font-size: 1.05rem; color: var(--ink); }
.brand-text small { font-size: .78rem; color: var(--muted); letter-spacing: .04em; text-transform: uppercase; }

.nav-menu { list-style: none; display: flex; align-items: center; gap: 6px; margin: 0; padding: 0; }
.nav-menu a { font-weight: 500; color: var(--ink); padding: 9px 14px; border-radius: 10px; transition: background .15s, color .15s; }
.nav-menu a:not(.btn):hover, .nav-menu a.active:not(.btn) { background: var(--surface-2); color: var(--royal); }
.nav-cta { color: #1c1300 !important; }
.nav-cta:hover { background: var(--gold) !important; }

.nav-toggle {
  display: none; flex-direction: column; gap: 5px; width: 44px; height: 44px;
  border: 1px solid var(--border); border-radius: 12px; background: #fff; cursor: pointer;
  align-items: center; justify-content: center;
}
.nav-toggle span { width: 22px; height: 2px; background: var(--ink); border-radius: 2px; transition: transform .25s, opacity .2s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero { position: relative; color: #fff; overflow: hidden; background: var(--grad-hero); }
.hero-bg { position: absolute; inset: 0; overflow: hidden; }
.blob { position: absolute; border-radius: 50%; filter: blur(46px); opacity: .55; }
.blob-1 { width: 420px; height: 420px; background: var(--sky); top: -120px; right: -80px; }
.blob-2 { width: 360px; height: 360px; background: var(--cranberry); bottom: -140px; left: -60px; opacity: .45; }
.blob-3 { width: 260px; height: 260px; background: var(--gold); top: 40%; right: 30%; opacity: .18; }
.hero-inner { position: relative; padding-top: clamp(64px, 11vh, 128px); padding-bottom: clamp(56px, 9vh, 104px); max-width: 860px; }
.eyebrow {
  display: inline-block; font-family: var(--font-head); font-weight: 600; font-size: .82rem;
  letter-spacing: .08em; text-transform: uppercase; color: #FFD7E6;
  border: 1px solid rgba(255,255,255,.30); padding: 7px 15px; border-radius: 999px; margin-bottom: 22px;
}
.hero h1 { color: #fff; margin-bottom: .35em; }
.hero .lead { font-size: clamp(1.05rem, 2.1vw, 1.32rem); color: #F6D9E6; max-width: 640px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 30px; }

.hero-stats {
  list-style: none; display: flex; flex-wrap: wrap; gap: clamp(24px, 6vw, 64px);
  margin: 52px 0 0; padding: 26px 0 0; border-top: 1px solid rgba(255,255,255,.16);
}
.hero-stats li { display: flex; flex-direction: column; }
.hero-stats .num { font-family: var(--font-head); font-weight: 800; font-size: clamp(1.9rem, 4vw, 2.6rem); color: var(--gold); }
.hero-stats small { color: #F2CFDF; font-size: .9rem; letter-spacing: .02em; }

/* ---------- Sezioni generiche ---------- */
.section { padding: clamp(64px, 10vh, 112px) 0; }
.section-alt { background: var(--surface); }
.section-head { max-width: 660px; margin: 0 auto clamp(38px, 6vh, 62px); text-align: center; }
.section-eyebrow {
  font-family: var(--font-head); font-weight: 600; font-size: .8rem; letter-spacing: .1em;
  text-transform: uppercase; color: var(--cranberry); margin-bottom: 10px;
}
.section-sub { color: var(--muted); font-size: 1.05rem; }

/* Layout a due colonne */
.two-col { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(32px, 5vw, 72px); align-items: center; }
.col-text .motto {
  margin-top: 22px; padding-left: 18px; border-left: 4px solid var(--gold);
  font-family: var(--font-head); font-style: italic; color: var(--royal); font-weight: 500;
}

.col-cards { display: grid; gap: 16px; }
.value-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 22px 24px; box-shadow: var(--shadow-soft); transition: transform .2s, box-shadow .2s;
}
.value-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.value-ico { font-size: 1.7rem; display: inline-block; margin-bottom: 8px; }
.value-card h3 { margin-bottom: 4px; color: var(--royal); }
.value-card p { margin: 0; color: var(--muted); font-size: .96rem; }

/* Aree di impegno */
.focus-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.focus-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 28px 24px; box-shadow: var(--shadow-soft); position: relative; overflow: hidden;
  transition: transform .2s, box-shadow .2s;
}
.focus-card::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 4px; background: var(--grad-brand); }
.focus-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.focus-ico {
  display: inline-flex; align-items: center; justify-content: center; width: 54px; height: 54px;
  border-radius: 14px; background: var(--surface-2); font-size: 1.5rem; margin-bottom: 14px;
}
.focus-card h3 { color: var(--royal); }
.focus-card p { margin: 0; color: var(--muted); font-size: .95rem; }

/* Attività */
.activities-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.activity-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow-soft); transition: transform .22s, box-shadow .22s;
  display: flex; flex-direction: column;
}
.activity-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.activity-media { position: relative; aspect-ratio: 4 / 3; overflow: hidden; }
.activity-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.activity-card:hover .activity-media img { transform: scale(1.05); }
.activity-tag {
  position: absolute; top: 12px; left: 12px; background: rgba(255,255,255,.92); color: var(--royal);
  font-family: var(--font-head); font-weight: 600; font-size: .74rem; letter-spacing: .03em;
  padding: 5px 12px; border-radius: 999px; backdrop-filter: blur(4px);
}
.activity-body { padding: 20px 22px 24px; }
.activity-body time { font-size: .82rem; font-weight: 600; color: var(--cranberry); text-transform: uppercase; letter-spacing: .04em; }
.activity-body h3 { margin: 6px 0 8px; color: var(--ink); }
.activity-body p { margin: 0; color: var(--muted); font-size: .95rem; }

/* Direttivo */
.team-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.team-card {
  margin: 0; background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 26px; display: flex; align-items: center; gap: 16px; box-shadow: var(--shadow-soft);
  transition: transform .2s, box-shadow .2s;
}
.team-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.avatar {
  flex: 0 0 auto; width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center;
  background: var(--grad-brand); color: #fff; font-family: var(--font-head); font-weight: 700; font-size: 1rem;
}
.team-card figcaption { display: flex; flex-direction: column; }
.team-card figcaption strong { font-family: var(--font-head); color: var(--ink); }
.team-card figcaption span { color: var(--muted); font-size: .9rem; }

/* Newsletter */
.newsletter { background: var(--grad-brand); color: #fff; }
.newsletter-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 32px; flex-wrap: wrap;
  padding-top: clamp(40px, 7vh, 72px); padding-bottom: clamp(40px, 7vh, 72px);
}
.newsletter-text { max-width: 460px; }
.newsletter-text h2 { color: #fff; margin-bottom: .2em; }
.newsletter-text p { margin: 0; color: #eaf1ff; }
.newsletter-form { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; position: relative; }
.newsletter-form input[type="email"] {
  min-width: 260px; flex: 1; padding: 14px 18px; border-radius: 999px; border: 2px solid transparent;
  font: inherit; background: rgba(255,255,255,.95); color: var(--ink);
}
.newsletter-form input[type="email"]:focus { outline: none; border-color: var(--gold); }

/* Contatti */
.contact-cols { align-items: start; }
.contact-list { list-style: none; margin: 24px 0 26px; padding: 0; display: grid; gap: 16px; }
.contact-list li { display: flex; gap: 14px; align-items: flex-start; }
.contact-ico {
  flex: 0 0 auto; width: 44px; height: 44px; border-radius: 12px; background: var(--surface-2);
  display: grid; place-items: center; font-size: 1.2rem;
}
.contact-list small { display: block; color: var(--muted); font-size: .82rem; text-transform: uppercase; letter-spacing: .04em; }
.contact-list a, .contact-list span { color: var(--ink); font-weight: 500; }
.contact-list a:hover { color: var(--royal); }
.socials { display: flex; gap: 12px; flex-wrap: wrap; }
.social {
  font-family: var(--font-head); font-weight: 600; font-size: .9rem; color: var(--royal);
  border: 1px solid var(--border); padding: 9px 18px; border-radius: 999px; transition: all .15s;
}
.social:hover { background: var(--royal); color: #fff; border-color: var(--royal); }

.contact-form-wrap {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: clamp(24px, 4vw, 38px); box-shadow: var(--shadow);
}
.contact-form-wrap h3 { color: var(--royal); font-size: 1.4rem; margin-bottom: 18px; }
.field { display: flex; flex-direction: column; margin-bottom: 16px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field label { font-size: .9rem; font-weight: 600; margin-bottom: 6px; color: var(--ink); }
.field input, .field textarea {
  font: inherit; padding: 12px 15px; border: 1.5px solid var(--border); border-radius: var(--radius-sm);
  background: var(--surface); color: var(--ink); transition: border-color .15s, background .15s;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--azure); background: #fff; }
.field textarea { resize: vertical; min-height: 120px; }
.field-check { flex-direction: row; align-items: flex-start; gap: 10px; }
.field-check input { margin-top: 4px; }
.field-check label { font-weight: 400; font-size: .88rem; color: var(--muted); margin: 0; }

/* honeypot nascosto */
.hp { position: absolute; left: -9999px; opacity: 0; height: 0; width: 0; }

.form-status { width: 100%; margin: 12px 0 0; font-size: .92rem; font-weight: 500; min-height: 1.2em; }
.form-status.ok { color: #0a7d3c; }
.form-status.err { color: #c62a2a; }
.newsletter .form-status.ok { color: #eafff2; }
.newsletter .form-status.err { color: #ffe0e0; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: #E9D4DE; padding-top: 48px; }
.footer-inner { display: flex; justify-content: space-between; gap: 30px; flex-wrap: wrap; padding-bottom: 30px; border-bottom: 1px solid rgba(255,255,255,.1); }
.footer-brand { display: flex; gap: 14px; align-items: center; }
.footer-brand img { height: 40px; width: auto; }
.footer-brand strong { font-family: var(--font-head); color: #fff; display: block; }
.footer-brand p { margin: 2px 0 0; font-size: .9rem; color: #C9A9B8; }
.footer-nav { display: flex; flex-wrap: wrap; gap: 8px 20px; align-items: center; }
.footer-nav a { color: #E9D4DE; font-weight: 500; }
.footer-nav a:hover { color: var(--gold); }
.footer-bottom { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding-top: 20px; padding-bottom: 30px; font-size: .84rem; color: #B695A5; }
.footer-bottom p { margin: 0; }

/* ---------- Animazioni allo scroll ---------- */
[data-animate] { opacity: 0; transform: translateY(22px); transition: opacity .6s ease, transform .6s ease; }
[data-animate].in { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .nav-toggle { display: inline-flex; }
  .nav-menu {
    position: fixed; inset: var(--header-h) 0 auto 0; flex-direction: column; align-items: stretch;
    gap: 4px; background: #fff; padding: 16px 22px 24px; border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow); transform: translateY(-140%); transition: transform .3s ease; z-index: 90;
  }
  .nav-menu.open { transform: translateY(0); }
  .nav-menu a { padding: 12px 14px; }
  .nav-cta { text-align: center; margin-top: 6px; }

  .two-col { grid-template-columns: 1fr; }
  .focus-grid { grid-template-columns: repeat(2, 1fr); }
  .activities-grid { grid-template-columns: repeat(2, 1fr); }
  .team-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 560px) {
  .focus-grid, .activities-grid, .team-grid { grid-template-columns: 1fr; }
  .field-row { grid-template-columns: 1fr; }
  .hero-stats { gap: 22px; }
  .newsletter-form input[type="email"] { min-width: 100%; }
  .newsletter-form .btn { width: 100%; }
}

/* Rispetta chi preferisce meno animazioni */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  [data-animate] { opacity: 1; transform: none; transition: none; }
  .btn:hover, .value-card:hover, .focus-card:hover, .activity-card:hover, .team-card:hover { transform: none; }
  .activity-card:hover .activity-media img { transform: none; }
}
