/* --- Partenariat --- */
.sr-partenariat-section {
  margin: 30px auto;
  width: 102%;
}

.sr-part-grid {
  display: grid;
  gap: 11px;
  align-items: center;
}

.sr-part-grid a {
  display: block;
  transition: transform 0.2s ease, opacity 0.2s ease;
  opacity: 0.85;
}

.sr-part-grid img {
  display: block;
  max-width: 100%;
  filter: sepia(84%) brightness(64%) contrast(100%) saturate(42%);
  transition: filter 0.25s ease;
  border-radius: 6px;
}

.sr-part-grid a:hover img {
  filter: none;
}

.sr-part-grid.sr-partenariat-kokoro {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  margin-bottom: 20px;
}

.sr-part-grid.sr-partenariat-kokoro img {
  max-width: 250px;
  border-radius: 6px;
}

.sr-part-grid.sr-partenariat-tomodachi {
  grid-template-columns: repeat(auto-fill, 50px);
}

/* --- MOBILE - Theming --- */
/* ========================================
   SHINOBI RETSUDEN - MOBILE DARK MODE ULTIMATE
   CSS complet pour TOUS les templates
   ======================================== */

@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+JP:wght@400;500;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Yuji+Boku&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Permanent+Marker&display=swap');

/* ========================================
   VARIABLES GLOBALES
   ======================================== */

:root {
    --dark-bg: #1a1a1a;
    --dark-card: #2a2a2a;
    --dark-card-hover: #333333;
    --gold: #d4a574;
    --gold-light: #e8c9a8;
    --gold-dark: #b8956a;
    --text-primary: #f5f5f5;
    --text-secondary: #a8a8a8;
    --text-tertiary: #7a7a7a;
    --border-gold: rgba(212, 165, 116, 0.3);
    --border-gold-light: rgba(212, 165, 116, 0.1);
    --border-gold-bright: rgba(212, 165, 116, 0.6);
  
    --bg: #1a1a1a;
    --card: #2a2a2a;
    --text: #f5f5f5;
}

/* Dark mode système */
@media (prefers-color-scheme: dark) {
    :root {
        --bg: #1a1a1a;
        --card: #2a2a2a;
        --text: #f5f5f5;
    }
}

/* ========================================
   MOBILE ONLY - Media Query
   Ces styles ne s'appliquent QUE sur mobile
   ======================================== */

@media screen and (max-width: 768px) {
/* ========================================
   RESET & BASE
   ======================================== */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: var(--dark-bg);
    color: var(--text-primary);
    font-size: 14px;
    line-height: 1.6;
    padding-bottom: 80px;
    overflow-x: hidden;
}

body {
  font-family: 'Noto Sans JP', sans-serif;
}

.title {
  font-family: 'Yuji Boku', cursive;
}

.graffiti {
  font-family: 'Permanent Marker', cursive;
}

/* ========================================
   FORCE DARK MODE TOTAL - Override tout
   ======================================== */

/* Tous les backgrounds blancs → dark */
table,
tbody,
tr,
td,
th,
.row1,
.row2,
.row3,
.rowpic,
.catBottom,
.catHead,
.catLeft,
.catRight,
.catSides {
    background: var(--dark-card) !important;
    background-color: var(--dark-card) !important;
}

/* Tous les containers blancs */
.forabg,
.forumline,
table.forumline,
.postbody,
.post {
    background: var(--dark-card) !important;
    border-color: var(--border-gold) !important;
}

/* Force texte clair */
td,
th,
span:not(.material-icons),
.genmed,
.gensmall,
.gen {
    color: var(--text-primary) !important;
}

/* Titres dorés */
h1, h2, h3, h4, h5, h6,
.cattitle,
.forumlink {
    color: var(--gold-light) !important;
}

#tab-bar {
    bottom: 0px;
    margin: 8px;
    background: rgba(25, 25, 25, 0.2);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    left: 0;
    position: fixed;
    right: 0;
    text-align: center;
    z-index: 1000201;
}

.forum {
      background: rgba(25, 25, 25, 0.2);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
  }
.forum-section-wrap:not(:last-child):after {
    background-color: transparent;
    clear: both;
    content: "";
    display: block;
    height: 1px;
    margin-left: 0;
    margin-right: 0;
    position: relative;
    z-index: 2;
}
  
.forum-section:hover .forum-icon {
    background-color: var(--sr-surface-container)!important;
}
  
.fa_darkmode h1, h2, h3, h4, h5, h6,
.cattitle,
.forumlink {
    color: var(--gold-light) !important;
}

.fa_darkmode #tab-bar {
    bottom: 0px;
    margin: 8px;
    background: rgba(25, 25, 25, 0.2);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    left: 0;
    position: fixed;
    right: 0;
    text-align: center;
    z-index: 1000201;
}
  
