@tailwind base;
@tailwind components;
@tailwind utilities;

/* ══════════════════════════════════════════════════
   Variables de marque HDA
   ══════════════════════════════════════════════════ */
:root {
  --hda-green:   #00594F;
  --hda-orange:  #B94700;
  --hda-cream:   #fffbf7;
  --hda-warm:    #F2E7DD;
  --hda-border:  #e8ddd4;
  --hda-input:   #c5b8ae;
  --font-heading: 'Byrd', Georgia, serif;
  --font-body:    'Roboto', ui-sans-serif, system-ui, sans-serif;
}

/* ══════════════════════════════════════════════════
   BASE — Typographie & globals
   ══════════════════════════════════════════════════ */
@layer base {
  html {
    font-size: 16px;
  }

  body {
    font-family: var(--font-body);
    background-color: var(--hda-cream);
    color: var(--hda-green);
    line-height: 1.7;
  }

  h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    line-height: 1.25;
  }

  /* Supprime le texte noir pur — texte principal en vert HDA */
  p, li, td, dd, dt, span, label {
    color: inherit;
  }

  /* Focus orange sur tous les inputs */
  input:not([type=checkbox]):not([type=radio]):not([type=submit]):not([type=file]):not([type=button]),
  select,
  textarea {
    accent-color: var(--hda-orange);
  }

  input:not([type=checkbox]):not([type=radio]):not([type=submit]):not([type=file]):not([type=button]):focus,
  select:focus,
  textarea:focus {
    outline: none;
    border-color: var(--hda-orange) !important;
    box-shadow: 0 0 0 2px rgba(185, 71, 0, 0.15) !important;
    --tw-ring-color: transparent !important;
    --tw-ring-shadow: none !important;
  }

  /* Checkboxes & radios en orange */
  input[type=checkbox]:checked,
  input[type=radio]:checked {
    background-color: var(--hda-green);
    border-color: var(--hda-green);
  }
}

/* ══════════════════════════════════════════════════
   COMPOSANTS — Système de design HDA
   ══════════════════════════════════════════════════ */
