/* ============================================================
   Tourisme Pays de Bégard — CSS Grid + Flexbox pur
   Style : Nature/Organique breton
   ============================================================ */

/* ---- Variables ---- */
:root {
  --mint:    #2DC997;
  --slate:   #2C4A52;
  --gold:    #E8A33D;
  --dark:    #1C2420;
  --light:   #F4F8F5;
  --white:   #FFFFFF;
  --muted:   #6B7C75;
  --border:  #D6E8DE;
  --radius:  12px;
  --radius-sm: 6px;
  --shadow:  0 4px 24px rgba(28,36,32,0.10);
  --shadow-sm: 0 2px 8px rgba(28,36,32,0.07);
  --font-title: 'Playfair Display', Georgia, serif;
  --font-body:  'Source Sans 3', 'Helvetica Neue', Arial, sans-serif;
  --max-w: 1280px;
  --content-w: 860px;
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.7;
  color: var(--dark);
  background: var(--white);
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }

/* ---- Typography ---- */
h1, h2, h3, h4, h5 {
  font-family: var(--font-title);
  line-height: 1.2;
  color: var(--slate);
}
h1 { font-size: clamp(2.2rem, 5vw, 4rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.4rem); }
h3 { font-size: clamp(1.2rem, 2.5vw, 1.6rem); }
p { margin-bottom: 1.2em; }
strong { font-weight: 700; }

/* ---- Utilities ---- */
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}
.container--narrow {
  max-width: var(--content-w);
  margin: 0 auto;
  padding: 0 24px;
}
.sr-only {
  position: absolute; width: 1px; height: 1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap;
}
.tag-badge {
  display: inline-block;
  background: var(--mint);
  color: var(--white);
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 20px;
  transition: background .2s;
}
.tag-badge:hover { background: var(--slate); }

/* ============================================================
   NAVIGATION
   ============================================================ */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--slate);
  box-shadow: 0 2px 16px rgba(28,36,32,0.18);
}
.nav-inner {
  display: flex;
  align-items: center;
  gap: 32px;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 12px 24px;
}
.nav-logo {
  flex-shrink: 0;
}
.nav-logo img {
  height: 72px;
  width: auto;
  display: block;
}

/* Menu Joornal main_menu */
.nav-menu {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px;
  flex: 1;
}
.nav-menu-item {
  display: inline-flex;
}
.nav-menu-link {
  display: block;
  font-family: var(--font-body);
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: .04em;
  color: rgba(255,255,255,0.85);
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  transition: color .2s, background .2s;
}
.nav-menu-link:hover,
.nav-menu-link.active {
  color: var(--white);
  background: rgba(45,201,151,0.18);
}

/* Mobile hamburger */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  margin-left: auto;
}
.nav-toggle span {
  display: block;
  width: 26px;
  height: 2px;
  background: var(--white);
  border-radius: 2px;
  transition: transform .3s, opacity .3s;
}

@media (max-width: 768px) {
  .nav-toggle { display: flex; }
  .nav-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--slate);
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px 0 16px;
    box-shadow: 0 8px 24px rgba(28,36,32,0.2);
  }
  .nav-menu.is-open { display: flex; }
  .nav-menu-link { padding: 12px 24px; border-radius: 0; font-size: 1rem; }
  .nav-logo img { height: 52px; }
  .site-nav { position: relative; }
}

/* ============================================================
   INDEX.HTML — Archétype E (Immersif + overlay)
   ============================================================ */
.hero-immersive {
  position: relative;
  min-height: 65vh;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
}
.hero-immersive__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero-immersive__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
.hero-immersive__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(28,36,32,0.82) 0%,
    rgba(28,36,32,0.38) 55%,
    rgba(28,36,32,0.10) 100%
  );
  z-index: 1;
}
.hero-immersive__content {
  position: relative;
  z-index: 2;
  width: 100%;
  padding: 48px 24px 52px;
  max-width: var(--max-w);
  margin: 0 auto;
}
.hero-immersive__eyebrow {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 16px;
}
.hero-immersive__title {
  font-family: var(--font-title);
  font-size: clamp(2.4rem, 6vw, 4.8rem);
  font-weight: 700;
  color: var(--white);
  line-height: 1.1;
  max-width: 760px;
  text-align: left;
  margin-bottom: 18px;
}
.hero-immersive__baseline {
  font-family: var(--font-body);
  font-size: clamp(1rem, 2vw, 1.25rem);
  color: rgba(255,255,255,0.82);
  max-width: 540px;
  line-height: 1.5;
  text-align: left;
}

