@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@500;900&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Space+Mono:wght@400;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Vollkorn:ital,wght@0,400;0,600;1,400&display=swap');

/* ============================================
   CSS Variables (Design System)
   ============================================ */

:root {
  /* Colors */
  --bg-primary: #ffffff;
  --bg-secondary: #f5f5f5;
  --text-primary: #0552AC;
  --text-secondary: #0552AC;
  --border-color: #f5f5f5;
  --accent-color: #0552AC;
  --accent-hover: #0552AC;
  --highlight-color: #FFCF21;
  --focus-color: #7C3AED;

  /* Spacing */
  --spacing-xs: 0.25rem;
  --spacing-sm: 0.5rem;
  --spacing-md: 1rem;
  --spacing-lg: 1.5rem;
  --spacing-xl: 2rem;
  --spacing-2xl: 3rem;

  /* Border Radius */
  --radius-sm: 0.05rem;
  --radius-md: 0.1rem;
  --radius-lg: 48px;

  /* Typography */
  --font-heading: 'Space Grotesk', monospace;
  --font-body: 'Roboto', sans-serif;
  --font-sans: 'Roboto', -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --font-mono: "Courier New", monospace;
  --font-size-sm: 0.875rem;
  --font-size-base: 1rem;
  --font-size-lg: 1.125rem;
  --font-size-xl: 1.5rem;
  --font-size-2xl: 2rem;

  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
}

/* ============================================
   Base Styles (Mobile-First)
   ============================================ */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: var(--font-size-base);
  line-height: 1.6;
  color: var(--text-primary);
  background-color: var(--bg-primary);
  background-image: url('../media/Background.gif');
  background-repeat: repeat-y;
  background-size: auto;
  background-position: center top;
  background-attachment: fixed;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}


/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-top: var(--spacing-sm);
}

h1 { font-size: var(--font-size-2xl);letter-spacing: -0.05em; }
h2 { font-size: var(--font-size-2xl); font-family: 'Space Grotesk', sans-serif; font-weight: 700;letter-spacing: -0.03em; }
h3 { font-size: var(--font-size-lg); }

p {
  margin-bottom: calc(var(--spacing-md) * 2);
}

small {
  font-family: var(--font-body);
}

/* Links */
a {
  color: var(--accent-color);
  text-decoration: none;
  transition: color 0.2s ease;
}

/* Keyboard focus indicator */
:focus-visible {
  outline: 2px dashed var(--focus-color);
  outline-offset: 4px;
}



.skip-link {
  position: absolute;
  top: -60px;
  left: var(--spacing-md);
  z-index: 200;
  padding: var(--spacing-sm) var(--spacing-md);
  background-color: var(--accent-color);
  color: #ffffff;
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-weight: 500;
  transition: top 0.2s ease;
}

.skip-link:focus {
  top: var(--spacing-md);
}

/* ============================================
   Layout Components
   ============================================ */

header {
  height: 90px;
  background-color: #ffffff;
  border-bottom-left-radius: var(--radius-lg);
  border-bottom-right-radius: var(--radius-lg);
  display: flex;
  justify-content: center;
  align-items: center;
}

.header-logo {
  max-width: 100%;
  width: 100px;
  height: auto;
}

main {
  padding: 0 16px 29px 16px;
  width: 100%;
  flex: 1;
  display: flex;
  flex-direction: column;
}

section {
  background-color: white;
  border-radius: var(--radius-lg);
  padding: 50px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  box-sizing: border-box;
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: start;
  flex: 1;
  letter-spacing: -0.04em;
}

/* Programmatic Sommaire landing point, not a visible control — the scroll itself is the feedback */
section[tabindex="-1"]:focus {
  outline: none;
}

footer {
  font-size: var(--font-size-sm);
}

/* Match the width of the membership tier cards */
#benefits-section {
  max-width: 1140px;
}

/* ============================================
   Form Elements
   ============================================ */

input[type="text"],
input[type="tel"],
input[type="email"],
input[type="password"],
textarea {
  width: 100%;
  padding: var(--spacing-sm) var(--spacing-md);
  font-family: var(--font-body);
  font-weight: 500;
  font-size: var(--font-size-base);
  border: none;
  border-radius: var(--radius-lg);
  background-color: #ffffff;
  color: var(--text-primary);
  transition: background-color 0.2s ease;
  letter-spacing: -0.05em;
}

input[type="text"]::placeholder,
input[type="tel"]::placeholder,
input[type="email"]::placeholder,
input[type="password"]::placeholder,
textarea::placeholder {
  color: var(--text-primary);
}

input:focus,
textarea:focus {
  outline: none;
  background-color: #ffffff;
  box-shadow: inset 0 0 0 2px var(--focus-color);
}

label {
  display: block;
  margin-bottom: var(--spacing-sm);
  font-family: var(--font-body);
  font-weight: 500;
  font-size: var(--font-size-sm);
}

div > label + input,
div > label + textarea {
  margin-bottom: var(--spacing-md);
}

form {
  width: 100%;
  height: 300px;
  max-width: 100%;
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm);
}

form label {
  width: 100%;
}

