/* ===================================
   GLAMPING PUGLIA — Stylesheet
   Design: magazine editoriale
=================================== */

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

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --sand:    #F5F0E8;
  --sand-dk: #E8DCC8;
  --black:   #1C1C1A;
  --gold:    #8B6914;
  --gold-lt: #C49A2A;
  --green:   #2D5016;
  --muted:   #6B6560;
  --white:   #FDFAF5;
  --serif:   'Cormorant Garamond', Georgia, serif;
  --sans:    'Inter', system-ui, sans-serif;
  --max:     1140px;
  --col:     680px;
}

html { scroll-behavior: smooth; }

body {
  background: var(--sand);
  color: var(--black);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.75;
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
}

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

/* --- Gold divider (firma visiva) --- */
.divider {
  display: block;
  width: 48px;
  height: 1px;
  background: var(--gold);
  margin: 2rem auto;
}
.divider--left { margin-left: 0; }
.divider--wide { width: 100%; opacity: .2; }

/* ===================================
   NAVIGAZIONE
=================================== */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(245, 240, 232, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(139,105,20,.15);
  padding: 0 2rem;
}
.nav__inner {
  max-width: var(--max);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.nav__logo {
  font-family: var(--serif);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: .02em;
  color: var(--black);
}
.nav__logo span { color: var(--gold); }
.nav__links {
  display: flex;
  gap: 2rem;
  list-style: none;
}
.nav__links a {
  font-size: .8rem;
  font-weight: 400;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
  transition: color .2s;
}
.nav__links a:hover { color: var(--gold); }

.nav__hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
}
.nav__hamburger span {
  display: block;
  width: 24px;
  height: 1.5px;
  background: var(--black);
  transition: all .3s;
}

/* Mobile nav */
@media (max-width: 768px) {
  .nav__links {
    display: none;
    position: absolute;
    top: 64px; left: 0; right: 0;
    flex-direction: column;
    background: var(--sand);
    padding: 1.5rem 2rem;
    gap: 1.25rem;
    border-bottom: 1px solid var(--sand-dk);
  }
  .nav__links.open { display: flex; }
  .nav__hamburger { display: flex; }
}

/* ===================================
   HERO — INDEX
=================================== */
.hero {
  padding-top: 64px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  position: relative;
  overflow: hidden;
}
.hero__bg {
  position: absolute;
  inset: 0;
  background-image: url('../images/hero-bg.jpg');
  background-size: cover;
  background-position: center 60%;
  filter: brightness(.55);
  z-index: 0;
}
.hero__content {
  position: relative;
  z-index: 1;
  max-width: var(--max);
  margin: 0 auto;
  padding: 5rem 2rem 4rem;
  width: 100%;
}
.hero__eyebrow {
  font-size: .75rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--gold-lt);
  font-family: var(--sans);
  font-weight: 400;
  margin-bottom: 1.25rem;
}
.hero__title {
  font-family: var(--serif);
  font-size: clamp(2.8rem, 7vw, 5.5rem);
  font-weight: 300;
  line-height: 1.1;
  color: var(--white);
  max-width: 16ch;
  margin-bottom: 1.5rem;
}
.hero__title em {
  font-style: italic;
  color: var(--gold-lt);
}
.hero__sub {
  font-size: 1rem;
  font-weight: 300;
  color: rgba(253,250,245,.75);
  max-width: 48ch;
  line-height: 1.6;
  margin-bottom: 2.5rem;
}
.hero__scroll {
  display: inline-flex;
  align-items: center;
  gap: .75rem;
  font-size: .75rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: rgba(253,250,245,.5);
}
.hero__scroll::before {
  content: '';
  display: block;
  width: 32px;
  height: 1px;
  background: var(--gold-lt);
}

/* ===================================
   INTRO SECTION (index)
=================================== */
.intro {
  max-width: var(--col);
  margin: 6rem auto;
  padding: 0 2rem;
  text-align: center;
}
.intro__label {
  font-size: .72rem;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 500;
  margin-bottom: 1.25rem;
}
.intro__text {
  font-family: var(--serif);
  font-size: clamp(1.25rem, 2.5vw, 1.6rem);
  font-weight: 300;
  line-height: 1.6;
  color: var(--black);
}

/* ===================================
   GRID ARTICOLI (index)
=================================== */
.articles {
  max-width: var(--max);
  margin: 0 auto 6rem;
  padding: 0 2rem;
}
.articles__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
}

/* Featured card (prima, a tutta larghezza) */
.card--featured {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 420px;
}
.card__image {
  overflow: hidden;
  background: var(--black);
}
.card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .6s ease;
}
.card:hover .card__image img { transform: scale(1.03); }

