/*
Theme Name: RevivalCS
Theme URI: https://example.com
Author: RevivalCS
Description: Theme WordPress classique pour le site RevivalCS, style Counter-Strike 1.x (menu illumine, sous-menus, bouton Discord).
Version: 1.4
Requires PHP: 7.2
Text Domain: revivalcs
*/

@font-face {
  font-family: 'FaceliftFont';
  src: local('Facelift'),
       local('Facelift Regular');
  font-weight: normal;
  font-style: normal;
}

@import url('https://fonts.googleapis.com/css2?family=Special+Elite&display=swap');

* { box-sizing: border-box; }

html, body {
  margin: 0;
  min-height: 100vh;
  background: #faf9f6;
  font-family: 'Arial Narrow', Arial, sans-serif;
}

body {
  display: flex;
  flex-direction: column;
}

/* ---------------------------------------------------------
   BARRE DE NAVIGATION
--------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: #2b2114;
  background-image: radial-gradient(ellipse at top, #4a3a24 0%, #241b11 45%, #120d08 85%);
  border-bottom: 1px solid #4d3d28;
  box-shadow: 0 1px 0 rgba(232, 176, 58, 0.15);
}

.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  min-height: 150px;
  padding: 20px 24px 2px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

.site-logo {
  display: flex;
  flex-direction: column;
  align-items: center;
  font-family: 'FaceliftFont', 'Arial Narrow', Arial, sans-serif;
  font-size: 42px;
  font-weight: normal;
  font-style: normal;
  letter-spacing: 3px;
  text-transform: uppercase;
  text-decoration: none;
  text-align: center;
  text-shadow: 0 0 4px rgba(0, 0, 0, 1), 0 0 10px rgba(0, 0, 0, 1), 0 0 18px rgba(0, 0, 0, 0.8), 3px 3px 3px rgba(255, 0, 0, 1), 0 0 14px rgba(255, 0, 0, 0.75);
  line-height: 1.15;
}

.site-logo .logo-revival {
  color: #f2ede0;
  transition: color 120ms ease-out, text-shadow 120ms ease-out;
}

.site-logo:hover .logo-revival {
  color: #ffffff;
  text-shadow:
    0 0 4px rgba(255, 255, 255, 1),
    0 0 10px rgba(255, 255, 255, 0.85),
    0 0 20px rgba(255, 255, 255, 0.6),
    2px 2px 4px rgba(255, 0, 0, 0.9);
}

.logo-a-small {
  font-size: 0.8em;
  vertical-align: baseline;
  position: relative;
  top: -3px;
  margin-right: 3px;
}

.site-logo .logo-cs {
  color: #f2ede0;
  font-size: 26px;
  text-transform: none;
  text-shadow: 0 0 4px rgba(0, 0, 0, 1), 0 0 10px rgba(0, 0, 0, 1), 0 0 18px rgba(0, 0, 0, 0.8);
  transition: color 120ms ease-out, text-shadow 120ms ease-out;
}

.site-logo:hover .logo-cs {
  color: #ffffff;
  text-shadow:
    0 0 4px rgba(255, 255, 255, 1),
    0 0 10px rgba(255, 255, 255, 0.85),
    0 0 20px rgba(255, 255, 255, 0.6);
}

nav.main-menu {
  display: flex;
  align-items: center;
  margin-top: auto;
}

.main-menu ul {
  list-style: none;
  display: flex;
  align-items: center;
  margin: 0;
  padding: 0;
}

.main-menu li {
  display: flex;
  align-items: center;
  position: relative;
}

.main-menu a {
  display: inline-block;
  padding: 10px 16px;
  font-family: 'Special Elite', cursive;
  color: #e8b03a;
  font-size: 18px;
  font-weight: normal;
  font-style: italic;
  letter-spacing: 2px;
  text-transform: none;
  text-decoration: none;
  transition: color 120ms ease-out, text-shadow 120ms ease-out, transform 120ms ease-out;
  text-shadow: 0 0 4px rgba(0, 0, 0, 1), 0 0 10px rgba(0, 0, 0, 1), 0 0 18px rgba(0, 0, 0, 0.8);
  transform-origin: center;
}

.main-menu a:hover {
  color: #fff6d8;
  transform: scale(1.04);
  text-shadow:
    0 0 2px rgba(255, 20, 20, 0.95),
    0 0 5px rgba(220, 0, 0, 0.75);
}

.main-menu a:active {
  text-shadow:
    0 0 2px #fff,
    0 0 6px rgba(255, 20, 20, 1);
}

/* Version mobile : le menu passe à la ligne si trop de liens */
@media (max-width: 720px) {
  .main-menu ul {
    flex-wrap: wrap;
    justify-content: center;
    row-gap: 8px;
  }
}

/* ---------------------------------------------------------
   SOUS-MENU (dropdown) style panneau de menu CS 1.5
   WordPress ajoute automatiquement la classe .menu-item-has-children
   aux <li> qui ont des sous-pages/sous-menus.
--------------------------------------------------------- */
.main-menu li.menu-item-has-children {
  position: relative;
}

.main-menu .sub-menu {
  display: block !important;
  list-style: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(-6px);
  min-width: 220px;
  margin: 0;
  padding: 6px 0;
  background: #1c150c;
  border: 1px solid #e8892a;
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.6),
    0 6px 14px rgba(0, 0, 0, 0.7),
    0 0 10px rgba(232, 176, 58, 0.08);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 120ms ease-out, transform 120ms ease-out, visibility 0s linear 120ms;
  z-index: 20;
}

