/* =========================================================================
   SEXY NAN'AS — Page d'accueil
   (le hub afterwork utilise encore assets/style.css)
   ========================================================================= */
:root {
    --night: #070d1f;
    --navy: #0a1128;
    --panel: #111a3a;
    --panel-2: #16224a;
    --line: rgba(255, 255, 255, 0.1);
    --red: #ff2a40;
    --orange: #ff8a1f;
    --leaf: #37c871;
    --gold: #ffd166;
    --text: #ffffff;
    --muted: #a7b3cc;
    --radius: 16px;
    --header-h: 68px;
    --font-display: 'Teko', 'Arial Narrow', sans-serif;
    --font-body: 'Poppins', system-ui, sans-serif;
    --font-script: 'Kaushan Script', cursive;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); -webkit-text-size-adjust: 100%; }
body {
    font-family: var(--font-body);
    background: var(--navy);
    color: var(--text);
    line-height: 1.55;
    min-height: 100vh;
    overflow-x: hidden;
}
body.editing { padding-bottom: 96px; }
body.no-scroll { overflow: hidden; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
button, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
[hidden] { display: none !important; }

/* ---------- Header ---------- */
.site-header {
    position: sticky; top: 0; z-index: 100;
    height: var(--header-h);
    display: flex; align-items: center; justify-content: space-between; gap: 16px;
    padding: 0 clamp(16px, 4vw, 40px);
    background: rgba(7, 13, 31, 0.86);
    -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; min-width: 0; }
.brand img { height: 44px; width: auto; }
.brand span {
    font-family: var(--font-display); font-size: 1.7rem; font-weight: 500;
    letter-spacing: 1px; text-transform: uppercase; line-height: 1; white-space: nowrap;
}
.brand span b { font-family: var(--font-script); font-weight: 400; color: var(--red); text-transform: none; letter-spacing: 0; margin-right: 4px; }

.site-nav { display: flex; align-items: center; gap: 26px; }
.site-nav a {
    font-family: var(--font-display); font-size: 1.35rem; text-transform: uppercase;
    letter-spacing: 0.5px; text-decoration: none; padding: 6px 0; position: relative;
    transition: color 0.2s;
}
.site-nav a.btn {
    font-family: var(--font-body); font-size: 0.85rem; text-transform: none;
    letter-spacing: 0; padding: 8px 16px;
}
.site-nav a:not(.btn)::after {
    content: ''; position: absolute; left: 0; right: 100%; bottom: 0; height: 2px;
    background: var(--orange); transition: right 0.25s;
}
.site-nav a:not(.btn):hover { color: var(--orange); }
.site-nav a:not(.btn):hover::after { right: 0; }

.nav-toggle {
    display: none; width: 44px; height: 44px; border: 1px solid var(--line);
    background: transparent; border-radius: 10px; font-size: 1.2rem;
}

/* ---------- Boutons ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 10px;
    padding: 12px 22px; border-radius: 999px; border: 1px solid transparent;
    font-family: var(--font-body); font-weight: 600; font-size: 0.95rem;
    text-decoration: none; text-transform: none; letter-spacing: 0; line-height: 1.2;
    transition: transform 0.2s, box-shadow 0.2s, background 0.2s, color 0.2s;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--orange); color: #1a0d00; }
.btn-primary:hover { box-shadow: 0 8px 24px rgba(255, 138, 31, 0.35); }
.btn-ghost { border-color: rgba(255, 255, 255, 0.3); background: rgba(255, 255, 255, 0.04); color: var(--text); }
.btn-ghost:hover { border-color: var(--text); }
.btn-insta { background: linear-gradient(45deg, #f09433, #dc2743 50%, #bc1888); color: #fff; }
.btn-insta:hover { box-shadow: 0 8px 24px rgba(220, 39, 67, 0.4); }
.btn-gold { border-color: var(--gold); color: var(--gold); background: rgba(255, 209, 102, 0.08); }
.btn-gold:hover { background: var(--gold); color: #201500; }
.btn-save { background: var(--leaf); color: #04200f; }
.btn-danger { border-color: var(--red); color: var(--red); background: rgba(255, 42, 64, 0.08); }
.btn-danger:hover { background: var(--red); color: #fff; }
.btn-sm { padding: 8px 14px; font-size: 0.85rem; }
.btn[disabled] { opacity: 0.5; pointer-events: none; }

/* ---------- Hero ---------- */
.hero {
    position: relative; overflow: hidden; isolation: isolate;
    padding: clamp(36px, 7vw, 80px) clamp(16px, 4vw, 40px) clamp(40px, 6vw, 72px);
    background:
        radial-gradient(ellipse 70% 60% at 78% 30%, rgba(255, 138, 31, 0.13), transparent 70%),
        radial-gradient(ellipse 60% 70% at 10% 0%, #1b2b5c 0%, transparent 70%),
        linear-gradient(180deg, var(--night), var(--navy));
    border-bottom: 1px solid var(--line);
}
.hero-beam {
    position: absolute; left: 0; top: 0; z-index: -1; width: 160vmax; height: 160vmax;
    background: conic-gradient(from 96deg at 0 0, transparent 0deg, rgba(255, 220, 150, 0.17) 9deg, transparent 24deg);
    transform-origin: 0 0; animation: sweep 10s ease-in-out infinite alternate; pointer-events: none;
}
@keyframes sweep { from { transform: rotate(-14deg); } to { transform: rotate(26deg); } }

.hero-inner {
    max-width: 1200px; margin: 0 auto;
    display: grid; grid-template-columns: 1.05fr 0.95fr; gap: clamp(24px, 5vw, 64px); align-items: center;
}
.hero-eyebrow {
    display: inline-flex; align-items: center; gap: 10px;
    font-size: 0.8rem; font-weight: 600; letter-spacing: 2.5px; text-transform: uppercase; color: var(--gold);
    margin-bottom: 14px;
}
.hero-eyebrow::before { content: ''; width: 28px; height: 2px; background: var(--gold); }
.hero h1 {
    font-family: var(--font-display); font-weight: 700; text-transform: uppercase;
    font-size: clamp(3rem, 8.2vw, 6.2rem); line-height: 0.92; letter-spacing: 0.5px;
    text-wrap: balance;
}
.hero-text { margin-top: 18px; max-width: 46ch; font-size: clamp(1rem, 1.6vw, 1.15rem); color: #d6def0; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.hero-logo { justify-self: center; width: min(100%, 520px); filter: drop-shadow(0 24px 50px rgba(0, 0, 0, 0.55)); animation: float 7s ease-in-out infinite; }
@keyframes float { 0%, 100% { transform: translateY(0) rotate(-1.5deg); } 50% { transform: translateY(-10px) rotate(1deg); } }

/* Prochain événement */
.next-event {
    max-width: 1200px; margin: clamp(32px, 5vw, 56px) auto 0;
    display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 20px 32px;
    padding: 22px clamp(18px, 3vw, 32px);
    background: linear-gradient(120deg, rgba(22, 34, 74, 0.92), rgba(17, 26, 58, 0.82));
    border: 1px solid var(--line); border-left: 4px solid var(--orange); border-radius: var(--radius);
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
}
.next-label { font-size: 0.75rem; font-weight: 600; letter-spacing: 2.5px; text-transform: uppercase; color: var(--orange); }
.next-title { font-family: var(--font-display); font-size: clamp(1.8rem, 3.6vw, 2.6rem); font-weight: 500; text-transform: uppercase; line-height: 1; margin-top: 4px; }
.next-meta { color: var(--muted); font-size: 0.95rem; margin-top: 4px; }
.countdown { display: flex; gap: 8px; }
.countdown div {
    min-width: 64px; padding: 8px 6px 6px; text-align: center; border-radius: 12px;
    background: rgba(7, 13, 31, 0.7); border: 1px solid var(--line);
}
.countdown b { display: block; font-family: var(--font-display); font-size: 2.3rem; font-weight: 500; line-height: 1; font-variant-numeric: tabular-nums; }
.countdown span { font-size: 0.65rem; letter-spacing: 1.5px; text-transform: uppercase; color: var(--muted); }

/* ---------- Sections ---------- */
main { max-width: 1200px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 40px); }
.section { padding: clamp(48px, 7vw, 84px) 0 0; }
.section-title {
    display: flex; align-items: center; gap: 14px; margin-bottom: 28px;
    font-family: var(--font-display); font-weight: 500; text-transform: uppercase;
    font-size: clamp(2.2rem, 5vw, 3.2rem); line-height: 1;
}
.section-title i { font-size: 0.6em; color: var(--orange); }
.section-title::after { content: ''; flex: 1; height: 1px; background: linear-gradient(90deg, var(--line), transparent); }

/* ---------- Événements ---------- */
.events-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 18px; }
.event-card {
    position: relative; display: grid; grid-template-columns: 78px 1fr; gap: 6px 18px; align-items: start;
    padding: 22px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
    transition: transform 0.25s, border-color 0.25s;
}
.event-card:hover { transform: translateY(-4px); border-color: rgba(255, 138, 31, 0.5); }
.event-date {
    grid-row: span 3; padding: 10px 6px; text-align: center; border-radius: 12px;
    background: rgba(255, 138, 31, 0.1); border: 1px solid rgba(255, 138, 31, 0.35);
    font-family: var(--font-display); font-size: 1.9rem; font-weight: 500; line-height: 0.95; color: var(--orange);
    text-transform: uppercase; word-spacing: 100vw;
}
.event-title { font-family: var(--font-display); font-size: 1.75rem; font-weight: 500; text-transform: uppercase; line-height: 1.05; }
.event-details { color: var(--muted); font-size: 0.95rem; }
.event-details i { margin-right: 6px; color: var(--orange); }
.event-card .btn { justify-self: start; margin-top: 10px; }
.event-card.is-next { border-color: var(--orange); box-shadow: 0 0 0 1px var(--orange), 0 14px 40px rgba(255, 138, 31, 0.12); }
.event-badge {
    position: absolute; top: -10px; right: 16px; padding: 3px 12px; border-radius: 999px;
    background: var(--orange); color: #1a0d00; font-size: 0.7rem; font-weight: 700; letter-spacing: 1px; text-transform: uppercase;
}
.event-card.is-past { opacity: 0.55; }
.event-card.is-past .event-badge { background: var(--muted); }

/* ---------- Clip ---------- */
.clip {
    position: relative; aspect-ratio: 16 / 9; width: 100%; overflow: hidden;
    border-radius: var(--radius); border: 1px solid var(--line); background: #000;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
}
.clip iframe, .clip img { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; object-fit: cover; }
.clip-play {
    position: absolute; inset: 0; width: 100%; border: 0; display: grid; place-items: center;
    background: linear-gradient(180deg, rgba(7, 13, 31, 0.1), rgba(7, 13, 31, 0.55));
}
.clip-play span {
    width: 84px; height: 84px; border-radius: 50%; display: grid; place-items: center; padding-left: 6px;
    background: var(--red); color: #fff; font-size: 1.8rem; box-shadow: 0 10px 40px rgba(255, 42, 64, 0.5);
    transition: transform 0.2s;
}
.clip-play:hover span { transform: scale(1.1); }

/* ---------- Équipe ---------- */
.manifesto {
    max-width: 820px; margin: 0 auto 8px; padding: 22px 26px; text-align: center;
    font-size: clamp(1rem, 1.7vw, 1.15rem); font-style: italic; color: #dfe6f5; white-space: pre-line;
    background: rgba(255, 42, 64, 0.06); border-left: 4px solid var(--red); border-radius: 0 var(--radius) var(--radius) 0;
}
.pole-title {
    display: flex; align-items: baseline; gap: 12px; margin: 44px 0 18px;
    font-family: var(--font-display); font-size: clamp(1.7rem, 3.4vw, 2.3rem); font-weight: 500; text-transform: uppercase; color: var(--red); line-height: 1;
}
.pole-title small { font-family: var(--font-body); font-size: 0.8rem; font-weight: 400; color: var(--muted); text-transform: none; }
.team-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(168px, 1fr)); gap: 16px; }
.member { text-align: center; }
.member-frame {
    position: relative; display: block; width: 100%; aspect-ratio: 720 / 988; overflow: hidden; padding: 0;
    border: 1px solid var(--line); border-radius: 14px; background: var(--panel);
    transition: transform 0.25s, box-shadow 0.25s, border-color 0.25s;
}
button.member-frame:hover { transform: translateY(-5px) rotate(-1deg); border-color: var(--orange); box-shadow: 0 16px 36px rgba(0, 0, 0, 0.5); }
.member-frame img { width: 100%; height: 100%; object-fit: cover; }
.member-initials {
    width: 100%; height: 100%; display: grid; place-items: center;
    background:
        radial-gradient(circle at 50% 42%, rgba(255, 138, 31, 0.2), transparent 55%),
        linear-gradient(160deg, var(--panel-2), var(--night));
    font-family: var(--font-display); font-size: 4.4rem; font-weight: 500; color: var(--orange); letter-spacing: 2px;
}
.member-name { margin-top: 10px; font-weight: 600; font-size: 0.98rem; line-height: 1.25; }
.member-role { display: inline-block; margin-top: 4px; font-size: 0.72rem; font-weight: 600; letter-spacing: 1px; text-transform: uppercase; color: var(--gold); }

