/*! HTML5 Boilerplate v9.0.1 | MIT License | https://html5boilerplate.com/ */

/* main.css 3.0.0 | MIT License | https://github.com/h5bp/main.css#readme */
/*
 * What follows is the result of much research on cross-browser styling.
 * Credit left inline and big thanks to Nicolas Gallagher, Jonathan Neal,
 * Kroc Camen, and the H5BP dev community and team.
 */

/* ==========================================================================
   Base styles: opinionated defaults
   ========================================================================== */

html {
  color: #222;
  font-size: 1em;
  line-height: 1.4;
}

/*
 * Remove text-shadow in selection highlight:
 * https://twitter.com/miketaylr/status/12228805301
 *
 * Customize the background color to match your design.
 */

::-moz-selection {
  background: #b3d4fc;
  text-shadow: none;
}

::selection {
  background: #b3d4fc;
  text-shadow: none;
}

/*
 * A better looking default horizontal rule
 */

hr {
  display: block;
  height: 1px;
  border: 0;
  border-top: 1px solid #ccc;
  margin: 1em 0;
  padding: 0;
}

/*
 * Remove the gap between audio, canvas, iframes,
 * images, videos and the bottom of their containers:
 * https://github.com/h5bp/html5-boilerplate/issues/440
 */

audio,
canvas,
iframe,
img,
svg,
video {
  vertical-align: middle;
}

/*
 * Remove default fieldset styles.
 */

fieldset {
  border: 0;
  margin: 0;
  padding: 0;
}

/*
 * Allow only vertical resizing of textareas.
 */

textarea {
  resize: vertical;
}

/* ==========================================================================
   Author's custom styles
   ========================================================================== */

/* --- Variables & Base --- */
:root {
  --teal: #2CB5A0;
  --teal-text: #1a857a;
  --teal-dark: #177a6e;
  --navy: #2C3E50;
  --bg-light: #f7fafa;
  --white: #fff;
  --gray-100: #f0f0f0;
  --red: #e74c3c;
  --green: #27ae60;
}

html {
  scroll-behavior: smooth;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--navy);
  background: var(--white);
  margin: 0;
  line-height: 1.6;
}

.container {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 1rem;
}

a {
  color: var(--teal-text);
  text-decoration: underline;
}

a:hover {
  color: var(--teal-dark);
}

/* --- Focus styles (WCAG 2.4.7) --- */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 2px solid var(--navy);
  outline-offset: 2px;
}

/* --- Skip link (WCAG 2.4.1) --- */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--navy);
  color: var(--white);
  padding: 0.5rem 1rem;
  z-index: 200;
  font-weight: 600;
  text-decoration: none;
}

.skip-link:focus {
  left: 0;
}

/* --- Header --- */
.site-header {
  background: var(--white);
  border-bottom: 3px solid var(--teal);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 0.75rem;
  padding-bottom: 0.75rem;
}

.logo-link {
  display: flex;
  align-items: center;
}

.logo {
  height: 98px;
  width: auto;
}

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

.nav-link {
  color: var(--navy);
  font-weight: 600;
  padding: 0.25rem 0;
  border-bottom: 2px solid transparent;
  text-decoration: none;
  transition: border-color 0.2s;
}

.nav-link:hover,
.nav-link[aria-current="page"] {
  border-bottom-color: var(--teal);
  text-decoration: none;
  color: var(--teal-text);
}

/* --- Hero --- */
.hero {
  background: var(--navy);
  color: var(--white);
  padding: 3rem 0;
  text-align: center;
}

.hero h1 {
  font-size: 2rem;
  margin: 0 0 1rem;
}

.hero-tagline {
  font-size: 1.15rem;
  max-width: 600px;
  margin: 0 auto;
  color: rgba(255, 255, 255, 0.95);
}

.btn-hero {
  display: inline-block;
  margin-top: 1.5rem;
  padding: 0.75rem 2rem;
  background: var(--teal);
  color: var(--white);
  font-weight: 600;
  font-size: 1rem;
  border-radius: 4px;
  text-decoration: none;
  transition: background 0.2s;
}

.btn-hero:hover {
  background: var(--teal-text);
  color: var(--white);
  text-decoration: none;
}

