/* ====== Ichibani 15 ans — Base, nav, sections, footer ====== */

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--ivory);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.55;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; }

/* Panorama de fond global — overlay fait par chaque section */
body {
  background-image: url('../assets/hero-bg.jpg');
  background-size: cover;
  background-position: center center;
  background-attachment: fixed;
  background-repeat: no-repeat;
  background-color: var(--ivory);
}
@media (max-width: 800px) {
  /* Parallaxe fixed instable sur iOS/Android */
  body { background-attachment: scroll; }
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: 0.005em;
  margin: 0;
  text-wrap: balance;
  color: var(--burgundy);
}

p { text-wrap: pretty; }
a { color: inherit; }

::selection { background: var(--burgundy); color: var(--ivory); }

.text-mute { color: var(--ink-mute); }
.text-burg { color: var(--burgundy); }

/* ====== TOP NAV ====== */
.topnav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.topnav-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 16px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}

.brand { display: flex; align-items: center; gap: 16px; }
.brand-logo {
  height: 32px;
  width: auto;
  display: block;
}
.brand-sep {
  width: 1px;
  height: 30px;
  background: var(--line);
}
.brand-meta-stack { display: flex; flex-direction: column; gap: 2px; }
.brand-anniv {
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  font-weight: 700;
  color: var(--burgundy);
  line-height: 1;
  letter-spacing: 0;
}
.brand-text {
  font-family: var(--font-display);
  font-size: 18px;
  color: var(--burgundy);
  letter-spacing: 0.01em;
  line-height: 1;
}
.brand-meta {
  font-family: var(--font-body);
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--grey);
  font-weight: 600;
  line-height: 1;
}

.tabs {
  display: flex;
  gap: 0;
  border: 1px solid var(--line);
  border-radius: 0;
  background: white;
}

.tab {
  appearance: none;
  border: none;
  background: transparent;
  padding: 12px 22px;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 10px;
  border-right: 1px solid var(--line);
}
.tab:last-child { border-right: none; }
.tab .tab-num {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: var(--fs-xs);
  color: var(--burgundy);
  opacity: 0.55;
}
.tab:hover { color: var(--burgundy); background: var(--cream); }
.tab.active {
  background: var(--burgundy);
  color: var(--ivory);
}
.tab.active .tab-num { opacity: 1; color: var(--ivory); }

.topnav-right {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 11px;
  color: var(--grey);
  letter-spacing: 0.08em;
}
.topnav-right .pill {
  padding: 8px 14px;
  border: 1px solid var(--burgundy);
  background: white;
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: 0.14em;
  font-size: 10px;
  color: var(--burgundy);
  font-family: var(--font-body);
}

/* ====== SECTIONS ====== */
.section { display: none; min-height: calc(100vh - 78px); }
.section.active { display: block; }

.section-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: var(--space-6) 40px;
}

.section-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--space-4);
  margin-bottom: var(--space-5);
  padding-bottom: var(--space-3);
  border-bottom: 2px solid var(--burgundy);
}

.eyebrow {
  font-family: var(--font-body);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--burgundy);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.eyebrow::before {
  content: '';
  width: 32px;
  height: 2px;
  background: var(--burgundy);
}

.section-title {
  font-family: var(--font-display);
  font-size: var(--fs-section);
  line-height: 1.05;
  color: var(--burgundy);
  letter-spacing: 0;
}
.section-title em {
  font-style: normal;
  color: var(--ink);
}

.section-sub {
  font-size: 14px;
  color: var(--ink-soft);
  max-width: 460px;
  text-align: right;
  margin-left: auto;
  line-height: 1.5;
}

/* Honeycomb bg utility */
.honeycomb-bg {
  position: absolute;
  inset: 0;
  opacity: 0.18;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='110' height='96' viewBox='0 0 110 96' fill='none'%3E%3Cpolygon points='55,4 104,29 104,67 55,92 6,67 6,29' stroke='%23ffffff' stroke-width='1.5' opacity='0.35'/%3E%3C/svg%3E");
  background-size: 110px 96px;
}

/* ====== FOOTER ====== */
.page-footer {
  background: var(--burgundy);
  color: var(--ivory);
  padding: 56px 40px;
  text-align: center;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 600;
  position: relative;
  overflow: hidden;
}
.footer-logo {
  height: 40px;
  width: auto;
  display: block;
  margin: 0 auto 12px;
  opacity: 0.95;
}
.footer-sub {
  font-size: var(--fs-sm);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-family: var(--font-body);
  font-weight: 500;
  opacity: 0.85;
  margin-bottom: 20px;
}
.footer-addr {
  font-size: 10px;
  letter-spacing: 0.22em;
  opacity: 0.6;
  font-weight: 600;
}