.card__body {
  background: var(--black);
  color: var(--white);
  padding: 3rem;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.card--featured .card__body { background: #111110; }

.card__cat {
  font-size: .7rem;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--gold-lt);
  font-weight: 400;
  margin-bottom: 1rem;
}
.card__title {
  font-family: var(--serif);
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  font-weight: 300;
  line-height: 1.25;
  margin-bottom: 1rem;
  color: var(--white);
}
.card__excerpt {
  font-size: .875rem;
  color: rgba(253,250,245,.6);
  line-height: 1.65;
  margin-bottom: 1.75rem;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.card__link {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  font-size: .75rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--gold-lt);
  font-weight: 400;
}
.card__link::after {
  content: '→';
  transition: transform .2s;
}
.card:hover .card__link::after { transform: translateX(4px); }

/* Regular cards */
.card {
  background: var(--sand-dk);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.card .card__image { height: 220px; flex-shrink: 0; }
.card .card__body {
  background: var(--sand-dk);
  color: var(--black);
  padding: 1.75rem;
  flex: 1;
}
.card .card__title { color: var(--black); font-size: 1.2rem; }
.card .card__excerpt { color: var(--muted); }
.card .card__link { color: var(--gold); }
.card .card__cat { color: var(--gold); }

/* Wishne highlight card */
.card--wishne {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 320px;
  background: var(--green);
}
.card--wishne .card__body {
  background: var(--green);
  color: var(--white);
}
.card--wishne .card__title { color: var(--white); }
.card--wishne .card__excerpt { color: rgba(253,250,245,.65); }
.card--wishne .card__link { color: #A8D878; }
.card--wishne .card__cat { color: #A8D878; }

@media (max-width: 900px) {
  .articles__grid { grid-template-columns: 1fr 1fr; }
  .card--featured { grid-template-columns: 1fr; min-height: auto; }
  .card--featured .card__image { height: 280px; }
  .card--wishne { grid-column: 1 / -1; grid-template-columns: 1fr; }
  .card--wishne .card__image { height: 240px; }
}
@media (max-width: 580px) {
  .articles__grid { grid-template-columns: 1fr; }
  .card--featured { grid-column: 1; }
}

/* ===================================
   ARTICLE PAGES
=================================== */
.article-hero {
  padding-top: 64px;
  height: 60vh;
  min-height: 380px;
  position: relative;
  overflow: hidden;
}
.article-hero__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: brightness(.5);
}
.article-hero__content {
  position: relative;
  z-index: 1;
  max-width: var(--max);
  margin: 0 auto;
  padding: 3rem 2rem;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.article-hero__cat {
  font-size: .72rem;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--gold-lt);
  margin-bottom: 1rem;
}
.article-hero__title {
  font-family: var(--serif);
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 300;
  line-height: 1.15;
  color: var(--white);
  max-width: 20ch;
  margin-bottom: 1rem;
}
.article-hero__sub {
  font-size: 1rem;
  color: rgba(253,250,245,.7);
  font-weight: 300;
  max-width: 52ch;
}

/* Article body */
.article-body {
  max-width: var(--col);
  margin: 5rem auto 6rem;
  padding: 0 2rem;
}
.article-body p {
  margin-bottom: 1.5rem;
  font-size: 1.05rem;
  color: #2A2925;
}
.article-body h2 {
  font-family: var(--serif);
  font-size: clamp(1.4rem, 3vw, 1.9rem);
  font-weight: 400;
  line-height: 1.25;
  color: var(--black);
  margin: 3rem 0 1.25rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(139,105,20,.2);
}
.article-body .intro-paragraph {
  font-family: var(--serif);
  font-size: clamp(1.15rem, 2.5vw, 1.4rem);
  font-weight: 300;
  line-height: 1.55;
  color: var(--black);
  margin-bottom: 2.5rem;
}

/* Photo credit */
.photo-credit {
  font-size: .72rem;
  color: var(--muted);
  text-align: center;
  margin-top: .5rem;
  letter-spacing: .03em;
}
.photo-credit a { color: var(--gold); text-decoration: underline; text-underline-offset: 2px; }

/* Inline image in article */
.article-image {
  margin: 2.5rem -2rem;
}
.article-image img {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
}
@media (min-width: 768px) {
  .article-image { margin: 3rem -4rem; }
}

/* Pull quote */
.pullquote {
  border-left: 3px solid var(--gold);
  padding: 1rem 0 1rem 2rem;
  margin: 2.5rem 0;
  font-family: var(--serif);
  font-size: 1.3rem;
  font-weight: 300;
  font-style: italic;
  line-height: 1.5;
  color: var(--green);
}

/* Back link */
.back-link {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  font-size: .75rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 3rem;
  font-weight: 400;
}
.back-link::before { content: '←'; }
.back-link:hover { color: var(--black); }

/* ===================================
   FOOTER
=================================== */
.footer {
  background: var(--black);
  color: rgba(253,250,245,.5);
  padding: 3rem 2rem;
  text-align: center;
}
.footer__logo {
  font-family: var(--serif);
  font-size: 1.4rem;
  font-weight: 300;
  color: var(--white);
  margin-bottom: 1rem;
}
.footer__logo span { color: var(--gold-lt); }
.footer__note {
  font-size: .8rem;
  line-height: 1.7;
  max-width: 500px;
  margin: 0 auto 1.5rem;
}
.footer__links {
  display: flex;
  justify-content: center;
  gap: 2rem;
  list-style: none;
  margin-bottom: 2rem;
}
.footer__links a {
  font-size: .72rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: rgba(253,250,245,.4);
  transition: color .2s;
}
.footer__links a:hover { color: var(--gold-lt); }
.footer__copy {
  font-size: .72rem;
  color: rgba(253,250,245,.25);
}