.fa_darkmode .forum-section-wrap:not(:last-child):after {
    background-color: transparent;
    clear: both;
    content: "";
    display: block;
    height: 1px;
    margin-left: 0;
    margin-right: 0;
    position: relative;
    z-index: 2;
}
/* ========================================
   HEADER - Bannière (index_body)
   ======================================== */

.box.forum-header {
    position: relative;
    height: 200px;
    margin: 0;
    overflow: hidden;
    background: var(--dark-card);
}

.forum-header-background {
    display: none;
}

.forum-header-background img {
    display: none;
}

.forum-header-content {
display: none;
}

#forum-description {
    position: absolute;
    top: 16px;
    left: 50%;
    transform: translateX(-50%);
    color: var(--gold);
    font-size: 9px;
    letter-spacing: 3px;
    text-transform: uppercase;
}

.vertical-help {
    display: none;
}

/* ========================================
   BREADCRUMBS - Navigation
   ======================================== */

.breadcrumbs {
    background: var(--dark-card);
    border: 1px solid var(--border-gold);
    border-radius: 12px;
    padding: 12px 16px;
    margin: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    overflow-x: auto;
    scrollbar-width: none;
}

.breadcrumbs::-webkit-scrollbar {
    display: none;
}

.breadcrumbs a {
    color: var(--gold);
    font-size: 12px;
    text-decoration: none;
    white-space: nowrap;
}

.breadcrumbs .nav {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* ========================================
   BOUTONS PRINCIPAUX
   ======================================== */

.btn,
.btn-rep-topic,
.btn-default {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: transparent !important;
    color: var(--gold) !important;
    border: 2px solid var(--border-gold) !important;
    padding: 12px 24px !important;
    border-radius: 8px !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    letter-spacing: 1.5px !important;
    text-decoration: none !important;
    margin: 16px !important;
    transition: all 0.3s !important;
    cursor: pointer !important;
}

.btn:active,
.btn-rep-topic:active,
.btn-default:active {
    background: rgba(212, 165, 116, 0.1) !important;
    transform: scale(0.98);
}

.btn .material-icons,
.btn-rep-topic .material-icons {
    font-size: 18px;
}

/* Bouton soft */
.btn-soft {
    background: transparent !important;
    border: 1px solid var(--border-gold) !important;
    color: var(--text-secondary) !important;
    padding: 8px 16px !important;
    margin: 8px !important;
}

/* Bouton flottant */
.btn-floating {
    position: fixed !important;
    bottom: 20px !important;
    right: 20px !important;
    z-index: 1000 !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 56px !important;
    height: 56px !important;
    background: var(--gold) !important;
    color: #1a1a1a !important;
    border: none !important;
    border-radius: 50% !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5) !important;
    text-decoration: none !important;
    transition: all 0.3s !important;
}

.btn-floating:active {
    transform: scale(0.9);
}

.btn-floating .material-icons {
    font-size: 24px;
}

.btn-floating-txt {
    display: none;
}

/* ========================================
   PAGE DESCRIPTION (viewtopic, viewforum)
   ======================================== */

#page-desc {
    background: var(--dark-card);
    border: 1px solid var(--border-gold);
    border-radius: 12px;
    margin: 16px;
    padding: 16px;
    max-height: 64px;
    overflow: hidden;
    transition: max-height 0.3s;
}

#page-desc.visible {
    display: block;
}

#page-desc.expanded {
    max-height: 500px;
}

.page-desc-content {
    color: var(--text-secondary);
    font-size: 13px;
    line-height: 1.6;
    margin-bottom: 12px;
}

.page-desc-content div {
    color: var(--gold-light);
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 8px;
}

.page-desc-btn {
    display: none;
    text-align: center;
    cursor: pointer;
}

.page-desc-btn.visible {
    display: block;
}

.page-desc-btn .material-icons {
    color: var(--gold);
    font-size: 24px;
}

#page-desc:not(.expanded) .page-desc-btn .material-icons:last-child,
#page-desc.expanded .page-desc-btn .material-icons:first-child {
    display: none;
}

/* ========================================
   QUICKMOD - Modération rapide
   ======================================== */

.quickmod {
    margin: 16px;
}

.quickmod-wrap select {
    width: 100%;
    background: var(--dark-card);
    border: 1px solid var(--border-gold);
    color: var(--text-primary);
    padding: 10px;
    border-radius: 8px;
    font-size: 13px;
}

/* ========================================
   PAGINATION
   ======================================== */

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin: 16px;
    flex-wrap: wrap;
}

.pagination a,
.pagination strong {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 12px;
    background: var(--dark-card);
    border: 1px solid var(--border-gold);
    border-radius: 8px;
    color: var(--gold);
    font-size: 12px;
    text-decoration: none;
}

