/* ============================================================
   FONTS
   ============================================================ */
/* dm-sans-300 - latin */
@font-face {
  font-display: swap; /* Check https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display for other options. */
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 300;
  src: url('../fonts/dm-sans-v17-latin-300.woff2') format('woff2'); /* Chrome 36+, Opera 23+, Firefox 39+, Safari 12+, iOS 10+ */
}
/* dm-sans-300italic - latin */
@font-face {
  font-display: swap; /* Check https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display for other options. */
  font-family: 'DM Sans';
  font-style: italic;
  font-weight: 300;
  src: url('../fonts/dm-sans-v17-latin-300italic.woff2') format('woff2'); /* Chrome 36+, Opera 23+, Firefox 39+, Safari 12+, iOS 10+ */
}
/* dm-sans-regular - latin */
@font-face {
  font-display: swap; /* Check https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display for other options. */
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 400;
  src: url('../fonts/dm-sans-v17-latin-regular.woff2') format('woff2'); /* Chrome 36+, Opera 23+, Firefox 39+, Safari 12+, iOS 10+ */
}
/* dm-sans-500 - latin */
@font-face {
  font-display: swap; /* Check https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display for other options. */
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 500;
  src: url('../fonts/dm-sans-v17-latin-500.woff2') format('woff2'); /* Chrome 36+, Opera 23+, Firefox 39+, Safari 12+, iOS 10+ */
}
/* plus-jakarta-sans-regular - latin */
@font-face {
  font-display: swap; /* Check https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display for other options. */
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 400;
  src: url('../fonts/plus-jakarta-sans-v12-latin-regular.woff2') format('woff2'); /* Chrome 36+, Opera 23+, Firefox 39+, Safari 12+, iOS 10+ */
}
/* plus-jakarta-sans-600 - latin */
@font-face {
  font-display: swap; /* Check https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display for other options. */
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 600;
  src: url('../fonts/plus-jakarta-sans-v12-latin-600.woff2') format('woff2'); /* Chrome 36+, Opera 23+, Firefox 39+, Safari 12+, iOS 10+ */
}
/* plus-jakarta-sans-700 - latin */
@font-face {
  font-display: swap; /* Check https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display for other options. */
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 700;
  src: url('../fonts/plus-jakarta-sans-v12-latin-700.woff2') format('woff2'); /* Chrome 36+, Opera 23+, Firefox 39+, Safari 12+, iOS 10+ */
}
/* plus-jakarta-sans-800 - latin */
@font-face {
  font-display: swap; /* Check https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display for other options. */
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 800;
  src: url('../fonts/plus-jakarta-sans-v12-latin-800.woff2') format('woff2'); /* Chrome 36+, Opera 23+, Firefox 39+, Safari 12+, iOS 10+ */
}

/* ============================================================
   RESET
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { min-height: 100vh; }
img, video { max-width: 100%; display: block; }
input, button, textarea, select { font: inherit; }
ul, ol { list-style: none; }
a { text-underline-offset: 4px; }
button { cursor: pointer; border: none; background: none; }

/* ============================================================
   CUSTOM PROPERTIES
   ============================================================ */
:root {
    /* Typography */
    --font-display: 'Plus Jakarta Sans', sans-serif;
    --font-body:    'DM Sans', sans-serif;

    /* Spacing */
    --space-xs:  0.5rem;
    --space-sm:  1rem;
    --space-md:  2rem;
    --space-lg:  4rem;
    --space-xl:  6rem;
    --space-2xl: 9rem;

    /* Misc */
    --radius:    8px;
    --radius-lg: 16px;
    --header-h:  72px;
    --transition: 220ms ease;
    --max-w:     1200px;
}

[data-theme="dark"] {
    /* Colors */
    --clr-bg:            hsl(0, 0%, 15%);
    --clr-bg-modal:      hsla(0, 0%, 0%, 0.8);
    --clr-bg-card:       hsl(0, 0%, 8%);
    --clr-bg-raised:     hsl(0, 0%, 10%);
    --clr-border:        hsl(0, 0%, 24%);

    /* --clr-primary:       #0d6efd;
    --clr-primary-hover: #0b5ed7; */
    --clr-primary:       #2f82ff;
    --clr-primary-hover: #1974fd;
    --clr-link:          #6ea8fe;
    --clr-text:          hsl(0, 0%, 95%);
    --clr-text-bt:       hsl(0, 0%, 100%);
    --clr-text-muted:    hsl(0, 0%, 80%);
    --clr-text-faint:    hsl(0, 0%, 46%);
    --clr-white:         #ffffff;
    --clr-success:       #22c55e;
    --clr-danger:        #e685b5;
}