form input,
form textarea {
  width: 100%;
  padding-bottom:0px;
}

.input-wrapper {
  position: relative;
  width: 100%;
  display: flex;
  align-items: center;
}

.input-symbol {
  position: absolute;
  left: var(--spacing-md);
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-primary);
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
}

.input-icon {
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-left: -4px;
  cursor: pointer;
}

.input-icon svg {
  width: 24px;
  height: 24px;
}

.arrow-group {
  transition: transform 0.2s ease-in-out;
  transform: translateX(0);
}

.input-icon.active .arrow-group {
  transform: translateX(4px);
}

.input-hash {
  font-weight: 900;
  font-size: var(--font-size-lg);
  display: none;
  align-items: center;
  justify-content: center;
  margin-left: 12px;
}

.input-wrapper input {
  padding-left: calc(var(--spacing-md) * 2.5);
}

.form-hint {
  font-size: var(--font-size-sm);
  color: var(--text-secondary);
  margin: 0 0 0 0;
  padding-bottom: var(--spacing-sm);
}

.error-message {
  font-size: var(--font-size-sm);
  color: #d32f2f;
  margin: 0 0 0 0;
  padding-top: 0;
}

/* Buttons */
button {
  width: 100%;
  padding: var(--spacing-sm) var(--spacing-lg);
  font-family: var(--font-body);
  font-size: var(--font-size-base);
  font-weight: 500;
  border: none;
  border-radius: var(--radius-lg);
  background-color: var(--accent-color);
  color: white;
  cursor: pointer;
  transition: background-color 0.2s ease, box-shadow 0.2s ease;
}

button:hover {
  background-color: var(--accent-hover);
  box-shadow: var(--shadow-md);
}

button:active {
  transform: scale(0.98);
}

button:disabled {
  cursor: not-allowed;
  background-color: #999999;
}

/* ============================================
   Responsive Styles
   ============================================ */

@media (max-width: 799px) {
  section {
    padding: 25px;
  }
}

@media (min-width: 800px) {


  section {
    max-width: 768px;
  }

  .content-wrapper,
  .section .content-wrapper {
    padding: 0 var(--spacing-2xl);
  }
}

/* ============================================
   Searching Animation
   ============================================ */

@keyframes fadeIn {
  from {
    visibility: hidden;
  }
  to {
    visibility: visible;
  }
}

.searching {
  animation: fadeIn 1s ease-in-out infinite;
}

/* ============================================
   Images Container (Wall Grid)
   ============================================ */

.images-container {
  display: flex;
  width: 100%;
  gap: 0;
  height: 300px;
  overflow-x: auto;
  overflow-y: hidden;
}

.wall-image {
  flex: 1;
  object-fit: contain;
  object-position: center;
}

.search-again-container {
  margin-top: var(--spacing-lg);
  min-height: 1.5rem;
  text-align: left;
}

.search-again-link {
  display: none;
  color: var(--accent-color);
  text-decoration: underline;
  transition: color 0.2s ease;
}


.search-again-link.visible {
  display: block;
}

#feedback {
  text-align: left;
}

#feedback a {
  color: var(--accent-color);
  text-decoration: none;
  transition: color 0.2s ease;
}


/* ============================================
   Custom Component Overrides
   ============================================ */

/* Add custom component styles here */

/* ============================================
   Adhesion Page Sections
   ============================================ */

.content-wrapper {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--spacing-lg);
}

.hero-section {
  position: relative;
  isolation: isolate;
  min-height: calc(100vh - var(--spacing-xl));
  width: calc(100% + 32px);
  max-width: none;
  margin-left: -16px;
  margin-right: -16px;
  border-radius: 0;
  display: flex;
  align-items: center;
  text-align: left;
  padding: var(--spacing-2xl) 0;
  background-color: transparent;
  border: 0;
  margin-bottom: 0;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  animation: hero-ken-burns 16s ease-in-out infinite alternate;
}

@keyframes hero-ken-burns {
  from {
    transform: scale(1);
  }
  to {
    transform: scale(1.12);
  }
}

.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: linear-gradient(to bottom, rgba(19, 53, 121, 55) 2%, rgba(19, 53, 121, 0) 91%);
}

.hero-section .content-wrapper {
  position: relative;
  z-index: 1;
  padding: 0 calc(var(--spacing-lg) + 8px);
  color: #ffffff;
  animation: hero-content-enter 800ms ease-out both;
}

.hero-section .tagline {
  font-size: clamp(1.25rem, 3vw, 2rem);
  color: #ffffff;
  margin-bottom: calc(var(--spacing-md) / 2);
}

.hero-section h1 {
  font-size: clamp(3rem, 8vw, 7rem);
  line-height: 0.98;
  max-width: 900px;
  color: #ffffff;
  margin-bottom: calc(var(--spacing-lg) / 2);
}

.hero-section .subtitle {
  font-size: clamp(1.25rem, 3vw, 2.25rem);
  max-width: 760px;
  color: #ffffff;
}

@keyframes hero-content-enter {
  from {
    transform: translateY(32px);
  }
  to {
    transform: translateY(0);
  }
}