.pagination strong {
    background: rgba(212, 165, 116, 0.2);
    border-color: var(--gold);
}

/* ========================================
   TOPICS - Container principal
   ======================================== */

.topic {
    background: var(--dark-card);
    border: 1px solid var(--border-gold);
    border-radius: 12px;
    margin: 16px;
    overflow: hidden;
}

/* ========================================
   POSTS - Messages (viewtopic)
   ======================================== */

.post-section {
    background: transparent;
    border-bottom: 1px solid var(--border-gold-light);
    padding: 16px;
}

.post-section:last-child {
    border-bottom: none;
}

.post-head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.post-icon {
    position: relative;
    width: 48px;
    height: 48px;
    flex-shrink: 0;
}

.post-icon .material-icons {
    position: absolute;
    width: 48px;
    height: 48px;
    background: rgba(212, 165, 116, 0.2);
    border: 2px solid var(--border-gold);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gold);
    font-size: 24px;
}

.post-icon img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 2px solid var(--border-gold);
    object-fit: cover;
    position: relative;
    z-index: 1;
}

.post-info {
    flex: 1;
}

.post-info .h3 {
    color: var(--gold-light);
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 4px;
}

.post-details {
    color: var(--text-secondary);
    font-size: 12px;
}

.post-details a {
    color: var(--gold);
    text-decoration: none;
}

.post-content {
    color: var(--text-primary);
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 16px;
    word-wrap: break-word;
}

.post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 8px 0;
}

.post-content a {
    color: var(--gold);
    text-decoration: underline;
}

/* Pièces jointes */
.attachbox {
    background: rgba(212, 165, 116, 0.05);
    border: 1px solid var(--border-gold);
    border-radius: 8px;
    padding: 12px;
    margin-top: 16px;
}