@layer components {

  /* ── Boutons ── */
  .button-green {
    background-color: var(--hda-green);
    font-family: var(--font-heading);
    color: var(--hda-cream);
    text-align: center;
    letter-spacing: .03em;
    padding: .7rem 1.5rem;
    font-weight: 400;
    border-radius: 4px;
    transition: background-color .2s, opacity .2s;
    display: inline-block;
    line-height: 1.5;
    white-space: nowrap;
  }
  .button-green:hover { background-color: #004840; }

  .button-orange {
    background-color: var(--hda-orange);
    font-family: var(--font-heading);
    color: var(--hda-cream);
    text-align: center;
    letter-spacing: .03em;
    padding: .7rem 1.5rem;
    font-weight: 400;
    border-radius: 4px;
    transition: background-color .2s, opacity .2s;
    display: inline-block;
    line-height: 1.5;
    white-space: nowrap;
  }
  .button-orange:hover { background-color: #9c3a00; }

  .button-white {
    background-color: var(--hda-cream);
    font-family: var(--font-heading);
    color: var(--hda-green);
    text-align: center;
    letter-spacing: .03em;
    padding: .7rem 1.5rem;
    font-weight: 400;
    border-radius: 4px;
    transition: background-color .2s;
    display: inline-block;
    line-height: 1.5;
    white-space: nowrap;
  }
  .button-white:hover { background-color: #f0e8de; }

  .button-outline {
    background-color: transparent;
    font-family: var(--font-heading);
    color: var(--hda-green);
    border: 2px solid var(--hda-green);
    text-align: center;
    letter-spacing: .03em;
    padding: calc(.7rem - 2px) calc(1.5rem - 2px);
    font-weight: 400;
    border-radius: 4px;
    transition: background-color .2s, color .2s;
    display: inline-block;
    line-height: 1.5;
    white-space: nowrap;
  }
  .button-outline:hover {
    background-color: var(--hda-green);
    color: var(--hda-cream);
  }

  /* ── Cards ── */
  .card {
    background-color: var(--hda-cream);
    border: 1px solid var(--hda-border);
    border-radius: 4px;
    padding: 1.5rem;
  }

  .card-warm {
    background-color: var(--hda-warm);
    border: 1px solid #d4c4b8;
    border-radius: 4px;
    padding: 1.5rem;
  }

  /* ── Champs de formulaire ── */
  .field-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--hda-green);
    margin-bottom: 0.25rem;
  }

  .field-input {
    width: 100%;
    border: 1px solid var(--hda-input);
    border-radius: 4px;
    padding: 0.5rem 0.75rem;
    background-color: var(--hda-cream);
    color: var(--hda-green);
    font-size: 0.875rem;
    font-family: var(--font-body);
    transition: border-color .15s;
  }
  .field-input:focus {
    outline: none;
    border-color: var(--hda-orange);
    box-shadow: 0 0 0 2px rgba(185,71,0,.15);
  }
  .field-input::placeholder { color: #a09080; }

  /* ── Badges de statut ── */
  .badge {
    display: inline-flex;
    align-items: center;
    padding: 0.2rem 0.65rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 500;
  }
  .badge-pending  { background-color: var(--hda-warm);    color: var(--hda-orange); }
  .badge-approved { background-color: #d6eeeb;             color: var(--hda-green);  }
  .badge-rejected { background-color: #fee2e2;             color: #991b1b;           }

  .badge-artisan   { background-color: #d6eeeb; color: var(--hda-green);  }
  .badge-entreprise{ background-color: var(--hda-warm); color: var(--hda-orange); }
  .badge-etudiant  { background-color: #f0ebe4; color: #5a5a5a; }
  .badge-benevole  { background-color: #ede9f6; color: #5b21b6; }
  .badge-admin     { background-color: #fef3c7; color: #92400e; }

  /* ── Flash messages ── */
  .flash-notice {
    background-color: #d6eeeb;
    border-left: 3px solid var(--hda-green);
    color: var(--hda-green);
    padding: 0.875rem 1.25rem;
    border-radius: 4px;
    font-size: 0.9rem;
  }
  .flash-alert {
    background-color: #fde8dc;
    border-left: 3px solid var(--hda-orange);
    color: var(--hda-orange);
    padding: 0.875rem 1.25rem;
    border-radius: 4px;
    font-size: 0.9rem;
  }

  /* ── Section alternée ── */
  .section-cream { background-color: var(--hda-cream); }
  .section-warm  { background-color: var(--hda-warm);  }
  .section-green {
    background-color: var(--hda-green);
    color: var(--hda-cream);
  }

  /* ── Séparateur de section ── */
  .section-title {
    font-family: var(--font-heading);
    color: var(--hda-green);
    text-align: center;
  }
  .section-subtitle {
    color: #6b7a78;
    text-align: center;
    font-size: 1rem;
    line-height: 1.7;
  }

  /* ── Tableau admin ── */
  .table-header-cell {
    padding: 0.75rem 1.25rem;
    text-align: left;
    font-size: 0.7rem;
    font-weight: 600;
    color: #6b7a78;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    background-color: var(--hda-warm);
  }
  .table-cell {
    padding: 0.875rem 1.25rem;
    font-size: 0.875rem;
    color: var(--hda-green);
    border-bottom: 1px solid var(--hda-border);
  }
}
@font-face {
  font-family: 'Byrd';
  src: url('/assets/Byrd - Titres/Byrd-Regular-e7eda7698fe87b8e997b4811e2b8d595ff27b0791de952753387437aebcde25f.otf') format('opentype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Byrd';
  src: url('/assets/Byrd - Titres/Byrd-RegularItalic-7ea46edd0d60756da403cc38469fede970247e027fa2603d65a0261fb9c25d53.otf') format('opentype');
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: 'Byrd';
  src: url('/assets/Byrd - Titres/Byrd-Bold-374118b674a6a7b51fea6b982c2236c7e78d8342dfb6fecdc69345974734204f.otf') format('opentype');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Byrd';
  src: url('/assets/Byrd - Titres/Byrd-BoldItalic-9e01c215ff7bb52cfb103ecfc686659e66612c4c804f6c4d2fd9037d6acddd3d.otf') format('opentype');
  font-weight: 700;
  font-style: italic;
  font-display: swap;
}
/*
 * This is a manifest file that'll be compiled into application.css, which will include all the files
 * listed below.
 *
 * Any CSS (and SCSS, if configured) file within this directory, lib/assets/stylesheets, or any plugin's
 * vendor/assets/stylesheets directory can be referenced here using a relative path.
 *
 * You're free to add application-wide styles to this file and they'll appear at the bottom of the
 * compiled file so the styles you add here take precedence over styles defined in any other CSS
 * files in this directory. Styles in this file should be added after the last require_* statement.
 * It is generally better to create a new file per style scope.
 *


 */