/* Index content section */
.index-content-section {
  background: var(--light);
  padding: 64px 0 48px;
  border-bottom: 1px solid var(--border);
}
.index-content-section .intro-text {
  font-size: 1.15rem;
  color: var(--dark);
  max-width: 900px;
}
.index-content-section .intro-text p:last-child { margin-bottom: 0; }

/* Index showcase section */
.index-showcase-section {
  padding: 64px 0 80px;
  background: var(--white);
}
.section-header {
  display: flex;
  align-items: baseline;
  gap: 20px;
  margin-bottom: 40px;
}
.section-header h2 {
  font-family: var(--font-title);
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  color: var(--slate);
}
.section-header__line {
  flex: 1;
  height: 2px;
  background: var(--border);
}

/* ============================================================
   POST-LOOP — Carte overlay asymétrique
   ============================================================ */
.post-card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  transition: transform .25s, box-shadow .25s;
  border: 1px solid var(--border);
}
.post-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow);
}
.post-card__thumb {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16/9;
}
.post-card__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s ease;
}
.post-card:hover .post-card__thumb img {
  transform: scale(1.04);
}
.post-card__body {
  padding: 20px 22px 24px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.post-card__meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.post-card__date {
  font-size: 0.78rem;
  color: var(--muted);
  font-weight: 500;
}
.post-card__title {
  font-family: var(--font-title);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--slate);
  line-height: 1.3;
  margin: 0;
}
.post-card__title a { color: inherit; transition: color .2s; }
.post-card__title a:hover { color: var(--mint); }
.post-card__excerpt {
  font-size: 0.92rem;
  color: var(--muted);
  line-height: 1.6;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.post-card__read-more {
  margin-top: auto;
  padding-top: 12px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--mint);
  letter-spacing: .04em;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: gap .2s;
}
.post-card__read-more:hover { gap: 10px; }

/* Showcase grid (injected by Joornal around post-loop items) */
.showcase-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}
@media (max-width: 900px) {
  .showcase-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 540px) {
  .showcase-grid { grid-template-columns: 1fr; }
}

/* ============================================================
   POST-LIST
   ============================================================ */
.post-list-header {
  background: var(--slate);
  padding: 56px 24px 48px;
  position: relative;
  overflow: hidden;
}
.post-list-header::before {
  content: '';
  position: absolute;
  right: -60px;
  top: -60px;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: rgba(45,201,151,0.12);
  pointer-events: none;
}
.post-list-header::after {
  content: '';
  position: absolute;
  left: 30%;
  bottom: -40px;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: rgba(232,163,61,0.08);
  pointer-events: none;
}
.post-list-header h1 {
  color: var(--white);
  font-size: clamp(1.8rem, 4vw, 3rem);
  text-align: left;
  position: relative;
  z-index: 1;
}
.post-list-header .breadcrumb {
  position: relative;
  z-index: 1;
  margin-bottom: 16px;
}

.post-list-content {
  padding: 56px 0 80px;
}
.post-list-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  margin-bottom: 56px;
}
@media (max-width: 900px) {
  .post-list-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 540px) {
  .post-list-grid { grid-template-columns: 1fr; }
}

/* ============================================================
   PAGINATION
   ============================================================ */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.pagination .page {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 12px;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--slate);
  border: 1.5px solid var(--border);
  background: var(--white);
  transition: all .2s;
}
.pagination .page:hover {
  background: var(--mint);
  color: var(--white);
  border-color: var(--mint);
}
.pagination .page.active {
  background: var(--slate);
  color: var(--white);
  border-color: var(--slate);
}

/* ============================================================
   POST.HTML — Article detail
   ============================================================ */
.post-header {
  background: var(--light);
  border-bottom: 1px solid var(--border);
  padding: 40px 24px 36px;
}
.post-header .container--narrow {
  max-width: 940px;
}

