@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html, body { max-width: 100%; overflow-x: hidden; }

:root {
    --bg:       #060606;
    --panel:    #101114;
    --panel-2:  #16181d;
    --border:   #23262d;
    --text:     #f5f5f5;
    --muted:    #9a9da5;
    --red:      #d71f26;
    --red-h:    #f02c34;
    --yellow:   #e2a93b;
    --blue:     #2479ff;
    --green:    #16a34a;
    --radius:   18px;
    --shadow:   0 10px 30px rgba(0,0,0,.45);
    --sidebar-w: 260px;
    --header-h:  72px;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: radial-gradient(circle at top, #161616 0%, #060606 55%);
    color: var(--text);
    min-height: 100vh;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }
button { cursor: pointer; font-family: inherit; }
input, textarea, select { font-family: inherit; }

/* ============================================
   GLOBAL HEADER
   ============================================ */
.site-header {
    position: sticky; top: 0; z-index: 999;
    background: rgba(6,6,6,.92); backdrop-filter: blur(14px);
    border-bottom: 1px solid rgba(255,255,255,.06);
    padding: 0 28px; height: var(--header-h);
    display: flex; align-items: center; justify-content: space-between;
}
.header-left { display: flex; align-items: center; gap: 26px; }
.logo { font-size: 22px; font-weight: 800; line-height: 1; flex-shrink: 0; }
.logo span { color: var(--red); }
.logo small { display: block; color: var(--muted); font-size: 10px; letter-spacing: 2px; margin-top: 5px; font-weight: 500; }
.header-search {
    width: 480px;
    background: #0b0c0f; border: 1px solid var(--border);
    border-radius: 14px; padding: 12px 18px; color: var(--text);
    outline: none; font-size: .9rem; transition: border-color .2s;
}
.header-search:focus { border-color: var(--red); }
.header-search::placeholder { color: var(--muted); }
.header-right { display: flex; align-items: center; gap: 20px; font-size: 14px; font-weight: 600; }
.header-nav { display: flex; gap: 22px; color: var(--muted); }
.header-nav span { cursor: pointer; transition: color .2s; }
.header-nav span:hover, .header-nav span.active { color: var(--text); }
.header-user { display: flex; align-items: center; gap: 12px; }
.header-avatar {
    width: 40px; height: 40px; border-radius: 50%;
    background-size: cover; background-position: center;
    border: 2px solid var(--border); flex-shrink: 0;
    overflow: hidden;
}
.header-avatar img { width: 100%; height: 100%; object-fit: cover; }
.header-user-info strong { display: block; font-size: 13px; }
.header-user-info span { font-size: 11px; color: var(--muted); font-weight: 400; }

/* Dropdown */
.user-menu-wrap { position: relative; cursor: pointer; }
.user-dropdown {
    position: absolute; top: calc(100% + 12px); right: 0;
    background: var(--panel); border: 1px solid var(--border);
    border-radius: 16px; box-shadow: var(--shadow);
    min-width: 200px; padding: .5rem; display: none; z-index: 500;
}
.user-menu-wrap.open .user-dropdown { display: block; }
.user-dropdown a, .user-dropdown button {
    display: flex; align-items: center; gap: .6rem;
    padding: .6rem .85rem; color: var(--muted); border-radius: 10px;
    font-size: .88rem; transition: all .2s; text-decoration: none;
    width: 100%; text-align: left; font-weight: 500; border: none; background: none;
}
.user-dropdown a:hover, .user-dropdown button:hover { background: rgba(255,255,255,.06); color: var(--text); }
.dd-divider { height: 1px; background: var(--border); margin: .35rem 0; }
.dd-logout { color: var(--red) !important; }

/* Icônes header */
.header-icon-btn {
    position: relative; width: 40px; height: 40px;
    display: flex; align-items: center; justify-content: center;
    background: rgba(255,255,255,.05); border: 1px solid var(--border);
    border-radius: 50%; color: var(--muted); font-size: 1rem;
    transition: all .2s; cursor: pointer; text-decoration: none;
}
.header-icon-btn:hover { background: rgba(255,255,255,.1); color: var(--text); }
.header-icon-btn .badge {
    position: absolute; top: -3px; right: -3px;
    background: var(--red); color: #fff; font-size: .6rem; font-weight: 800;
    min-width: 16px; height: 16px; border-radius: 8px;
    display: flex; align-items: center; justify-content: center; padding: 0 3px;
    border: 2px solid var(--bg);
}

/* ============================================
   LAYOUT PRINCIPAL
   ============================================ */
.app-layout {
    display: grid;
    grid-template-columns: var(--sidebar-w) 1fr;
    min-height: calc(100vh - var(--header-h));
}

/* ============================================
   SIDEBAR
   ============================================ */
.site-sidebar {
    background: rgba(16,17,20,.95); border: 1px solid var(--border);
    border-radius: var(--radius); box-shadow: var(--shadow);
    backdrop-filter: blur(12px);
    padding: 24px; height: calc(100vh - var(--header-h) - 44px);
    position: sticky; top: calc(var(--header-h) + 22px);
    margin: 22px 0 22px 22px;
    overflow-y: auto; scrollbar-width: thin; scrollbar-color: var(--border) transparent;
    display: flex; flex-direction: column;
}
.site-sidebar::-webkit-scrollbar { width: 4px; }
.site-sidebar::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }

.sidebar-logo { font-size: 24px; font-weight: 800; line-height: 1; margin-bottom: 32px; }
.sidebar-logo span { color: var(--red); }
.sidebar-logo small { display: block; color: var(--muted); font-size: 10px; letter-spacing: 2px; margin-top: 6px; font-weight: 500; }

.sidebar-menu { display: flex; flex-direction: column; gap: 6px; flex: 1; }
.nav-link {
    display: flex; align-items: center; gap: .75rem;
    padding: 13px 16px; color: var(--muted);
    font-size: .9rem; font-weight: 500;
    transition: all .25s; text-decoration: none;
    border-radius: 14px; border: 1px solid transparent;
}
.nav-link:hover, .nav-link.active {
    background: linear-gradient(90deg, rgba(215,31,38,.18), rgba(215,31,38,.05));
    color: var(--text); border-color: rgba(215,31,38,.35);
}
.nav-link-icon { font-size: 1.05rem; width: 22px; text-align: center; flex-shrink: 0; }
.nav-link-label { flex: 1; }
.nav-link-sub { font-size: .68rem; color: var(--muted); display: block; margin-top: 1px; font-weight: 400; }
.nav-badge { background: var(--red); color: #fff; font-size: .6rem; font-weight: 700; min-width: 18px; height: 18px; border-radius: 9px; display: flex; align-items: center; justify-content: center; padding: 0 4px; }

/* Events in sidebar */
.sidebar-events { margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--border); }
.sidebar-events h4 { font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); margin-bottom: 14px; }
.sidebar-event-card { background: rgba(16,17,20,.95); border: 1px solid var(--border); border-radius: 14px; padding: 14px; margin-bottom: 10px; }
.sidebar-event-card strong { display: block; font-size: .88rem; margin-bottom: 4px; }
.sidebar-event-card p { font-size: .78rem; color: var(--muted); }