.hero-scroll-indicator {
  position: absolute;
  left: 50%;
  bottom: var(--spacing-xl);
  z-index: 2;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--spacing-sm);
}

.hero-scroll-label {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: var(--font-size-sm);
  letter-spacing: 0.05em;
  color: var(--text-primary);
  text-shadow:
    -1px -1px 0 #ffffff,
    1px -1px 0 #ffffff,
    -1px 1px 0 #ffffff,
    1px 1px 0 #ffffff;
}

.hero-scroll-badge {
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-scroll-wheel {
  transform-box: fill-box;
  transform-origin: center;
  animation: hero-scroll-wheel-bob 1.8s ease-in-out infinite;
}

@keyframes hero-scroll-wheel-bob {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(8px);
  }
}

.section {
  padding: var(--spacing-2xl) 0;
  background-color: #ffffff;
  border-bottom: 1px solid var(--border-color);
  width: 100%;
  margin-bottom: var(--spacing-xl);
}

.section .content-wrapper {
  padding: 0 var(--spacing-2xl);
}

#project-model {
  width: calc(100% + 32px);
  max-width: none;
  margin-top: var(--spacing-xl);
  margin-left: -16px;
  margin-right: -16px;
  margin-bottom: var(--spacing-xl);
  border-radius: 0;
}

.project-model-media {
  width: 100%;
  margin-top: var(--spacing-lg);
}

.project-model-image {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--radius-md);
}

@media (min-width: 800px) {
  #project-model {
    flex-direction: row;
    align-items: stretch;
  }

  #project-model > .content-wrapper {
    flex: 1 1 50%;
    max-width: 50%;
    margin: 0;
  }

  .project-model-media {
    flex: 1 1 50%;
    max-width: 50%;
    margin: 0;
    padding: 0;
  }

  .project-model-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 0;
    margin: 0;
    padding: 0;
  }
}

#campaign-section {
  width: calc(100% + 32px);
  max-width: none;
  margin-left: -16px;
  margin-right: -16px;
  margin-bottom: var(--spacing-xl);
  border-radius: 0;
}

.campaign-media {
  width: 100%;
  margin-bottom: var(--spacing-lg);
}

.campaign-image {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 0;
}

@media (min-width: 800px) {
  #campaign-section {
    flex-direction: row;
    align-items: stretch;
  }

  .campaign-media {
    flex: 1 1 50%;
    max-width: 50%;
    margin: 0;
    padding: 0;
  }

  .campaign-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background-color: #ffffff;
    border-radius: 0;
    margin: 0;
    padding: 0;
  }

  #campaign-section > .content-wrapper {
    flex: 1 1 50%;
    max-width: 50%;
    margin: 0;
  }
}

#association-projects {
  width: calc(100% + 32px);
  max-width: none;
  margin-left: -16px;
  margin-right: -16px;
  margin-bottom: var(--spacing-xl);
  border-radius: 0;
}

.association-projects-container {
  width: 100%;
}

@media (min-width: 800px) {
  #assoc-projects-content {
    column-count: 2;
    column-gap: var(--spacing-2xl);
  }

  #assoc-projects-content p {
    break-inside: avoid;
  }

  #assoc-projects-content .emphasis {
    column-span: all;
    display: table;
    margin-left: auto;
    margin-right: auto;
  }

  #assoc-projects-content .emphasis-icon {
    column-span: all;
  }

  #benefits-content {
    column-count: 2;
    column-gap: var(--spacing-2xl);
  }

  #benefits-content p {
    break-inside: avoid;
  }

  /* Force the "À sa création en 2018..." paragraph to close out the left
     column instead of letting column-fill: balance decide where it lands. */
  #benefits-content > p:nth-of-type(4) {
    break-after: column;
  }
}

.section h2 {
  margin-bottom: var(--spacing-lg);
}

.project-section {
  margin: 0;
  padding: var(--spacing-lg) 0;
  background-color: #ffffff;
  border-radius: 0;
}

.project-section h3 {
  margin-bottom: var(--spacing-md);
}

.project-section ul {
  width: 66.6667%;
  margin: var(--spacing-2xl) 0;
  padding-left: 0;
}

.project-section li {
  display: flex;
  align-items: flex-start;
  gap: var(--spacing-sm);
  margin-bottom: var(--spacing-md);
  color: var(--text-secondary);
}

.mission-number {
  display: inline-flex;
  flex: 0 0 24px;
  width: 24px;
  height: 24px;
  align-items: center;
  justify-content: center;
  color: #0552AC !important;
  line-height: 1;
}

.mission-number--count {
  margin-top: 2px;
  border-radius: 50%;
  border: 1.5px solid #0552AC;
  font-size: 0.8125rem;
  font-weight: 700;
}

.project-section li:last-child {
  margin-bottom: 0;
}

.values-list {
  width: 100%;
  margin: var(--spacing-md) 0;
  padding-left: 0;
}

