/* ========================================================================== */
/* RESET & ROOT */
/* ========================================================================== */
* { margin: 0; padding: 0; box-sizing: border-box; }

html, body {
    width: 100%; height: 100%;
    overflow: hidden;
    font-family: Arial, sans-serif;
    background: var(--background-light, #f4f4f4) !important;
}

:root {
    --ui-bg: rgba(255,255,255,0.92);
    --ui-fg: #1a1a1a;
    --ui-border: #e0e0e0;
    --ui-shadow: 0 4px 12px rgba(0,0,0,0.2);
    --background-light: #f4f4f4;

    --text-main: #333;
    --text-secondary: #555;
    --interactive: #8B8B8B;
    --icon: #C0C0C0;
    --highlight: #FFD700;

    --color-1: #F3D9DC;
    --color-2: #F7E6CF;
    --color-3: #FFF9D9;
    --color-4: #D6ECD2;
    --color-5: #D9E8F6;
    --color-6: #E6DAF1;
    --color-7: #FAF9F6;
    --color-8: #000000;
}



/* ========================================================================== */
/* HEADER */
/* ========================================================================== */
.ui-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;

    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 20px;

    z-index: 2000;
}

.ui-header,
.ui-header * {
    pointer-events: auto !important;
}

.ui-header-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.ui-header-right {
    margin-left: auto; /* Ã¢Â­Â Le menu langue va Ãƒ  droite */
}

.ui-burger {
    width: 42px; height: 42px;
    border-radius: 50%;
    background: var(--ui-bg);
    border: 1px solid var(--ui-border);
    display: flex; justify-content: center; align-items: center;
    cursor: pointer;
    box-shadow: var(--ui-shadow);
}





.ui-brand {
    padding-left: 25px;
    font-size: 20px;
    font-weight: bold;
    color: #fff;
    text-shadow: 1px 1px 2px rgba(255,255,255,0.35), -1px -1px 2px rgba(0,0,0,0.25);
    pointer-events: none;
}
.ui-brand .subtitle { font-size: 13px; opacity: .95; }




/* ========================================================================== */
/* WRAPPER */
/* ========================================================================== */
.wrapper {
    width: 90%; max-height: 80vh;
    margin: auto; padding: 20px;
    background: #fff; border-radius: 8px; opacity: .75;
    overflow-y: auto; overflow-x: hidden;
    font-family: Arial, sans-serif; line-height: 1.6;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
      z-index: 0;
}

.wrapper > .title {
    text-align: center;
    font-size: 2.4em; font-weight: 700;
    margin: 2rem 0 1.5rem;
    color: #222;
    letter-spacing: .5px;
}

.wrapper > h2,
.wrapper > h3,
.wrapper > h4,
.wrapper > h5,
.wrapper > h6 {
    color: #333; font-weight: 600;
    line-height: 1.3;
    margin: 2em 0 .5em;
}