/* ============================================
   CONTENU PRINCIPAL
   ============================================ */
.site-main { padding: 22px; min-width: 0; }

/* ============================================
   CARDS
   ============================================ */
.card {
    background: rgba(16,17,20,.95);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    backdrop-filter: blur(12px);
    padding: 26px;
}
.card + .card { margin-top: 22px; }
.card h3 { font-size: 1.25rem; font-weight: 700; margin-bottom: 18px; }

/* ============================================
   BOUTONS
   ============================================ */
.btn {
    border: none; border-radius: 14px; padding: 13px 22px;
    font-weight: 700; cursor: pointer; transition: all .25s;
    font-family: inherit; font-size: .92rem; display: inline-flex; align-items: center; gap: .4rem;
}
.btn-primary { background: var(--red); color: #fff; }
.btn-primary:hover { background: var(--red-h); transform: translateY(-2px); }
.btn-secondary { background: rgba(255,255,255,.08); color: var(--text); border: 1px solid rgba(255,255,255,.08); }
.btn-secondary:hover { background: rgba(255,255,255,.13); }
.btn-sm { padding: 9px 16px !important; font-size: .82rem !important; border-radius: 10px !important; }
.btn-xs { padding: 6px 12px; font-size: .76rem; border-radius: 8px; }
.btn-full { width: 100%; justify-content: center; }
.btn-ghost { background: none; border: none; color: var(--muted); padding: 8px 14px; border-radius: 10px; font-size: .85rem; font-weight: 600; transition: all .2s; }
.btn-ghost:hover { background: rgba(255,255,255,.06); color: var(--text); }

/* ============================================
   BADGES
   ============================================ */
.badge { padding: 7px 13px; border-radius: 999px; font-size: 11px; font-weight: 700; letter-spacing: .5px; display: inline-block; }
.badge.red   { background: rgba(215,31,38,.18); color: #ff6b72; }
.badge.blue  { background: rgba(36,121,255,.18); color: #6da7ff; }
.badge.yellow{ background: rgba(226,169,59,.18); color: #ffd67c; }
.badge.green { background: rgba(22,163,74,.15);  color: #4ade80; }
.tag { display: inline-flex; align-items: center; gap: .3rem; font-size: .72rem; font-weight: 700; padding: 5px 10px; border-radius: 999px; }
.tag-red    { background: rgba(215,31,38,.18); color: #ff6b72; }
.tag-blue   { background: rgba(36,121,255,.18); color: #6da7ff; }
.tag-yellow { background: rgba(226,169,59,.18); color: #ffd67c; }
.tag-green  { background: rgba(22,163,74,.15);  color: #4ade80; }
.tag-grey   { background: rgba(255,255,255,.07); color: var(--muted); border: 1px solid var(--border); }
.tag-disc   { background: rgba(36,121,255,.18);  color: #6da7ff; }
.tag-per    { background: rgba(226,169,59,.18);  color: #ffd67c; }
.tag-car    { background: rgba(156,39,176,.18);  color: #ce93d8; }
.badge-count { background: var(--red); color: #fff; font-size: .6rem; font-weight: 700; min-width: 18px; height: 18px; border-radius: 9px; display: inline-flex; align-items: center; justify-content: center; padding: 0 4px; }

/* ============================================
   ONGLETS
   ============================================ */
.tabs { display: flex; gap: 10px; padding: 0 6px; margin-bottom: 22px; }
.tab {
    padding: 11px 18px; border-radius: 12px; color: var(--muted);
    background: transparent; border: 1px solid transparent;
    cursor: pointer; transition: all .25s; font-size: .88rem; font-weight: 600;
    font-family: inherit;
}
.tab:hover { color: var(--text); background: rgba(255,255,255,.05); }
.tab.active { background: rgba(215,31,38,.15); border-color: rgba(215,31,38,.3); color: var(--text); }
.tab-bar { display: flex; gap: 10px; margin-bottom: 22px; }
.tab-btn { padding: 11px 18px; border-radius: 12px; color: var(--muted); background: transparent; border: 1px solid transparent; cursor: pointer; transition: all .25s; font-size: .88rem; font-weight: 600; font-family: inherit; }
.tab-btn:hover { color: var(--text); background: rgba(255,255,255,.05); }
.tab-btn.active { background: rgba(215,31,38,.15); border-color: rgba(215,31,38,.3); color: var(--text); }

/* ============================================
   FORMULAIRES
   ============================================ */
.form-group { margin-bottom: 1rem; }
.form-group label { display: block; font-size: .82rem; font-weight: 600; margin-bottom: .35rem; color: var(--muted); }
.form-group input, .form-group textarea, .form-group select, .form-control {
    width: 100%; padding: 12px 16px;
    background: #0b0c0f; border: 1px solid var(--border);
    border-radius: 14px; font-size: .9rem; color: var(--text);
    transition: border-color .2s; outline: none;
}
.form-group input:focus, .form-group textarea:focus, .form-group select:focus, .form-control:focus { border-color: var(--red); }
.form-group input::placeholder, .form-control::placeholder { color: var(--muted); }
.form-group select option { background: var(--panel); }
.form-error { color: var(--red); font-size: .82rem; margin-top: .3rem; }
.form-row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
.form-row-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: .75rem; }

/* ============================================
   HERO
   ============================================ */
.hero {
    position: relative; overflow: hidden; border-radius: 28px;
    background-size: cover; background-position: center;
    display: flex; align-items: flex-end; padding: 48px;
    border: 1px solid rgba(255,255,255,.08); box-shadow: 0 20px 60px rgba(0,0,0,.5);
}
.hero::before {
    content: ''; position: absolute; inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,.45), rgba(0,0,0,.05) 60%, transparent 100%);
}
.hero-content { position: relative; z-index: 2; max-width: 760px; }
.hero-content .badges { display: flex; gap: 10px; margin-bottom: 20px; }
.hero-content h1 { font-size: clamp(2rem, 5vw, 4.5rem); line-height: .95; font-weight: 900; margin-bottom: 20px; }
.hero-content p { font-size: 1.1rem; line-height: 1.8; color: #d0d3da; max-width: 640px; margin-bottom: 28px; }
.hero-content .actions { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-logo-text { font-size: clamp(2rem, 6vw, 4rem); font-weight: 900; color: var(--text); margin-bottom: 1rem; }
.hero-logo-text span { color: var(--red); }

/* ============================================
   FEED / POSTS
   ============================================ */
.feed-layout { display: grid; grid-template-columns: 1fr 340px; gap: 22px; align-items: start; }
.feed-main { min-width: 0; display: flex; flex-direction: column; gap: 22px; }
.feed-right { position: sticky; top: calc(var(--header-h) + 22px); display: flex; flex-direction: column; gap: 22px; }
.feed-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 22px; }
.feed-header h2 { font-size: 2rem; font-weight: 800; }
.feed-header p { color: var(--muted); margin-top: 6px; font-size: .9rem; }
.feed-filters { display: flex; gap: 10px; }

.post-item {
    background: rgba(255,255,255,.03);
    border: 1px solid rgba(255,255,255,.06);
    padding: 22px; border-radius: 24px; transition: border-color .2s;
}
.post-item:hover { border-color: rgba(255,255,255,.1); }
.post-header { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }
.post-avatar { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; flex-shrink: 0; border: 2px solid var(--border); }
.post-meta strong { display: block; font-size: .92rem; font-weight: 700; }
.post-meta p { font-size: .78rem; color: var(--muted); margin-top: 3px; }
.post-body { line-height: 1.85; margin-bottom: 18px; color: var(--muted); font-size: .92rem; }
.post-img { width: 100%; border-radius: 20px; margin-bottom: 16px; object-fit: cover; }
.post-footer { display: flex; justify-content: space-between; color: var(--muted); font-size: .88rem; }
.post-footer span { cursor: pointer; transition: color .2s; }
.post-footer span:hover { color: var(--text); }

/* Ancien style posts (rétrocompat) */
.post-card {
    background: rgba(255,255,255,.03); border: 1px solid rgba(255,255,255,.06);
    border-radius: 24px; padding: 22px; margin-bottom: 0; transition: border-color .2s;
}
.post-card:hover { border-color: rgba(255,255,255,.1); }
.post-card-header { display: flex; align-items: flex-start; gap: .85rem; margin-bottom: 1rem; }
.post-author-link { display: flex; align-items: flex-start; gap: .85rem; text-decoration: none; flex: 1; min-width: 0; }
.post-author-link img { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; flex-shrink: 0; border: 2px solid var(--border); }
.post-author-info { flex: 1; min-width: 0; }
.post-author-top { display: flex; align-items: baseline; gap: .5rem; flex-wrap: wrap; margin-bottom: .3rem; }
.author-name { font-size: .92rem; font-weight: 700; color: var(--text); }
.post-time { font-size: .72rem; color: var(--muted); }
.post-tags { display: flex; gap: .3rem; flex-wrap: wrap; margin-top: .25rem; }
.post-card-body { color: var(--muted); font-size: .92rem; line-height: 1.75; margin: .65rem 0; }
.post-ai-badge { background: rgba(22,163,74,.12); border: 1px solid rgba(22,163,74,.25); border-radius: 10px; padding: .4rem .85rem; font-size: .82rem; color: #4ade80; margin: .5rem 0; display: flex; align-items: center; gap: .4rem; }
.post-card-footer { display: flex; align-items: center; justify-content: space-between; border-top: 1px solid rgba(255,255,255,.06); padding-top: .85rem; margin-top: .85rem; }
.post-actions { display: flex; align-items: center; gap: .25rem; flex: 1; }
.action-btn { display: inline-flex; align-items: center; gap: .35rem; padding: .45rem .75rem; border-radius: 999px; font-size: .88rem; color: var(--muted); cursor: pointer; transition: all .2s; background: none; border: none; font-family: inherit; }
.action-btn:hover { background: rgba(255,255,255,.06); color: var(--text); }
.action-btn.liked { color: var(--red); }
.action-btn.liked:hover { background: rgba(215,31,38,.12); }
.like-count, .comment-count, .share-count { font-size: .78rem; font-weight: 600; }

/* ============================================
   GRILLE PHOTOS
   ============================================ */
.post-photos { display: grid; gap: 3px; overflow: hidden; border-radius: 20px; cursor: pointer; margin: .75rem 0; }
.post-photos.count-1 .post-photo-item img { max-height: 520px; width: 100%; object-fit: cover; }
.post-photos.count-2 { grid-template-columns: 1fr 1fr; }
.post-photos.count-2 .post-photo-item { height: 240px; }
.post-photos.count-3 { grid-template-columns: 2fr 1fr; }
.post-photos.count-3 .photo-main { height: 280px; grid-row: span 2; }
.post-photos.count-3 .photo-thumb { height: 138px; }
.post-photos.count-4 { grid-template-columns: 2fr 1fr; }
.post-photos.count-4 .photo-main { height: 400px; grid-row: span 3; }
.post-photos.count-4 .photo-thumb { height: 133px; }
.post-photos.count-5 { grid-template-columns: 2fr 1fr 1fr; }
.post-photos.count-5 .photo-main { height: 280px; grid-row: span 2; }
.post-photos.count-5 .photo-thumb { height: 138px; }
.post-photo-item { overflow: hidden; position: relative; }
.post-photo-item img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .3s; }
.post-photo-item:hover img { transform: scale(1.03); }
.photo-more-overlay { position: absolute; inset: 0; background: rgba(0,0,0,.65); display: flex; align-items: center; justify-content: center; color: #fff; font-size: 2rem; font-weight: 800; }

/* ============================================
   RÉACTIONS
   ============================================ */
.reaction-wrap { position: relative; display: inline-flex; align-items: center; gap: .4rem; }
.reaction-picker { position: absolute; bottom: calc(100% + 6px); left: 0; background: var(--panel); border: 1px solid var(--border); border-radius: 999px; padding: .5rem .75rem; display: flex; gap: .4rem; align-items: center; box-shadow: var(--shadow); opacity: 0; pointer-events: none; transform: scale(.8) translateY(8px); transform-origin: bottom left; transition: all .2s cubic-bezier(.34,1.56,.64,1); z-index: 50; white-space: nowrap; padding-bottom: 14px; margin-bottom: -8px; }
.reaction-wrap.picker-open .reaction-picker { opacity: 1; pointer-events: all; transform: scale(1) translateY(0); }
.reaction-btn { font-size: 1.5rem; width: 34px; height: 34px; padding: 0; border: none; background: none; cursor: pointer; border-radius: 50%; transition: transform .15s; display: flex; align-items: center; justify-content: center; }
.reaction-btn:hover { transform: scale(1.4); }
.reaction-current { font-size: .95rem; }

/* ============================================
   COMMENTAIRES
   ============================================ */
.comments-section { border-top: 1px solid rgba(255,255,255,.06); margin-top: .85rem; padding-top: .85rem; }
.comment-item { display: flex; gap: .5rem; margin-bottom: .75rem; }
.comment-reply { margin-left: 2.5rem; margin-top: .4rem; }
.comment-avatar { width: 30px; height: 30px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.comment-body { flex: 1; min-width: 0; }
.comment-bubble { background: rgba(255,255,255,.05); border-radius: 12px; padding: .5rem .85rem; display: inline-block; max-width: 100%; }
.comment-author { display: block; font-size: .78rem; font-weight: 700; margin-bottom: 2px; }
.comment-text { font-size: .88rem; color: var(--muted); margin: 0; word-break: break-word; }
.comment-meta { display: flex; align-items: center; gap: .75rem; margin-top: .25rem; padding-left: .25rem; }
.comment-time { font-size: .7rem; color: var(--muted); opacity: .6; }
.btn-reply-comment { font-size: .72rem; color: var(--muted); background: none; border: none; cursor: pointer; font-weight: 600; padding: 0; }
.btn-reply-comment:hover { color: var(--red); }
.btn-delete-comment { font-size: .72rem; color: var(--muted); background: none; border: none; cursor: pointer; padding: 0; opacity: .5; }
.btn-delete-comment:hover { color: var(--red); opacity: 1; }
.comment-input-wrap { display: flex; gap: .5rem; align-items: flex-start; margin-top: .5rem; }
.comment-input-inner { flex: 1; display: flex; gap: .4rem; align-items: flex-end; }
.comment-input { flex: 1; padding: .5rem .85rem; background: #0b0c0f; border: 1px solid var(--border); border-radius: 20px; font-size: .88rem; font-family: inherit; resize: none; outline: none; min-height: 36px; color: var(--text); transition: border-color .2s; }
.comment-input:focus { border-color: var(--red); }
.comment-input::placeholder { color: var(--muted); }

/* ============================================
   PARTAGE
   ============================================ */
.share-wrap { position: relative; display: inline-flex; align-items: center; }
.share-picker { position: absolute; bottom: calc(100% + 6px); left: 0; background: var(--panel); border: 1px solid var(--border); border-radius: 16px; padding: .4rem; min-width: 200px; box-shadow: var(--shadow); opacity: 0; pointer-events: none; transform: scale(.9) translateY(6px); transform-origin: bottom left; transition: all .2s ease; z-index: 50; padding-bottom: 12px; margin-bottom: -8px; }
.share-wrap.picker-open .share-picker { opacity: 1; pointer-events: all; transform: scale(1) translateY(0); }
.share-btn { display: flex; align-items: center; gap: .5rem; width: 100%; padding: .55rem .85rem; background: none; border: none; border-radius: 10px; font-size: .85rem; cursor: pointer; text-align: left; color: var(--text); transition: background .2s; text-decoration: none; }
.share-btn:hover { background: rgba(255,255,255,.06); }
.share-btn.shared { color: var(--red); font-weight: 600; }
@media (max-width: 430px) {
    .share-picker {
        position: fixed !important;
        bottom: 58px !important;
        left: 8px !important;
        right: 8px !important;
        top: auto !important;
        min-width: auto !important;
        border-radius: 16px !important;
        padding: .5rem !important;
        z-index: 9999 !important;
        transform: none !important;
        opacity: 0;
        pointer-events: none;
    }
    .share-wrap.picker-open .share-picker {
        opacity: 1 !important;
        pointer-events: all !important;
    }
    .share-btn {
        padding: .75rem 1rem !important;
        font-size: .9rem !important;
    }
.mobile-tabs-bar {
    justify-content: center !important;
    gap: 8px !important;
}
.mobile-tabs-bar .tab {
    font-size: 1.3rem !important;
    padding: 6px 14px !important;
    min-width: 48px !important;
}
}

/* ============================================
   GRILLE QUICK ACCESS (landing)
   ============================================ */
.quick-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.quick-card {
    background: rgba(16,17,20,.95); border: 1px solid var(--border);
    border-radius: var(--radius); box-shadow: var(--shadow); padding: 28px;
    min-height: 220px; display: flex; flex-direction: column;
    justify-content: space-between; transition: all .25s; cursor: pointer;
    text-decoration: none;
}
.quick-card:hover { border-color: rgba(215,31,38,.3); transform: translateY(-4px); }
.quick-card .fi { font-size: 2.5rem; margin-bottom: 16px; }
.quick-card h3 { font-size: 1.05rem; font-weight: 700; margin-bottom: 10px; }
.quick-card p { font-size: .88rem; color: var(--muted); line-height: 1.6; flex: 1; }
.quick-card-link { margin-top: 20px; color: var(--text); font-weight: 700; font-size: .9rem; }

/* ============================================
   PROJETS
   ============================================ */
.projects-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.project-card { overflow: hidden; border-radius: 18px; background: var(--panel-2); border: 1px solid var(--border); transition: all .25s; }
.project-card:hover { border-color: rgba(215,31,38,.3); transform: translateY(-3px); }
.project-card img { width: 100%; height: 180px; object-fit: cover; display: block; }
.project-content { padding: 18px; }
.project-content h4 { font-size: .95rem; font-weight: 700; margin-bottom: 8px; }
.project-content p { font-size: .82rem; color: var(--muted); line-height: 1.55; margin-bottom: 10px; }
.progress-bar { height: 8px; background: rgba(255,255,255,.08); border-radius: 999px; overflow: hidden; margin-top: 12px; }
.progress-bar span { display: block; height: 100%; background: linear-gradient(90deg, var(--green), #4ade80); border-radius: 999px; }
.project-type { font-size: .72rem; font-weight: 700; padding: 3px 8px; border-radius: 6px; text-transform: uppercase; letter-spacing: .04em; }
.project-type.restauration { background: rgba(215,31,38,.15); color: #ff6b72; }
.project-type.preparation { background: rgba(36,121,255,.15); color: #6da7ff; }

/* ============================================
   FICHE TECHNIQUE (specs)
   ============================================ */
.specs { display: flex; flex-direction: column; gap: 14px; }
.spec { display: flex; justify-content: space-between; align-items: center; color: var(--muted); padding-bottom: 12px; border-bottom: 1px solid rgba(255,255,255,.06); font-size: .9rem; }
.spec:last-child { border-bottom: none; padding-bottom: 0; }
.spec strong { color: var(--text); font-weight: 600; }

/* ============================================
   GALERIE
   ============================================ */
.gallery-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 16px; }
.gallery-grid img { width: 100%; border-radius: 12px; height: 120px; object-fit: cover; cursor: pointer; transition: opacity .2s; }
.gallery-grid img:hover { opacity: .85; }

/* ============================================
   AVATARS GROUPÉS
   ============================================ */
.avatars-stack { display: flex; align-items: center; }
.avatars-stack .av { width: 38px; height: 38px; border-radius: 50%; border: 3px solid var(--panel); margin-left: -10px; background-size: cover; background-position: center; }
.avatars-stack .av:first-child { margin-left: 0; }
.avatars-stack .av img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }

/* ============================================
   STATS
   ============================================ */
.stats-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin-top: 22px; }
.stat-box { background: rgba(255,255,255,.03); border: 1px solid rgba(255,255,255,.04); padding: 16px; border-radius: 14px; }
.stat-box strong { display: block; font-size: 1.3rem; font-weight: 800; margin-bottom: 4px; }
.stat-box span { font-size: .8rem; color: var(--muted); }

/* ============================================
   PROFIL
   ============================================ */
.profile-cover { height: 240px; background-size: cover; background-position: center; background-color: var(--panel-2); border-radius: var(--radius) var(--radius) 0 0; position: relative; overflow: hidden; }
.profile-cover::after { content: ''; position: absolute; inset: 0; background: linear-gradient(to bottom, transparent 50%, rgba(0,0,0,.7) 100%); }
.btn-edit-cover { position: absolute; bottom: 1rem; right: 1rem; z-index: 1; padding: .35rem .85rem; background: rgba(0,0,0,.7); color: #fff; border: 1px solid rgba(255,255,255,.2); border-radius: 10px; font-size: .8rem; cursor: pointer; backdrop-filter: blur(4px); }
.profile-header-card { background: rgba(16,17,20,.95); border: 1px solid var(--border); border-top: none; border-radius: 0 0 var(--radius) var(--radius); padding: 0 1.5rem 1.25rem; margin-bottom: 1.25rem; box-shadow: var(--shadow); }
.profile-header-inner { display: flex; align-items: flex-end; gap: 1.25rem; flex-wrap: wrap; }
.profile-avatar-wrap { position: relative; margin-top: -50px; flex-shrink: 0; }
.profile-avatar-wrap img { width: 110px; height: 110px; border-radius: 50%; border: 4px solid var(--panel); object-fit: cover; box-shadow: 0 4px 20px rgba(0,0,0,.5); }
.btn-edit-avatar { position: absolute; bottom: 4px; right: 4px; width: 28px; height: 28px; background: var(--red); color: #fff; border: 2px solid var(--panel); border-radius: 50%; font-size: .7rem; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.profile-info { flex: 1; padding-top: .5rem; }
.profile-info h1 { font-size: 1.35rem; font-weight: 800; margin-bottom: .25rem; }
.profile-bio { color: var(--muted); font-size: .9rem; margin-bottom: .5rem; font-style: italic; }
.profile-meta { display: flex; gap: 1rem; flex-wrap: wrap; font-size: .82rem; color: var(--muted); margin-bottom: .6rem; }
.profile-stats-row { display: flex; gap: 1.5rem; }
.pstat { text-align: center; font-size: .75rem; color: var(--muted); }
.pstat span { display: block; font-size: 1.2rem; font-weight: 800; color: var(--text); }
.profile-actions { display: flex; gap: .75rem; padding-top: .75rem; flex-wrap: wrap; }
.profile-content { display: grid; grid-template-columns: 260px 1fr; gap: 1.25rem; align-items: start; }
.profile-sidebar { position: sticky; top: calc(var(--header-h) + 1rem); }

/* ============================================
   MESSAGERIE
   ============================================ */
.messages-wrap { display: grid; grid-template-columns: 280px 1fr; height: calc(100vh - var(--header-h) - 44px); background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.conv-panel { border-right: 1px solid var(--border); overflow-y: auto; background: rgba(10,10,12,.8); }
.conv-panel-header { padding: 1rem; font-weight: 700; border-bottom: 1px solid var(--border); position: sticky; top: 0; background: rgba(10,10,12,.95); }
.conv-item { display: flex; align-items: center; gap: .65rem; padding: .8rem 1rem; cursor: pointer; border-bottom: 1px solid var(--border); transition: background .2s; }
.conv-item:hover, .conv-item.active { background: rgba(255,255,255,.05); }
.conv-item img { width: 42px; height: 42px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.conv-info { flex: 1; min-width: 0; }
.conv-name { display: block; font-size: .88rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.conv-date { font-size: .72rem; color: var(--muted); }
.conv-unread { background: var(--red); color: #fff; font-size: .65rem; font-weight: 700; min-width: 18px; height: 18px; border-radius: 9px; display: flex; align-items: center; justify-content: center; padding: 0 4px; flex-shrink: 0; }
.chat-panel { display: flex; flex-direction: column; }
.chat-body { flex: 1; overflow-y: auto; padding: 1.25rem; display: flex; flex-direction: column; gap: .65rem; }
.bubble { display: flex; flex-direction: column; max-width: 72%; }
.bubble-mine { align-self: flex-end; align-items: flex-end; }
.bubble-theirs { align-self: flex-start; align-items: flex-start; }
.bubble-text { padding: .6rem 1rem; border-radius: 18px; font-size: .9rem; line-height: 1.5; word-break: break-word; }
.bubble-mine .bubble-text { background: var(--red); color: #fff; border-bottom-right-radius: 4px; }
.bubble-theirs .bubble-text { background: rgba(255,255,255,.07); border-bottom-left-radius: 4px; }
.bubble-time { font-size: .68rem; color: var(--muted); margin-top: 2px; padding: 0 4px; }
.chat-input-wrap { padding: .85rem 1rem; border-top: 1px solid var(--border); display: flex; gap: .65rem; align-items: flex-end; }
#chat-input { flex: 1; padding: .6rem 1rem; background: #0b0c0f; border: 1px solid var(--border); border-radius: 22px; font-size: .9rem; resize: none; max-height: 120px; outline: none; color: var(--text); transition: border-color .2s; }
#chat-input:focus { border-color: var(--red); }
#btn-send { width: 38px; height: 38px; background: var(--red); color: #fff; border-radius: 50%; font-size: .95rem; display: flex; align-items: center; justify-content: center; flex-shrink: 0; transition: background .2s; border: none; cursor: pointer; }
#btn-send:hover { background: var(--red-h); }

/* ============================================
   MEMBRES
   ============================================ */
.members-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 1rem; }
.member-card { background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.1rem; text-align: center; box-shadow: var(--shadow); transition: all .25s; }
.member-card:hover { transform: translateY(-4px); border-color: rgba(215,31,38,.3); }
.member-card img { width: 60px; height: 60px; border-radius: 50%; object-fit: cover; margin: 0 auto .65rem; border: 2px solid var(--border); }
.member-name { font-weight: 700; font-size: .88rem; margin-bottom: .25rem; }
.member-sub { font-size: .75rem; color: var(--muted); margin-bottom: .65rem; }
.member-actions { display: flex; gap: .4rem; justify-content: center; }

/* ============================================
   MODALE AUTH
   ============================================ */
.modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.8); z-index: 2000; display: none; align-items: center; justify-content: center; padding: 1rem; }
.modal-overlay.open { display: flex; }
.auth-modal { background: var(--panel); border: 1px solid var(--border); border-radius: 22px; padding: 2rem; width: 100%; max-width: 420px; box-shadow: var(--shadow); position: relative; backdrop-filter: blur(12px); }
.modal-close { position: absolute; top: .85rem; right: .85rem; width: 30px; height: 30px; border-radius: 50%; background: rgba(255,255,255,.08); font-size: 1.1rem; color: var(--text); display: flex; align-items: center; justify-content: center; cursor: pointer; border: none; }
.modal-close:hover { background: var(--red); }
.auth-logo { text-align: center; font-size: 1.5rem; font-weight: 800; margin-bottom: 1.25rem; }
.auth-logo span { color: var(--red); }
.auth-tabs { display: flex; gap: 3px; margin-bottom: 1.25rem; background: rgba(255,255,255,.04); border-radius: 10px; padding: 3px; }
.auth-tab { flex: 1; padding: .5rem; background: none; font-size: .88rem; font-weight: 600; color: var(--muted); cursor: pointer; border-radius: 8px; transition: all .2s; border: none; font-family: inherit; }
.auth-tab.active { background: var(--red); color: #fff; }
.auth-form { display: none; }
.auth-form.active { display: block; }
.btn-auth { width: 100%; padding: .8rem; background: var(--red); color: #fff; border-radius: 14px; font-size: .95rem; font-weight: 700; margin-top: .5rem; transition: background .2s; border: none; cursor: pointer; font-family: inherit; }
.btn-auth:hover { background: var(--red-h); }
.check-label { display: flex; gap: .6rem; align-items: flex-start; font-size: .82rem; color: var(--muted); cursor: pointer; }
.check-label input { margin-top: 3px; flex-shrink: 0; accent-color: var(--red); }
.check-label a { color: var(--yellow); }

/* ============================================
   COOKIE BANNER
   ============================================ */
.cookie-banner { position: fixed; bottom: 0; left: 0; right: 0; z-index: 9999; background: var(--panel); border-top: 1px solid var(--border); padding: 1rem 1.5rem; box-shadow: 0 -4px 30px rgba(0,0,0,.5); }
.cookie-banner-inner { max-width: 1200px; margin: 0 auto; display: flex; align-items: center; gap: 1.5rem; flex-wrap: wrap; }
.cookie-banner-text { display: flex; align-items: flex-start; gap: .75rem; flex: 1; }
.cookie-icon { font-size: 1.4rem; flex-shrink: 0; }
.cookie-banner-text p { color: var(--muted); font-size: .88rem; margin: 0; line-height: 1.6; }
.cookie-banner-text a { color: var(--yellow); }
.cookie-banner-actions { display: flex; gap: .75rem; flex-shrink: 0; }
.btn-cookie-refuse { padding: .45rem 1.1rem; background: transparent; color: var(--muted); border: 1px solid var(--border); border-radius: 10px; font-size: .88rem; cursor: pointer; font-family: inherit; }
.btn-cookie-refuse:hover { color: var(--text); }
.btn-cookie-accept { padding: .45rem 1.1rem; background: var(--yellow); color: #000; border: none; border-radius: 10px; font-size: .88rem; font-weight: 700; cursor: pointer; font-family: inherit; }

/* ============================================
   FOOTER
   ============================================ */
.site-footer { margin-top: 60px; padding: 36px 50px; border-top: 1px solid rgba(255,255,255,.06); background: rgba(0,0,0,.35); }
.footer-inner { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 20px; }
.footer-links { display: flex; gap: 24px; color: var(--muted); font-size: .85rem; flex-wrap: wrap; }
.footer-links a { color: var(--muted); transition: color .2s; }
.footer-links a:hover { color: var(--text); }
.footer-logo { text-align: center; font-size: 1.1rem; font-weight: 800; }
.footer-logo span { color: var(--red); }
.footer-logo small { display: block; color: var(--muted); font-size: .62rem; letter-spacing: 2px; margin-top: 4px; font-weight: 500; }
.footer-social { display: flex; justify-content: flex-end; gap: 20px; color: var(--muted); font-size: .85rem; }
.footer-social a { color: var(--muted); transition: color .2s; }
.footer-social a:hover { color: var(--text); }

/* ============================================
   AMIS
   ============================================ */
.friend-row { display: flex; align-items: center; gap: .55rem; padding: .5rem 0; border-bottom: 1px solid rgba(255,255,255,.05); }
.friend-row:last-child { border-bottom: none; }
.friend-row img { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.friend-info { flex: 1; min-width: 0; }
.friend-name { display: block; font-size: .83rem; font-weight: 600; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.friend-name:hover { color: var(--red); }
.friend-car { display: block; font-size: .72rem; color: var(--muted); }
.friend-btns { display: flex; gap: .35rem; margin-top: .25rem; }
.btn-friend-rm { color: var(--muted); font-size: 1rem; padding: 0 4px; opacity: .5; background: none; border: none; cursor: pointer; }
.btn-friend-rm:hover { color: var(--red); opacity: 1; }
.see-all { display: block; text-align: center; font-size: .78rem; color: var(--red); margin-top: .5rem; }
.friends-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: .5rem; margin-bottom: .5rem; }
.friend-thumb { display: flex; flex-direction: column; align-items: center; gap: .25rem; text-decoration: none; }
.friend-thumb img { width: 46px; height: 46px; border-radius: 50%; object-fit: cover; border: 2px solid var(--border); transition: border-color .2s; }
.friend-thumb:hover img { border-color: var(--red); }
.friend-thumb span { font-size: .64rem; color: var(--muted); text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 46px; }
.friends-cards-list { display: flex; flex-direction: column; gap: .85rem; }
.friend-profile-card { background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; transition: transform .2s, border-color .2s; }
.friend-profile-card:hover { transform: translateY(-3px); border-color: rgba(215,31,38,.3); }
.fpc-cover { height: 110px; background-size: cover; background-position: center; background-color: var(--panel-2); }
.fpc-body { display: flex; align-items: flex-start; gap: .85rem; padding: .75rem 1rem 1rem; }
.fpc-avatar { width: 54px; height: 54px; border-radius: 50%; object-fit: cover; border: 3px solid var(--panel); margin-top: -27px; flex-shrink: 0; }
.fpc-info { flex: 1; min-width: 0; }
.fpc-name { font-size: .9rem; font-weight: 700; margin-bottom: .2rem; }
.fpc-bio { font-size: .74rem; color: var(--muted); font-style: italic; margin-bottom: .3rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fpc-meta { display: flex; flex-wrap: wrap; gap: .25rem; }
.fpc-meta span { font-size: .68rem; background: rgba(255,255,255,.06); color: var(--muted); padding: 2px 7px; border-radius: 20px; }
.fpc-actions { display: flex; flex-direction: column; gap: .4rem; flex-shrink: 0; padding-top: .25rem; }

/* ============================================
   CAFÉ DU PADDOCK
   ============================================ */
.cafe-wrap { background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); display: flex; flex-direction: column; height: 520px; overflow: hidden; }
.cafe-header { background: rgba(10,10,12,.9); border-bottom: 1px solid var(--border); padding: .75rem 1rem; display: flex; align-items: center; justify-content: space-between; font-size: .88rem; font-weight: 700; flex-shrink: 0; }
.cafe-body { flex: 1; overflow-y: auto; padding: 1rem; display: flex; flex-direction: column; gap: .6rem; scroll-behavior: smooth; }
.cafe-msg { display: flex; gap: .5rem; align-items: flex-end; max-width: 85%; }
.cafe-msg-mine { align-self: flex-end; flex-direction: row-reverse; margin-left: auto; }
.cafe-avatar { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.cafe-bubble-wrap { display: flex; flex-direction: column; min-width: 0; }
.cafe-msg-mine .cafe-bubble-wrap { align-items: flex-end; }
.cafe-author { font-size: .7rem; font-weight: 600; color: var(--muted); margin-bottom: 2px; padding: 0 .5rem; opacity: .7; }
.cafe-bubble { background: rgba(255,255,255,.07); border-radius: 14px; border-bottom-left-radius: 4px; padding: .5rem .85rem; font-size: .88rem; line-height: 1.5; word-break: break-word; }
.cafe-msg-mine .cafe-bubble { background: var(--red); color: #fff; border-radius: 14px; border-bottom-right-radius: 4px; }
.cafe-time { font-size: .68rem; color: var(--muted); margin-top: 3px; padding: 0 .5rem; display: flex; align-items: center; gap: .35rem; opacity: .6; }
.cafe-del-btn { background: none; border: none; color: var(--muted); font-size: .85rem; cursor: pointer; }
.cafe-del-btn:hover { color: var(--red); }
.cafe-input-wrap { display: flex; gap: .5rem; align-items: flex-end; padding: .75rem; border-top: 1px solid var(--border); flex-shrink: 0; }
.cafe-input-inner { flex: 1; min-width: 0; }
.cafe-input-row { display: flex; gap: .4rem; align-items: flex-end; }
#cafe-input { flex: 1; padding: .5rem .85rem; background: #0b0c0f; border: 1px solid var(--border); border-radius: 20px; font-size: .88rem; font-family: inherit; resize: none; outline: none; min-height: 36px; max-height: 100px; color: var(--text); transition: border-color .2s; }
#cafe-input:focus { border-color: var(--red); }
.cafe-bubble-img { margin-bottom: .35rem; }
.cafe-bubble-img img { max-width: 220px; max-height: 180px; border-radius: 10px; object-fit: cover; display: block; }
.cafe-mod-badge { font-size: .7rem; background: rgba(226,169,59,.15); color: var(--yellow); border-radius: 4px; padding: 1px 5px; }

/* ============================================
   PAGES LÉGALES
   ============================================ */
.legal-content { max-width: 1100px; margin: 0 auto; padding: 2rem 1.25rem; display: grid; grid-template-columns: 220px 1fr; gap: 2.5rem; align-items: start; }
.legal-toc { background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.25rem; position: sticky; top: calc(var(--header-h) + 1rem); }
.legal-toc h2 { font-size: .82rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; margin-bottom: .85rem; color: var(--muted); }
.legal-toc a { font-size: .82rem; color: var(--muted); text-decoration: none; line-height: 1.7; display: block; transition: color .2s; }
.legal-toc a:hover { color: var(--red); }
.legal-body section { background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.75rem; margin-bottom: 1.25rem; }
.legal-body h2 { font-size: 1.05rem; font-weight: 800; border-left: 4px solid var(--red); padding-left: .85rem; margin: 0 0 1.1rem; }
.legal-body p, .legal-body li { font-size: .92rem; line-height: 1.75; color: var(--muted); }
.legal-table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.legal-table th, .legal-table td { padding: .6rem .85rem; border: 1px solid var(--border); text-align: left; }
.legal-table th { background: rgba(255,255,255,.04); font-weight: 700; }

/* ============================================
   UTILITAIRES
   ============================================ */
.loading-spinner { text-align: center; padding: 2rem; color: var(--muted); font-size: .9rem; }
.empty-state { text-align: center; padding: 3rem 1rem; color: var(--muted); }
.empty-state h3 { font-size: 1.05rem; margin-bottom: .4rem; color: var(--text); }
.text-muted { color: var(--muted); font-size: .85rem; }
.btn-load-more { display: block; width: 100%; padding: .75rem; text-align: center; margin-top: .5rem; }
.sidebar-sticky { position: sticky; top: calc(var(--header-h) + 1rem); }
.sponsored-badge { display: inline-flex; align-items: center; gap: .3rem; font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--yellow); background: rgba(226,169,59,.12); border: 1px solid rgba(226,169,59,.2); border-radius: 20px; padding: 2px 8px; }
.about-item { display: flex; gap: .6rem; align-items: flex-start; padding: .5rem 0; border-bottom: 1px solid rgba(255,255,255,.05); }
.about-item:last-of-type { border-bottom: none; }
.about-emoji { font-size: 1rem; width: 22px; flex-shrink: 0; }
.about-item strong { display: block; font-size: .72rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.about-item p { margin: 0; font-size: .86rem; }
.spinner { width: 22px; height: 22px; border: 2px solid rgba(255,255,255,.1); border-top-color: var(--red); border-radius: 50%; animation: spin .7s linear infinite; display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }
#btn-top { position: fixed !important; bottom: 1.5rem !important; right: 1.25rem !important; z-index: 9000 !important; width: 36px; height: 36px; border-radius: 50%; background: rgba(16,17,20,.9); color: var(--muted); border: 1px solid var(--border); font-size: 1rem; cursor: pointer; display: flex; align-items: center; justify-content: center; opacity: 0; pointer-events: none; transition: opacity .25s, background .2s; backdrop-filter: blur(4px); }
#btn-top.visible { opacity: 1; pointer-events: all; }
#btn-top:hover { background: var(--red); color: #fff; }
.pwa-install-btn { background: rgba(226,169,59,.12) !important; color: var(--yellow) !important; border-color: rgba(226,169,59,.25) !important; }

/* ============================================
   HAMBURGER & MOBILE SIDEBAR
   ============================================ */
.hamburger-btn { display: none; flex-direction: column; justify-content: center; align-items: center; gap: 5px; width: 38px; height: 38px; background: rgba(255,255,255,.06); border-radius: 10px; border: 1px solid var(--border); cursor: pointer; flex-shrink: 0; }
.hamburger-btn span { display: block; width: 18px; height: 2px; background: var(--text); border-radius: 2px; transition: all .25s; }
.hamburger-btn.open span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.hamburger-btn.open span:nth-child(2) { opacity: 0; }
.hamburger-btn.open span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }
.mobile-nav-overlay { display: none; position: fixed; inset: 0; z-index: 998; background: rgba(0,0,0,.65); }
.mobile-nav-overlay.open { display: block; }
.mobile-sidebar { position: fixed; top: 0; left: -100%; width: 280px; height: 100vh; background: var(--panel); border-right: 1px solid var(--border); z-index: 999; overflow-y: auto; transition: left .3s ease; padding-top: var(--header-h); }
.mobile-sidebar.open { left: 0; }

/* Bottom nav mobile */
.mobile-bottom-nav { display: none; position: fixed; bottom: 0; left: 0; right: 0; z-index: 900; background: rgba(6,6,6,.95); border-top: 1px solid var(--border); padding: .5rem 0 calc(.5rem + env(safe-area-inset-bottom)); backdrop-filter: blur(12px); }
.mobile-bottom-nav-inner { display: flex; justify-content: space-around; align-items: center; }
.mobile-nav-item { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: .3rem .75rem; color: var(--muted); text-decoration: none; font-size: .6rem; font-weight: 600; transition: color .2s; cursor: pointer; background: none; border: none; font-family: inherit; }
.mobile-nav-item .nav-item-icon { font-size: 1.3rem; }
.mobile-nav-item.active { color: var(--red); }
.mobile-nav-post-btn { width: 48px; height: 48px; border-radius: 50%; background: var(--red); color: #fff; border: none; display: flex; align-items: center; justify-content: center; font-size: 1.4rem; box-shadow: 0 4px 16px rgba(215,31,38,.5); cursor: pointer; transition: all .25s; }
.mobile-nav-post-btn:hover { background: var(--red-h); transform: scale(1.05); }

/* Filtres mobile */
.mobile-filters { display: none; position: sticky; top: var(--header-h); z-index: 100; background: rgba(6,6,6,.95); border-bottom: 1px solid var(--border); padding: .5rem .75rem; gap: .4rem; align-items: center; overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; backdrop-filter: blur(8px); }
.mobile-filters::-webkit-scrollbar { display: none; }
.mobile-filter-select { flex-shrink: 0; padding: .35rem .6rem; background: rgba(255,255,255,.06); color: var(--text); border: 1px solid var(--border); border-radius: 20px; font-size: .75rem; cursor: pointer; outline: none; appearance: none; max-width: 130px; }
.mobile-filter-select option { background: var(--panel); }
.mobile-filter-reset { flex-shrink: 0; width: 28px; height: 28px; background: rgba(255,255,255,.06); color: var(--muted); border: none; border-radius: 50%; font-size: .8rem; cursor: pointer; }
.mobile-filter-reset:hover { background: var(--red); color: #fff; }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1300px) {
    .quick-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 1100px) {
    .feed-layout { grid-template-columns: 1fr; }
    .feed-right { position: static; }
    .projects-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 980px) {
    .app-layout { grid-template-columns: 1fr; }
    .site-sidebar { display: none; }
    .site-main { padding: 16px; padding-bottom: 5.5rem; }
    .hamburger-btn { display: flex; }
    .mobile-bottom-nav { display: block; }
    .mobile-filters { display: flex !important; }
    .header-search { max-width: 220px; }
    .header-user-info { display: none; }
}
@media (max-width: 700px) {
    :root { --header-h: 60px; }
    .site-header { padding: 0 16px; }
    .header-search { display: none; }
    .hero { padding: 28px; border-radius: 20px; min-height: 380px; }
    .hero-content h1 { font-size: 2rem; }
    .quick-grid { grid-template-columns: 1fr; }
    .projects-grid { grid-template-columns: 1fr; }
    .footer-inner { grid-template-columns: 1fr; text-align: center; gap: 16px; }
    .footer-links, .footer-social { justify-content: center; }
    .legal-content { grid-template-columns: 1fr; }
    .legal-toc { position: static; }
    .profile-content { grid-template-columns: 1fr; }
    .messages-wrap { grid-template-columns: 1fr; height: auto; }
    .conv-panel { max-height: 40vh; }
    .form-row-2, .form-row-3 { grid-template-columns: 1fr; }
    #btn-top { bottom: 5rem !important; }
}
/* ============================================
   RÉELS — Carrousel + Lecteur
   ============================================ */

/* Carrousel dans le feed */
.reels-carousel-wrap {
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 16px 16px 12px;
    margin-bottom: 14px;
    overflow: hidden;
}
.reels-carousel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
    font-size: .82rem;
    font-weight: 700;
    color: var(--text);
}
.reels-carousel-count {
    font-size: .72rem;
    color: var(--muted);
    font-weight: 400;
}
.reels-carousel-track {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 4px;
}
.reels-carousel-track::-webkit-scrollbar { display: none; }

/* Vignette réel */
.reel-thumb {
    position: relative;
    flex-shrink: 0;
    width: 100px;
    height: 160px;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    background: var(--panel-2);
    transition: transform .2s;
}
.reel-thumb:hover { transform: scale(1.03); }
.reel-thumb-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.reel-thumb-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    background: var(--panel-2);
}
.reel-thumb-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(transparent 50%, rgba(0,0,0,.7) 100%);
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    padding: 6px 8px;
}
.reel-duration {
    font-size: .65rem;
    color: #fff;
    font-weight: 700;
    background: rgba(0,0,0,.5);
    padding: 2px 5px;
    border-radius: 4px;
}
.reel-play-icon {
    font-size: .75rem;
    color: #fff;
    opacity: .8;
}
.reel-thumb-author {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 4px 6px;
    font-size: .62rem;
    color: #fff;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: center;
}

/* Mobile */
@media (max-width: 430px) {
    .reel-thumb {
        width: 85px;
        height: 140px;
    }
    .reels-carousel-wrap {
        border-radius: 14px;
        padding: 12px 12px 8px;
    }
}