.main-menu li.menu-item-has-children:hover > .sub-menu,
.main-menu li.menu-item-has-children:focus-within > .sub-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
  transition: opacity 120ms ease-out, transform 120ms ease-out, visibility 0s;
}

.main-menu .sub-menu li {
  display: block !important;
  box-shadow: inset 0 1px 0 rgba(232, 137, 42, 0.5);
}

.main-menu .sub-menu li:first-child {
  box-shadow: none;
}

.main-menu .sub-menu a {
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  height: 38px;
  padding: 0 20px;
  font-size: 16px;
  letter-spacing: 1px;
  text-align: center;
  white-space: nowrap;
  text-shadow: 0 0 3px rgba(0, 0, 0, 1), 0 0 7px rgba(0, 0, 0, 1);
  transform: none;
}

.main-menu .sub-menu a:hover {
  color: #fff6d8;
  background: rgba(232, 176, 58, 0.06);
  transform: none;
  text-shadow:
    0 0 2px rgba(255, 20, 20, 0.95),
    0 0 5px rgba(220, 0, 0, 0.75);
}

/* Item parent avec sous-menu : non cliquable, curseur normal */
.main-menu li.menu-item-has-children > a {
  cursor: default;
}

.main-menu li.menu-item-has-children > a::after {
  content: '';
  display: inline-block;
  margin-left: 6px;
  vertical-align: middle;
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 6px solid #e8b03a;
  opacity: 1;
  transition: border-top-color 120ms ease-out, filter 120ms ease-out;
}

.main-menu li.menu-item-has-children > a:hover::after {
  border-top-color: #fff6d8;
  filter:
    drop-shadow(0 0 2px rgba(255, 20, 20, 0.95))
    drop-shadow(0 0 5px rgba(220, 0, 0, 0.75));
}

@media (max-width: 720px) {
  .main-menu .sub-menu {
    position: static;
    transform: none;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    box-shadow: none;
    border: none;
    background: rgba(0, 0, 0, 0.2);
    min-width: 0;
    display: none;
  }
  .main-menu li.menu-item-has-children:hover > .sub-menu,
  .main-menu li.menu-item-has-children:focus-within > .sub-menu {
    display: block;
  }
}

/* ---------------------------------------------------------
   SELECTEUR DE LANGUE
--------------------------------------------------------- */
.lang-switcher {
  position: absolute;
  top: 16px;
  left: calc(50% - 454px);
  display: flex;
  gap: 8px;
}

.lang-switcher button {
  all: unset;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 22px;
  border-radius: 2px;
  cursor: pointer;
  overflow: hidden;
  border: 1px solid #4d3d28;
  opacity: 0.55;
  filter: grayscale(35%);
  transition: opacity 120ms ease-out, filter 120ms ease-out, box-shadow 120ms ease-out, transform 120ms ease-out;
}

.lang-switcher button svg {
  width: 100%;
  height: 100%;
  display: block;
}

.lang-switcher button:hover {
  opacity: 1;
  filter: grayscale(0%);
  transform: translateY(-1px);
  box-shadow:
    0 0 3px rgba(255, 157, 28, 0.9),
    0 0 7px rgba(255, 140, 0, 0.65);
}

.lang-switcher button.active {
  opacity: 1;
  filter: grayscale(0%);
  border-color: #ff9d1c;
  box-shadow: 0 0 4px rgba(255, 157, 28, 0.8);
}

/* ---------------------------------------------------------
   BOUTON DISCORD
--------------------------------------------------------- */
.discord-btn {
  position: absolute;
  top: 14px;
  left: calc(50% + 333px);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  background: #5865F2;
  border: 1px solid #7983f5;
  border-radius: 4px;
  color: #ffffff;
  text-decoration: none;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 14px;
  font-weight: bold;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  box-shadow: 0 0 0 rgba(88, 101, 242, 0);
  transition: background 120ms ease-out, box-shadow 120ms ease-out, transform 120ms ease-out;
  animation: discord-glow 2.4s ease-in-out infinite;
}

@keyframes discord-glow {
  0%, 100% {
    box-shadow: 0 0 0 rgba(255, 255, 255, 0);
  }
  50% {
    box-shadow:
      0 0 8px rgba(255, 255, 255, 0.85),
      0 0 20px rgba(210, 215, 255, 0.6);
  }
}

.discord-btn svg {
  width: 18px;
  height: 18px;
  fill: #ffffff;
  flex-shrink: 0;
}

.discord-btn:hover {
  background: #6f78f5;
  transform: translateY(-1px);
  box-shadow:
    0 0 6px rgba(88, 101, 242, 0.9),
    0 0 16px rgba(88, 101, 242, 0.5);
  animation-play-state: paused;
}

.discord-btn:active {
  background: #4752c4;
  transform: translateY(0);
}

/* ---------------------------------------------------------
   CONTENU DE PAGE (basique, a adapter/enrichir plus tard)
--------------------------------------------------------- */
.site-content {
  max-width: 1000px;
  margin: 0 auto;
  padding: 40px 24px;
  font-family: Arial, sans-serif;
  color: #222;
}

.page-end-fade {
  flex: 1 0 1.5cm;
  background: linear-gradient(to bottom, #faf9f6 0%, #faf5ed 40%, #f1ddc6 100%);
}