.attachbox .title {
    color: var(--gold);
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.attachments {
    list-style: none;
}

.attachments dt {
    color: var(--gold-light);
    font-size: 13px;
    margin-bottom: 4px;
}

.attachments dd {
    color: var(--text-secondary);
    font-size: 11px;
    margin-bottom: 12px;
    margin-left: 0;
}

/* Message édité */
.post-section > div[style*="color"] {
    color: var(--text-secondary) !important;
    font-size: 11px;
    font-style: italic;
    margin-top: 8px;
}

/* ========================================
   POST BUTTONS - Like/Dislike/Menu
   ======================================== */

.post-buttons {
    display: flex;
    align-items: center;
    gap: 8px;
    list-style: none;
    flex-wrap: wrap;
    margin: 0;
    padding: 0;
}

.rep-button {
    display: inline-flex !important;
    align-items: center;
    gap: 6px;
    background: transparent !important;
    border: 1px solid var(--border-gold) !important;
    color: var(--gold) !important;
    padding: 8px 14px !important;
    border-radius: 8px !important;
    font-size: 11px !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    cursor: pointer !important;
    transition: all 0.3s !important;
}

.rep-button:active {
    background: rgba(212, 165, 116, 0.1) !important;
    transform: scale(0.95);
}

.rep-button .material-icons {
    font-size: 16px;
}

.rep-button span {
    display: none;
}

.rep-button.fa_voted {
    background: rgba(212, 165, 116, 0.2) !important;
    border-color: var(--gold) !important;
}

/* Menu contextuel */
.navmenu_block {
    position: relative;
}

.navmenu_show {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: transparent;
    border: 1px solid var(--border-gold);
    border-radius: 8px;
    cursor: pointer;
}

.navmenu_show .material-icons {
    color: var(--gold);
    font-size: 20px;
}

.navmenu_list {
    display: none;
    position: absolute;
    right: 0;
    top: 100%;
    margin-top: 8px;
    background: var(--dark-card);
    border: 1px solid var(--border-gold);
    border-radius: 8px;
    padding: 8px;
    min-width: 150px;
    z-index: 100;
    list-style: none;
}

.navmenu_show:active + .navmenu_list {
    display: block;
}

.navmenu_list li {
    padding: 8px;
}

.navmenu_list a {
    color: var(--gold);
    font-size: 12px;
    text-decoration: none;
    display: block;
}

/* ========================================
   LIKES/DISLIKES
   ======================================== */

.fa_like_div {
    background: rgba(212, 165, 116, 0.05);
    border: 1px solid var(--border-gold);
    border-radius: 8px;
    padding: 12px;
    margin: 16px 0;
    font-size: 12px;
    color: var(--text-secondary);
}

/* ========================================
   FORUMS - Liste des catégories (index_box)
   ======================================== */

.forum {
    background: var(--dark-card) !important;
    border: 1px solid var(--border-gold) !important;
    border-radius: 12px;
    margin: 16px;
    overflow: hidden;
}

.forum h2 {
    background: transparent !important;
    padding: 14px 16px;
    font-size: 16px;
    font-weight: 600;
    color: var(--gold-light) !important;
    text-transform: uppercase;
    letter-spacing: 2px;
    border-bottom: 1px solid var(--border-gold);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.forum h2 span {
    flex: 1;
}

/* Bouton collapse */
.forum-hide {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    position: relative;
    flex-shrink: 0;
}

.forum-hide-icon-a,
.forum-hide-icon-b {
    position: absolute;
    width: 12px;
    height: 2px;
    background: var(--gold);
    border-radius: 2px;
}

.forum-hide-icon-b {
    transform: rotate(90deg);
    transition: opacity 0.3s;
}

.forum-hide.forum-show .forum-hide-icon-b {
    opacity: 0;
}

.forum-hidden .forum-section-wrap {
    display: none;
}

/* Section de forum */
.forum-section-wrap {
    background: rgba(25, 25, 25, 0.2)!important;
    backdrop-filter: blur(8px)!important;
    -webkit-backdrop-filter: blur(8px)!important;
    border-bottom: 1px solid var(--border-gold-light);
    padding: 16px;
}

.forum-section-wrap:last-child {
    border-bottom: none;
}

.forum-section {
    display: flex;
    gap: 12px;
    background: transparent !important;
}
  
@media screen and (max-width: 768px) {
    .forum-section {
        display: flex;
        gap: 12px;
        background: transparent !important;
        border: 1px solid var(--border-gold);
        border-radius: 12px;
    }
}
  
.forum-section:before {
background-color: transparent;
border-color: transparent;
    content: "";
    display: block;
    clear: both;
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    width: 32px;
    border-right-width: 1px;
    border-right-style: solid;
    z-index: 1;
}

.forum-icon {
    background-color: var(--sr-surface-container)!important;
    position: relative;
    width: 48px;
    height: 48px;
    flex-shrink: 0;
}
  
.forum-icon i:only-child {
  display:none;}

.forum-icon .material-icons {
    display:none;
}

.forum-avatar {
    position: relative;
    z-index: 1;
        width: 48px;
    height: 48px;
}

.forum-avatar img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 2px solid var(--border-gold);
    object-fit: cover;
}

.forum-content {
    flex: 1;
    min-width: 0;
    margin: 8px;
}

.forum-content a {
    color: var(--gold-light) !important;
    text-decoration: none !important;
}

.forum-content h3 {
    color: var(--gold-light) !important;
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 6px;
}

.forum-statistics {
    background-color: transparent;
    letter-spacing: 0.96px;
    text-transform: uppercase;
    display: block;
    font-size: 12px;
    max-width: 100%;
    overflow: hidden;
    padding: 0 6px;
    position: absolute;
    right: 0;
    text-overflow: ellipsis;
    top: 0;
    white-space: nowrap;
    direction: ltr;
}

.forum-description {
    color: var(--text-secondary) !important;
    font-size: 12px;
    line-height: 1.5;
    margin-bottom: 12px;
}

.forum-lastpost-wrap {
        display: flex;
        align-items: flex-start;
        gap: 8px;
        margin-top: 8px;
        padding-top: 8px;
        border-top: 1px solid var(--border-gold-light);
        flex-direction: column-reverse;
}

.forum-lastpost-wrap a {
    display: none;
}

.forum-lastpost-wrap .material-icons {
    color: var(--gold) !important;
    font-size: 16px;
    flex-shrink: 0;
    margin:0px;
}

.forum-lastpost {
    color: var(--gold-light) !important;
    font-size: 12px;
    font-weight: 500;
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    width: -webkit-fill-available;
}

.forum-lastpost-time {
    color: var(--text-secondary) !important;
    font-size: 10px;
}

.forum-empty {
    padding: 32px 16px;
    text-align: center;
    color: var(--text-secondary);
    font-size: 13px;
}

.last-post-link {
    display: none;
}

/* ========================================
   NAVIGATION BOTTOM - Style dark
   ======================================== */

/* Container de navigation ForumActif */
#mpage-body-modern {
    background: var(--dark-bg) !important;
}

/* Bottom nav bar */
.bottom-nav,
nav[class*="bottom"],
div[class*="bottom-nav"] {
    position: fixed !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    z-index: 999 !important;
    background: var(--dark-card) !important;
    border-top: 1px solid var(--border-gold) !important;
    padding: 8px 0 env(safe-area-inset-bottom, 8px) !important;
    display: flex !important;
    justify-content: space-around !important;
    align-items: center !important;
}

/* Items de navigation */
.bottom-nav a,
nav[class*="bottom"] a,
div[class*="bottom-nav"] a {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    gap: 4px !important;
    color: var(--text-secondary) !important;
    font-size: 11px !important;
    text-decoration: none !important;
    padding: 8px 16px !important;
    transition: all 0.3s !important;
}