.hero-small {
  padding: 2rem 0;
}

.hero-small h1 {
  margin-bottom: 0;
}

/* --- Sections --- */
.section {
  padding: 2.5rem 0;
}

.section:nth-child(even) {
  background: var(--bg-light);
}

.section h2 {
  color: var(--navy);
  font-size: 1.5rem;
  margin: 0 0 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--teal);
  display: inline-block;
}

/* --- Mission --- */
.mission-list {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0;
}

.mission-list li {
  padding: 0.5rem 0 0.5rem 1.5rem;
  position: relative;
  font-size: 1.1rem;
}

.mission-list li::before {
  content: "\2714";
  color: var(--teal);
  position: absolute;
  left: 0;
  font-weight: bold;
}

.mission-goal {
  font-style: italic;
  color: #595959;
  font-size: 1.05rem;
}

/* --- Prestations --- */
.prestations-list {
  columns: 2;
  column-gap: 2rem;
  padding-left: 1.5rem;
  margin: 1rem 0;
}

.prestations-list li {
  padding: 0.25rem 0;
}

.prestations-note {
  font-style: italic;
  color: #595959;
  margin-top: 1rem;
}

/* --- Tarifs --- */
.tarifs-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
}

.tarifs-table th,
.tarifs-table td {
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--gray-100);
}

.tarifs-table thead th {
  background: var(--navy);
  color: var(--white);
}

.tarifs-table tbody tr:hover {
  background: var(--gray-100);
}

.tarifs-table td:last-child {
  font-weight: 700;
  white-space: nowrap;
}

.tarifs-note {
  font-size: 0.9rem;
  color: #595959;
  font-style: italic;
}

/* --- Soutenir --- */
.iban {
  font-size: 1.2rem;
  font-weight: 700;
  background: var(--gray-100);
  display: inline-block;
  padding: 0.75rem 1.5rem;
  border-radius: 4px;
  letter-spacing: 0.5px;
  font-family: "Courier New", Courier, monospace;
}

.qr-code {
  display: block;
  margin: 1.5rem 0 0;
  max-width: 180px;
}

/* --- Contact Info --- */
.contact-details p {
  font-size: 1.1rem;
  margin: 0.5rem 0;
}

/* --- Contact Form --- */
.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.35rem;
}

.required {
  color: var(--red);
}

.required-note {
  font-size: 0.9rem;
  color: #595959;
  margin-bottom: 1.5rem;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.6rem 0.75rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 1rem;
  font-family: inherit;
  transition: border-color 0.2s;
}

.form-group input:focus-visible,
.form-group textarea:focus-visible {
  border-color: var(--teal-text);
  box-shadow: 0 0 0 2px rgba(26, 133, 122, 0.3);
  outline: none;
}

.form-group input[aria-invalid="true"],
.form-group textarea[aria-invalid="true"] {
  border-color: var(--red);
}

.captcha-group input {
  max-width: 120px;
}

.btn {
  display: inline-block;
  padding: 0.75rem 2rem;
  font-size: 1rem;
  font-weight: 600;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.2s;
}

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

.btn-primary:hover {
  background: var(--teal-dark);
}

.btn:focus-visible {
  outline: 2px solid var(--navy);
  outline-offset: 2px;
}

.btn-primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.form-message {
  padding: 1rem 1.5rem;
  border-radius: 4px;
  margin-bottom: 1.5rem;
}

.form-message-success {
  background: #eafaf1;
  border: 1px solid var(--green);
  color: #1e7e34;
}

.form-message-error {
  background: #fdecea;
  border: 1px solid var(--red);
  color: #c0392b;
}

.field-error {
  color: var(--red);
  font-size: 0.9rem;
  margin-top: 0.25rem;
}