.values-list li {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  margin-bottom: var(--spacing-xs);
  padding: var(--spacing-md) var(--spacing-lg);
  border-radius: var(--radius-md);
  background-color: rgba(245, 245, 245, 0.5);
  backdrop-filter: blur(12px) saturate(160%);
  -webkit-backdrop-filter: blur(12px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.5);
  color: var(--text-secondary);
  font-family: var(--font-heading);
  font-weight: 700;
  cursor: pointer;
}

.values-list li:last-child {
  margin-bottom: 0;
}

b, .emphasis {
  font-family: 'Space Mono', monospace;
  display: inline-block;
  width: fit-content;
  padding: var(--spacing-xs) var(--spacing-md);
  background-color: var(--highlight-color);
  color: var(--text-primary) !important;
  border-radius: 4px;
  margin-top: var(--spacing-lg);
}

b, .emphasis * {
  color: var(--text-primary) !important;
}

@media (max-width: 799px) {
  .emphasis {
    display: block;
    width: 100%;
    box-sizing: border-box;
    padding: var(--spacing-md) var(--spacing-lg);
    border-radius: var(--radius-md);
    background-color: var(--bg-secondary);
    box-shadow: none;
  }
}

.emphasis-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 0;
  color: var(--text-primary);
}

#missions-content .emphasis-icon svg {
  will-change: transform;
}

.lighthouse-ray {
  animation: ray-blink 600ms linear infinite;
}

@keyframes ray-blink {
  0%, 16.667% {
    stroke: #ffffff;
  }
  16.7%, 50% {
    stroke: var(--highlight-color);
  }
  50.1%, 100% {
    stroke: #ffffff;
  }
}

#missions-content .project-section ul {
  margin-left: auto;
  margin-right: auto;
}

#missions-content .project-section .emphasis {
  display: table;
  margin-left: auto;
  margin-right: auto;
}

.section-intro {
  font-size: var(--font-size-lg);
  color: var(--text-secondary);
  margin-bottom: var(--spacing-lg);
}

/* Carousel Styles */
.carousel {
  position: relative;
  display: flex;
  overflow-x: auto;
  overflow-y: visible;
  gap: var(--spacing-lg);
  margin: 2rem 0;
}

.carousel-nav {
  position: absolute;
  top: 0; /* overridden in JS to center on the photo height, not the whole card */
  z-index: 5;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.5);
  background-color: rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(12px) saturate(160%);
  -webkit-backdrop-filter: blur(12px) saturate(160%);
  color: var(--text-primary);
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-50%) scale(1);
  transition: opacity 0.3s ease, background-color 0.2s ease, backdrop-filter 0.2s ease, transform 0.2s ease;
}

.carousel-nav.is-visible {
  opacity: 1;
  pointer-events: auto;
}

/* Feedback stays put (translateY(-50%) never changes) — only the blur eases
   off and the button scales up, so it never shifts position on press. */
.carousel-nav:hover,
.carousel-nav:active {
  background-color: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(6px) saturate(160%);
  -webkit-backdrop-filter: blur(6px) saturate(160%);
}

.carousel-nav:hover {
  transform: translateY(-50%) scale(1.08);
}

.carousel-nav:active {
  transform: translateY(-50%) scale(1.15);
}

.carousel-nav--prev {
  left: var(--spacing-md);
}

.carousel-nav--next {
  right: var(--spacing-md);
}

.carousel-items {
  display: flex;
  gap: var(--spacing-lg);
  padding:32px 0;
  overflow-x: auto;
  overflow-y: visible;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
}

.carousel-item {
  position: relative;
  flex: 0 0 280px;
  display: flex;
  flex-direction: column;
  background-color: #ffffff;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, filter 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}

.carousel-item:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-md);
}

.carousel-item.card-blur-pulse {
  filter: blur(6px);
}

.carousel-item img {
  width: 100%;
  aspect-ratio: 5 / 4;
  object-fit: cover;
}

.carousel-item h4 {
  padding: var(--spacing-md);
  margin: 0;
  font-size: var(--font-size-lg);
}

.carousel-item p {
  padding: 0 var(--spacing-md) var(--spacing-md) var(--spacing-md);
  margin: 0;
  font-size: var(--font-size-sm);
  color: var(--text-secondary);
}

/* Wall Section */
.wall-header {
  margin-bottom: var(--spacing-lg);
  text-align: center;
}

.wall-tagline {
  font-family: 'Vollkorn', serif;
  font-size: var(--font-size-xl);
  color: var(--text-secondary);
  margin: var(--spacing-xl) var(--spacing-xl) calc(var(--spacing-xl) * 2);
  text-align: center;
}

#wall-content {
  margin-top: var(--spacing-lg);
}

/* Instant, transition-free hide — overrides .reveal.is-visible's opacity: 1
   so the section starts invisible before the fade-in animation takes over. */
#wall-content.attention-pending {
  opacity: 0 !important;
  transition: none !important;
}

#wall-content.attention-flash {
  animation: wall-content-fade-in 0.7s ease;
}

@keyframes wall-content-fade-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  #wall-content.attention-flash {
    animation: none;
  }
}

.wall-content-title {
  margin-bottom: var(--spacing-md);
}

#wall-content img {
  max-width: 100%;
  height: auto;
  margin: var(--spacing-lg) 0;
  border-radius: var(--radius-md);
}