/* Nav icons */
.bottom-nav a svg,
.bottom-nav a i,
.bottom-nav a .material-icons,
nav[class*="bottom"] svg,
nav[class*="bottom"] i {
    color: var(--text-secondary) !important;
    font-size: 24px !important;
}

/* Active state */
.bottom-nav a.active,
.bottom-nav a:active,
nav[class*="bottom"] a.active,
nav[class*="bottom"] a:active {
    color: var(--gold) !important;
}

.bottom-nav a.active svg,
.bottom-nav a.active i,
nav[class*="bottom"] a.active svg,
nav[class*="bottom"] a.active i {
    color: var(--gold) !important;
}

/* ========================================
   TOPICS LIST (topics_list_box)
   ======================================== */

.lastpost-arrow {
    display: none;
}

/* ========================================
   TOPICS GRID (topics_grid_box)
   ======================================== */

.posts.forum-grid {
    background: var(--dark-card);
    border: 1px solid var(--border-gold);
    border-radius: 12px;
    margin: 16px;
    overflow: hidden;
}

.posts-header {
    background: transparent;
    padding: 14px 16px;
    border-bottom: 1px solid var(--border-gold);
}

.posts-title {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--gold-light);
    font-size: 16px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.posts-title .material-icons {
    font-size: 20px;
}

.grid-section {
    padding: 16px;
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

.topic-card {
    background: rgba(42, 42, 42, 0.5);
    border: 1px solid var(--border-gold);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s;
}

.topic-card:active {
    transform: scale(0.98);
}

.cover-image {
    position: relative;
    width: 100%;
    height: 180px;
    background: linear-gradient(135deg, rgba(42, 42, 42, 0.8), rgba(26, 26, 26, 0.9)), var(--cover-image);
    background-size: cover;
    background-position: center;
}

.posts-icon {
    position: absolute;
    top: 12px;
    left: 12px;
    width: 40px;
    height: 40px;
    background: rgba(212, 165, 116, 0.2);
    border: 2px solid var(--border-gold);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.posts-icon .material-icons {
    color: var(--gold);
    font-size: 20px;
}

.stats {
    position: absolute;
    top: 12px;
    right: 12px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.stats span {
    display: flex;
    align-items: center;
    gap: 4px;
    background: rgba(25, 25, 25, 0.2);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 11px;
    color: var(--text-primary);
}

.stats .material-icons {
    font-size: 14px;
}

.topic-type {
    position: absolute;
    bottom: 12px;
    left: 12px;
    background: rgba(212, 165, 116, 0.9);
    color: #1a1a1a;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
}

.author-avatar {
    position: absolute;
    bottom: 12px;
    right: 12px;
}

.author-avatar img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid var(--border-gold);
}

.topic-card .content {
    padding: 16px;
}

.topic-card h3 {
    color: var(--gold-light);
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 8px;
}

.description {
    color: var(--text-secondary);
    font-size: 12px;
    line-height: 1.5;
    margin-bottom: 12px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 12px;
    border-top: 1px solid var(--border-gold-light);
}

.forum-avatar-footer {
    display: flex;
    align-items: center;
    gap: 8px;
}

.forum-avatar-footer img {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 2px solid var(--border-gold);
}

.forum-avatar-footer span {
    color: var(--gold);
    font-size: 11px;
}

.time {
    display: flex;
    align-items: center;
    gap: 4px;
    color: var(--text-secondary);
    font-size: 10px;
}

.time .material-icons {
    font-size: 14px;
}

.participate-check {
    display:none;
}
.participate-check i {
    display:none;
}
.posts-empty {
    padding: 32px 16px;
    text-align: center;
    color: var(--text-secondary);
}

/* ========================================
   POSTING (posting_body, posting_topic_review)
   ======================================== */

form[name="post"] {
    margin: 16px;
}

fieldset.submit-buttons {
    border: none;
    margin: 16px 0;
    padding: 0;
}

.input-subtle,
.select-subtle select,
textarea#text_editor_textarea {
    width: 100%;
    background: var(--dark-card) !important;
    border: 1px solid var(--border-gold) !important;
    color: var(--text-primary) !important;
    padding: 12px !important;
    border-radius: 8px !important;
    font-size: 13px !important;
    font-family: 'Noto Sans JP', sans-serif !important;
    margin-bottom: 12px !important;
}

.input-subtle::placeholder,
textarea::placeholder {
    color: var(--text-secondary) !important;
}

.select-subtle {
    background: var(--dark-card);
    border: 1px solid var(--border-gold);
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 12px;
}

.select-subtle select {
    border: none !important;
    margin: 0 !important;
}

.input-username {
    margin-bottom: 8px !important;
}

#add_username {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: transparent;
    border: 1px solid var(--border-gold);
    border-radius: 8px;
    color: var(--gold);
    cursor: pointer;
    margin-bottom: 12px;
}