.wrapper > h2 { font-size: 1.6em; padding-bottom: .3em; }
.wrapper > h3 { font-size: 1.4em; }
.wrapper > h4 { font-size: 1.2em; font-weight: 500; }
.wrapper > h5 { font-size: 1em;   font-weight: 500; color: #555; }
.wrapper > h6 { font-size: .9em;  font-weight: 500; color: #777; text-transform: uppercase; letter-spacing: .5px; }


.article {
    max-width: 920px;
    width: 100%;
    margin: 0 auto;          /* centre l'article */
    padding: 0 20px;         /* respire sur mobile */
    box-sizing: border-box;
}

.article .title {
  font-size: 2rem;
  text-align: center;
  margin-bottom: 1rem;
  color: var(--text-main, #333);
}

.article .lead {
  font-style: italic;
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
  color: #555;
}

.article p {margin-bottom: 1rem;}

.article-image {
  margin: 2rem auto;
  text-align: center;
  max-width: 100%;
  overflow: hidden;
}

.article-image img {
  width: 100%;
  height: auto;
  border-radius: 1rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease;
  max-height: 600px;
}


.page-title {
  text-align: center;
  font-size: 2rem;
  margin: 2rem 0;
}


.content a {
    color: #333;                     /* lisible et neutre */
    text-decoration: none;           /* pas d'underline moche */
    border-bottom: 1px solid #333;   /* soulignement propre */
    cursor: pointer;
    transition: color 0.15s ease, border-color 0.15s ease;
}

.content a:hover {
    color: #000;                     /* lÃƒÂ©ger foncÃƒÂ© */
    border-bottom-color: #000;       /* underline plus net */
} 
.astro-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: center;
  padding: 1rem;
}

.astro-card {
  width: 300px;
  background: #fff;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.05);
  transition: transform 0.2s ease;
}

.astro-card:hover {
  transform: translateY(-4px);
}

.astro-card a {
  text-decoration: none;
  color: inherit;
}

.astro-thumb img {
  width: 150px;
  height: 85px;
  object-fit: cover;
  display: block;
}

.astro-body {
  padding: 1rem;
}

.astro-body h2 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
  color: #222;
}

.excerpt {
  font-size: 0.95rem;
  color: #555;
  margin-bottom: 1rem;
}

.read-more  {
  font-weight: bold;
  color: #0077cc; 
}

.pagination {
  text-align: center;
  margin: 2rem 0;
}

.pagination a {
  margin: 0 1rem;
  text-decoration: none;
  color: #0077cc;
  font-weight: bold;
}

/* ========================================================================== */
/* LANG-MENU (RÃƒâ€°DUIT) */
/* ========================================================================== */
.lang-menu {
    position: relative;
    display: inline-block;
    z-index: 10000;
}

.lang-menu .lang-current,
.lang-menu .lang-list {
    background: #fff;
    border: 1px solid #ccc;
    border-radius: 12px;
}

.lang-menu .lang-current {
    padding: 6px 14px;
    cursor: pointer;
    font-size: 14px;
}

.lang-menu .lang-list {
    position: absolute;
    top: 10; right: 0;
    list-style: none;
    margin: 0; padding: 6px 0;
    display: none;
    z-index: 10001;
}

.lang-menu .lang-list {
    display: none;
}

.lang-menu.open .lang-list {
    display: block;
}

.lang-menu .lang-list a {
    display: block;
    padding: 8px 12px;
    color: #333; text-decoration: none;
}
.lang-menu .lang-list a:hover { background: #eee; }


/* ========================================================================== */
/* MAIN */
/* ========================================================================== */
.ui-main {
    position: relative;
    padding: 80px 20px;
    height: 100vh;
    z-index: 0;
    pointer-events: auto;
    overflow-y: auto;
}

/* GRID : 1 colonne large + 3 normales */
.grid-4 {
    display: grid;
    grid-template-columns: 33% 22% 22% 22%;
    gap: 9px;
    width: 100%;
    margin-top: 4px;
    align-items: flex-start;   /* Ã¢Â­Â IMPORTANT : plus juste que center */
    justify-content: center;
}

.grid-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 9px;
}

/* --- TILES --- */
.tile,
.tile-small {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    width: 100%;
    max-width: 180px;     /* Ã¢Â­Â remplace tes 130px fixes */
    aspect-ratio: 1 / 1;  /* Ã¢Â­Â rond 100% responsive */

    border-radius: 50%;
    cursor: pointer;
    text-align: center;

    transition: transform .25s ease, box-shadow .25s ease;
}

/* Explore */
.tile-large {
    width: 100%;
    aspect-ratio: 1 / 1;
    border-radius: 20px;
    padding: 20px;
max-width: 100% !important;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Hover */
.tile:hover {
    transform: translateY(-6px);
    box-shadow: 0 8px 22px rgba(0,0,0,0.2);
}

/* Symboles */
.symbol {
    font-size: 38px;
    margin-bottom: 8px;
    pointer-events: none;
}

.circle-logo {
    width: 80%;
    max-width: 300px;
    height: auto;
    object-fit: contain;
    display: block;
    margin: 0 auto;
}

.tile p {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
    color: var(--ui-fg);
}



/* BARRE DE RECHERCHE */
.search-container {
    position: relative;
    max-width: 420px;
    margin: 0 auto 25px;
}

.search-container input {
    width: 100%;
    padding: 12px 14px;
    font-size: 15px;

    border-radius: 12px;
    border: 1px solid #ccc;
    outline: none;

    background: rgba(255,255,255,0.75);
    backdrop-filter: blur(4px);
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  background-color: rgba(255, 255, 255, 0.8);
  padding: 1.5rem;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  font-family: Helvetica, Arial, sans-serif;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 1rem 1.2rem;       /* plus grand padding */
  font-size: 1.05rem;         /* texte plus grand */
  font-family: Helvetica, Arial, sans-serif;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 8px;
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.06);
  transition: border 0.3s ease, box-shadow 0.3s ease;
  color: var(--text-main);
}

/* focus visuel */
.contact-form input:focus,
.contact-form textarea:focus {
  border-color: var(--highlight);
  box-shadow: 0 0 0 3px rgba(255, 215, 0, 0.25);
  outline: none;
}

/* zone de message plus haute */
.contact-form textarea {
  min-height: 160px;
  resize: vertical;
}

/* labels plus espacés et visibles */
.contact-form label {
  font-weight: 600;
  font-size: 1rem;
  margin-bottom: 0.5rem;
  color: var(--text-secondary);
}
.contact-form button {
  padding: 0.8rem 1.2rem;
  background-color: var(--highlight);
  color: #333;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  font-size: 1rem;
  transition: background-color 0.3s ease, transform 0.2s ease;
}

.contact-form button:hover {
  background-color: #e6c200;
  transform: translateY(-2px);
}

.alert {
  padding: 1rem;
  border-radius: 6px;
  font-size: 0.9rem;
}

.alert-success {
  background-color: #d4edda;
  color: #155724;
}

.alert-danger {
  background-color: #f8d7da;
  color: #721c24;
}

/* SUGGESTIONS */
#suggestions {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;

    background: white;
    border: 1px solid #ddd;
    border-radius: 12px;
    list-style: none;
    margin: 0;
    padding: 6px 0;
    z-index: 10;
    box-shadow: 0 4px 18px rgba(0,0,0,0.15);
}