/* ---------- Galerie ---------- */
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.photo-card { aspect-ratio: 4 / 3; overflow: hidden; padding: 0; border: 1px solid var(--line); border-radius: 14px; background: var(--panel); }
.photo-card img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s; }
.photo-card:hover img { transform: scale(1.06); }

/* ---------- Boîte à idées ---------- */
.idea-box { background: var(--panel); border: 1px solid var(--line); border-left: 4px solid var(--gold); border-radius: var(--radius); padding: clamp(20px, 4vw, 36px); }
.idea-box p { color: var(--muted); margin-bottom: 18px; }
.field {
    width: 100%; padding: 13px 14px; margin-bottom: 14px; border-radius: 10px;
    background: rgba(7, 13, 31, 0.7); border: 1px solid var(--line); color: var(--text); font-size: 1rem;
    transition: border-color 0.2s;
}
.field:focus { outline: none; border-color: var(--gold); }
textarea.field { resize: vertical; min-height: 110px; }

/* ---------- Footer ---------- */
.site-footer { margin-top: clamp(56px, 8vw, 96px); padding: 44px 20px 36px; text-align: center; background: var(--night); border-top: 2px solid var(--red); }
.site-footer img { height: 84px; width: auto; margin: 0 auto 12px; }
.footer-title { font-family: var(--font-display); font-size: 2rem; font-weight: 500; letter-spacing: 1px; text-transform: uppercase; }
.site-footer p { color: var(--muted); font-size: 0.9rem; }
.footer-admin { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 22px; }