#wall-content b {
  background-color: var(--accent-color);
  color: #ffffff !important;
  padding: 0.05em 0.3em;
  border-radius: 4px;
}

.price-tiers {
  display: flex;
  gap: var(--spacing-lg);
  margin: var(--spacing-lg) 0;
  flex-wrap: wrap;
}

/* Contre-parties tabs (Transitions.dev tabs-sliding pattern) */
.t-tabs {
  --tabs-dur: 250ms;
  --tabs-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --tabs-text-muted: var(--text-secondary);
  --tabs-text-active: #ffffff;
  position: relative;
  display: flex;
  width: fit-content;
  align-items: center;
  gap: 3px;
  padding: 3px;
  margin: var(--spacing-md) auto 0;
  border-radius: 48px;
  background-color: var(--bg-secondary);
}

.t-tab {
  position: relative;
  appearance: none;
  width: auto;
  flex: 0 0 auto;
  white-space: nowrap;
  border: 0;
  background: transparent;
  height: 36px;
  padding: 4px 16px;
  font: inherit;
  font-size: var(--font-size-sm);
  color: var(--tabs-text-muted);
  cursor: pointer;
  border-radius: 48px;
  z-index: 1;
  transition: color var(--tabs-dur) var(--tabs-ease);
}

.t-tab:hover {
  background-color: transparent;
  box-shadow: none;
}

.t-tab[aria-selected="true"] {
  color: var(--tabs-text-active);
}

.t-tabs-pill {
  position: absolute;
  top: 3px;
  left: 0;
  height: 36px;
  width: 0;
  background-color: var(--accent-color);
  border-radius: 48px;
  transform: translateX(0);
  transition:
    transform var(--tabs-dur) var(--tabs-ease),
    width     var(--tabs-dur) var(--tabs-ease);
  will-change: transform, width;
  z-index: 0;
  pointer-events: none;
}

@media (prefers-reduced-motion: reduce) {
  .t-tabs-pill, .t-tab { transition: none !important; }
}

.price-tier {
  flex: 1;
  min-width: 150px;
  padding: var(--spacing-lg);
  background-color: #f5f5f5;
  border-radius: 16px;
  text-align: left;
}

.price-tier .amount {
  font-family: 'Space Mono', monospace;
  display: block;
  font-size: var(--font-size-xl);
  font-weight: 900;
  line-height: 0.8;
  color: var(--accent-color);
  margin-bottom: var(--spacing-sm);
}

.price-tier .description {
  display: block;
  font-size: var(--font-size-sm);
  color: var(--text-secondary);
}

.price-tiers-legend {
  font-size: var(--font-size-sm);
  color: var(--text-secondary);
}

/* Membership Tiers */
.membership-section {
  border-radius: 0;
  width: calc(100% + 32px);
  max-width: none;
  margin-left: -16px;
  margin-right: -16px;
  padding-top: 0;
  background-color: #0552AC;
  background-image: url('../media/pattern-scaled.jpg');
  background-position: center top;
  background-repeat: no-repeat;
  background-size: cover;
  background-attachment: fixed;
  border-bottom: 0;
}

.membership-section h2 {
  margin-bottom: var(--spacing-md);
}

.membership-intro {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 var(--spacing-xl) var(--spacing-2xl);
  background-color: #ffffff;
  color: #133579;
}

.badges-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-lg);
}

.tier-badge {
  height: auto;
  padding: 4px;
  cursor: pointer;
  transition: transform 0.3s ease-in-out;
}

.tier-badge:hover,
.tier-badge:focus-visible {
  transform: scale(1.08);
}

.tier-badge:active {
  transform: scale(0.92);
  transition-duration: 0.15s;
}

.membership-tier.is-anchored {
  animation: tier-anchor-pulse 1.1s ease-in-out;
}

@keyframes tier-anchor-pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(124, 58, 237, 0);
    transform: translateY(0);
  }
  30% {
    box-shadow: 0 0 0 8px rgba(124, 58, 237, 0.45);
    transform: translateY(-2px);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(124, 58, 237, 0);
    transform: translateY(0);
  }
}

.membership-intro h2 {
  margin-top: 0;
  color: #133579;
}

.membership-section .section-intro {
  max-width: 760px;
  font-size: var(--font-size-lg);
  color: #133579;
  margin-bottom: 0;
}

.membership-tiers {
  max-width: 1140px;
  display: flex;
  flex-direction: column;
  gap: var(--spacing-lg);
  margin: var(--spacing-lg) auto 0;
}

.membership-tier {
  position: relative;
  overflow: hidden;
  min-height: 229.5px;
  padding: var(--spacing-lg) var(--spacing-xl);
  background-color: var(--bg-secondary);;
  border: 0;
  border-radius: 20px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-rows: auto auto 1fr;
  column-gap: var(--spacing-xl);
  color: #133579;
  cursor: pointer;
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.625;
  transition: background-color 0.2s ease, transform 0.2s ease;
}

.tilt-glare {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0;
  border-radius: inherit;
  transition: opacity 0.3s ease;
}

