
:root{
  --pico-border-radius: 18px;
}

header.container { padding-top: 1.25rem; }
.brand { text-decoration:none; letter-spacing:.2px; }

.hero {
  position: relative;
  overflow: hidden;
  padding: 1.5rem 1.5rem;
  border: 1px solid var(--pico-muted-border-color);
  border-radius: var(--pico-border-radius);
  background: radial-gradient(1200px 400px at 20% 0%, rgba(0,0,0,.06), transparent 60%),
              radial-gradient(900px 400px at 80% 30%, rgba(0,0,0,.05), transparent 60%);
}

.hero h1 { margin-bottom: .4rem; }
.hero p { max-width: 70ch; }

.grid.cards{
  display:grid;
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
  gap: 1.1rem;
  margin-top: 1rem;
}

.card{
  border: 1px solid var(--pico-muted-border-color);
  border-radius: var(--pico-border-radius);
  padding: 1rem;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0,0,0,.05);
}

.card .cover{
  display:block;
  height: 190px;
  border-radius: calc(var(--pico-border-radius) - 6px);
  background-size: cover;
  background-position: center;
  margin-bottom: .85rem;
}

.muted{ opacity:.72; }
.tags{ display:flex; flex-wrap:wrap; gap:.45rem; }

.tag{
  border: 1px solid var(--pico-muted-border-color);
  border-radius: 999px;
  padding: .2rem .6rem;
  text-decoration:none;
  font-size: .92rem;
}

/* ================= TYPOGRAPHY UPGRADE ================= */

.prose {
  max-width: 760px;
  margin: 0 auto;
  font-size: 1.15rem;
  line-height: 1.85;
  letter-spacing: 0.2px;
  text-align: justify;
}

.prose p {
  margin-bottom: 1.6rem;
}

.prose h1 {
  font-size: 2.6rem;
  font-weight: 600;
  margin-bottom: 1.2rem;
  line-height: 1.2;
  text-align: left;
}

.prose img {
  margin: 2.2rem auto;
  display: block;
  border-radius: 14px;
}

/* Migliora leggibilità su schermi grandi */
@media (min-width: 1200px) {
  .prose {
    font-size: 1.2rem;
  }
}

.footer{
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid var(--pico-muted-border-color);
}

/* ================= HEADER ================= */

.site-header {
  position: sticky;
  top: 0;
  backdrop-filter: blur(10px);
  background: rgba(255,255,255,0.75);
  border-bottom: 1px solid var(--pico-muted-border-color);
  z-index: 1000;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 0;
}

.logo {
  display: flex;
  align-items: center;
  gap: .6rem;
  text-decoration: none;
}

.logo-mark {
  font-size: 1.2rem;
  letter-spacing: -2px;
  font-weight: 700;
}

.logo-text {
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: .5px;
}

.main-nav {
  display: flex;
  gap: 1.5rem;
}

.main-nav a {
  position: relative;
  text-decoration: none;
  font-weight: 500;
  opacity: .8;
  transition: all .25s ease;
}

.main-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 0%;
  height: 2px;
  background: currentColor;
  transition: width .25s ease;
}

.main-nav a:hover {
  opacity: 1;
}

.main-nav a:hover::after {
  width: 100%;
}

.hero {
  padding: 3rem 2.5rem;
  border-radius: 20px;
}

main.container {
  max-width: 1100px;
}


/* ====== MAGAZINE TYPOGRAPHY ====== */

.prose {
  max-width: 860px;
  margin: 0 auto;
  font-size: 1.12rem;
  line-height: 1.9;
  letter-spacing: .15px;

  /* Giustificazione “vera” */
  text-align: justify;
  text-justify: inter-word;
  hyphens: auto;
}

/* più aria tra paragrafi */
.prose p { margin: 0 0 1.55rem; }

/* Titoli più editoriali */
.prose h1 {
  text-align: left;
  font-size: 2.6rem;
  line-height: 1.15;
  margin: 0 0 1.1rem;
  letter-spacing: .2px;
}

/* Lead (prima riga più “importante”) */
.prose p:first-of-type {
  font-size: 1.18rem;
  opacity: .95;
}

/* Immagini pulite */
.prose img{
  width: 100%;
  height: auto;
  border-radius: 16px;
  border: 1px solid var(--pico-muted-border-color);
  margin: 2rem 0;
}

/* ====== 2 COLONNE “SFALSATE” (DESKTOP) ======
   Su mobile torna 1 colonna automaticamente.
*/
@media (min-width: 980px) {
  .prose-home {
    column-count: 2;
    column-gap: 3.2rem;
    column-fill: balance;
  }

  /* Titolo e primo paragrafo a tutta larghezza, poi parte la doppia colonna */
  .prose-home h1,
  .prose-home p:first-of-type {
    column-span: all;
  }

  /* Effetto “sfalsato”: la seconda colonna parte leggermente più giù
     (trucco: aggiungo una riga di respiro dopo il lead) */
  .prose-home p:first-of-type {
    margin-bottom: 2.2rem;
  }

  /* immagini a tutta larghezza (rompono le colonne) */
  .prose-home img {
    column-span: all;
    margin: 2.4rem 0;
  }
}

/* Mobile: 1 colonna, più leggibile */
@media (max-width: 979px) {
  .prose { font-size: 1.08rem; }
}