/* ---------- Mode édition ---------- */
.edit-panel { background: var(--panel); border: 1px dashed rgba(255, 209, 102, 0.6); border-radius: var(--radius); padding: 20px; }
.hero-edit { max-width: 1200px; margin: 28px auto 0; }
.edit-panel h3 { font-family: var(--font-display); font-size: 1.5rem; font-weight: 500; text-transform: uppercase; color: var(--gold); margin-bottom: 12px; }
.edit-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.edit-label { display: block; font-size: 0.75rem; font-weight: 600; letter-spacing: 0.5px; color: var(--muted); margin-bottom: 4px; }
.edit-input {
    width: 100%; padding: 10px 12px; border-radius: 8px; font-size: 0.95rem;
    background: rgba(7, 13, 31, 0.8); border: 1px solid rgba(255, 255, 255, 0.22); color: var(--text); color-scheme: dark;
}
.edit-input:focus { outline: none; border-color: var(--orange); }
textarea.edit-input { min-height: 110px; resize: vertical; }
.edit-hint { font-size: 0.78rem; color: var(--muted); margin-top: 4px; }
.edit-card { display: flex; flex-direction: column; gap: 10px; padding: 16px; background: var(--panel); border: 1px dashed rgba(255, 138, 31, 0.6); border-radius: var(--radius); }
.edit-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.edit-toolbar strong { font-size: 0.85rem; color: var(--orange); }
.edit-toolbar div { display: flex; gap: 6px; }
.icon-btn { width: 36px; height: 36px; border-radius: 8px; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.05); font-size: 0.85rem; }
.icon-btn:hover { border-color: var(--text); }
.icon-btn.danger { border-color: rgba(255, 42, 64, 0.6); color: var(--red); }
.icon-btn.danger:hover { background: var(--red); color: #fff; }
.add-btn {
    display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; margin-top: 16px; padding: 14px;
    border: 1px dashed var(--leaf); border-radius: 12px; background: rgba(55, 200, 113, 0.07); color: var(--leaf); font-weight: 600; text-align: center;
}
.add-btn:hover { background: var(--leaf); color: #04200f; }
.add-btn.gold { border-color: var(--gold); color: var(--gold); background: rgba(255, 209, 102, 0.07); }
.add-btn.gold:hover { background: var(--gold); color: #201500; }
.add-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; }
.upload-btn { position: relative; overflow: hidden; cursor: pointer; }
.upload-btn input { position: absolute; inset: 0; opacity: 0; cursor: pointer; font-size: 0; }
.upload-btn.is-loading { opacity: 0.5; pointer-events: none; }
.pole-edit { display: flex; gap: 8px; align-items: center; margin: 40px 0 16px; }
.pole-edit .edit-input { font-family: var(--font-display); font-size: 1.5rem; color: var(--red); text-transform: uppercase; }
.member-edit .member-frame { max-width: 120px; margin: 0 auto; }
.member-edit .member-initials { font-size: 2.6rem; }
.member-add { min-height: 180px; margin-top: 0; flex-direction: column; }
.photo-edit img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 10px; }

.edit-bar {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 200;
    display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px 16px;
    padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
    background: rgba(7, 13, 31, 0.95); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
    border-top: 2px solid var(--gold); box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.5);
}
.edit-bar-status { font-weight: 600; font-size: 0.95rem; }
.edit-bar-status i { color: var(--gold); margin-right: 6px; }
.edit-bar-status small { display: block; font-weight: 400; color: var(--muted); font-size: 0.75rem; }

