:root {
  --ink: #171b18;
  --muted: #777d77;
  --paper: #eee8dc;
  --paper-2: #dcd2c0;
  --accent: #b34d3e;
  --green: #84a98c;
  --line: #bdb4a5;
  --night: #090b0a;
  --night-2: #111512;
  --panel: #171b18;
  --glow: #9bc4a2;
  --shadow: 0 24px 70px rgba(0, 0, 0, .58);
}

* {
  box-sizing: border-box
}

html {
  scroll-behavior: smooth
}

body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 18% 14%, rgba(132, 169, 140, .12), transparent 28%),
    radial-gradient(circle at 82% 8%, rgba(179, 77, 62, .08), transparent 24%),
    linear-gradient(145deg, var(--night), #0e120f 55%, #070908);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

a {
  color: inherit;
  text-decoration: none
}

button,
input,
textarea {
  font: inherit
}

.shell {
  min-height: 100vh;
  padding: 28px
}

.site-frame {
  max-width: 1180px;
  margin: 0 auto;
  background: rgba(20, 24, 21, .98);
  border: 1px solid rgba(155, 196, 162, .16);
  box-shadow: var(--shadow);
  position: relative;
}

.site-frame:before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: linear-gradient(rgba(255, 255, 255, .018) 1px, transparent 1px);
  background-size: 100% 28px
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 16px 24px;
  border-bottom: 1px solid rgba(155, 196, 162, .18);
  background: rgba(9, 11, 10, .88);
  backdrop-filter: blur(16px)
}

.brand {
  font-family: "Courier New", monospace;
  font-weight: 800;
  letter-spacing: .05em;
  color: #f0eee8
}

.brand small {
  display: block;
  color: var(--muted);
  font-weight: 400;
  font-size: .72rem;
  margin-top: 2px
}

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

.nav a {
  padding: 8px 10px;
  border: 1px solid transparent;
  font-family: "Courier New", monospace;
  font-size: .88rem;
  color: #c7cdc8
}

.nav a:hover,
.nav a.active {
  border-color: rgba(155, 196, 162, .55);
  background: rgba(155, 196, 162, .08);
  color: #eef5ef
}

.page {
  padding: 54px 48px 64px;
  position: relative;
  z-index: 1;
  background: linear-gradient(180deg, rgba(255, 255, 255, .01), transparent)
}

.eyebrow {
  font-family: "Courier New", monospace;
  text-transform: uppercase;
  letter-spacing: .14em;
  color: #65716a;
  font-size: .78rem
}

h1,
h2,
h3 {
  font-family: Georgia, "Times New Roman", serif;
  margin: 0 0 18px
}

h1 {
  font-size: clamp(2.6rem, 6vw, 5.8rem);
  line-height: .95;
  max-width: 850px
}

h2 {
  font-size: clamp(2rem, 4vw, 3.8rem)
}

h3 {
  font-size: 1.55rem
}

.lead {
  font-size: 1.18rem;
  line-height: 1.7;
  max-width: 760px;
  color: #353732
}

.hero {
  min-height: 68vh;
  display: grid;
  grid-template-columns: 1.35fr .65fr;
  gap: 44px;
  align-items: center;
  color: #070908
}

.hero-folder {
  background: linear-gradient(145deg, #725a35, #4b3b24);
  min-height: 430px;
  padding: 42px;
  position: relative;
  border-radius: 3px 18px 8px 4px;
  box-shadow: 0 28px 45px rgba(67, 48, 26, .25);
  transform: rotate(-1.2deg)
}

.hero-folder:before {
  content: "";
  position: absolute;
  top: -22px;
  left: 40px;
  width: 180px;
  height: 36px;
  background: #725a35;
  border-radius: 8px 8px 0 0
}

.hero-paper {
  background: #eee8dc;
  padding: 42px;
  min-height: 100%;
  border: 1px solid rgba(48, 42, 34, .25);
  box-shadow: 0 6px 15px rgba(0, 0, 0, .12);
  position: relative
}

.stamp {
  display: inline-block;
  border: 3px solid var(--accent);
  color: var(--accent);
  padding: 8px 12px;
  font-family: "Courier New", monospace;
  font-weight: 800;
  transform: rotate(-7deg);
  margin: 12px 0 28px
}

.cta-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 28px
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 18px;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: #fff;
  font-family: "Courier New", monospace;
  font-weight: 700
}