#add_username .material-icons {
    font-size: 20px;
}

.dropdown-usernames {
    position: absolute;
    background: var(--dark-card);
    border: 1px solid var(--border-gold);
    border-radius: 8px;
    list-style: none;
    z-index: 1000;
    max-height: 200px;
    overflow-y: auto;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5);
}

.dropdown-usernames li {
    padding: 10px 16px;
    color: var(--text-primary);
    cursor: pointer;
    font-size: 13px;
}

.dropdown-usernames li:hover {
    background: rgba(212, 165, 116, 0.1);
}

/* Boutons de formulaire */
.btn-black,
.btn-mini {
    background: transparent !important;
    border: 1px solid var(--border-gold) !important;
    color: var(--gold) !important;
    padding: 8px 16px !important;
    border-radius: 8px !important;
    font-size: 11px !important;
}

/* ========================================
   MESSAGE BODY
   ======================================== */

.page-title {
    color: var(--gold-light);
    font-size: 20px;
    font-weight: 600;
    text-align: center;
    margin-bottom: 16px;
}

.frm-info {
    color: var(--text-secondary);
    font-size: 14px;
    text-align: center;
    line-height: 1.6;
}

/* ========================================
   BOUTON REJOINDRE (index_body)
   ======================================== */

#join_index_btn {
    padding: 16px;
    text-align: center;
    background: none;
    margin: 0;
}

#join_index_btn .btn {
    margin: 0 !important;
}

#join_index_btn .btn .material-icons {
    display: none;
}

/* ========================================
   MESSAGES ADMIN (index_body)
   ======================================== */

.box.introduction {
        display: none;
}

/* ========================================
   SIDEBAR TABS (index_body)
   ======================================== */

.cp-sidebar {
    margin: 16px;
    background: var(--dark-card);
    border: 1px solid var(--border-gold);
    border-radius: 12px;
    overflow: hidden;
}

.cp-sidebar #tabs ul {
    display: flex;
    list-style: none;
    overflow-x: auto;
    scrollbar-width: none;
}

.cp-sidebar #tabs ul::-webkit-scrollbar {
    display: none;
}

.cp-sidebar #tabs ul li {
    flex-shrink: 0;
}

.cp-sidebar #tabs ul a {
    display: block;
    padding: 14px 20px;
    color: var(--text-secondary);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    text-decoration: none;
    border-bottom: 2px solid transparent;
    transition: all 0.3s;
}

.cp-sidebar #tabs ul a.active,
.cp-sidebar #tabs ul a:hover {
    color: var(--gold);
    background: rgba(212, 165, 116, 0.05);
    border-bottom-color: var(--gold);
}

/* ========================================
   MODULES & BOXES GÉNÉRIQUES
   ======================================== */

.box,
.module {
    display: none;
}

.box h2,
.box .h3,
.module .h3 {
    background: transparent;
    padding: 14px;
    font-size: 16px;
    font-weight: 600;
    color: var(--gold-light);
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 2px;
    border-bottom: 1px solid var(--border-gold);
}

.box-content,
.module-table {
    padding: 16px;
}

/* ========================================
   STATISTIQUES (index_body)
   ======================================== */

.box-subtle,
.box-widget-bottom {
    background: var(--dark-card);
    border: 1px solid var(--border-gold);
    border-radius: 12px;
    padding: 16px;
    margin: 16px;
    color: var(--text-secondary);
    font-size: 12px;
    line-height: 1.8;
}

.box-subtle h2 {
    background: none;
    color: var(--gold-light);
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 12px;
    padding: 0;
    border: none;
}

.box-widget-bottom strong {
    color: var(--gold);
}

/* ========================================
   QUI EST EN LIGNE (index_body)
   ======================================== */

.whoisonline-toggle {
    display: inline-block;
    margin-top: 12px;
    padding: 8px 16px;
    background: transparent;
    border: 1px solid var(--border-gold);
    border-radius: 6px;
    color: var(--gold);
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    cursor: pointer;
    transition: all 0.3s;
}

.whoisonline-toggle:active {
    background: rgba(212, 165, 116, 0.1);
}

.whoisonline-modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    z-index: 10000;
    padding: 20px;
    overflow-y: auto;
}

.whoisonline-modal > div:first-child {
    background: rgba(25, 25, 25, 0.2);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 2px solid var(--border-gold);
    border-radius: 12px;
    max-width: 500px;
    margin: 40px auto;
}

