@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@300;400;500;600;700;800&family=Space+Grotesk:wght@400;500;600;700&display=swap');

:root {
  --bg: #0b0d12;
  --bg2: #12161d;
  --bg3: #1a1f29;
  --surface: #141922;
  --surface2: #1b212c;
  --border: rgba(255, 255, 255, 0.06);
  --border2: rgba(255, 255, 255, 0.12);
  --gold: #c9a86a;
  --gold-dim: rgba(201, 168, 106, 0.08);
  --gold-mid: rgba(201, 168, 106, 0.16);
  --cyan: #3b82f6; 
  --cyan-dim: rgba(59, 130, 246, 0.1);
  --cyan-mid: rgba(59, 130, 246, 0.2);
  --blue: #6366f1;
  --blue-dim: rgba(99, 102, 241, 0.1);
  --text: #f5f5f5;
  --text2: #b9bec8;
  --text3: #7d8694;
  --mono: 'Space Grotesk', sans-serif;
  --sans: 'Manrope', sans-serif;
}

/* =========================================================
   BASE STYLES & TYPOGRAPHY
   ========================================================= */

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

html { 
  scroll-behavior: smooth;
  scroll-padding-top: 70px;
}

body {
  font-family: var(--sans);
  background-color: var(--bg);
  background-image: radial-gradient(circle at 50% 0%, rgba(201, 168, 106, 0.04) 0%, transparent 70%);
  color: var(--text);
  font-size: 16px;
  line-height: 1.7;
  overflow-x: hidden;
}

/* Remove animated glowing orbs */
body::before, 
body::after {
  display: none;
}

h1 {
  font-family: var(--mono);
  font-size: clamp(3rem, 6vw, 5rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.05em;
  color: var(--text);
  margin-bottom: 0.5rem;
}

h1 span { 
  color: var(--gold); 
}

h2 {
  font-family: var(--mono);
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--text);
}

section { 
  position: relative; 
  z-index: 1; 
}

/* =========================================================
   NAVIGATION
   ========================================================= */

nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  height: 60px;
  background: rgba(11, 13, 18, 0.85);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--border);
}

.nav-logo {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 14px;
  color: var(--gold);
  letter-spacing: 0.05em;
}

.nav-links {
  display: flex;
  gap: 2rem;
  list-style: none;
}

.nav-links a {
  font-family: var(--sans);
  font-weight: 500;
  font-size: 13px;
  color: var(--text2);
  text-decoration: none;
  letter-spacing: 0.03em;
  transition: color 0.2s;
}

.nav-links a:hover { 
  color: var(--gold); 
}

/* =========================================================
   GENERAL SECTIONS
   ========================================================= */

.section-wrap {
  max-width: 1100px;
  margin: 0 auto;
  padding: 5rem 2rem;
}

.section-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 3rem;
}

.section-num {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 11px;
  color: var(--gold);
  letter-spacing: 0.15em;
  opacity: 0.7;
}

.section-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(to right, rgba(201, 168, 106, 0.2), transparent);
}

/* MENU  */
.mobile-menu-btn {
  display: none;
  background: transparent;
  border: none;
  outline: none; /* Rimuove la riga bianca/blu di focus */
  color: var(--text);
  cursor: pointer;
  padding: 0.5rem;
  -webkit-tap-highlight-color: transparent; /* Rimuove l'alone grigio al tocco sugli smartphone */
}

/* Sicurezza extra per forzare la rimozione dell'outline anche quando il bottone è attivo */
.mobile-menu-btn:focus,
.mobile-menu-btn:active {
  outline: none;
  border: none;
}

.mobile-menu-btn svg {
  width: 26px;
  height: 26px;
  display: block;
}

/* =========================================================
   MOBILE RESPONSIVENESS
   ========================================================= */

@media (max-width: 700px) {
  h1 { font-size: clamp(2.6rem, 10vw, 4rem); }
  h2 { font-size: 1.7rem; }
  
  nav { padding: 0 1.5rem; }
  
  .mobile-menu-btn { display: block; }
  
  .nav-links {
    position: absolute;
    top: 60px;
    left: 0;
    right: 0;
    background: rgba(10, 15, 24, 0.95);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    align-items: center;
    padding: 2rem 0;
    gap: 2rem;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-10px);
    transition: all 0.3s ease;
  }
  
  .nav-links.nav-open {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
  }

  .hero-inner { 
    grid-template-columns: 1fr; 
    text-align: center;
    gap: 2rem;
  }
  
  .hero-tag { justify-content: center; }
  .hero-subtitle { margin: 0 auto 1.5rem; }
  .hero-desc { margin: 0 auto 2.5rem; }
  .hero-btns { justify-content: center; }
  
  .hero-stats { 
    justify-content: center; 
    gap: 1.5rem; 
  }
  
  .hero-avatar-wrap { 
    display: flex;
    justify-content: center;
    order: -1; 
    margin-top: 2rem;
  }
  
  .hero-avatar {
    width: 140px; 
    height: 140px;
  }
  
  .avatar-ring {
    inset: -8px; 
  }

  .edu-item { grid-template-columns: 1fr; }
  .edu-item::before { display: none; }
  .edu-date { text-align: left; }
  .edu-content { padding-left: 0; }
  .edu-content::before { display: none; }

  .project-card {
    border-radius: 16px;
  }
}