@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@500;600;700&family=DM+Sans:ital,wght@0,400;0,500;0,700;1,400&display=swap');

/* ===== VARIABILI ===== */
:root {
  --bg-primary: #07071a;
  --bg-secondary: #0f0f2e;
  --accent-purple: #6c63ff;
  --accent-indigo: #4f46e5;
  --accent-blue: #3b82f6;
  --text-primary: #f0f0ff;
  --text-secondary: #a0a0c0;
  --card-overlay: rgba(79, 70, 229, 0.45);
  --glass-bg: rgba(255, 255, 255, 0.05);
  --glass-border: rgba(255, 255, 255, 0.10);
}

/* ===== RESET ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background:
    radial-gradient(circle at 15% 20%, rgba(108, 99, 255, 0.25), transparent 38%),
    radial-gradient(circle at 80% 10%, rgba(59, 130, 246, 0.2), transparent 35%),
    linear-gradient(145deg, var(--bg-primary), #090924 45%, var(--bg-secondary));
  color: var(--text-primary);
  font-family: 'DM Sans', sans-serif;
  min-height: 100vh;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }

/* ===== NAVBAR ===== */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  padding: 10px 0;
  pointer-events: none;
  transition: padding 0.35s ease;
}

.navbar-inner {
  width: calc(100% - 20px);
  margin: 0 auto;
  padding: 16px clamp(18px, 4vw, 54px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  pointer-events: auto;
  backdrop-filter: blur(20px);
  border: 1px solid transparent;
  border-bottom-color: rgba(255, 255, 255, 0.1);
  background: rgba(7, 7, 26, 0.48);
  border-radius: 999px;
  transition:
    width 0.45s cubic-bezier(0.2, 0.75, 0.22, 1),
    padding 0.45s cubic-bezier(0.2, 0.75, 0.22, 1),
    border-color 0.45s ease,
    background 0.45s ease,
    box-shadow 0.45s ease;
}

.navbar.compact { padding: 8px 0; }

.navbar.compact .navbar-inner {
  width: min(1080px, calc(100% - 34px));
  padding: 10px 18px;
  background: rgba(6, 10, 35, 0.82);
  border-color: rgba(255, 255, 255, 0.16);
  box-shadow: 0 18px 40px rgba(2, 4, 22, 0.42);
}

.brand {
  font-family: 'Cormorant Garamond', serif;
  font-size: 2rem;
  letter-spacing: 0.04em;
  transition: font-size 0.35s ease;
}

.navbar.compact .brand { font-size: 1.65rem; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
}

.nav-links a {
  color: var(--text-secondary);
  font-size: 0.95rem;
  transition: color 0.3s ease, transform 0.3s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text-primary);
  transform: translateY(-2px);
}

.language-switcher {
  position: relative;
  margin-left: 12px;
  padding-left: 12px;
  border-left: 1px solid var(--glass-border);
}

.lang-dropdown-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  background: transparent;
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  padding: 6px 10px;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.9rem;
  color: var(--text-primary);
  transition: border-color 0.2s, background 0.2s;
  white-space: nowrap;
}

.lang-dropdown-btn:hover {
  border-color: rgba(255,255,255,0.3);
  background: var(--glass-bg);
}

.lang-dropdown-btn .flag { font-size: 1.2rem; line-height: 1; }
.lang-dropdown-btn .arrow { font-size: 0.6rem; color: var(--text-secondary); transition: transform 0.2s; }
.lang-dropdown-btn.open .arrow { transform: rotate(180deg); }

.lang-dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background: rgba(10, 10, 35, 0.96);
  border: 1px solid var(--glass-border);
  border-radius: 10px;
  overflow: hidden;
  backdrop-filter: blur(16px);
  box-shadow: 0 12px 32px rgba(0,0,0,0.4);
  min-width: 130px;
  z-index: 200;
}

.lang-dropdown-menu.open { display: block; }

.lang-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  cursor: pointer;
  font-size: 0.9rem;
  color: var(--text-secondary);
  transition: background 0.15s, color 0.15s;
  border: none;
  background: none;
  width: 100%;
  font-family: inherit;
  text-align: left;
}