.membership-tier:hover {
  background-color: var(--bg-primary);
  transform: translateY(-2px);
}

.membership-tier--sold-out {
  background-color: var(--accent-color);
  cursor: default !important;
}

.membership-tier--sold-out:hover {
  background-color: var(--accent-color);
}

.membership-tier--sold-out .tilt-glare {
  opacity: 0 !important;
}

.membership-tier--sold-out .tier-header h3,
.membership-tier--sold-out .tier-price .price,
.membership-tier--sold-out .tier-price .currency,
.membership-tier--sold-out .tier-description,
.membership-tier--sold-out .tier-perks li {
  color: #ffffff;
}

.tier-header {
  position: relative;
  z-index: 2;
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: var(--spacing-lg);
  margin-bottom: var(--spacing-md);
}

.tier-header h3 {
  margin: 0;
  font-size: clamp(1.35rem, 2.4vw, 2rem);
  color: #133579;
}

.tier-stamp {
  position: absolute;
  z-index: 1;
  display: inline-block;
  padding: 0.15em 0.6em;
  border-radius: 4px;
  background-color: #ffffff;
  color: #0552AC;
  font-family: 'Space Mono', monospace;
  font-size: var(--font-size-sm);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  pointer-events: none;
}

.tier-price {
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
  white-space: nowrap;
}

.tier-price-badge {
  height: auto;
  object-fit: contain;
  flex-shrink: 0;
  margin-right: 16px;
}

.tier-price .price {
  font-family: 'Space Mono', monospace;
  font-size: 2rem;
  line-height: 1;
  font-weight: 900;
  color: #133579;
}

.tier-price .currency {
  font-family: 'Space Mono', monospace;
  font-size: var(--font-size-xl);
  font-weight: 900;
  color: #133579;
}

.tier-description {
  grid-column: 1 / 2;
  min-height: 0;
  max-width: 760px;
  font-size: var(--font-size-base);
  color: #133579;
  margin-bottom: var(--spacing-md);
}

.tier-perks {
  grid-column: 1 / 2;
  list-style: none;
  padding: 0;
  margin: 0 0 var(--spacing-lg);
}

.tier-perks li {
  display: flex;
  align-items: flex-start;
  gap: var(--spacing-sm);
  padding: var(--spacing-sm) 0;
  color: #133579;
  font-size: var(--font-size-sm);
  border-bottom: 0;
}

.perk-icon {
  display: inline-flex;
  flex: 0 0 24px;
  width: 24px;
  height: 24px;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.tier-perks li:last-child {
  border-bottom: none;
}

/* Functional link to the wall inscription details, styled invisibly so it
   reads as plain perk text rather than a link. */
.perk-link {
  color: inherit;
  text-decoration: none;
}

/* Link inside a contrepartie's own text, jumping to another contrepartie tab. */
.tab-link {
  color: var(--accent-color);
  text-decoration: underline;
}

.membership-tier .btn {
  grid-column: 2;
  grid-row: 3;
  align-self: end;
  justify-self: end;
  width: 33px;
  min-width: 33px;
  height: 33px;
  padding: 0;
  border: 0;
  font-size: 0;
}

.membership-tier .btn::after {
  content: '→';
  display: block;
  width: 33px;
  height: 33.5px;
  color: #133579;
  font-family: var(--font-sans);
  font-size: 33px;
  font-weight: 400;
  line-height: 33px;
  text-align: center;
  vertical-align: baseline;
}

/* CTA Container */
.cta-container {
  text-align: center;
  width: 100%;
  margin: var(--spacing-2xl) 0;
  padding: var(--spacing-lg);
  background-color: #ffffff;
  border-radius: var(--radius-md);
}

.cta-subtext {
  display: block;
  width: fit-content;
  color: var(--text-secondary);
  margin: var(--spacing-md) auto 0;
}

/* Button Styles */
.btn {
  font-family: 'Space Mono', monospace;
  display: inline-block;
  padding: var(--spacing-md) var(--spacing-xl);
  border-radius: var(--radius-md);
  font-size: var(--font-size-base);
  font-weight: 900;
  text-decoration: none;
  transition: all 0.2s ease;
  border: none;
  cursor: pointer;
}

.btn-primary {
  background-color: var(--accent-color);
  color: white;
}

.btn-primary:hover {
  background-color: var(--accent-hover);
  transform: scale(1.05);
}

.btn-secondary {
  background-color: transparent;
  color: var(--accent-color);
  border: 2px solid var(--accent-color);
}

.btn-secondary:hover {
  background-color: var(--accent-color);
  color: white;
}

/* FAQ Styles */
.faq-items {
  display: flex;
  flex-direction: column;
  gap: calc(var(--spacing-lg) / 2);
}

.faq-item {
  background-color: #ffffff;
  border-radius: var(--radius-md);
  padding: var(--spacing-lg);
}

.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--spacing-md);
  width: 100%;
  background: none;
  border: none;
  padding: 0;
  text-align: left;
  cursor: pointer;
  outline: none;
  user-select: none;
  color: var(--accent-color);
  font-size: var(--font-size-lg);
}