/* ---------- Modales, lightbox, toasts ---------- */
.overlay {
    position: fixed; inset: 0; z-index: 300; display: grid; place-items: center; padding: 20px;
    background: rgba(3, 6, 16, 0.88); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
.modal { width: 100%; max-width: 400px; padding: 32px 28px; text-align: center; background: var(--panel); border: 1px solid var(--line); border-top: 4px solid var(--red); border-radius: var(--radius); }
.modal h3 { font-family: var(--font-display); font-size: 2.2rem; font-weight: 500; text-transform: uppercase; color: var(--red); line-height: 1; }
.modal p { color: var(--muted); font-size: 0.9rem; margin: 8px 0 18px; }
.modal .field { text-align: center; font-size: 1.1rem; }
.modal .btn { width: 100%; }
.modal-error { color: var(--red); font-weight: 600; font-size: 0.9rem; margin-bottom: 12px; }
.link-btn { background: none; border: 0; color: var(--muted); text-decoration: underline; margin-top: 14px; font-size: 0.9rem; }
.lightbox img { max-width: min(92vw, 720px); max-height: 88vh; border-radius: 12px; box-shadow: 0 30px 80px rgba(0, 0, 0, 0.7); }
.lightbox-close { position: absolute; top: 16px; right: 16px; width: 46px; height: 46px; border-radius: 50%; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.08); font-size: 1.2rem; }
.toasts { position: fixed; left: 50%; top: calc(var(--header-h) + 14px); transform: translateX(-50%); z-index: 400; display: flex; flex-direction: column; gap: 8px; width: min(92vw, 420px); pointer-events: none; }
.toast { padding: 12px 16px; border-radius: 12px; background: var(--panel-2); border: 1px solid var(--line); border-left: 4px solid var(--leaf); font-size: 0.92rem; box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5); animation: toast-in 0.25s ease-out; }
.toast.error { border-left-color: var(--red); }
@keyframes toast-in { from { opacity: 0; transform: translateY(-8px); } }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
    .nav-toggle { display: inline-grid; place-items: center; }
    .site-nav {
        position: fixed; top: var(--header-h); left: 0; right: 0;
        flex-direction: column; align-items: stretch; gap: 0; padding: 8px 20px 20px;
        background: rgba(7, 13, 31, 0.98); border-bottom: 1px solid var(--line);
        transform: translateY(-12px); opacity: 0; visibility: hidden; transition: transform 0.2s, opacity 0.2s, visibility 0.2s;
    }
    .site-nav.open { transform: none; opacity: 1; visibility: visible; }
    .site-nav a:not(.btn) { padding: 14px 4px; font-size: 1.6rem; border-bottom: 1px solid var(--line); }
    .site-nav a:not(.btn)::after { display: none; }
    .site-nav .btn { margin-top: 16px; }

    .hero-inner { grid-template-columns: 1fr; text-align: center; }
    .hero-logo { order: -1; width: min(78%, 360px); }
    .hero-eyebrow::before { display: none; }
    .hero-text { margin-left: auto; margin-right: auto; }
    .hero-cta { justify-content: center; }
    .next-event { grid-template-columns: 1fr; text-align: center; justify-items: center; }
}
@media (max-width: 520px) {
    :root { --header-h: 60px; }
    .brand img { height: 38px; }
    .brand span { font-size: 1.4rem; }
    .hero-cta .btn { flex: 1 1 100%; }
    .countdown { width: 100%; }
    .countdown div { flex: 1; min-width: 0; }
    .next-event .btn { width: 100%; }
    .team-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
    .photo-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .member-initials { font-size: 3.4rem; }
    .edit-bar .btn { flex: 1; }
    .edit-bar-status { width: 100%; text-align: center; }
    .edit-bar-status small { display: none; }
}
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation: none !important; transition: none !important; }
}