#suggestions.visible {
    display: block;
}

#suggestions li a {
    display: block;
    padding: 10px 14px;
    text-decoration: none;
    color: #333;
}

#suggestions li a:hover {
    background: #f0f0f0;
}

/* BOUTONS DU HERO */
.hero-global button {
    padding: 10px 16px;
    margin: 0 6px;

    border: 1px solid var(--ui-border);
    border-radius: 10px;

    background: var(--ui-bg);
    color: var(--ui-fg);

    cursor: pointer;
    box-shadow: var(--ui-shadow);

    transition: transform .25s, box-shadow .25s;
}

.hero-global button:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}


.hero-global {
    display: flex;
    flex-direction: column;
    align-items: center; 
    justify-content: center;
    margin-top: 20px;
}

.hero-logo img {
    width: 260px;
    opacity: 0;
    animation: fadeIn 1.2s ease forwards;
}

.hero-intro {
    text-align: center;
    margin-top: 25px;
    opacity: 0;
    animation: fadeIn 1.6s ease forwards;
}

.hero-intro h1 {
    font-size: 1.9rem;
    font-weight: 300;
    color: #444;
    margin-bottom: 8px;
}

.hero-intro p {
    font-size: 1.1rem;
    color: #666;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* =========================================================
   CANVAS MODE — UI SITE OFF
   ========================================================= */

body.module-active .lang-menu {
    pointer-events: none;
}
body.canvas-ui-hidden .ui-footer,
body.canvas-ui-hidden nav,
body.canvas-ui-hidden .lang-menu,
body.canvas-ui-hidden .support-btn,
body.canvas-ui-hidden .site-ui {
  display: none !important;
  pointer-events: none;
}
/* ========================================================================== */
/* FOOTER */
/* ========================================================================== */
.ui-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 12px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: transparent;
    z-index: 20;
}

.footer-left ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 20px;
}

.footer-left a {
    color: #333;
    text-decoration: none;
    font-size: 14px;
    opacity: .85;
}

.footer-left a:hover {
    opacity: 1;
}