.whoisonline-title {
    background: transparent;
    padding: 16px;
    font-size: 14px;
    font-weight: 600;
    color: var(--gold-light);
    text-transform: uppercase;
    letter-spacing: 2px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-gold);
}

.whoisonline-close {
    cursor: pointer;
    font-size: 24px;
    color: var(--gold);
}

.whoisonline-list {
    padding: 20px;
    color: var(--text-secondary);
    font-size: 12px;
    line-height: 1.8;
}

.whoisonline-list strong {
    color: var(--gold);
}

/* ========================================
   DERNIÈRES IMAGES (index_body)
   ======================================== */

.module.index-last-images {
    background: var(--dark-card);
    border: 1px solid var(--border-gold);
    border-radius: 12px;
    margin: 16px;
    overflow: hidden;
}

.module.index-last-images .h3 {
    display: flex;
    align-items: center;
    gap: 8px;
}

.container-imgs-list {
    padding: 16px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.container-imgs-list img {
    width: 100%;
    height: 100px;
    object-fit: cover;
    border-radius: 8px;
    border: 2px solid var(--border-gold);
}

/* ========================================
   PROMOTION TRAFIC
   ======================================== */

.module-table table {
    width: 100%;
    border-collapse: collapse;
}

.module-table td {
    padding: 12px;
    border-bottom: 1px solid var(--border-gold-light);
}

.module-table td:last-child {
    border-bottom: none;
}

.module-table a {
    color: var(--gold);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* ========================================
   FORMULAIRES GÉNÉRIQUES
   ======================================== */

input[type="text"],
input[type="password"],
input[type="email"],
textarea,
select {
    background: var(--dark-card);
    border: 1px solid var(--border-gold);
    color: var(--text-primary);
    padding: 10px;
    border-radius: 8px;
    font-size: 13px;
    font-family: 'Noto Sans JP', sans-serif;
}

input::placeholder,
textarea::placeholder {
    color: var(--text-secondary);
}

input[type="submit"],
input[type="button"],
button:not(.rep-button):not(.btn):not(.btn-default):not(.btn-soft) {
    background: transparent;
    color: var(--gold);
    border: 2px solid var(--border-gold);
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    cursor: pointer;
    transition: all 0.3s;
}

input[type="submit"]:active,
input[type="button"]:active,
button:active {
    background: rgba(212, 165, 116, 0.1);
}

/* ========================================
   AVATARS
   ======================================== */

.avatar,
.avatar img {
    border-radius: 50%;
    border: 2px solid var(--border-gold);
    object-fit: cover;
}

/* ========================================
   LIENS
   ======================================== */

a {
    color: var(--gold);
    text-decoration: none;
    transition: opacity 0.3s;
}

a:hover,
a:active {
    opacity: 0.7;
}

/* ========================================
   IMAGES
   ======================================== */

img {
    max-width: 100%;
    height: auto;
}

/* ========================================
   MATERIAL ICONS
   ======================================== */

.material-icons {
    font-family: 'Material Icons';
    font-size: 18px;
    vertical-align: middle;
    display: inline-block;
}

/* ========================================
   SCROLLBAR DARK MODE
   ======================================== */

::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: var(--dark-bg);
}

::-webkit-scrollbar-thumb {
    background: var(--gold);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--gold-light);
}

/* ========================================
   RESPONSIVE
   ======================================== */

@media (max-width: 480px) {
    .forum-header-content img {
        max-width: 120px;
    }
    
    .container-imgs-list {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .box h2,
    .box .h3,
    .forum h2,
    .module .h3 {
        font-size: 14px;
    }
    
    .post-icon,
    .post-icon .material-icons,
    .post-icon img,
    .forum-icon,
    .forum-icon .material-icons,
    .avatar,
    .avatar img {
        width: 40px;
        height: 40px;
    }
    
    .grid-section {
        padding: 12px;
    }
}

/* ========================================
   OPTIMISATIONS PERFORMANCE
   ======================================== */

@media (prefers-reduced-motion: reduce) {
    * {
        animation: none !important;
        transition: none !important;
    }
}

/* Safe area pour notch iPhone */
@supports (padding: env(safe-area-inset-bottom)) {
    body {
        padding-bottom: max(80px, env(safe-area-inset-bottom));
    }
}

} /* FIN MEDIA QUERY MOBILE (max-width: 768px) */

/* --- Aside elements (PgUp, Player...) --- */
/* ── SR Media Player ── */
.sr-bottom-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.sr-vol-wrap {
  display: flex;
  align-items: center;
  padding: 0 4px;
}

input[type="range"].sr-volume {
  -webkit-appearance: none;
  appearance: none;
  width: 70px;
  height: 3px;
  border-radius: 2px;
  background: linear-gradient(to right, var(--sr-border-accent) 0%, var(--sr-border-accent) var(--vol), var(--sr-border) var(--vol));
  outline: none;
  cursor: pointer;
}