/* ====== RESPONSIVE ====== */
@media (max-width: 800px) {
  .topnav-inner { padding: 12px 20px; flex-wrap: wrap; gap: 12px; }
  .section-inner { padding: var(--space-4) 20px; }
  .tabs { flex-wrap: wrap; }
  .tab { padding: 10px 14px; font-size: 11px; }
}

/* Phones */
@media (max-width: 600px) {
  .topnav-inner {
    padding: 10px 16px;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: space-between;
  }
  .brand { gap: 10px; order: 1; flex: 1 1 auto; min-width: 0; }
  .brand-logo { height: 26px; }
  .brand-sep { height: 24px; }
  .brand-anniv { font-size: 11px; }
  .brand-meta { font-size: 9px; letter-spacing: 0.12em; }
  .topnav-right { order: 2; flex-shrink: 0; }
  .tabs { order: 3; flex-basis: 100%; width: 100%; }
  .tab {
    flex: 1 1 0;
    padding: 9px 4px;
    font-size: 10px;
    letter-spacing: 0.04em;
    justify-content: center;
    min-width: 0;
  }
  .section-inner { padding: var(--space-3) 16px; }
  .section-header {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-2);
  }
  .section-sub {
    max-width: 100%;
    text-align: left;
    margin-left: 0;
  }
  .section { min-height: calc(100vh - 120px); }
  .page-footer { padding: 40px 20px; }
  .footer-addr { letter-spacing: 0.14em; line-height: 1.6; }
}

/* Small phones */
@media (max-width: 400px) {
  .topnav-inner { padding: 10px 12px; gap: 8px; }
  .brand-logo { height: 22px; }
  .brand-anniv { font-size: 10px; }
  .brand-meta { font-size: 8px; }
  .cta-inscription { padding: 7px 12px; font-size: 12px; }
  .cta-inscription .cta-arrow { font-size: 1em; }
  .tab { padding: 8px 2px; font-size: 9px; }
  .section-inner { padding: var(--space-3) 12px; }
}

/* === CTA Inscription (topnav-right) === */
.cta-inscription {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 22px;
  background: var(--burgundy);
  color: #faf7f2;
  font-family: inherit;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.02em;
  text-decoration: none;
  border-radius: 999px;
  border: 2px solid var(--burgundy);
  box-shadow: 0 2px 8px rgba(117, 32, 49, 0.18);
  transition: transform .25s ease, box-shadow .25s ease, background .25s ease;
  position: relative;
  white-space: nowrap;
}

.cta-inscription:hover,
.cta-inscription:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(117, 32, 49, 0.32);
  color: #faf7f2;
}

.cta-inscription:focus-visible {
  outline: 3px solid rgba(117, 32, 49, 0.35);
  outline-offset: 3px;
}

.cta-inscription:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(117, 32, 49, 0.22);
}

.cta-arrow {
  display: inline-block;
  transition: transform .25s ease;
  font-size: 1.05em;
  line-height: 1;
}

.cta-inscription:hover .cta-arrow,
.cta-inscription:focus-visible .cta-arrow {
  transform: translateX(4px);
}

/* Micro-pulse subtil sur la bordure pour attirer l'oeil — une pulsation toutes les 4s */
@keyframes cta-pulse-ring {
  0%, 85%, 100% { box-shadow: 0 2px 8px rgba(117, 32, 49, 0.18), 0 0 0 0 rgba(117, 32, 49, 0); }
  92% { box-shadow: 0 2px 8px rgba(117, 32, 49, 0.18), 0 0 0 8px rgba(117, 32, 49, 0.22); }
  98% { box-shadow: 0 2px 8px rgba(117, 32, 49, 0.18), 0 0 0 16px rgba(117, 32, 49, 0); }
}

.cta-inscription:not(:hover):not(:focus-visible) {
  animation: cta-pulse-ring 4.5s ease-in-out infinite;
}

@media (prefers-reduced-motion: reduce) {
  .cta-inscription { animation: none !important; transition: none !important; }
  .cta-inscription:hover .cta-arrow { transform: none; }
}

/* Responsive : sur mobile, le bouton reste lisible */
@media (max-width: 600px) {
  .cta-inscription {
    padding: 8px 16px;
    font-size: 13px;
  }
}