.faq-question:focus-visible {
  outline: 2px dashed var(--focus-color);
  outline-offset: 4px;
  border-radius: 2px;
}

.faq-question:hover {
  background-color: transparent;
  box-shadow: none;
}

.faq-caret {
  flex: 0 0 24px;
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 200ms ease;
}

.faq-item.open .faq-caret {
  transform: rotate(180deg);
}

.faq-answer {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 200ms ease;
}

.faq-item.open .faq-answer {
  grid-template-rows: 1fr;
  transition: grid-template-rows 400ms ease;
}

.faq-answer-inner {
  overflow: hidden;
}

.faq-item p {
  color: var(--text-secondary);
  margin: var(--spacing-md) 0 0 0;
}

/* Header Styles */
header {
  height: 90px;
  padding: 0;
  background-color: #f5f5f5;
  border-bottom-left-radius: var(--radius-lg);
  border-bottom-right-radius: var(--radius-lg);
  display: flex;
  justify-content: center;
  align-items: center;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
}

.header-logo {
  width: 100px;
  height: auto;
  position: absolute;
  padding-top: 66px;
  cursor: pointer;
}

/* Footer Styles */
footer {
  width: 100%;
  padding: var(--spacing-xl) var(--spacing-lg);
  text-align: center;
  background-color: #ffffff;
  border-top: 2px solid var(--border-color);
  color: var(--text-secondary);
  margin-top: auto;
}

.footer-image {
  display: block;
  width: 100%;
  height: auto;
}

.legal-link {
  display: inline;
  background: none;
  border: none;
  padding: 0;
  margin: 0;
  font: inherit;
  color: var(--accent-color);
  text-decoration: underline;
  cursor: pointer;
}

.legal-link:hover {
  background-color: transparent;
  box-shadow: none;
}

/* Legal Notice Modal (no scrim) */
.legal-modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--spacing-lg);
  background-color: transparent;
}

html.modal-open,
html.modal-open body {
  overflow: hidden;
}

.legal-modal[hidden] {
  display: none;
}

.legal-modal-card {
  position: relative;
  width: 100%;
  max-width: 700px;
}

.legal-modal-content {
  position: relative;
  width: 100%;
  max-height: 80vh;
  overflow: hidden;
  background-color: #ffffff;
  border-radius: 24px;
  box-shadow: var(--shadow-lg);
  color: var(--text-secondary);
}

#legal-modal .legal-modal-content {
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
  background-color: rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(12px) saturate(160%);
  -webkit-backdrop-filter: blur(12px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.5);
}

.legal-modal-scroll {
  max-height: 80vh;
  overflow-y: auto;
  padding: var(--spacing-2xl);
}

#summary-modal .legal-modal-scroll {
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* Edge/IE legacy */
}

#summary-modal .legal-modal-scroll::-webkit-scrollbar {
  display: none; /* Chrome/Safari */
}

#summary-modal .legal-modal-card {
  max-width: 1200px;
}

#summary-modal .legal-modal-content {
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
  background-color: rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(12px) saturate(160%);
  -webkit-backdrop-filter: blur(12px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.5);
}

.glass-cta {
  position: fixed;
  left: 50%;
  bottom: var(--spacing-lg);
  z-index: 90;
  color: var(--text-primary);
  background-color: rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(12px) saturate(160%);
  -webkit-backdrop-filter: blur(12px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.5);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 150%);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.glass-cta.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, 0);
}

.legal-modal-content h3 {
  margin-top: var(--spacing-lg);
}

.legal-modal-content h3:first-child {
  margin-top: 0;
  font-size: var(--font-size-xl); /* exceptionally larger: this is the modal's main title */
}

.legal-modal-content ul {
  padding-left: var(--spacing-lg);
  margin: var(--spacing-sm) 0;
}

.legal-modal-content li {
  margin-bottom: var(--spacing-sm);
}

.legal-modal-close {
  position: absolute;
  top: -16px;
  right: -16px;
  z-index: 1;
  width: 40px;
  height: 40px;
  aspect-ratio: 1 / 1;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(5, 24, 51, 0.35);
  border: none;
  border-radius: 50%;
  font-size: var(--font-size-xl);
  line-height: 1;
  color: #ffffff;
  cursor: pointer;
}

.legal-modal-close:hover {
  background-color: rgba(5, 24, 51, 0.55);
  box-shadow: none;
}

@media (min-width: 800px) {
  .legal-modal-close {
    top: 0;
    right: -56px;
  }
}

.summary-modal-title {
  margin-top: 0;
  margin-bottom: calc(var(--spacing-lg) + 16px);
  font-size: clamp(2rem, 4.8vw, 2.8rem);
  text-align: center;
}

.summary-modal-list {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--spacing-2xl);
  text-align: center;
}

@media (max-width: 799px) {
  .summary-modal-list {
    gap: calc(var(--spacing-2xl) / 2);
  }

  .summary-modal-item {
    font-size: calc(var(--font-size-xl) * 0.8);
  }
}

.summary-modal-item {
  width: auto;
  background: none;
  padding: 0;
  text-align: center;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: calc(var(--font-size-2xl) * 0.8);
  line-height: 1.5;
  color: var(--text-primary);
  cursor: pointer;
}