.btn.secondary {
  background: transparent;
  color: var(--ink)
}

.note-card {
  background: #c8b77f;
  padding: 20px;
  transform: rotate(2deg);
  box-shadow: 0 10px 22px rgba(0, 0, 0, .12);
  font-family: "Courier New", monospace;
  line-height: 1.5
}

.grid {
  display: grid;
  gap: 24px
}

.grid.two {
  grid-template-columns: repeat(2, minmax(0, 1fr))
}

.grid.three {
  grid-template-columns: repeat(3, minmax(0, 1fr))
}

.card {
  background: linear-gradient(180deg, rgba(238, 232, 220, .98), rgba(222, 214, 200, .98));
  border: 1px solid #a69c8d;
  padding: 26px;
  box-shadow: 0 14px 28px rgba(0, 0, 0, .24)
}

.type {
  font-family: "Courier New", monospace
}

.profile-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 40px;
  align-items: start
}

.photo-placeholder {
  aspect-ratio: 4/5;
  background: linear-gradient(145deg, #31332f, #76786f);
  display: grid;
  place-items: center;
  color: #f5f2ea;
  font-family: "Courier New", monospace;
  border: 12px solid #f8f4ea;
  box-shadow: 0 10px 25px rgba(0, 0, 0, .18);
  transform: rotate(2deg)
}

.data-list {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 12px 18px;
  margin-top: 24px
}

.data-list dt {
  font-family: "Courier New", monospace;
  font-weight: 800
}

.data-list dd {
  margin: 0;
  color: #3c3e39
}

.cat-card {
  position: relative;
  padding-top: 0;
  overflow: hidden
}

.cat-photo {
  height: 240px;
  background: linear-gradient(135deg, #777, #d8d0c1);
  display: grid;
  place-items: center;
  font-family: "Courier New", monospace
}

.cat-card .content {
  padding: 24px
}

.badge {
  display: inline-block;
  padding: 5px 9px;
  border: 1px solid var(--ink);
  font-family: "Courier New", monospace;
  font-size: .75rem;
  margin-bottom: 12px
}

.progress {
  height: 12px;
  border: 1px solid var(--ink);
  background: #f6f2e8
}

.progress>span {
  display: block;
  height: 100%;
  background: var(--ink)
}

.skill {
  display: grid;
  grid-template-columns: 170px 1fr 48px;
  gap: 16px;
  align-items: center;
  margin: 16px 0
}

.timeline {
  border-left: 2px solid var(--ink);
  padding-left: 28px
}

.event {
  position: relative;
  padding: 0 0 30px
}

.event:before {
  content: "";
  position: absolute;
  left: -36px;
  top: 4px;
  width: 14px;
  height: 14px;
  background: var(--paper);
  border: 2px solid var(--ink);
  border-radius: 50%
}

.event strong {
  font-family: "Courier New", monospace
}

.faq details {
  border-top: 1px solid var(--line);
  padding: 18px 0
}

.faq details:last-child {
  border-bottom: 1px solid var(--line)
}

.faq summary {
  cursor: pointer;
  font-family: "Courier New", monospace;
  font-weight: 800
}

.faq p {
  color: #4b4d47
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 12px
}

.shot {
  min-height: 200px;
  background: linear-gradient(145deg, #595d58, #c1b7a7);
  border: 8px solid #faf7ef;
  box-shadow: 0 8px 18px rgba(0, 0, 0, .12);
  display: grid;
  place-items: center;
  font-family: "Courier New", monospace;
  color: white
}

.shot:nth-child(1) {
  grid-column: span 7
}

.shot:nth-child(2) {
  grid-column: span 5
}

.shot:nth-child(3),
.shot:nth-child(4),
.shot:nth-child(5) {
  grid-column: span 4
}

.map {
  min-height: 380px;
  border: 1px solid var(--line);
  background: radial-gradient(circle at 40% 40%, rgba(125, 145, 123, .35), transparent 25%), linear-gradient(#eee8dc, #d7d1c4);
  display: grid;
  place-items: center;
  font-family: "Courier New", monospace;
  position: relative;
  overflow: hidden
}

.map:after {
  content: "Mappa dei risultati";
  position: absolute;
  bottom: 18px;
  right: 18px;
  background: #ece0bd;
  padding: 12px 16px;
  transform: rotate(-2deg)
}

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

.stat {
  background: #fbf8f0;
  border: 1px solid var(--line);
  padding: 22px
}

.stat b {
  display: block;
  font-family: Georgia, serif;
  font-size: 2.2rem;
  margin-top: 10px
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding: 18px 24px;
  border-top: 1px solid rgba(155, 196, 162, .16);
  font-family: "Courier New", monospace;
  font-size: .8rem;
  color: #7f8881;
  background: #0b0e0c
}

@media(max-width:900px) {

  .hero,
  .profile-layout,
  .grid.two,
  .grid.three {
    grid-template-columns: 1fr
  }

  .nav {
    display: none
  }

  .page {
    padding: 38px 22px
  }

  .hero-folder {
    padding: 20px
  }

  .hero-paper {
    padding: 28px
  }

  .stats {
    grid-template-columns: 1fr 1fr
  }

  .photo-grid {
    grid-template-columns: 1fr
  }

  .shot,
  .shot:nth-child(n) {
    grid-column: auto
  }

  .data-list {
    grid-template-columns: 1fr
  }

  .skill {
    grid-template-columns: 1fr
  }

  .topbar {
    padding: 14px 18px
  }
}

@media(max-width:560px) {
  .shell {
    padding: 0
  }

  .site-frame {
    border: 0
  }

  .stats {
    grid-template-columns: 1fr
  }

  .hero-folder {
    transform: none;
    border-radius: 0
  }

  .page {
    padding: 28px 18px
  }

  .hero {
    min-height: auto
  }

  .hero-paper {
    padding: 24px
  }

  h1 {
    font-size: 2.8rem
  }
}

.profile-note {
    margin-top: 3rem;
    padding: 1rem 1.25rem;
    border-left: 3px solid var(--accent);
    background: rgba(255,255,255,.03);
    color: var(--text-muted);
    font-size: .95rem;
    font-style: italic;
}

.profile-note strong {
    color: var(--text);
    font-style: normal;
}

/* Dark dossier refinement */
.page:not(.hero) {
  background: linear-gradient(180deg, #eee8dc 0%, #e7dfd1 100%);
  color: var(--ink)
}

.page:not(.hero)::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(rgba(31, 35, 31, .028) 1px, transparent 1px);
  background-size: 100% 29px;
  mix-blend-mode: multiply
}

.page:not(.hero)>* {
  position: relative;
  z-index: 1
}

.hero .lead {
  color: #343732
}

.hero aside {
  filter: drop-shadow(0 16px 24px rgba(0, 0, 0, .38))
}

.btn {
  box-shadow: 0 8px 18px rgba(0, 0, 0, .18)
}

.btn.secondary {
  background: rgba(255, 255, 255, .18)
}

.card:hover {
  transform: translateY(-2px);
  transition: .2s ease;
  box-shadow: 0 18px 36px rgba(0, 0, 0, .28)
}

.photo-placeholder,
.shot {
  box-shadow: 0 14px 28px rgba(0, 0, 0, .28)
}

.badge {
  background: rgba(255, 255, 255, .32)
}

.footer span:last-child {
  color: #8ca893
}

@media(max-width:560px) {
  .shell {
    background: #090b0a
  }
}

.origins-section,
.dna-curiosities {
    margin-top: 60px;
}

.section-intro {
    margin-bottom: 32px;
    opacity: .72;
}

.origin-results {
    display: grid;
    gap: 26px;
}

.origin-row {
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(255,255,255,.08);
}

.origin-label {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 10px;
}

.origin-label span {
    font-family: monospace;
}

.origin-bar {
    width: 100%;
    height: 8px;
    overflow: hidden;
    border-radius: 999px;
    background: rgba(255,255,255,.08);
}

.origin-bar span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: var(--accent);
}

.origin-detail {
    margin-top: 12px;
    font-size: .9rem;
    opacity: .65;
    line-height: 1.6;
}

.dna-map {
    overflow: hidden;
}

.dna-map img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.origins-comment {
    margin-top: 34px;
}

.dna-accordion {
    display: grid;
    gap: 12px;
    margin-top: 34px;
}

.dna-accordion details {
    border: 1px solid rgba(255,255,255,.08);
    background: rgba(255,255,255,.025);
    border-radius: 8px;
}

.dna-accordion summary {
    cursor: pointer;
    padding: 18px 20px;
    font-weight: 700;
    list-style: none;
}

.dna-accordion summary::-webkit-details-marker {
    display: none;
}

.dna-accordion summary::after {
    content: "+";
    float: right;
    opacity: .55;
}

.dna-accordion details[open] summary::after {
    content: "−";
}

.details-content {
    padding: 0 20px 20px;
    line-height: 1.75;
}

.details-content p:last-child {
    margin-bottom: 0;
}

.dna-summary {
    margin-top: 42px;
    padding: 28px;
    border: 1px solid rgba(255,255,255,.08);
    background: rgba(255,255,255,.025);
}

.origins-layout{
    display:grid;
    grid-template-columns: 1.2fr .8fr;
    gap:2rem;
    align-items:start;
}

/* =========================================================
   LANDING PAGE TEMPORANEA
   ========================================================= */

.landing-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.65fr) 300px;
    gap: 48px;
    align-items: center;
    overflow: hidden;
}

.landing-hero > * {
    min-width: 0;
}

.landing-hero aside {
    width: 100%;
    max-width: 300px;
    min-width: 0;
    padding: 8px;
    margin-top: 30px;
}

.landing-hero aside .note-card,
.landing-hero aside .card {
    width: 100%;
    max-width: 100%;
}

.landing-hero aside .note-card {
    transform: rotate(1deg);
    transform-origin: center;
}

.landing-hero aside .card {
    transform: rotate(-1deg);
    transform-origin: center;
}

.landing-build {
    margin-top: 30px;
    padding-top: 18px;
    border-top: 1px solid rgba(23, 27, 24, .18);
    font-family: "Courier New", monospace;
    font-size: .82rem;
    line-height: 1.6;
    color: #575b55;
}

.landing-build strong {
    color: var(--ink);
}

.landing-progress {
    display: inline-block;
    margin: 6px 0 2px;
    letter-spacing: .05em;
}


/* Tablet */

@media (max-width: 900px) {

    .landing-hero {
        grid-template-columns: 1fr;
        gap: 34px;
        overflow: visible;
    }

    .landing-hero aside {
        max-width: 100%;
        margin-top: 0;
        padding: 0 8px 8px;
    }

    .landing-hero aside .note-card {
        transform: rotate(1deg);
    }

    .landing-hero aside .card {
        transform: rotate(-.5deg);
    }

}


/* Smartphone */

@media (max-width: 560px) {

    .landing-hero {
        gap: 26px;
    }

    .landing-hero aside {
        padding: 0;
    }

    .landing-hero aside .note-card,
    .landing-hero aside .card {
        transform: none;
    }

}