.lang-option:hover { background: var(--glass-bg); color: var(--text-primary); }
.lang-option.active { color: var(--text-primary); font-weight: 600; }
.lang-option .flag { font-size: 1.2rem; }

.menu-btn {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 1.4rem;
  cursor: pointer;
}

/* ===== HERO (HOME) ===== */
.hero {
  position: relative;
  height: 100vh;
  display: grid;
  place-items: center;
  padding: 100px 20px 40px;
  overflow: hidden;
}

.aurora {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 20% 30%, rgba(108, 99, 255, 0.45), transparent 40%),
    radial-gradient(ellipse at 78% 12%, rgba(79, 70, 229, 0.35), transparent 36%),
    radial-gradient(ellipse at 55% 80%, rgba(59, 130, 246, 0.28), transparent 40%);
  filter: blur(8px);
  animation: drift 12s ease-in-out infinite alternate;
}

@keyframes drift {
  from { transform: scale(1) translateY(0); }
  to   { transform: scale(1.1) translateY(-20px); }
}

.hero-content {
  position: relative;
  max-width: 900px;
  text-align: center;
  z-index: 1;
}

.hero h1 {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2.5rem, 6vw, 5.5rem);
  line-height: 0.96;
  margin: 0;
}

.hero p {
  color: var(--text-secondary);
  font-size: clamp(1rem, 2.2vw, 1.25rem);
  max-width: 680px;
  margin: 20px auto 0;
}

.countup {
  margin-top: 22px;
  color: #d4d4ff;
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.scroll-arrow {
  display: inline-block;
  margin-top: 34px;
  font-size: 1.8rem;
  animation: bounce 2s ease infinite;
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(8px); }
}

/* ===== SEZIONE PROTAGONISTE (MARQUEE) ===== */
.protagoniste {
  padding: 90px 0;
  overflow: hidden;
}

.section-inner {
  width: min(1200px, 92vw);
  margin: 0 auto;
}

.section-title {
  margin: 0 0 22px;
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2.1rem, 4vw, 3.5rem);
}

.marquee-wrap { overflow: hidden; }

.marquee-track {
  display: flex;
  gap: 18px;
  width: max-content;
  animation: marquee 72s linear infinite;
}

.marquee-wrap:hover .marquee-track { animation-play-state: paused; }

@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* ===== CARD SCIENZIATA (MARQUEE) ===== */
.card-scienziata {
  width: 430px;
  min-height: 610px;
  border-radius: 20px;
  overflow: hidden;
  position: relative;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(10px);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  flex-shrink: 0;
  cursor: pointer;
}

.card-scienziata:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 60px rgba(108, 99, 255, 0.3);
}

.card-scienziata img {
  width: 100%;
  height: 500px;
  object-fit: cover;
  object-position: top;
  filter: grayscale(1) saturate(0) contrast(1.05);
  transition: filter 0.45s ease;
}

.card-scienziata:hover img {
  filter: grayscale(0) saturate(1) contrast(1);
}

.card-overlay {
  position: absolute;
  inset: 0;
  background: var(--card-overlay);
  mix-blend-mode: multiply;
  transition: background 0.3s ease;
}

.card-scienziata:hover .card-overlay { background: rgba(124, 58, 237, 0.6); }

.card-info {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 18px;
  background: linear-gradient(transparent, rgba(7, 7, 26, 0.95));
}

.card-title { margin: 0; font-size: 1.35rem; }
.card-meta { margin: 6px 0; color: var(--text-secondary); font-size: 0.95rem; }

.badge {
  display: inline-block;
  margin-top: 10px;
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.24);
}

/* ===== PAGINA ESPLORA (GRIGLIA) ===== */
.pagina-esplora {
  width: min(1400px, 100%);
  margin: 0 auto;
  padding: 110px min(4vw, 44px) 80px;
}

.esplora-header { display: flex; flex-direction: column; gap: 14px; }

.esplora-titolo {
  margin: 0;
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-size: clamp(2.3rem, 5vw, 4.4rem);
}