.breadcrumb {
  font-size: 0.82rem;
  color: var(--muted);
  margin-bottom: 20px;
}
.breadcrumb ol {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  list-style: none;
  margin: 0;
  padding: 0;
}
.breadcrumb li { list-style: none; }
.breadcrumb a { color: var(--mint); transition: color .2s; }
.breadcrumb a:hover { color: var(--slate); }
.breadcrumb__sep { color: var(--border); }

.post-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 18px;
}
.post-meta__date {
  font-size: 0.85rem;
  color: var(--muted);
  font-weight: 500;
}
.post-meta__read {
  font-size: 0.85rem;
  color: var(--muted);
}

.post-article {
  padding: 48px 0 80px;
}
.post-article .container--narrow {
  max-width: 860px;
}

.post-thumbnail {
  margin-bottom: 40px;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.post-thumbnail img {
  width: 100%;
  max-height: 520px;
  object-fit: cover;
}

.post-body {
  font-size: 1.08rem;
  line-height: 1.85;
  color: var(--dark);
}
.post-body h2 {
  font-size: 1.7rem;
  margin: 2em 0 0.6em;
  color: var(--slate);
  border-left: 4px solid var(--mint);
  padding-left: 16px;
}
.post-body h3 {
  font-size: 1.3rem;
  margin: 1.8em 0 0.5em;
  color: var(--slate);
}
.post-body ul, .post-body ol {
  margin: 1em 0 1.2em 1.5em;
}
.post-body ul { list-style: disc; }
.post-body ol { list-style: decimal; }
.post-body li { margin-bottom: .4em; }
.post-body blockquote {
  border-left: 4px solid var(--gold);
  margin: 1.8em 0;
  padding: 14px 24px;
  background: rgba(232,163,61,0.07);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-style: italic;
  color: var(--slate);
}
.post-body a {
  color: var(--mint);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
.post-body a:hover { color: var(--slate); }
.post-body img {
  border-radius: var(--radius-sm);
  margin: 1.5em 0;
}

/* Table of contents */
.toc-box {
  background: var(--light);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
  margin-bottom: 40px;
}
.toc-box h4 {
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 12px;
}

/* Signatory / Author box */
.post-signatory {
  margin-top: 56px;
  padding: 28px 32px;
  background: var(--light);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  display: flex;
  align-items: flex-start;
  gap: 20px;
}
.post-signatory__label {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--mint);
  margin-bottom: 8px;
  display: block;
}
.post-signatory__name {
  font-family: var(--font-title);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--slate);
}

/* Related articles */
.related-section {
  padding: 64px 0;
  background: var(--light);
  border-top: 1px solid var(--border);
}
.related-section .section-header {
  margin-bottom: 36px;
}
.related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
@media (max-width: 900px) {
  .related-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 540px) {
  .related-grid { grid-template-columns: 1fr; }
}

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer {
  background: var(--dark);
  color: rgba(255,255,255,0.65);
  padding: 36px 24px;
}
.footer-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}
.footer-copy {
  font-size: 0.85rem;
  line-height: 1.6;
}
.footer-copy a {
  color: var(--mint);
  text-decoration: underline;
}
.footer-accent {
  display: inline-block;
  width: 40px;
  height: 3px;
  background: linear-gradient(90deg, var(--mint), var(--gold));
  border-radius: 2px;
}

/* ============================================================
   DECORATIVE ACCENTS
   ============================================================ */
.wave-divider {
  width: 100%;
  overflow: hidden;
  line-height: 0;
  margin-bottom: -2px;
}
.wave-divider svg {
  display: block;
  width: 100%;
  height: 48px;
}

/* ============================================================
   RESPONSIVE TWEAKS
   ============================================================ */
@media (max-width: 768px) {
  .hero-immersive { min-height: 55vw; }
  .hero-immersive__content { padding: 32px 20px 40px; }
  .index-content-section { padding: 44px 0 36px; }
  .index-showcase-section { padding: 44px 0 56px; }
  .post-list-content { padding: 36px 0 56px; }
  .post-article { padding: 32px 0 56px; }
  .post-signatory { flex-direction: column; gap: 12px; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 480px) {
  body { font-size: 16px; }
  .section-header { flex-direction: column; gap: 8px; }
  .section-header__line { width: 60px; height: 2px; flex: none; }
}