.summary-modal-item-text u {
  text-decoration: none;
}

.summary-modal-item-text {
  display: inline;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
  padding-bottom: 0.1em;
  background-image: linear-gradient(currentColor, currentColor);
  background-repeat: no-repeat;
  background-position: 0 100%;
  background-size: 0% 2px;
  transition: background-size 0.3s ease;
}

.summary-modal-item:hover,
.summary-modal-item:focus-visible {
  background: none;
  box-shadow: none;
}

.summary-modal-item:hover .summary-modal-item-text,
.summary-modal-item:focus-visible .summary-modal-item-text {
  background-size: 100% 2px;
}

#summary-modal .legal-modal-card {
  transform: translateY(-120%);
  opacity: 0;
  transition: transform 0.4s ease, opacity 0.4s ease;
}

#summary-modal.is-open .legal-modal-card {
  transform: translateY(0);
  opacity: 1;
}

#summary-modal.is-closing .legal-modal-card {
  transform: translateY(120%);
  opacity: 0;
}

@media (prefers-reduced-motion: reduce) {
  #summary-modal .legal-modal-card {
    transition: none;
  }
}

.header-logo {
  cursor: pointer;
}

.hero-section {
  cursor: pointer;
}

/* Main Content */
main {
  flex: 1;
  padding-top: 0;
}

/* Section Images and Parallax */
.section-image {
  width: 100%;
  max-width: 100%;
  height: auto;
  margin: var(--spacing-2xl) 0;
  display: block;
}

.section-image-figure {
  margin: var(--spacing-2xl) 0;
}

.section-image-figure .section-image {
  margin: 0;
}

.section-image-caption {
  margin-top: 16px;
  font-size: var(--font-size-sm);
  color: var(--text-secondary);
  text-align: center;
}

.section-image-fullwidth {
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  height: 400px;
  object-fit: cover;
  margin-top: 0;
  margin-bottom: 0;
}

.parallax-section {
  background-attachment: fixed;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

.parallax-background {
  background-attachment: fixed;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  min-height: 300px;
}

/* Responsive Design */
@media (max-width: 768px) {
  .hero-section {
    min-height: calc(100vh - var(--spacing-xl));
  }

  .hero-section h1 {
    font-size: clamp(2.5rem, 13vw, 4.5rem);
  }

  .section {
    padding: var(--spacing-lg);
  }

  .membership-section {
    padding-top: 0;
  }

  .project-section ul {
    width: 100%;
  }

  .membership-tiers {
    grid-template-columns: 1fr;
  }

  .carousel-item {
    flex: 0 0 250px;
  }

  .carousel-nav--prev {
    left: var(--spacing-xs);
  }

  .carousel-nav--next {
    right: var(--spacing-xs);
  }

  .content-wrapper,
  .section .content-wrapper,
  .hero-section .content-wrapper {
    padding-left: 0;
    padding-right: 0;
  }

  .faq-item {
    padding-left: 0;
    padding-right: 0;
  }

  .price-tiers {
    flex-direction: column;
  }

  .tier-header {
    flex-direction: column;
    gap: var(--spacing-md);
  }

  .tier-price {
    margin-top: var(--spacing-sm);
  }
}

/* ============================================
   3D Tilt Cards
   ============================================ */

.tilt-card {
  transform-style: preserve-3d;
  will-change: transform;
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16'%3E%3Ccircle cx='8' cy='8' r='2' fill='%230552AC'/%3E%3C/svg%3E") 8 8, pointer;
}

.tilt-card > * {
  transform: translateZ(20px);
}

#cta-button.tilt-card,
.membership-tier.tilt-card {
  cursor: pointer;
}

/* ============================================
   Scroll Reveal
   ============================================ */

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
  transition-delay: var(--reveal-delay, 0ms);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .hero-section .content-wrapper {
    animation: none;
  }

  .hero-bg {
    animation: none;
  }

  .hero-scroll-wheel {
    animation: none;
  }

  .reveal {
    transition: none;
    opacity: 1;
    transform: none;
  }

  .lighthouse-ray {
    animation: none;
  }
}

/* ============================================
   Access Gate
   ============================================ */

.access-gate {
  position: fixed;
  top: 90px; /* leaves the fixed header visible above the scrim */
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 50; /* stays below the header's (100), which sits on top */
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--spacing-2xl);
  background-color: #133579;
  opacity: 1;
  overflow-y: auto;
  transition: opacity 0.4s ease;
}

.access-gate.is-closing {
  opacity: 0;
  pointer-events: none;
}

.access-gate[hidden] {
  display: none;
}

.access-gate-message {
  font-family: var(--font-heading);
  font-weight: 700;
  /* Scales with the viewport height (minus the header) so the message always
     fits without scrolling, while staying readable on short/tall screens. */
  font-size: clamp(1.75rem, 9vh, 140px);
  line-height: 1.15;
  color: #ffffff;
  text-align: center;
  max-width: 90vw;
  margin: 0;
}

@media (prefers-reduced-motion: reduce) {
  .access-gate {
    transition: none;
  }
}