.esplora-sottotitolo { color: rgba(160, 160, 192, 0.92); margin: 0; font-size: 1rem; }

.barra-ricerca { width: 100%; max-width: 620px; position: relative; }

.barra-ricerca input {
  width: 100%;
  padding: 14px 48px 14px 44px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  backdrop-filter: blur(12px);
  color: #f0f0ff;
  font-size: 0.95rem;
  font-family: 'DM Sans', sans-serif;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.barra-ricerca input:focus {
  border-color: rgba(108, 99, 255, 0.6);
  box-shadow: 0 0 0 3px rgba(108, 99, 255, 0.15);
}

.barra-ricerca input::placeholder { color: rgba(160, 160, 192, 0.6); }

.barra-ricerca__icona {
  position: absolute;
  left: 14px; top: 50%;
  transform: translateY(-50%);
  color: rgba(160, 160, 192, 0.6);
  pointer-events: none;
}

.barra-ricerca__clear {
  position: absolute;
  right: 14px; top: 50%;
  transform: translateY(-50%);
  background: none; border: none;
  color: rgba(160, 160, 192, 0.6);
  cursor: pointer; padding: 4px; border-radius: 4px;
  font-size: 1.1rem; line-height: 1;
  transition: color 0.2s;
}
.barra-ricerca__clear:hover { color: #f0f0ff; }

.filtri-disciplina { display: flex; gap: 8px; flex-wrap: wrap; }

.filtri-disciplina__pill {
  padding: 7px 16px;
  border-radius: 100px;
  font-size: 0.78rem; font-weight: 600; letter-spacing: 0.05em;
  cursor: pointer; font-family: inherit;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  color: rgba(160, 160, 192, 0.9);
  transition: all 0.2s ease;
  white-space: nowrap;
}

.filtri-disciplina__pill:hover {
  border-color: rgba(108, 99, 255, 0.4);
  color: #f0f0ff;
  background: rgba(108, 99, 255, 0.08);
}

.filtri-disciplina__pill--attiva {
  background: #6c63ff;
  border-color: #6c63ff;
  color: #fff;
  box-shadow: 0 0 20px rgba(108, 99, 255, 0.3);
}

.esplora-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 2px;
  color: rgba(225, 225, 245, 0.88);
  gap: 14px;
}

.ordina-select {
  padding: 8px 12px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #f0f0ff;
  font-family: inherit;
  font-size: 0.9rem;
  cursor: pointer;
}

/* ===== GRIGLIA ESPLORA ===== */
.griglia-esplora {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  padding: 40px 0 80px;
}

.card-esplora {
  border-radius: 16px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(12px);
  cursor: pointer;
  display: flex; flex-direction: column;
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.35s ease, border-color 0.35s ease;
  text-decoration: none;
}

.card-esplora:hover {
  transform: translateY(-10px) scale(1.01);
  box-shadow: 0 30px 80px rgba(108, 99, 255, 0.2), 0 0 0 1px rgba(108, 99, 255, 0.35);
  border-color: rgba(108, 99, 255, 0.4);
}

.card-esplora__immagine-wrap {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
}

.card-esplora__immagine {
  width: 100%; height: 100%;
  object-fit: cover; object-position: top;
  filter: grayscale(100%);
  transition: filter 0.5s ease, transform 0.5s ease;
}

.card-esplora:hover .card-esplora__immagine {
  filter: grayscale(60%) sepia(15%);
  transform: scale(1.04);
}

.card-esplora__overlay {
  position: absolute; inset: 0;
  mix-blend-mode: color;
  transition: opacity 0.4s ease;
  opacity: 0.35;
}

.card-esplora:hover .card-esplora__overlay { opacity: 0.5; }

.card-esplora__separatore {
  height: 1px;
  background: rgba(255, 255, 255, 0.07);
  margin: 0; border: none;
}

.card-esplora__body {
  padding: 16px 18px 20px;
  display: flex; flex-direction: column;
  gap: 6px; flex: 1;
}

.card-esplora__pill {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 0.68rem; font-weight: 700;
  letter-spacing: 0.09em; text-transform: uppercase;
  padding: 3px 10px; border-radius: 100px;
  width: fit-content;
}

.card-esplora__nome {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.45rem; font-weight: 700;
  color: #f0f0ff; line-height: 1.2;
  margin: 4px 0 0;
}

.card-esplora__anni {
  font-family: ui-monospace, monospace;
  font-size: 0.72rem;
  color: rgba(160, 160, 192, 0.7);
  letter-spacing: 0.05em;
}

.card-esplora__nazionalita {
  font-size: 0.78rem;
  color: rgba(160, 160, 192, 0.8);
}

.card-esplora__descrizione {
  font-size: 0.83rem;
  color: rgba(160, 160, 192, 0.85);
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
  margin-top: 4px;
}

.card-esplora__cta {
  margin-top: 14px;
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 0.78rem; font-weight: 700;
  color: #6c63ff;
  letter-spacing: 0.04em;
  transition: gap 0.2s ease, color 0.2s ease;
  width: fit-content;
}

.card-esplora:hover .card-esplora__cta { gap: 10px; color: #8b85ff; }

.stato-vuoto {
  grid-column: 1 / -1;
  display: flex; flex-direction: column;
  align-items: center; gap: 16px;
  padding: 80px 20px; text-align: center;
  color: rgba(160, 160, 192, 0.6);
}

/* ===== PROFILO SCIENZIATA ===== */
.profilo-page {
  width: 100%;
  background: linear-gradient(180deg, #f6f7fb 0%, #fff 100%);
  min-height: 100vh;
}

.profilo-hero {
  position: relative;
  height: 100vh;
  overflow: hidden;
}

.profilo-hero img {
  width: 100%; height: 100%;
  object-fit: cover; object-position: top;
}

.profilo-hero__overlay {
  position: absolute; inset: 0;
  background: linear-gradient(rgba(0, 0, 0, 0.45), rgba(0, 0, 0, 0.75));
  display: flex; flex-direction: column;
  justify-content: center; align-items: center;
  text-align: center; padding: 20px; color: white;
}

.profilo-hero__title {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2.5rem, 10vw, 5.5rem);
  margin-bottom: 20px; font-weight: 700; line-height: 1.1;
}

.profilo-hero__tagline {
  max-width: 700px;
  font-size: 1.3rem; font-style: italic; opacity: 0.95;
}

/* Container con 2 colonne: timeline sx, contenuto dx */
.profilo-container {
  width: min(1400px, 90%);
  margin: 0 auto;
}

.profilo-info-card {
  margin-top: -80px;
  background: white;
  border-radius: 25px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  overflow: hidden;
  position: relative; z-index: 10;
  margin-bottom: 60px;
}

.profilo-info-box {
  padding: 30px; text-align: center;
  border-right: 1px solid rgba(0, 0, 0, 0.05);
}
.profilo-info-box:last-child { border-right: none; }

.profilo-info-box h3 {
  color: #6c63ff; margin-bottom: 10px;
  font-size: 0.95rem; text-transform: uppercase;
  letter-spacing: 0.06em; font-weight: 600;
}

.profilo-info-box p { color: #1e1e2f; font-size: 1.15rem; font-weight: 500; }

/* Layout: TIMELINE SINISTRA + CONTENUTO DESTRA */
.profilo-corpo {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 60px;
  padding-bottom: 80px;
}

/* Sidebar Timeline */
.profilo-sidebar {
  position: sticky;
  top: 100px;
  height: fit-content;
}

.profilo-timeline {
  background: white;
  border-radius: 20px;
  padding: 30px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

.profilo-timeline h3 {
  font-size: 0.95rem; font-weight: 600;
  color: #1e1e2f; margin: 0 0 25px;
  text-transform: uppercase; letter-spacing: 0.06em;
}

.profilo-timeline__items {
  position: relative;
  padding-left: 20px;
}

.profilo-timeline__items::before {
  content: '';
  position: absolute; left: 0; top: 0; bottom: 0;
  width: 2px;
  background: linear-gradient(180deg, #6c63ff, rgba(108, 99, 255, 0.2));
}

.profilo-timeline__item {
  margin-bottom: 30px;
  position: relative; display: flex; gap: 15px;
}
.profilo-timeline__item:last-child { margin-bottom: 0; }

.profilo-timeline__dot {
  position: absolute; left: -15px; top: 2px;
  width: 12px; height: 12px;
  background: #6c63ff; border-radius: 50%;
  border: 3px solid white;
  box-shadow: 0 0 0 2px #6c63ff;
}

.profilo-timeline__content { flex: 1; padding-left: 10px; }
.profilo-timeline__year { font-weight: 600; color: #6c63ff; font-size: 0.95rem; }
.profilo-timeline__content p { margin: 4px 0 0; color: #666; font-size: 0.9rem; }

/* Contenuto biografia */
.profilo-articolo {
  display: flex; flex-direction: column; gap: 0;
}

.profilo-sezione {
  padding: 50px 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}
.profilo-sezione:first-child { padding-top: 0; }
.profilo-sezione:last-child { border-bottom: none; }

.profilo-sezione__header { margin-bottom: 30px; }
.profilo-sezione__header h2 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 2.2rem; color: #1e1e2f; margin-bottom: 6px;
}
.profilo-sezione__header p { color: #888; font-size: 0.95rem; }

.profilo-bio {
  background: white; border-radius: 20px;
  padding: 40px; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.07);
}

.profilo-bio__content {
  color: #1e1e2f; line-height: 1.85; font-size: 1.05rem;
}
.profilo-bio__content p { margin-bottom: 18px; }
.profilo-bio__content p:last-child { margin-bottom: 0; }
.profilo-bio__content strong { color: #1e1e2f; font-weight: 600; }
.profilo-bio__content ul { padding-left: 28px; margin: 16px 0; }
.profilo-bio__content li { margin-bottom: 10px; line-height: 1.7; }

/* Badge Nobel */
.nobel-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: linear-gradient(135deg, rgba(108,99,255,0.1), rgba(79,70,229,0.15));
  border: 1px solid rgba(108, 99, 255, 0.35);
  border-radius: 999px;
  padding: 10px 20px;
  font-size: 0.9rem; font-weight: 600;
  color: #4f46e5; margin-bottom: 28px;
  width: fit-content;
}

/* Scienziate correlate */
.profilo-correlate {
  padding: 50px 0 0;
}

.profilo-correlate h2 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 2rem; color: #1e1e2f; margin-bottom: 24px;
}

.profilo-correlate__griglia {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.card-correlata {
  background: #f8f9ff;
  border: 1px solid rgba(108, 99, 255, 0.12);
  border-radius: 16px; overflow: hidden;
  transition: transform 0.3s, box-shadow 0.3s;
  text-decoration: none; color: inherit;
  display: block;
}

.card-correlata:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 32px rgba(108, 99, 255, 0.15);
}

.card-correlata img {
  width: 100%; height: 180px;
  object-fit: cover; object-position: top;
  filter: grayscale(40%);
  transition: filter 0.4s;
}
.card-correlata:hover img { filter: grayscale(0); }

.card-correlata__body { padding: 16px; }
.card-correlata__disc {
  font-size: 0.72rem; font-weight: 700;
  color: #6c63ff; text-transform: uppercase;
  letter-spacing: 0.08em; margin-bottom: 6px;
}
.card-correlata h3 { color: #1e1e2f; font-size: 1.1rem; margin-bottom: 4px; }
.card-correlata p { color: #888; font-size: 0.85rem; line-height: 1.5; }

/* Back link */
.profilo-back-link {
  display: inline-block;
  margin-top: 30px; padding: 14px 28px;
  background: #6c63ff; color: white;
  border-radius: 25px; font-weight: 600;
  transition: all 0.3s ease;
  border: 2px solid #6c63ff;
}

.profilo-back-link:hover {
  background: transparent;
  color: #6c63ff;
}

/* ===== FOOTER ===== */
.site-footer {
  padding: 32px;
  text-align: center;
  color: var(--text-secondary);
  font-size: 0.9rem;
  border-top: 1px solid var(--glass-border);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1100px) {
  .griglia-esplora { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 900px) {
  .navbar-inner { width: calc(100% - 12px); padding: 12px 14px; }
  .navbar.compact .navbar-inner { width: calc(100% - 12px); border-radius: 16px; }
  .nav-links {
    position: absolute; top: 60px; right: 0;
    display: none; flex-direction: column;
    width: min(280px, calc(100vw - 40px));
    background: rgba(7, 7, 26, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px; padding: 14px;
    align-items: flex-start;
  }
  .nav-links.open { display: flex; }
  .menu-btn { display: block; }

  .profilo-corpo { grid-template-columns: 1fr; gap: 40px; }
  .profilo-sidebar { position: static; }
  .profilo-correlate__griglia { grid-template-columns: repeat(2, 1fr); }
  .griglia-esplora { grid-template-columns: repeat(2, 1fr); gap: 16px; }
}

@media (max-width: 640px) {
  .profilo-hero__title { font-size: 2.5rem; }
  .profilo-container { width: 100%; padding: 0 16px; }
  .profilo-info-card { grid-template-columns: 1fr; margin-top: -50px; border-radius: 0; }
  .profilo-info-box { border-right: none; border-bottom: 1px solid rgba(0,0,0,.05); padding: 20px 24px; }
  .profilo-info-box:last-child { border-bottom: none; }
  .profilo-bio { padding: 24px; border-radius: 0; }
  .profilo-timeline { border-radius: 0; }
  .profilo-correlate__griglia { grid-template-columns: 1fr; }
  .griglia-esplora { grid-template-columns: 1fr; }
  .filtri-disciplina { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 8px; }
  .esplora-meta { flex-direction: column; align-items: flex-start; }
}

/* ===== CITAZIONE HERO ===== */
.profilo-hero__citazione {
  font-size: clamp(1rem, 2vw, 1.3rem);
  font-style: italic;
  color: rgba(255,255,255,0.85);
  max-width: 680px;
  margin-bottom: 10px;
  line-height: 1.6;
}

/* ===== CURIOSITÀ ===== */
.curiosita-list {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.curiosita-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  background: #f8f9ff;
  border: 1px solid rgba(108, 99, 255, 0.1);
  border-radius: 14px;
  padding: 18px 20px;
  font-size: 0.97rem;
  color: #2a2a4a;
  line-height: 1.6;
  transition: transform 0.2s, box-shadow 0.2s;
}

.curiosita-item:hover {
  transform: translateX(4px);
  box-shadow: 0 4px 20px rgba(108, 99, 255, 0.1);
}

.curiosita-icon {
  font-size: 1.2rem;
  flex-shrink: 0;
  margin-top: 1px;
}

/* ===== ANIMAZIONI DI ENTRATA (card griglia) ===== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(32px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* card animation ora gestita inline via JS */

/* ===== TEMA CHIARO ===== */
[data-theme="light"] {
  --bg-primary: #f4f4fb;
  --bg-secondary: #e8e8f5;
  --text-primary: #1e1e2f;
  --text-secondary: #5a5a7a;
  --glass-bg: rgba(0,0,0,0.04);
  --glass-border: rgba(0,0,0,0.1);
}

[data-theme="light"] body {
  background: linear-gradient(145deg, #f0f0fa, #e8e8f8 45%, #ededf8);
}

[data-theme="light"] .hero {
  background: linear-gradient(145deg, #e8e8fb, #dcdcf5);
}

[data-theme="light"] .navbar-inner {
  background: rgba(240,240,250,0.85);
  border-color: rgba(0,0,0,0.08);
}

[data-theme="light"] .aurora {
  opacity: 0.35;
}

/* ===== HERO LOGO ===== */
.hero-logo {
  max-width: min(700px, 90vw);
  height: auto;
  margin: 0 auto 16px;
  display: block;
  filter: drop-shadow(0 0 40px rgba(108,99,255,0.4));
}

/* ===== CTA SECTION ===== */
.cta-section {
  padding: 60px 0 100px;
  text-align: center;
}

.cta-btn {
  display: inline-block;
  padding: 16px 36px;
  background: var(--accent-purple, #6c63ff);
  color: #fff;
  border-radius: 999px;
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  transition: opacity 0.2s, transform 0.2s;
}

.cta-btn:hover { opacity: 0.85; transform: translateY(-2px); }

/* ===== IMPOSTAZIONI PAGE ===== */
.impostazioni-page {
  min-height: 100vh;
  padding: 120px 20px 80px;
}

.impostazioni-container {
  max-width: 680px;
  margin: 0 auto;
}

.impostazioni-container h1 {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  margin-bottom: 8px;
}

.impostazioni-sub {
  color: var(--text-secondary);
  margin-bottom: 48px;
}

.sett-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  padding: 28px 32px;
  margin-bottom: 20px;
}

.sett-card__header h2 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 4px;
}

.sett-card__header p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-bottom: 20px;
}

/* Tema */
.theme-options { display: flex; gap: 12px; }

.theme-btn {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  background: var(--glass-bg); border: 2px solid var(--glass-border);
  border-radius: 14px; padding: 14px 24px;
  cursor: pointer; font-family: inherit; font-size: 0.9rem;
  color: var(--text-primary); transition: all 0.2s;
}

.theme-btn.active { border-color: var(--accent-purple, #6c63ff); box-shadow: 0 0 0 3px rgba(108,99,255,0.2); }

.theme-preview { display: block; width: 48px; height: 32px; border-radius: 8px; }
.theme-preview--dark  { background: linear-gradient(135deg, #07071a, #1a1a3e); }
.theme-preview--light { background: linear-gradient(135deg, #f0f0fa, #e8e8f8); border: 1px solid #ddd; }

/* Lingua */
.lang-options { display: flex; gap: 12px; }

.lang-card-btn {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  background: var(--glass-bg); border: 2px solid var(--glass-border);
  border-radius: 14px; padding: 16px 28px;
  cursor: pointer; font-family: inherit; font-size: 0.9rem;
  color: var(--text-primary); transition: all 0.2s;
}

.lang-card-btn:hover { border-color: var(--accent-purple, #6c63ff); }

/* Colori */
.color-options { display: flex; gap: 10px; flex-wrap: wrap; }

.color-btn {
  width: 40px; height: 40px; border-radius: 50%;
  border: 3px solid transparent; cursor: pointer;
  transition: transform 0.2s, border-color 0.2s;
}

.color-btn:hover { transform: scale(1.15); }
.color-btn.active { border-color: white; box-shadow: 0 0 0 2px var(--accent-purple, #6c63ff); }

/* Font size */
.font-options { display: flex; gap: 10px; }

.font-btn {
  background: var(--glass-bg); border: 2px solid var(--glass-border);
  border-radius: 10px; padding: 10px 20px;
  cursor: pointer; font-family: inherit;
  color: var(--text-primary); transition: all 0.2s;
}

.font-btn.active { border-color: var(--accent-purple, #6c63ff); background: rgba(108,99,255,0.1); }

/* Reset */
.sett-card--reset { text-align: center; }

.reset-btn {
  background: transparent;
  border: 1px solid rgba(239,68,68,0.4);
  color: #ef4444; border-radius: 10px;
  padding: 12px 28px; cursor: pointer;
  font-family: inherit; font-size: 0.9rem;
  transition: all 0.2s;
}

.reset-btn:hover { background: rgba(239,68,68,0.08); }

/* ===== RIMUOVI FOOTER ===== */
.site-footer { display: none; }

/* ===== ANIMAZIONE CARD — delay inline ===== */
.card-esplora {
  opacity: 0;
  animation: fadeInUp 0.45s ease forwards;
  /* il delay viene messo inline via JS */
}

/* ===== NAV LOGO (icona) ===== */
.brand { display: flex; align-items: center; }

.nav-logo {
  height: 36px;
  width: auto;
  display: block;
  transition: opacity 0.2s, transform 0.3s;
  filter: drop-shadow(0 0 6px rgba(108,99,255,0.5));
}

.nav-logo:hover {
  opacity: 0.8;
  transform: rotate(30deg);
}

.navbar.compact .nav-logo { height: 30px; }