/* BOUTON BUY ME A COFFEE */
.coffee-btn {
    padding: 10px 18px;
    border-radius: 8px;
    border: 1px solid var(--ui-border);
    background: var(--ui-bg);
    color: var(--ui-fg);
    text-decoration: none;
    box-shadow: var(--ui-shadow);
    transition: transform .25s, box-shadow .25s;
}

.coffee-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}




/* ========================================================================== */
/* CLOSE SCENE BUTTON */
/* ========================================================================== */
.ui-close-scene {
    position: fixed;
    top: 15px; right: 15px;
    width: 42px; height: 42px;
    border: none; border-radius: 50%;
    background: var(--ui-bg);
    color: var(--ui-fg);
    display: flex; justify-content: center; align-items: center;
    cursor: pointer;
    z-index: 40;
    box-shadow: var(--ui-shadow);
}

.hidden { display: none !important; }


/* ========================================================================== */
/* UTILITIES */
/* ========================================================================== */
.glass {
    background: rgba(255,255,255,0.75);
    backdrop-filter: blur(6px);
    border-radius: 16px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.btn-round {
    border-radius: 50%;
    background: rgba(255,255,255,0.25);
    border: 2px solid rgba(255,255,255,0.35);
    backdrop-filter: blur(6px);
    display: flex; align-items: center; justify-content: center;
    cursor: pointer;
    transition: .25s;
}

.card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.grid { display: grid; gap: 20px; }

.hover-up:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.2);
}

.input {
    background: #fff;
    border: 1px solid #ccc;
    border-radius: 8px;
    padding: 12px;
}

.fixed-bottom-right { position: fixed; bottom: 20px; right: 20px; }
.fixed-bottom-left  { position: fixed; bottom: 20px; left: 20px; }

.gold-text {
    background-image: linear-gradient(#e5c55a, #b89d42);
    -webkit-background-clip: text;
    color: transparent;
}

/* ==========================================================================
   CANVAS — GLOBAL
   ========================================================================== */
canvas {
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 5 !important;
    pointer-events: none; /* activé uniquement si module actif */
}

/* ========================================================================== */
/* THREE.JS CONTAINER — Mini → Fullscreen */
/* ========================================================================== */

#threejs-container {
    position: absolute;
    top: 10px;
    right: 10px;

    width: 50px;
    height: 50px;

    background: transparent;
    overflow: hidden;
    border-radius: 50%;

    opacity: 0;
    pointer-events: none;

    transition: all 1s ease-in-out;
    z-index: 1;
}

/* Mode FULLSCREEN 3D */
#threejs-container.active {
    top: 0;
    right: 0;

    width: 100%;
    height: 100%;
    background: #000;

    border-radius: 0;
    opacity: 1;
    pointer-events: auto;

    z-index: 5;
}

/* Canvas interactif seulement si module 3D actif */
body.module-active #threejs-container,
body.module-active #threejs-container canvas {
    pointer-events: auto;
}

/* ======================================================================
   CLOSE SCENE BUTTON — FINAL
   ====================================================================== */

#close-scene-btn {
    position: fixed;
    top: 10px;
    right: 20px;

    width: 25px;
    height: 25px;

    display: flex;
    align-items: center;
    justify-content: center;

    background: rgba(255, 255, 255, 0.22);
    border: 2px solid rgba(255, 255, 255, 0.35);
    border-radius: 50%;

    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);

    cursor: pointer;

    opacity: 0;
    transform: scale(0.85);
    pointer-events: none;

    transition:
        opacity 0.35s ease,
        transform 0.35s ease,
        background 0.25s ease,
        box-shadow 0.25s ease;

    z-index: 10000;
}

#close-scene-btn i {
    font-size: 1.2rem;
    color: #fff;
    text-shadow: 0 0 8px rgba(0,0,0,0.45);
}

/* === Visible UNIQUEMENT quand module actif === */
body.module-active #close-scene-btn {
    opacity: 1;
    transform: scale(1);
    pointer-events: auto;
}

/* Hover */
#close-scene-btn:hover {
    background: rgba(255,255,255,0.4);
    box-shadow: 0 6px 20px rgba(0,0,0,0.25);
}