[data-theme="light"] {
    /* sono da sistemare i colori e tenere allineati con quelli del tema dark */
    --clr-bg:            hsl(0, 0%, 96%);
    --clr-bg-modal:      hsla(0, 0%, 0%, 0.5);
    --clr-bg-card:       hsl(0, 0%, 100%);
    --clr-bg-raised:     hsl(0, 0%, 94%);
    --clr-border:        hsl(0, 0%, 78%);

    --clr-primary:       #2f82ff;
    --clr-primary-hover: #1974fd;
    --clr-link:          #1a5fcc;
    --clr-text:          hsl(0, 0%, 10%);
    --clr-text-bt:       hsl(0, 0%, 100%);
    --clr-text-muted:    hsl(0, 0%, 30%);
    --clr-text-faint:    hsl(0, 0%, 55%);
    --clr-white:         #000000;
    --clr-success:       #16a34a;
    --clr-danger:        #c2185b;
}

/* ============================================================
   BASE
   ============================================================ */
body {
    font-family: var(--font-body);
    font-size: 1rem;
    line-height: 1.7;
    background-color: var(--clr-bg);
    color: var(--clr-text);
}

.container {
    width: 100%;
    max-width: var(--max-w);
    margin-inline: auto;
    padding-inline: 1.5rem;
}

h1, h2, h3, h4, h5 {
    font-family: var(--font-display);
    line-height: 1.15;
    color: var(--clr-white);
}

p { color: var(--clr-text); }
a { color: var(--clr-link); }
a:hover { color: var(--clr-white); }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.75rem;
    border-radius: var(--radius);
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 0.95rem;
    letter-spacing: 0.02em;
    white-space: nowrap;
}
.btn {text-decoration: none;}
.btn-primary {background-color: var(--clr-primary);color:var(--clr-text-bt);}
.btn-primary:hover, a.btn-primary:hover {background-color: var(--clr-primary-hover);color:var(--clr-text-bt);}
.btn-outline {border: 1px solid var(--clr-primary);color: var(--clr-text-muted);}
.btn-outline:hover, a.btn-outline:hover {background-color: var(--clr-primary);color: var(--clr-text-bt);}

.btn-ghost {
    color: var(--clr-text-muted);
    text-decoration: underline;
    text-underline-offset: 3px;
    padding-inline: 0;
}
.btn-ghost:hover { color: var(--clr-white); }

/* ============================================================
   HEADER
   ============================================================ */
.site-header {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: var(--header-h);
    z-index: 900;
    background-color: var(--clr-bg-raised);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--clr-border);
}

.header-inner {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--clr-white);
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.2rem;
    text-decoration: none;
}
.logo:hover { color: var(--clr-link); }
.logo-mark {
    color: var(--clr-link);
    font-size: 1.4rem;
}

.main-nav ul {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.main-nav a {
    color: var(--clr-text-muted);
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 0.9rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    transition: color var(--transition);
    text-decoration: none;
}
.main-nav a:hover,
.main-nav a.active {
    color: var(--clr-link);
}

.menu-toggle {
    display: none;
    color: var(--clr-text);
    font-size: 1.4rem;
    padding: 0.25rem;
}

/* Mobile nav */
@media (max-width: 768px) {
    .menu-toggle { display: flex; }

    .main-nav {
        display: none;
        position: fixed;
        inset: var(--header-h) 0 0 0;
        background-color: var(--clr-bg);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        z-index: 800;
    }
    .main-nav.is-open { display: flex; }

    .main-nav ul {
        flex-direction: column;
        gap: 2.5rem;
        text-align: center;
    }
    .main-nav a { font-size: 1.5rem; }
}

/* ============================================================
   MAIN
   ============================================================ */
main { padding: var(--header-h); }

/* ============================================================
   SECTIONS — generic spacing
   ============================================================ */
.section {
    padding-block: var(--space-xl);
}
.section-sm { padding-block: var(--space-lg); }

.section-label {
    display: inline-block;
    font-family: var(--font-display);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--clr-link);
    margin-bottom: 1rem;
}

.section-title {
    font-size: clamp(1.8rem, 4vw, 3rem);
    margin-bottom: 1.25rem;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--clr-text-muted);
    max-width: 600px;
}

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer {
    border-top: 1px solid var(--clr-border);
    background-color: var(--clr-bg);
}

.footer-inner {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 2rem;
    padding-block: var(--space-lg);
}

.footer-col h4 {
    font-size: 0.85rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--clr-link);
    margin-bottom: 1rem;
}

.footer-col ul { display: flex; flex-direction: column; gap: 0.5rem; }
.footer-col ul a { color: var(--clr-text-muted); font-size: 0.9rem; text-decoration: none;}
.footer-col ul a:hover { color: var(--clr-white); }
.footer-tagline { color: var(--clr-text-muted); font-size: 0.9rem; margin-top: 0.5rem; }

.footer-bottom {
    border-top: 1px solid var(--clr-border);
    padding-block: 1.25rem;
    text-align: center;
}
.footer-bottom p { font-size: 0.85rem; color: var(--clr-text-faint); }

@media (max-width: 768px) {
    .footer-inner { grid-template-columns: 1fr; }
}

/* ============================================================
   PROTECTED EMAIL
   ============================================================ */
.protected-email { cursor: pointer; }