input[type="range"].sr-volume::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--sr-fontype-color-secondary);
  border: 1px solid var(--sr-border-accent);
  cursor: pointer;
}

.sr-player[data-style="mini"] {
  max-width: 56px;
  padding: 8px;
}

.sr-thumb-overlay svg {
  color: var(--sr-fontype-color-secondary);
}

.sr-player.playing .sr-thumb-overlay svg polygon {
  display: none;
}

.sr-player.playing .sr-thumb-overlay svg::after {
  content: '';
}

.sr-player.playing .sr-thumb-overlay::before {
  content: '';
  display: block;
  width: 10px;
  height: 12px;
  background: linear-gradient(to right, var(--sr-fontype-color-secondary) 0%, var(--sr-fontype-color-secondary) 35%, transparent 35%, transparent 65%, var(--sr-fontype-color-secondary) 65%);
  opacity: 0.85;
}

.sr-player.playing .sr-thumb-overlay svg {
  d: path('M4,3 L4,13 M12,3 L12,13');
}

.sr-player {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--sr-surface-container-low);
  border: 1px solid var(--sr-border);
  border-radius: 40px;
  padding: 8px 18px 8px 8px;
  width: 100%;
  max-width: 360px;
}

.sr-thumb {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  border: 1px solid var(--sr-border-accent);
  cursor: pointer;
  position: relative;
}

.sr-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.7) sepia(0.2);
  transition: filter 0.3s;
}

.sr-thumb:hover img { filter: brightness(0.9); }

.sr-thumb-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: oklch(0% 0 0 / 0.3);
  transition: background 0.2s;
}

.sr-thumb:hover .sr-thumb-overlay { background: oklch(0% 0 0 / 0.1); }

.sr-thumb-overlay svg {
  width: 12px;
  height: 12px;
  fill: var(--sr-fontype-color-secondary);
  margin-left: 1px;
  opacity: 0.85;
}

.sr-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.sr-title {
  font-size: 12px;
  color: var(--sr-fontype-color-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: 0.3px;
}

.sr-label {
  font-size: 8px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--sr-fontype-color-primary);
  opacity: 0.7;
}

.sr-ext {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  opacity: 0.35;
  transition: opacity 0.2s;
  text-decoration: none;
}

.sr-ext:hover { opacity: 0.8; }

.sr-ext svg {
  width: 13px;
  height: 13px;
  fill: none;
  stroke: var(--sr-fontype-color-secondary);
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Lightbox */
#sr-lb {
  display: none;
  position: fixed;
  inset: 0;
  background: oklch(10% 0 0 / 0.92);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(6px);
  cursor: pointer;
}

#sr-lb.on { display: flex; }

.sr-lb-inner {
  width: min(90vw, 700px);
  aspect-ratio: 16/9;
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid var(--sr-border-accent);
  box-shadow: 0 20px 60px oklch(0% 0 0 / 0.7);
  cursor: default;
}

.sr-lb-inner iframe {
  width: 100%;
  height: 100%;
  border: none;
}

/*** Boutons scroll haut / bas ***/
.sr-scroll-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  text-decoration: none;
  background: radial-gradient(
    circle at 38% 30%,
    oklch(27% 0.012 50 / 0.9),
    var(--sr-surface-container-low) 70%
  );
  border: 1.5px solid var(--sr-border);
  box-shadow: 0 0 0 1px oklch(0% 0 0 / 0.55),
    inset 0 1px 0 oklch(100% 0 0 / 0.04),
    0 4px 18px oklch(0% 0 0 / 0.55);
  overflow: hidden;
  transition: border-color .28s ease,
    box-shadow .28s ease, transform .18s ease;
}

/* Anneau intérieur */
.sr-scroll-btn::before {
  content: '';
  position: absolute;
  inset: 4px;
  border-radius: 50%;
  border: 1px solid var(--sr-border);
  transition: border-color .28s ease;
  pointer-events: none;
}

/* Hover */
.sr-scroll-btn:hover {
  border-color: var(--sr-border-accent);
  box-shadow: 0 0 12px oklch(from var(--sr-border-accent) l c h / 0.22),
    0 6px 22px oklch(0% 0 0 / 0.65);
  transform: scale(1.07);
}
.sr-scroll-btn:active {
  transform: scale(0.95);
}

/* Flèche SVG */
.sr-scroll-btn svg {
  width: 13px; height: 13px;
  fill: none;
  stroke: var(--sr-fontype-color-primary);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: stroke .28s ease;
}
.sr-scroll-btn:hover svg {
  stroke: var(--sr-fontype-color-secondary);
}
#sr-scroll-btns {
  position: fixed;
  bottom: 24px;
  right: 24px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 9999;
}