/* --- Footer --- */
.site-footer {
  background: var(--navy);
  color: var(--white);
  padding: 2rem 0;
  margin-top: 0;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-contact p {
  margin: 0.25rem 0;
}

.footer-contact a {
  color: #5cd6c3;
}

.footer-copy {
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.85rem;
}

.footer-copy p {
  margin: 0;
}

/* --- Responsive --- */
@media (max-width: 600px) {
  .hero h1 {
    font-size: 1.5rem;
  }

  .hero-tagline {
    font-size: 1rem;
  }

  .prestations-list {
    columns: 1;
  }

  .footer-inner {
    flex-direction: column;
    text-align: center;
  }

  .tarifs-table th,
  .tarifs-table td {
    padding: 0.5rem;
    font-size: 0.9rem;
  }

  .logo {
    height: 65px;
  }
}

/* ==========================================================================
   Helper classes
   ========================================================================== */

/*
 * Hide visually and from screen readers
 */

.hidden,
[hidden] {
  display: none !important;
}

/*
 * Hide only visually, but have it available for screen readers:
 * https://snook.ca/archives/html_and_css/hiding-content-for-accessibility
 *
 * 1. For long content, line feeds are not interpreted as spaces and small width
 *    causes content to wrap 1 word per line:
 *    https://medium.com/@jessebeach/beware-smushed-off-screen-accessible-text-5952a4c2cbfe
 */

.visually-hidden {
  border: 0;
  clip: rect(0, 0, 0, 0);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  white-space: nowrap;
  width: 1px;
  /* 1 */
}

/*
 * Extends the .visually-hidden class to allow the element
 * to be focusable when navigated to via the keyboard:
 * https://www.drupal.org/node/897638
 */

.visually-hidden.focusable:active,
.visually-hidden.focusable:focus {
  clip: auto;
  height: auto;
  margin: 0;
  overflow: visible;
  position: static;
  white-space: inherit;
  width: auto;
}

/*
 * Hide visually and from screen readers, but maintain layout
 */

.invisible {
  visibility: hidden;
}

/*
 * Clearfix: contain floats
 *
 * The use of `table` rather than `block` is only necessary if using
 * `::before` to contain the top-margins of child elements.
 */

.clearfix::before,
.clearfix::after {
  content: "";
  display: table;
}

.clearfix::after {
  clear: both;
}

/* ==========================================================================
   EXAMPLE Media Queries for Responsive Design.
   These examples override the primary ('mobile first') styles.
   Modify as content requires.
   ========================================================================== */

@media only screen and (min-width: 35em) {
  /* Style adjustments for viewports that meet the condition */
}

@media print,
  (-webkit-min-device-pixel-ratio: 1.25),
  (min-resolution: 1.25dppx),
  (min-resolution: 120dpi) {
  /* Style adjustments for high resolution devices */
}

/* ==========================================================================
   Print styles.
   Inlined to avoid the additional HTTP request:
   https://www.phpied.com/delay-loading-your-print-css/
   ========================================================================== */

@media print {
  *,
  *::before,
  *::after {
    background: #fff !important;
    color: #000 !important;
    /* Black prints faster */
    box-shadow: none !important;
    text-shadow: none !important;
  }

  a,
  a:visited {
    text-decoration: underline;
  }

  a[href]::after {
    content: " (" attr(href) ")";
  }

  abbr[title]::after {
    content: " (" attr(title) ")";
  }

  /*
   * Don't show links that are fragment identifiers,
   * or use the `javascript:` pseudo protocol
   */
  a[href^="#"]::after,
  a[href^="javascript:"]::after {
    content: "";
  }

  pre {
    white-space: pre-wrap !important;
  }

  pre,
  blockquote {
    border: 1px solid #999;
    page-break-inside: avoid;
  }

  tr,
  img {
    page-break-inside: avoid;
  }

  p,
  h2,
  h3 {
    orphans: 3;
    widows: 3;
  }

  h2,
  h3 {
    page-break-after: avoid;
  }

  .site-header {
    position: static;
    border-bottom: 1px solid #000;
  }

  .hero {
    padding: 1.5rem 0;
  }

  .btn-hero,
  .skip-link {
    display: none !important;
  }

  .nav-link {
    color: #000 !important;
  }

  .nav-link::after {
    content: none !important;
  }

  .site-footer {
    border-top: 1px solid #000;
    padding: 1rem 0;
  }

  .footer-contact a::after {
    content: none !important;
  }

  .tarifs-table thead th {
    border-bottom: 2px solid #000;
  }

  .tarifs-table td {
    border-bottom: 1px solid #ccc;
  }

  .section {
    padding: 1.5rem 0;
  }
}

