@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,  wght@0,  400;0,  600;0,  700;1,  400;1,  600&family=Poppins:wght@300;400;500;600;700&display=swap');

/* ══════════════════════════════════════════════
   WORLD TRAINER FORUM — DESIGN SYSTEM v3.0
   Light Ivory Theme · Premium · Professional
══════════════════════════════════════════════ */

:root {
  /* ── Brand Colors ── */
  --navy: #0B1B32;
  --navy-2: #122644;
  --royal: #2455C9;
  --royal-2: #3A6BE0;
  --gold: #C9A24B;
  --gold-light: #E7C878;
  --ivory: #FAF6EC;
  --ivory-dim: #F0EADA;
  --ink: #101826;

  --line: rgba(255, 255, 255, 0.10);
  --line-dark: rgba(11, 27, 50, 0.10);

  --support: var(--ivory-dim);

  /* ── Backgrounds ── */
  --bg-main: var(--ivory);
  --bg-card: #FFFFFF;
  --bg-card-h: #F9F9F9;
  --bg-glass: rgba(255, 255, 255, 0.6);
  --bg-glass-h: rgba(255, 255, 255, 0.9);

  /* ── Text ── */
  --tp: var(--ink);
  --ts: rgba(16, 24, 38, 0.75);
  --tm: rgba(16, 24, 38, 0.5);
  --bd: var(--line-dark);
  --bd2: rgba(11, 27, 50, 0.05);

  /* ── Status ── */
  --ok: #4ADE80;
  --err: #FC8181;
  --warn: #F6AD55;
  --info: #63B3ED;

  /* ── Utilities ── */
  --r: 10px;
  --rl: 18px;
  --rxl: 24px;
  --sh: 0 4px 20px rgba(0, 0, 0, 0.08);
  --shm: 0 8px 40px rgba(0, 0, 0, 0.12);
  --shl: 0 20px 80px rgba(0, 0, 0, 0.16);
  --glow-gold: 0 0 30px rgba(201, 162, 75, 0.25);
  --glow-royal: 0 0 30px rgba(36, 85, 201, 0.3);
  --nav: 70px;
}

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

html {
  font-size: 17px;
  scroll-behavior: smooth;
  overflow-x: hidden
}

body {
  font-family: 'Poppins', sans-serif;
  background: var(--ivory);
  background-attachment: fixed;
  color: var(--tp);
  line-height: 1.6;
  
  min-height: 100vh;
}

a {
  text-decoration: none;
  color: inherit
}

button {
  cursor: pointer;
  font-family: 'Poppins', sans-serif
}

ul {
  list-style: none
}

::-webkit-scrollbar {
  width: 5px
}

::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.05)
}

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

/* ══ PAGE SYSTEM ══ */
.page {
  display: none;
  min-height: 100vh
}

.page.active {
  display: block
}

.fade-in {
  animation: fadeUp .45s ease both
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(16px)
  }

  to {
    opacity: 1;
    transform: translateY(0)
  }
}

/* ══ NAVBAR ══ */
/* Dark context overrides for hero/nav/header sections */
.hero,  
.page-hero,  
.prof-header,  
.dark-context,  
#nav {
  --tp: var(--ivory);
  --ts: rgba(250, 246, 236, 0.75);
  --tm: rgba(250, 246, 236, 0.5);
  --bg-glass: rgba(255, 255, 255, 0.08);
  --bg-glass-h: rgba(255, 255, 255, 0.14);
  --bd: var(--line);
  --bd2: rgba(255, 255, 255, 0.06);
  color: var(--tp);
}

#nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 900;
  height: var(--nav);
  background: rgba(11, 27, 50, 0.92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0  16px;
  transition: all .3s;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.55rem;
  font-weight: 700;
  color: var(--ivory);
  letter-spacing: -.01em;
  white-space: nowrap;
  flex-shrink: 0;
}

.logo .g {
  color: var(--gold)
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-links li {
  display: flex;
  height: 100%;
}

.nav-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 38px;
  padding: 0 8px;
  font-size: .85rem;
  font-weight: 500;
  color: rgba(250, 246, 236, 0.72);
  transition: color .2s, background .2s;
  position: relative;
  border-radius: var(--r);
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gold-light);
  transition: width .25s;
}

.nav-links a:hover {
  color: var(--ivory);
}

.nav-links a:hover::after,  
.nav-links a.active::after {
  width: 100%;
}

.nav-links a.active {
  color: var(--gold-light);
}

.nav-r {
  display: flex;
  align-items: center;
  gap: 10px;
  position: relative;
 flex-shrink: 0;}

/* Hamburger */
.ham-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  cursor: pointer;
  padding: 8px;
  color: var(--ivory);
  transition: all .25s ease;
}

.ham-btn:hover {
  background: rgba(255, 255, 255, 0.1);
}

.ham-btn svg {
  width: 24px;
  height: 24px;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

/* Strict Desktop Hiding */
@media (min-width: 769px) {
  .ham-btn {
    display: none !important;
  }
}

/* Mobile nav drawer — visibility controlled by transform,   NOT display */
.mobile-nav {
  display: flex;
  position: fixed;
  top: var(--nav);
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(11, 27, 50, 0.97);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  z-index: 899;
  flex-direction: column;
  padding: 32px 5%;
  transform: translateX(-100%);
  transition: transform .35s cubic-bezier(.4,0,.2,1);
  overflow-y: auto;
}

.mobile-nav.open {
  transform: translateX(0);
}

/* Backdrop overlay */
.nav-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 898;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  transition: opacity .3s;
}

.nav-overlay.open {
  display: block;
}

/* Hamburger → X animation */
.ham-btn.open {
  background: rgba(255, 255, 255, 0.15);
}

/* ── Notification Bell & Panel ── */
.notif-wrap {
  position: relative;
}

.notif-btn {
  background: none;
  border: 1px solid rgba(250, 246, 236, 0.18);
  border-radius: 8px;
  color: var(--ivory);
  font-size: 1.05rem;
  padding: 6px 10px;
  cursor: pointer;
  position: relative;
  display: inline-flex;
  align-items: center;
  transition: background .2s, border-color .2s;
  line-height: 1;
}

.notif-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(250, 246, 236, 0.35);
}

.notif-dot {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 7px;
  height: 7px;
  background: var(--gold);
  border-radius: 50%;
  border: 1.5px solid rgba(11, 27, 50, 0.92);
  display: none;
}

.notif-panel {
  display: none;
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 300px;
  background: #0D1B3E;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.45);
  z-index: 1100;
  overflow: hidden;
  animation: notifFadeIn .2s ease;
}

.notif-panel.open {
  display: block;
}

@keyframes notifFadeIn {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}

.notif-panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  color: var(--ivory);
  font-weight: 600;
  font-size: 0.88rem;
  letter-spacing: .01em;
}

.notif-panel-header button {
  background: none;
  border: none;
  color: rgba(250, 246, 236, 0.45);
  cursor: pointer;
  font-size: 0.95rem;
  padding: 3px 7px;
  border-radius: 5px;
  transition: color .2s, background .2s;
  font-family: inherit;
}

.notif-panel-header button:hover {
  color: var(--ivory);
  background: rgba(255, 255, 255, 0.08);
}

.notif-panel-body {
  padding: 6px 0;
  max-height: 300px;
  overflow-y: auto;
}

.notif-item {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 11px 18px;
  cursor: pointer;
  transition: background .2s;
}

.notif-item:hover {
  background: rgba(255, 255, 255, 0.05);
}

.notif-icon {
  font-size: 1.15rem;
  flex-shrink: 0;
  margin-top: 1px;
}

.notif-item-text p {
  color: rgba(250, 246, 236, 0.85);
  font-size: 0.83rem;
  line-height: 1.45;
  margin: 0 0 3px;
}

.notif-item-text span {
  color: rgba(250, 246, 236, 0.38);
  font-size: 0.74rem;
}

.mobile-nav a,  
.mobile-nav button.mn-link {
  font-size: 1.2rem;
  font-weight: 500;
  color: rgba(250, 246, 236, 0.75);
  padding: 16px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  display: block;
  background: none;
  border-left: none;
  border-right: none;
  border-top: none;
  text-align: left;
  cursor: pointer;
  transition: color .2s;
}

.mobile-nav a:hover,  
.mobile-nav button.mn-link:hover {
  color: var(--gold)
}

/* ══ BUTTONS ══ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 10px 22px;
  border-radius: var(--r);
  font-size: .875rem;
  font-weight: 600;
  border: none;
  transition: all .22s;
  letter-spacing: .01em;
  white-space: nowrap;
  cursor: pointer;
  font-family: 'Poppins', sans-serif;
  position: relative;
  overflow: hidden;
}

.ripple {
  position: absolute;
  border-radius: 50%;
  transform: scale(0);
  animation: ripple-anim 0.6s linear;
  background-color: rgba(255, 255, 255, 0.4);
  pointer-events: none;
}

@keyframes ripple-anim {
  to {
    transform: scale(4);
    opacity: 0;
  }
}

.btn-gold {
  background: var(--gold);
  color: var(--ink);
}

.btn-gold:hover {
  background: var(--gold-light);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(197, 160, 89, 0.5);
}

.btn-outline {
  background: transparent;
  border: 1.5px solid rgba(197, 160, 89, 0.6);
  color: var(--gold);
}

.btn-outline:hover {
  border-color: var(--gold);
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  border: 1px solid var(--bd);
  color: var(--tp);
}

.btn-ghost:hover {
  background: rgba(16, 24, 38, 0.05);
  border-color: rgba(197, 160, 89, 0.4)
}

/* Inside dark navbar,   ghost & dark buttons render as ivory */
#nav .btn-ghost {
  border-color: rgba(250, 246, 236, 0.3);
  color: rgba(250, 246, 236, 0.8);
}

#nav .btn-ghost:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--gold-light);
  color: var(--ivory);
}

.btn-dark {
  background: rgba(255, 255, 255, 0.08);
  color: rgba(250, 246, 236, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.btn-dark:hover {
  background: rgba(255, 255, 255, 0.14);
  color: var(--ivory)
}

.btn-ok {
  background: rgba(74, 222, 128, 0.15);
  color: var(--ok);
  border: 1px solid rgba(74, 222, 128, 0.3)
}

.btn-ok:hover {
  background: rgba(74, 222, 128, 0.25)
}

.btn-err {
  background: rgba(252, 129, 129, 0.15);
  color: var(--err);
  border: 1px solid rgba(252, 129, 129, 0.3)
}

.btn-err:hover {
  background: rgba(252, 129, 129, 0.25)
}

.btn-sm {
  padding: 7px 16px;
  font-size: .8rem;
  border-radius: 8px
}

.btn-lg {
  padding: 14px 32px;
  font-size: 1rem;
  border-radius: 12px
}

.btn-xl {
  padding: 17px 38px;
  font-size: 1.05rem;
  border-radius: 14px
}

.btn-full {
  width: 100%
}

/* ══ TYPOGRAPHY ══ */
.section-label {
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 10px;
  display: block;
}

.section-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(1.9rem, 3.5vw, 2.9rem);
  font-weight: 700;
  color: var(--tp);
  margin-bottom: 10px;
  line-height: 1.15;
  letter-spacing: -.02em;
}

.section-title .a {
  color: var(--gold)
}

.section-sub {
  color: var(--ts);
  font-size: .95rem;
  font-weight: 300;
  line-height: 1.85;
  max-width: 520px;
}

.section-hdr {
  text-align: center
}

.section-hdr .section-sub {
  margin: 0 auto 52px
}

/* ══ HERO ══ */
.hero {
  min-height: calc(100vh - var(--nav));
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 80px 5% 60px;
  position: relative;
  overflow: hidden;
  background: #0B1B32;
}

.hero-bg-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  opacity: 0.4;
  pointer-events: none;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 25% 20%, rgba(58, 107, 224, 0.35) 0%, transparent 55%),
    radial-gradient(ellipse at 80% 80%, rgba(201, 162, 75, 0.12) 0%, transparent 50%);
  pointer-events: none;
}

.hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
}

.h-orb1 {
  width: 500px;
  height: 500px;
  background: rgba(36, 85, 201, 0.25);
  top: -100px;
  right: -80px;
  animation: orbFloat 8s ease-in-out infinite
}

.h-orb2 {
  width: 400px;
  height: 400px;
  background: rgba(197, 160, 89, 0.12);
  bottom: -80px;
  left: -80px;
  animation: orbFloat 10s ease-in-out infinite reverse
}

@keyframes orbFloat {

  0%,  
  100% {
    transform: translateY(0) scale(1)
  }

  50% {
    transform: translateY(-30px) scale(1.05)
  }
}

.hero-grid {
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(201, 162, 75, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(201, 162, 75, 0.06) 1px, transparent 1px);
  background-size: 54px 54px;
}

.hero-inner {
  position: relative;
  z-index: 1;
  max-width: 820px;
  margin: 0 auto
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(197, 160, 89, 0.12);
  border: 1px solid rgba(197, 160, 89, 0.3);
  border-radius: 999px;
  padding: 7px 18px;
  color: var(--gold);
  font-size: .8rem;
  font-weight: 500;
  margin-bottom: 28px;
  backdrop-filter: blur(10px);
}

.live-dot {
  width: 7px;
  height: 7px;
  background: #4ADE80;
  border-radius: 50%;
  animation: blink 1.8s infinite;
  box-shadow: 0 0 8px #4ADE80;
}

@keyframes blink {

  0%,  
  100% {
    opacity: 1
  }

  50% {
    opacity: .25
  }
}

.hero h1 , 

.hero h1 {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(3rem, 6.5vw, 5.4rem);
  font-weight: 700;
  color: var(--ivory);
  line-height: 1.08;
  margin-bottom: 20px;
  letter-spacing: -.025em;
}

.hero h1 .gld {
  color: var(--gold-light)
}

.hero-sub {
  font-size: clamp(.95rem, 1.4vw, 1.1rem);
  color: rgba(250, 246, 236, 0.75);
  max-width: 560px;
  margin: 0 auto 44px;
  font-weight: 300;
  line-height: 1.85;
}

.hero-search {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(197, 160, 89, 0.25);
  border-radius: var(--rl);
  padding: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  backdrop-filter: blur(16px);
  max-width: 760px;
  margin: 0 auto;
  box-shadow: var(--sh);
}

.hero-search input,  
.hero-search select {
  background: transparent;
  border: none;
  outline: none;
  font-size: .9rem;
  color: var(--ivory);
  font-family: 'Poppins', sans-serif;
  padding: 8px 10px;
  flex: 1;
  min-width: 110px;
}

.hero-search input::placeholder {
  color: rgba(250, 246, 236, 0.5)
}

.hero-search select option {
  background: #0B1B32;
  color: var(--ivory)
}

.h-sep {
  width: 1px;
  height: 26px;
  background: rgba(255, 255, 255, 0.15);
  flex-shrink: 0
}

.hero-nums {
  display: flex;
  justify-content: center;
  gap: 48px;
  margin-top: 60px;
  flex-wrap: wrap;
}

.hnum {
  display: flex;
  align-items: center;
  gap: 12px;
  text-align: left
}

.hnum .n {
  font-family: 'Cormorant Garamond', serif;
  font-size: 2.1rem;
  font-weight: 700;
  color: var(--gold-light);
  display: block;
  line-height: 1;
}

.hnum .l {
  font-size: .76rem;
  color: rgba(250, 246, 236, 0.75);
  margin-top: 5px;
  font-weight: 500
}

.h-ico {
  width: 38px;
  height: 38px;
  color: var(--gold);
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 8px;
}

.h-ico svg {
  width: 100%;
  height: 100%
}

/* ══ HERO SPLIT LAYOUT ══ */
.hero-split {
  flex-direction: column;
  justify-content: flex-end;
  align-items: stretch;
  text-align: center;
  padding: calc(var(--nav) + 28px) 5% 48px;
  gap: 0;
}

.hero-split .hero-inner {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.hero-media-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  flex: 1;
}

.hero-media-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: transparent;
  border: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  overflow: hidden;
  transition: border-color .3s;
  backdrop-filter: blur(8px);
}

.hero-media-frame:hover {
  border-color: rgba(197, 160, 89, 0.75);
  border-style: solid;
}

.hero-media-frame::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 40%, rgba(36, 85, 201, 0.25) 0%, transparent 70%);
  pointer-events: none;
}

.hero-media-icon {
  font-size: 3.2rem;
  color: rgba(197, 160, 89, 0.65);
  line-height: 1;
  filter: drop-shadow(0 0 18px rgba(197, 160, 89, 0.35));
  transition: transform .3s, color .3s;
}

.hero-media-frame:hover .hero-media-icon {
  transform: scale(1.12);
  color: var(--gold);
}

.hero-media-label {
  font-size: .88rem;
  color: rgba(250, 246, 236, 0.75);
  font-weight: 500;
  letter-spacing: .01em;
  position: relative;
}

.hero-media-hint {
  font-size: .7rem;
  color: rgba(250, 246, 236, 0.5);
  letter-spacing: .06em;
  text-transform: uppercase;
  position: relative;
}

.hero-lower {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 22px;
}

.hero-lower h1 , 

.hero-lower h1 {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2.6rem, 5.5vw, 4.8rem);
  font-weight: 700;
  color: var(--ivory);
  line-height: 1.08;
  letter-spacing: -.025em;
  margin: 0;
}

.hero-lower h1 .gld {
  color: var(--gold-light)
}

.hero-lower .hero-search {
  margin: 0;
  max-width: 860px
}

/* ══ SECTIONS ══ */
section {
  padding: 80px 5%
}

.bg-fog {
  background: var(--ivory);
}

.bg-cream {
  background: var(--ivory-dim);
}

/* Category section label/title overrides for light bg */
.bg-fog .section-label {
  color: var(--royal);
}

.bg-fog .section-title {
  color: var(--navy);
}

.bg-fog .section-sub {
  color: var(--ink);
  opacity: 0.7;
}

.bg-dark {
  background: var(--navy-2);
}

.bg-ink {
  background: var(--navy);
}

/* ══ GLASS CARDS ══ */
.card {
  background: var(--bg-card);
  border: 1px solid var(--bd);
  border-radius: var(--rl);
  padding: 26px;
  box-shadow: var(--sh);
}

.card h3 ,  

.card h3 {
  font-size: .95rem;
  font-weight: 700;
  color: var(--tp);
  margin-bottom: 16px;
}

/* ══ TRAINER CARD ══ */
.tc {
  background: var(--bg-card);
  border: 1px solid var(--bd);
  border-radius: var(--rl);
  overflow: visible;
  transition: all .35s ease;
  cursor: pointer;
  box-shadow: var(--sh);
  position: relative;
  display: flex;
  flex-direction: column;
}

.tc:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 60px rgba(11, 27, 50, 0.15), var(--glow-gold);
  border-color: rgba(197, 160, 89, 0.5);
  background: var(--bg-card-h);
}

.tc-banner {
  height: 112px;
  position: relative;
  overflow: visible;
  transition: all .3s ease;
  flex-shrink: 0;
  border-radius: var(--rl) var(--rl) 0 0;
}

.tc:hover .tc-banner {
  filter: brightness(1.1)
}

.tc-fav {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(11, 27, 50, 0.7);
  backdrop-filter: blur(8px);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .9rem;
  transition: all .25s;
  cursor: pointer;
  z-index: 2;
  box-shadow: var(--sh);
}

.tc-fav:hover {
  transform: scale(1.2);
  background: rgba(11, 27, 50, 0.9)
}

.tc-fav.on {
  color: #FC8181
}

.tc-feat {
  position: absolute;
  top: 10px;
  left: 10px;
  background: var(--gold);
  color: var(--ink);
  font-size: .68rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: .06em;
  z-index: 2;
  box-shadow: 0 2px 8px rgba(197, 160, 89, 0.4);
}

.tc-avatar {
  position: absolute;
  top: -32px;
  left: 50%;
  transform: translateX(-50%);
  width: 70px;
  height: 70px;
  border-radius: 50%;
  border: 4px solid #fff;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  font-weight: 700;
  color: #fff;
  z-index: 8;
  transition: all .3s ease;
  overflow: hidden;
}

.tc:hover .tc-avatar {
  transform: translateX(-50%) scale(1.1);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2)
}

.tc-body {
  padding: 52px 18px 22px;
  text-align: center;
  flex: 1;
  display: flex;
  flex-direction: column;
  transition: all .3s ease;
}

.tc-head {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-bottom: 4px;
  flex-wrap: wrap
}

.tc-name {
  font-size: .97rem;
  font-weight: 700;
  color: var(--tp)
}

.tc-role {
  font-size: .78rem;
  color: var(--ts);
  margin-bottom: 10px;
  min-height: 36px;
  line-height: 1.5
}

.tc-tags {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 5px;
  margin-bottom: 12px
}

.tag {
  font-size: .7rem;
  font-weight: 500;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(197, 160, 89, 0.1);
  color: var(--gold);
  border: 1px solid rgba(197, 160, 89, 0.2);
  transition: all .25s ease;
}

.tag:hover {
  background: rgba(197, 160, 89, 0.2);
  transform: translateY(-1px)
}

.tc-footer {
  display: flex;
  align-items: center;
  gap: 14px;
  border-top: 1px solid var(--bd);
  padding-top: 12px;
  margin-top: auto;
}

.tc-stat {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: .78rem;
  color: var(--ts)
}

.tc-stat b {
  color: var(--tp);
  font-weight: 700
}

.stars {
  color: var(--gold);
  font-size: .74rem
}

.tc:hover .stars {
  filter: brightness(1.1)
}

.tc-price {
  margin-left: auto;
  font-size: .95rem;
  font-weight: 700;
  color: var(--gold)
}

.tc-price small {
  font-size: .72rem;
  color: var(--tm);
  font-weight: 500
}

/* ══ CHIPS & PILLS ══ */
.chip {
  display: inline-block;
  background: rgba(197, 160, 89, 0.1);
  color: var(--gold);
  border: 1px solid rgba(197, 160, 89, 0.2);
  padding: 4px 12px;
  border-radius: 999px;
  font-size: .76rem;
  font-weight: 500;
  margin: 2px;
}

.verified {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(74, 222, 128, 0.1);
  color: var(--ok);
  font-size: .7rem;
  font-weight: 600;
  padding: 2px 9px;
  border-radius: 999px;
  border: 1px solid rgba(74, 222, 128, 0.2);
}

.pill {
  display: inline-block;
  font-size: .72rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 999px
}

.p-ok {
  background: rgba(74, 222, 128, 0.12);
  color: var(--ok)
}

.p-warn {
  background: rgba(246, 173, 85, 0.12);
  color: var(--warn)
}

.p-err {
  background: rgba(252, 129, 129, 0.12);
  color: var(--err)
}

.p-info {
  background: rgba(99, 179, 237, 0.12);
  color: var(--info)
}

/* ══ GRADIENT BANNERS ══ */
.gb-blue {
  background: linear-gradient(135deg, #0D3A6B, #1A5FA8)
}

.gb-green {
  background: linear-gradient(135deg, #0D3D28, #1A6B44)
}

.gb-purple {
  background: linear-gradient(135deg, #2D1260, #6B3AA0)
}

.gb-red {
  background: linear-gradient(135deg, #5C1818, #A02020)
}

.gb-teal {
  background: linear-gradient(135deg, #073B3B, #0A6B6B)
}

.gb-orange {
  background: linear-gradient(135deg, #5C3010, #A05820)
}

.gb-navy {
  background: linear-gradient(135deg, #081838, #0D3060)
}

.gb-rose {
  background: linear-gradient(135deg, #5C1038, #A02060)
}

.gb-indigo {
  background: linear-gradient(135deg, #200860, #4010A0)
}

.gb-olive {
  background: linear-gradient(135deg, #2A3010, #4A5820)
}

.gb-maroon {
  background: linear-gradient(135deg, #4A0808, #7A1010)
}

.gb-steel {
  background: linear-gradient(135deg, #0D2038, #1A3060)
}

/* ══ CATEGORY CARD ══ */
.cat-card {
  background: #FFFFFF;
  border: 1px solid var(--line-dark);
  border-radius: var(--rl);
  padding: 22px 16px;
  text-align: center;
  cursor: pointer;
  box-shadow: 0 2px 12px rgba(11, 27, 50, 0.06);
  transition: all .26s;
}

.cat-card:hover {
  border-color: var(--gold);
  transform: translateY(-6px);
  box-shadow: 0 16px 40px rgba(11, 27, 50, 0.12);
  background: #FDFAF2;
}

.cat-icon {
  width: 52px;
  height: 52px;
  background: rgba(197, 160, 89, 0.1);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin: 0 auto 12px;
  transition: transform .25s;
}

.cat-card:hover .cat-icon {
  transform: scale(1.15)
}

.cat-card h3 ,  

.cat-card h3 {
  font-size: .84rem;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 4px
}

.cat-card p {
  font-size: .74rem;
  color: var(--ts)
}

/* ══ GRIDS ══ */
.trainers-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr) !important;
  gap: 22px;
}
@media (max-width: 1024px) {
  .trainers-grid { grid-template-columns: repeat(4, 1fr) !important; }
}
@media (max-width: 768px) {
  .trainers-grid { grid-template-columns: repeat(3, 1fr) !important; }
}
@media (max-width: 480px) {
  .trainers-grid { grid-template-columns: repeat(2, 1fr) !important; gap: 12px; }
}

.cats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 14px;
  margin-top: 48px
}

.testi-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px
}

.how-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px
}

.kpi-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 24px
}

.grid2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px
}

.grid3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px
}

/* ══ HOW IT WORKS ══ */
.how-step {
  text-align: center;
  padding: 32px;
  background: var(--bg-card);
  border: 1px solid var(--bd);
  border-radius: var(--rl);
  transition: all .3s
}

.how-step:hover {
  transform: translateY(-8px);
  border-color: rgba(197, 160, 89, 0.4);
  box-shadow: var(--shm)
}

.how-num {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: rgba(197, 160, 89, 0.1);
  border: 1.5px solid rgba(197, 160, 89, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--gold);
  margin: 0 auto 20px;
}

.how-step h3 ,  

.how-step h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--tp);
  margin-bottom: 8px
}

.how-step p {
  font-size: .84rem;
  color: var(--ts);
  line-height: 1.8
}

/* ══ TESTIMONIALS ══ */
.testi-card {
  background: var(--bg-card);
  border: 1px solid var(--bd);
  border-radius: var(--rl);
  padding: 28px;
  box-shadow: var(--sh);
  transition: all .3s;
}

.testi-card:hover {
  border-color: rgba(197, 160, 89, 0.35);
  transform: translateY(-4px)
}

.testi-stars {
  color: var(--gold);
  font-size: .95rem;
  margin-bottom: 14px
}

.testi-quote {
  font-size: .9rem;
  line-height: 1.85;
  color: var(--ts);
  margin-bottom: 20px;
  font-style: italic;
  position: relative;
}

.testi-quote::before {
  content: '\201C';
  font-family: 'Cormorant Garamond', serif;
  font-size: 3rem;
  color: rgba(197, 160, 89, 0.3);
  position: absolute;
  top: -12px;
  left: -8px;
  line-height: 1;
}

.testi-author {
  display: flex;
  align-items: center;
  gap: 12px
}

.t-av {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .82rem;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.t-name {
  font-weight: 600;
  font-size: .85rem;
  color: var(--tp)
}

.t-role {
  font-size: .74rem;
  color: var(--tm)
}

/* ══ AI MATCHING SECTION ══ */
.ai-section {
  padding: 80px 5%;
  background: var(--navy);
  position: relative;
  overflow: hidden;
}

.ai-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 50%, rgba(197, 160, 89, 0.08) 0%, transparent 70%);
}

.ai-box {
  max-width: 780px;
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(197, 160, 89, 0.3);
  border-radius: var(--rxl);
  padding: 48px;
  backdrop-filter: blur(16px);
  box-shadow: var(--glow-gold), var(--shm);
  position: relative;
}

.ai-input-wrap {
  display: flex;
  gap: 12px;
  margin: 28px 0;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--line);
  border-radius: var(--rl);
  padding: 8px 8px 8px 20px;
  align-items: center;
}

#ai-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  font-size: 1rem;
  color: var(--ivory);
  font-family: 'Poppins', sans-serif;
}

#ai-input::placeholder {
  color: rgba(250, 246, 236, 0.4)
}

.ai-suggestions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px
}

.ai-pill {
  padding: 7px 16px;
  border-radius: 999px;
  font-size: .8rem;
  font-weight: 500;
  background: rgba(197, 160, 89, 0.1);
  border: 1px solid rgba(197, 160, 89, 0.25);
  color: var(--gold);
  cursor: pointer;
  transition: all .2s;
}

.ai-pill:hover {
  background: rgba(197, 160, 89, 0.2);
  transform: translateY(-2px)
}

.ai-result {
  background: rgba(11, 27, 50, 0.6);
  border: 1px solid var(--line);
  border-radius: var(--rl);
  padding: 24px;
  margin-top: 24px;
  display: none;
  animation: fadeUp .4s ease;
}

.ai-result.show {
  display: block
}

.ai-typing {
  display: flex;
  gap: 5px;
  align-items: center;
  color: rgba(250, 246, 236, 0.5);
  font-size: .85rem
}

.ai-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gold);
  animation: dotBounce .8s infinite
}

.ai-dot:nth-child(2) {
  animation-delay: .15s
}

.ai-dot:nth-child(3) {
  animation-delay: .3s
}

@keyframes dotBounce {

  0%,  
  100% {
    transform: translateY(0)
  }

  50% {
    transform: translateY(-6px)
  }
}

/* ══ SUCCESS STORIES ══ */
.story-card {
  background: var(--bg-card);
  border: 1px solid var(--bd);
  border-radius: var(--rxl);
  padding: 32px;
  transition: all .3s;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.story-card:hover {
  transform: translateY(-6px);
  border-color: rgba(197, 160, 89, 0.35)
}

.story-metric {
  font-family: 'Cormorant Garamond', serif;
  font-size: 2.8rem;
  font-weight: 700;
  color: var(--gold);
  line-height: 1;
}

.story-label {
  font-size: .8rem;
  color: var(--tm);
  margin-top: 4px
}

/* ══ CTA BAND ══ */
.cta-band {
  background: var(--navy);
  text-align: center;
  padding: 90px 5%;
  position: relative;
  overflow: hidden;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.cta-band::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, rgba(197, 160, 89, 0.1) 0%, transparent 65%);
}

.cta-band h2 {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2rem, 4vw, 3.2rem);
  color: var(--ivory);
  margin-bottom: 14px;
  position: relative;
}

.cta-band p {
  color: rgba(250, 246, 236, 0.75);
  margin-bottom: 32px;
  position: relative;
  font-weight: 300
}

.cta-btns {
  display: flex;
  gap: 14px;
  justify-content: center;
  position: relative;
  flex-wrap: wrap
}

/* ══ NOTIFICATIONS ══ */
.notif-btn {
  position: relative;
  background: none;
  border: none;
  font-size: 1.2rem;
  color: var(--ivory);
  cursor: pointer;
  padding: 4px;
}

.notif-dot {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 8px;
  height: 8px;
  background: var(--err);
  border-radius: 50%;
  border: 2px solid rgba(11, 27, 50, 0.92);
}

.notif-panel {
  position: fixed;
  top: var(--nav);
  right: 20px;
  width: 340px;
  background: var(--navy-2);
  border: 1px solid var(--line);
  border-radius: var(--rl);
  box-shadow: var(--shm);
  z-index: 999;
  display: none;
  overflow: hidden;
}

.notif-panel.open {
  display: block
}

.notif-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  color: var(--ivory);
}

.notif-item {
  display: flex;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  transition: background .2s;
  cursor: pointer;
}

.notif-item:hover {
  background: rgba(255, 255, 255, 0.04)
}

.notif-item.unread {
  background: rgba(36, 85, 201, 0.08)
}

.notif-ico {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: .9rem;
}

.notif-txt {
  font-size: .8rem;
  color: rgba(250, 246, 236, 0.75);
  line-height: 1.5;
}

.notif-txt b {
  color: var(--ivory);
}

.notif-time {
  font-size: .72rem;
  color: rgba(250, 246, 236, 0.4);
  margin-top: 3px;
}

/* ══ PROFILE WIDGET ══ */
.profile-widget {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  padding: 4px 10px 4px 4px;
  border-radius: 999px;
  border: 1px solid var(--line);
  transition: background .2s;
}

.profile-widget:hover {
  background: rgba(255, 255, 255, 0.08)
}

.prof-av {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .82rem;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.prof-name {
  font-size: .8rem;
  font-weight: 600;
  color: var(--ivory);
}

.prof-sub {
  font-size: .7rem;
  color: rgba(250, 246, 236, 0.5);
}

/* ══ TRAINER PROFILE ══ */
.prof-header {
  background: var(--navy);
  padding: 90px 5% 40px;
  border-bottom: 1px solid var(--line);
}

/* ══ GLOBAL MODAL OVERLAY & CLOSE BUTTON ══ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(11, 27, 50, 0.85);
  backdrop-filter: blur(8px);
  z-index: 9999;
  display: none;
  align-items: flex-start;
  justify-content: center;
  padding: 20px;
  box-sizing: border-box;
  overflow-y: auto;
}

.modal-overlay.open,
.modal-overlay.active {
  display: flex !important;
}

#post-detail-modal .modal-close,
.modal-overlay .modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 10000;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #f1f5f9;
  color: #0f172a;
  border: 1px solid #cbd5e1;
  font-size: 1.4rem;
  font-weight: bold;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

#post-detail-modal .modal-close:hover,
.modal-overlay .modal-close:hover {
  background: #e2e8f0;
  transform: scale(1.08);
}

@media (min-width: 1024px) {
  #post-detail-modal .modal-content-box,
  .modal-overlay > div {
    margin-top: 80px !important;
  }
}

/* ══ BOOKING MODAL ══ */
.bmodal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(6px);
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
}

.bmodal-overlay.open {
  display: flex
}

.bmodal-box {
  background: var(--bg-card);
  border: 1px solid var(--bd);
  border-radius: var(--rxl);
  max-width: 540px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shl);
}

.bmodal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--bd);
}

.bmodal-body {
  padding: 24px
}

/* ══ CALENDAR PICKER ══ */
.cal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  color: var(--tp);
}

.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.cal-day {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .78rem;
  font-weight: 500;
  border-radius: 8px;
  cursor: pointer;
  transition: all .2s;
  color: var(--tp);
}

.cal-day:hover:not(.cal-day-head):not(.cal-empty) {
  background: rgba(197, 160, 89, 0.15);
  color: var(--gold)
}

.cal-day.selected {
  background: var(--gold);
  color: var(--ink);
  font-weight: 700
}

.cal-day.today {
  border: 1.5px solid var(--royal)
}

.cal-day.unavail {
  opacity: .3;
  cursor: not-allowed
}

.cal-day-head {
  font-size: .7rem;
  font-weight: 700;
  color: var(--tm);
  cursor: default
}

.cal-empty {
  cursor: default
}

/* ══ TIME SLOTS ══ */
.slot-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-top: 12px
}

.slot {
  padding: 8px;
  border-radius: 8px;
  border: 1px solid var(--bd);
  text-align: center;
  font-size: .78rem;
  cursor: pointer;
  transition: all .2s;
  color: var(--tp);
  background: var(--bg-card);
}

.slot:hover:not(.slot-taken) {
  border-color: var(--gold);
  color: var(--gold)
}

.slot.slot-taken {
  opacity: .35;
  cursor: not-allowed
}

.slot.slot-sel {
  background: var(--gold);
  color: var(--ink);
  border-color: var(--gold);
  font-weight: 700
}

/* ══ TRAINER MODAL ══ */
/* ── 1. MODAL OVERLAY BACKDROP ── */
#booking-modal,
#book-session-modal,
.booking-modal-overlay,
.modal-overlay,
.tmodal-overlay,
.modal-bg,
.modal,
#trainer-modal,
#auth-modal {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  z-index: 999999 !important;
  background: rgba(0, 0, 0, 0.8) !important;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  display: none;
  justify-content: center !important;
  align-items: flex-start !important; /* Starts content at the top so it scrolls downwards */
  padding: 40px 16px !important;
  overflow-y: auto !important; /* Enables vertical scrolling when content exceeds viewport */
  -webkit-overflow-scrolling: touch !important; /* Smooth scroll on mobile safari */
  box-sizing: border-box !important;
}

#booking-modal.open,
#book-session-modal.open,
.booking-modal-overlay.open,
.modal-overlay.open,
.tmodal-overlay.open,
.modal-bg.open,
.modal.open,
#trainer-modal.open,
#auth-modal.open {
  display: flex !important;
}

/* ── 2. INNER MODAL CARD CONTAINER ── */
.modal-content,
.modal-card,
.trainer-profile-modal,
.booking-modal,
.bpm-box,
.tmodal-box,
.modal-box,
.tpm-box {
  position: relative !important;
  width: 100% !important;
  max-width: 900px !important;
  max-height: none !important; /* Remove fixed height restrictions */
  overflow: visible !important;
  margin: auto !important;
  box-sizing: border-box !important;
}

.tmodal-banner {
  height: 200px;
  position: relative;
  flex-shrink: 0;
  border-radius: var(--rxl) var(--rxl) 0 0;
  overflow: hidden;
}

/* ── 3. CLOSE / CROSS BUTTON POSITIONING ── */
.modal-close,
.close-btn,
.popup-close-button,
.tpm-close,
.tmodal-close {
  position: absolute !important;
  top: 16px !important;
  right: 16px !important;
  z-index: 1000000 !important;
  width: 36px !important;
  height: 36px !important;
  background: #1E293B !important; /* Dark slate background for visibility */
  color: #FFFFFF !important;
  border: 1px solid #475569 !important;
  border-radius: 50% !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 22px !important;
  line-height: 1 !important;
  cursor: pointer !important;
  transition: all 0.2s ease;
}
.modal-close:hover,
.close-btn:hover,
.popup-close-button:hover,
.tpm-close:hover,
.tmodal-close:hover {
  background: rgba(239, 68, 68, 0.85) !important;
  border-color: rgba(239, 68, 68, 0.9) !important;
  color: #FFFFFF !important;
  transform: rotate(90deg) scale(1.08);
}

.tmodal-avatar {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  border: 4px solid #fff;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  font-weight: 700;
  color: #fff;
  overflow: hidden;
}

.tmodal-header {
  padding: 0 32px 24px;
  margin-top: -50px;
  display: flex;
  align-items: flex-end;
  gap: 16px;
}

/* ── TAB NAVIGATION (IN-FLOW & RELATIVE POSITIONING) ── */
.modal-tabs,
.profile-nav-tabs,
.tab-header,
.tmodal-tabs {
  position: relative !important; /* Change from fixed/sticky to relative */
  width: 100% !important;
  background: #0B132B !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
  margin-bottom: 24px !important; /* Space out tabs from cards below */
  z-index: 10 !important;
  box-sizing: border-box !important;
  display: flex;
  gap: 4px;
  padding: 0 32px;
}

.tmodal-tab {
  padding: 12px 18px;
  font-size: .84rem;
  font-weight: 600;
  color: var(--ts);
  border: none;
  background: none;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: all .2s;
  margin-bottom: -1px;
}

.tmodal-tab.active {
  color: var(--royal);
  border-bottom-color: var(--royal);
}

/* ── BODY LAYOUT & PREVENT OVERLAPPING CARDS ── */
.modal-tab-content,
.profile-body,
.tab-pane,
.tmodal-main,
.tmodal-pane {
  padding-top: 16px !important;
  display: block !important;
  clear: both !important;
  box-sizing: border-box !important;
}

.tmodal-main {
  padding: 28px 32px;
}

.tmodal-pane {
  display: none
}

.tmodal-pane.active {
  display: block
}

/* ══ FORM ELEMENTS ══ */
.form-group {
  margin-bottom: 18px
}

.form-label {
  display: block;
  font-size: .8rem;
  font-weight: 600;
  color: var(--ts);
  margin-bottom: 6px;
  letter-spacing: .02em;
}

.form-input,  
.form-select,  
.form-textarea {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--bd);
  border-radius: var(--r);
  padding: 10px 14px;
  font-size: .9rem;
  color: var(--tp);
  font-family: 'Poppins', sans-serif;
  outline: none;
  transition: border-color .2s;
}

.form-input:focus,  
.form-select:focus,  
.form-textarea:focus {
  border-color: var(--royal)
}

.form-textarea {
  resize: vertical;
  min-height: 90px
}

/* ══ PAGE HERO (inner pages) ══ */
.page-hero {
  padding: 90px 5% 60px;
  background: var(--navy);
  border-bottom: 1px solid var(--line);
}

.page-hero h1 , 

.page-hero h1 {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2.2rem, 5vw, 4rem);
  font-weight: 700;
  color: var(--ivory);
  margin-bottom: 12px;
}

.page-hero p {
  color: rgba(250, 246, 236, 0.75);
  font-size: .95rem;
  max-width: 520px
}

/* ══ BROWSE / FIND TRAINERS PAGE ══ */
.browse-hero {
  background: var(--navy);
  padding: calc(var(--nav) + 50px) 5% 60px;
  text-align: center;
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  --tp: var(--ivory);
  --ts: rgba(250, 246, 236, 0.75);
}

.browse-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 30% 50%, rgba(58, 107, 224, 0.3) 0%, transparent 60%),
              radial-gradient(ellipse at 80% 20%, rgba(201, 162, 75, 0.12) 0%, transparent 50%);
  pointer-events: none;
}

.browse-hero h1 , 

.browse-hero h1 {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2rem, 5vw, 3.6rem);
  font-weight: 700;
  color: var(--ivory);
  margin-bottom: 10px;
  position: relative;
}

.browse-hero p {
  color: rgba(250, 246, 236, 0.7);
  font-size: .95rem;
  margin-bottom: 32px;
  position: relative;
}

.browse-bar {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(201, 162, 75, 0.25);
  border-radius: var(--rl);
  padding: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  backdrop-filter: blur(16px);
  max-width: 820px;
  margin: 0 auto;
  position: relative;
}

.browse-bar input,  
.browse-bar select {
  background: transparent;
  border: none;
  outline: none;
  font-size: .9rem;
  color: var(--ivory);
  font-family: 'Poppins', sans-serif;
  padding: 8px 10px;
  flex: 1;
  min-width: 110px;
}

.browse-bar input::placeholder {
  color: rgba(250, 246, 236, 0.4)
}

.browse-bar select option {
  background: #0B1B32;
  color: var(--ivory)
}

/* ══ BROWSE LAYOUT ══ */
.browse-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  align-items: start;
  padding: 32px 5%;
  max-width: 1440px;
  margin: 0 auto;
}

.browse-results {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.results-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding: 14px 20px;
  background: #FFFFFF;
  border: 1px solid var(--line-dark);
  border-radius: var(--rl);
  box-shadow: 0 2px 8px rgba(11, 27, 50, 0.05);
}

.results-count {
  font-size: .88rem;
  color: var(--ts);
}

.results-count strong {
  color: var(--navy);
  font-weight: 700;
}

.sort-sel {
  background: var(--ivory-dim);
  border: 1px solid var(--line-dark);
  border-radius: 8px;
  padding: 8px 12px;
  font-size: .84rem;
  color: var(--ink);
  font-family: 'Poppins', sans-serif;
  outline: none;
  cursor: pointer;
  transition: border-color .2s;
}

.sort-sel:focus {
  border-color: var(--gold)
}

.filter-panel {
  background: var(--bg-card);
  border: 1px solid var(--bd);
  border-radius: var(--rl);
  padding: 22px;
  position: sticky;
  top: calc(var(--nav) + 16px);
}

.filter-panel h3 ,  

.filter-panel h3 {
  font-size: .88rem;
  font-weight: 700;
  color: var(--tp);
  margin-bottom: 16px;
}

.filter-group {
  margin-bottom: 18px
}

.filter-group label {
  font-size: .78rem;
  font-weight: 600;
  color: var(--ts);
  display: block;
  margin-bottom: 6px;
}

.filter-group select,  
.filter-group input[type="range"] {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--bd);
  border-radius: 8px;
  padding: 8px 10px;
  font-size: .84rem;
  color: var(--tp);
  font-family: 'Poppins', sans-serif;
  outline: none;
}

/* ══ FOOTER ══ */
#site-footer {
  background: var(--navy-2);
  color: rgba(250, 246, 236, 0.5);
  border-top: 1px solid var(--line);
  position: relative;
  overflow: hidden;
  --tp: var(--ivory);
  --ts: rgba(250, 246, 236, 0.65);
  --tm: rgba(250, 246, 236, 0.4);
  --bd: var(--line);
}

#site-footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(197, 160, 89, 0.5), transparent);
}

.footer-main {
  padding: 72px 5% 0;
}

.footer-top-grid {
  display: grid;
  grid-template-columns: 2.2fr 1fr 1fr 1fr 1.5fr;
  gap: 52px;
  margin-bottom: 56px;
  align-items: start;
}

.footer-brand-col {
  display: flex;
  flex-direction: column;
  gap: 0
}

.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--ivory);
  letter-spacing: -.01em;
  text-decoration: none;
  margin-bottom: 14px;
  transition: opacity .25s;
}

.footer-logo:hover {
  opacity: .85
}

.footer-logo img {
  height: 36px;
  flex-shrink: 0
}

.footer-logo .g {
  color: var(--gold)
}

.footer-tagline {
  font-size: .84rem;
  line-height: 1.82;
  color: rgba(250, 246, 236, 0.65);
  margin-bottom: 20px;
  max-width: 300px;
}

.footer-trust-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 9px;
  margin-bottom: 26px;
}

.footer-trust-list li {
  font-size: .8rem;
  color: rgba(250, 246, 236, 0.65);
  display: flex;
  align-items: center;
  gap: 9px;
}

.footer-trust-list li i {
  color: var(--gold);
  font-size: .78rem;
  flex-shrink: 0;
}

.footer-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 26px;
}

.footer-stat-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 14px 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  text-align: center;
  transition: all .3s ease;
  cursor: default;
}

.footer-stat-card:hover {
  background: rgba(197, 160, 89, 0.06);
  border-color: rgba(197, 160, 89, 0.25);
  transform: translateY(-3px);
}

.footer-stat-card i {
  font-size: .88rem;
  color: var(--gold);
  margin-bottom: 2px;
}

.fsc-num {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--ivory);
  line-height: 1;
}

.fsc-lbl {
  font-size: .68rem;
  color: rgba(250, 246, 236, 0.4);
  letter-spacing: .04em;
  text-transform: uppercase;
  font-weight: 500;
}

.footer-social {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.fsoc-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(250, 246, 236, 0.65);
  font-size: .85rem;
  text-decoration: none;
  transition: all .3s ease;
}

.fsoc-btn:hover {
  background: rgba(197, 160, 89, 0.12);
  border-color: rgba(197, 160, 89, 0.5);
  color: var(--gold);
  transform: scale(1.15) translateY(-2px);
}

.footer-col {
  display: flex;
  flex-direction: column
}

.footer-col-hd {
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ivory);
  margin-bottom: 18px;
  position: relative;
  padding-bottom: 12px;
}

.footer-col-hd::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 28px;
  height: 2px;
  background: linear-gradient(90deg, var(--gold), var(--royal));
  border-radius: 2px;
  transition: width .35s ease;
}

.footer-col:hover .footer-col-hd::after {
  width: 56px
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-links a {
  font-size: .82rem;
  color: rgba(250, 246, 236, 0.55);
  transition: all .2s;
}

.footer-links a:hover {
  color: var(--gold);
  transform: translateX(4px);
}

.footer-newsletter-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-newsletter-form input {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 10px 14px;
  font-size: .84rem;
  color: var(--ivory);
  font-family: 'Poppins', sans-serif;
  outline: none;
  transition: border-color .2s;
}

.footer-newsletter-form input:focus {
  border-color: var(--gold)
}

.footer-newsletter-form input::placeholder {
  color: rgba(250, 246, 236, 0.35)
}

.footer-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, rgba(197, 160, 89, 0.25) 30%, rgba(36, 85, 201, 0.25) 70%, transparent 100%);
  margin: 0;
}

.footer-bottom {
  padding: 24px 5%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-copy {
  font-size: .78rem;
  color: rgba(250, 246, 236, 0.35);
}

.fl-links {
  display: flex;
  gap: 20px;
}

.fl-links a {
  font-size: .78rem;
  color: rgba(250, 246, 236, 0.35);
  transition: color .2s;
}

.fl-links a:hover {
  color: var(--gold)
}

/* ══ TOAST ══ */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.toast {
  background: var(--navy-2);
  border: 1px solid var(--line);
  color: var(--ivory);
  padding: 14px 20px;
  border-radius: var(--rl);
  font-size: .88rem;
  box-shadow: var(--shm);
  animation: fadeUp .3s ease;
  max-width: 320px;
}

/* ══ DASHBOARD EMBEDDED ══ */
.dash-card {
  background: var(--bg-card);
  border: 1px solid var(--bd);
  border-radius: var(--rl);
  padding: 22px;
  margin-bottom: 18px;
  box-shadow: var(--sh);
}

.dash-card h3 ,  

.dash-card h3 {
  font-size: .92rem;
  font-weight: 700;
  color: var(--tp);
  margin-bottom: 14px;
}

.kpi-card {
  background: var(--bg-card);
  border: 1px solid var(--bd);
  border-radius: var(--rl);
  padding: 18px;
  box-shadow: var(--sh);
}

.kpi-card .kpi-ico {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  margin-bottom: 10px;
}

.kpi-card .kpi-val {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--tp);
  line-height: 1;
}

.kpi-card .kpi-label {
  font-size: .75rem;
  color: var(--ts);
  margin-top: 4px;
}

/* ══ QUICK STATS & CHECK ITEMS ══ */
.check-item {
  position: relative;
  padding-left: 28px;
  margin-bottom: 14px;
  color: var(--tp);
  font-size: 1rem;
}

.check-item::before {
  content: '✓';
  position: absolute;
  left: 0;
  top: 0;
  color: var(--gold);
  font-weight: bold;
  font-size: 1.1rem;
}

.quick-stat {
  background: var(--bg-card);
  border: 1px solid var(--bd);
  border-radius: var(--rl);
  padding: 24px;
  text-align: left;
  transition: all .3s;
  box-shadow: 0 4px 12px rgba(0,0,0,0.03);
  display: flex;
  flex-direction: column;
}

.quick-stat:hover {
  transform: translateY(-4px);
  border-color: rgba(197, 160, 89, 0.4);
  box-shadow: var(--shm);
}

.quick-stat .qs-num {
  font-family: 'Cormorant Garamond', serif;
  font-size: 2rem;
  font-weight: 700;
  color: var(--navy);
  margin: 4px 0 8px;
}

.quick-stat .qs-lbl {
  font-size: 0.9rem;
  color: var(--ts);
  line-height: 1.5;
}

/* ══ RESPONSIVE ══ */
@media (max-width: 1024px) {
  .footer-top-grid {
    grid-template-columns: 1fr 1fr;
    gap: 36px
  }

  .how-grid {
    grid-template-columns: 1fr 1fr
  }

  .testi-grid {
    grid-template-columns: 1fr 1fr
  }

  .browse-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  html {
    font-size: 15px
  }

  /* Use #nav specificity to beat any inline-style nav ul { display: flex } */
  #nav .nav-links {
    display: none !important;
  }

  .nav-links {
    display: none;
  }

  .ham-btn {
    display: flex !important;
  }

  /* Hide desktop-only nav links in inline-styled pages */
  nav ul.nav-links {
    display: none;
  }

  /* Mobile Header Refactor */
  .nav-r .btn {
    display: none !important;
  }
  
  /* Make ghost button visible on dark mobile nav */
  .mobile-nav .btn-ghost {
    color: #fff;
    border-color: rgba(255, 255, 255, 0.4);
  }
  
  .logo {
    font-size: 1.15rem;
  }
  
  .logo img {
    height: 32px !important;
  }

  /* 2-Column Responsive Categories Grid */
  .cats-grid,   .cats-full-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 12px;
  }

  .cat-card,   .cat-full-card {
    padding: 12px 8px;
  }

  .cat-icon {
    width: 36px;
    height: 36px;
    font-size: 1.1rem;
    margin-bottom: 8px;
  }
  .cat-full-card .cat-icon {
    width: 40px;
    height: 40px;
    font-size: 1.25rem;
  }

  .cat-card h3,  

  .cat-card .h3-title,   .cat-full-card h3 ,   .cat-full-card h3 {
    font-size: 0.75rem;
  }

  .cat-card p {
    font-size: 0.68rem;
  }

  .hero {
    padding: 60px 5% 40px
  }

  .hero h1 , 

  .hero h1 {
    font-size: 2.6rem
  }

  section {
    padding: 60px 5%
  }

  .testi-grid {
    grid-template-columns: 1fr
  }

  .footer-top-grid {
    grid-template-columns: 1fr;
    gap: 32px
  }

  .hero-split {
    padding: calc(var(--nav) + 16px) 5% 32px;
  }

  .hero-media-frame {
    aspect-ratio: 16 / 9;
  }

  .hero-lower h1 , 

  .hero-lower h1 {
    font-size: clamp(2rem, 7vw, 3rem)
  }

  /* Notif panel: full-width on small screens */
  .notif-panel {
    width: 280px;
    right: -10px;
  }
}

@media (max-width: 480px) {
  html {
    font-size: 14px
  }

  .hero h1 , 

  .hero h1 {
    font-size: 2.1rem
  }

  .hero-nums {
    gap: 24px
  }

  .hnum {
    gap: 8px
  }

  .hnum .n {
    font-size: 1.7rem
  }

  .how-grid {
    grid-template-columns: 1fr
  }

  .testi-grid {
    grid-template-columns: 1fr
  }

  .kpi-row {
    grid-template-columns: 1fr 1fr
  }

  /* Dropdown: prevent right overflow on narrow screens */
  .user-dropdown {
    right: 0;
    min-width: 220px;
  }
}

/* ════════════════════════════════════════
   UNIFIED USER AVATAR & DROPDOWN
   ════════════════════════════════════════ */
.user-avatar-wrap {
  position: relative;
  display: inline-block;
  margin-left: 10px;
 flex-shrink: 0;}

/* Hidden by default — shown when logged in via JS */
.user-avatar-wrap {
  display: none;
 flex-shrink: 0;}

.user-av-btn {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--gold);
  color: #0a1f3c;
  font-weight: 700;
  font-size: 1rem;
  border: 2.5px solid rgba(255,255,255,0.25);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color .2s, transform .2s;
  box-shadow: 0 2px 10px rgba(0,0,0,0.2);
  letter-spacing: .03em;
}

.user-av-btn:hover {
  border-color: rgba(255,255,255,0.8);
  transform: scale(1.07);
}

/* Floating dropdown card */
.user-dropdown {
  position: absolute;
  top: 52px;
  right: 0;
  width: 250px;
  background: #ffffff;
  border-radius: 14px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.18), 0 2px 8px rgba(0,0,0,0.08);
  border: 1px solid rgba(0,0,0,0.07);
  padding: 0;
  z-index: 9999;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px) scale(0.97);
  transform-origin: top right;
  transition: opacity .22s ease, transform .22s ease, visibility .22s ease;
}

.user-dropdown.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

/* Header section: avatar + name/email */
.ud-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 18px 14px;
  background: #f8f7f4;
}

.ud-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--gold);
  color: #0a1f3c;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1rem;
  flex-shrink: 0;
  letter-spacing: .03em;
}

.ud-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.ud-name {
  font-weight: 700;
  font-size: .88rem;
  color: #0a1f3c;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}

.ud-email {
  font-size: .72rem;
  color: #6b7a90;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 2px;
}

.user-dropdown hr {
  border: none;
  border-top: 1px solid rgba(0,0,0,0.07);
  margin: 0;
}

/* Menu links */
.ud-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 18px;
  color: #1e2d45;
  text-decoration: none;
  font-size: .88rem;
  font-weight: 500;
  transition: background .18s;
  border: none;
  background: transparent;
  width: 100%;
  cursor: pointer;
}

.ud-link i {
  font-size: .95rem;
  color: var(--gold);
  width: 18px;
  text-align: center;
  flex-shrink: 0;
}

.ud-link:hover {
  background: rgba(0,0,0,0.04);
  color: var(--gold);
}

.ud-logout {
  color: #c0392b;
}

.ud-logout i {
  color: #c0392b;
}

.ud-logout:hover {
  background: rgba(192,57,43,0.07);
  color: #c0392b;
}
.fw-bold { font-weight: 700; }


/* --- MOBILE LAYOUT & CLIPPING FIXES --- */
@media (max-width: 768px) {
  #nav, .db-topnav { padding-left: 16px !important; padding-right: 16px !important; }
  .nav-r > *, .nav-profile-btn, .notif-btn, .user-avatar-wrap { flex-shrink: 0 !important; }
  .db-section, .db-main { padding-left: 16px !important; padding-right: 16px !important; max-width: 100vw !important; overflow-x: hidden !important; box-sizing: border-box !important; }
  .dash-card, .cat-card, .card, .profile-layout, .db-modal, #services-container, #packages-container, form, input, textarea { max-width: 100% !important; box-sizing: border-box !important; }
  /* Enforce single column for dashboard grids that overflow */
  #services-container, #packages-container { grid-template-columns: 1fr !important; }
}


/* =============================================================
   MOBILE FIX PATCH  Form Sizing, Label Wrapping, Ham-btn
   ============================================================= */

/* 1. Universal Form Fluid Sizing */
.form-group,
.form-control,
.form-row,
input[type="text"],
input[type="email"],
input[type="date"],
input[type="time"],
input[type="number"],
input[type="url"],
input[type="password"],
select,
textarea {
  box-sizing: border-box;
  max-width: 100%;
}

/* 2. Labels & helper text must wrap cleanly */
.form-group label,
.form-label,
.form-hint,
.form-group small,
.form-group p {
  white-space: normal;
  word-break: break-word;
  overflow-wrap: break-word;
  max-width: 100%;
}

/* 3. Input-with-button wrappers flex-wrap */
.input-group,
.input-row,
.fnl-input-wrap,
.search-bar,
.hero-search {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  max-width: 100%;
  box-sizing: border-box;
}

/* 4. Hamburger button  always above everything on mobile */
.ham-btn {
  position: relative;
  z-index: 1001 !important;
  pointer-events: auto !important;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  cursor: pointer;
}

/* 5. Nav must not clip the ham-btn */
#nav {
  overflow: visible !important;
}

/* 6. Ensure nav-r cannot block ham-btn on mobile */
@media (max-width: 768px) {
  #nav {
    padding-left: 16px !important;
    padding-right: 16px !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow: visible !important;
  }

  .nav-r {
    gap: 6px;
    flex-shrink: 0;
  }

  /* Ensure ham-btn is always clickable and visible on mobile */
  .ham-btn {
    display: flex !important;
    z-index: 1001 !important;
    pointer-events: auto !important;
  }

  .hero-search,
  .browse-bar {
    flex-direction: column !important;
    padding: 16px !important;
    gap: 12px !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .hero-search input, .hero-search select, .hero-search button,
  .browse-bar input, .browse-bar select, .browse-bar button {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  .hero-search .h-sep,
  .browse-bar .h-sep {
    display: none !important;
  }

  /* Form fields stack fluidly in narrow containers */
  .form-row {
    display: flex;
    flex-direction: column !important;
    gap: 12px !important;
  }

  .form-group,
  .form-control,
  input, select, textarea {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
  }

  /* Drop-zone helper text wraps */
  .upload-hint,
  .drop-zone p,
  .drop-zone span,
  .photo-fields p,
  .photo-fields small {
    white-space: normal !important;
    word-break: break-word !important;
    font-size: 0.78rem;
    line-height: 1.5;
  }
}

/* ================================================================
   COMPREHENSIVE MOBILE FIX PATCH v2
   1. Form fluidity  2. Ham-btn  3. Avatar dropdown  4. Calendar  5. Cat grid
   ================================================================ */

/* -- 1. FORM: Fluid sizing & label wrapping ---------------------- */
.form-group,
.form-row,
.form-label,
.form-group label {
  white-space: normal;
  word-break: break-word;
  overflow-wrap: break-word;
  max-width: 100%;
  display: block;
  width: 100%;
  box-sizing: border-box;
}

.form-control,
input[type="text"],
input[type="email"],
input[type="date"],
input[type="time"],
input[type="url"],
input[type="number"],
input[type="password"],
select, textarea {
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  box-sizing: border-box !important;
}

.input-group,
.input-with-btn,
.photo-fields,
.fnl-input-wrap,
.hero-search {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  max-width: 100%;
  box-sizing: border-box;
}

/* -- 2. HAM-BTN: z-index & pointer-events guarantee ------------- */
#nav {
  overflow: visible !important;
  z-index: 900;
}

.ham-btn {
  position: relative;
  z-index: 1001 !important;
  pointer-events: auto !important;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  cursor: pointer;
}

.ham-btn span {
  pointer-events: none; /* icon bars don't eat the click � button does */
  display: block;
}

/* -- 3. AVATAR DROPDOWN: Clean layout for all viewports --------- */
.user-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 260px;
  background: #ffffff;
  border-radius: 14px;
  box-shadow: 0 16px 48px rgba(0,0,0,0.18), 0 2px 8px rgba(0,0,0,0.08);
  border: 1px solid rgba(0,0,0,0.07);
  z-index: 9999;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px) scale(0.97);
  transform-origin: top right;
  transition: opacity .18s ease, transform .18s ease, visibility .18s;
}

.user-dropdown.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

.ud-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 18px;
  background: linear-gradient(135deg, #f8f9ff 0%, #fff 100%);
}

.ud-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: linear-gradient(135deg, #0B1B32, #2455C9);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .78rem;
  font-weight: 700;
  flex-shrink: 0;
}

.ud-name {
  display: block;
  font-size: .85rem;
  font-weight: 700;
  color: #0B1B32;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 170px;
}

.ud-email {
  display: block;
  font-size: .72rem;
  color: #64748b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 170px;
}

.user-dropdown hr {
  border: none;
  border-top: 1px solid rgba(0,0,0,0.07);
  margin: 0;
}

.ud-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 18px;
  font-size: .84rem;
  color: #1e293b;
  transition: background .15s;
  cursor: pointer;
  text-decoration: none;
}

.ud-link:hover {
  background: #f8f9ff;
  color: #2455C9;
}

.ud-link i {
  width: 16px;
  text-align: center;
  color: #64748b;
  flex-shrink: 0;
}

.ud-link:hover i {
  color: #2455C9;
}

.ud-logout {
  color: #dc2626 !important;
}

.ud-logout i {
  color: #dc2626 !important;
}

.ud-logout:hover {
  background: rgba(220,38,38,0.06) !important;
}

/* Avatar button */
.user-av-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, #0B1B32, #2455C9);
  color: #fff;
  border: 2px solid rgba(201,168,76,0.4);
  font-size: .72rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color .2s, transform .2s;
  flex-shrink: 0;
}

.user-av-btn:hover {
  border-color: var(--gold, #C9A84C);
  transform: scale(1.05);
}

/* -- 4. CALENDAR: High-contrast date readability ---------------- */
.cal-day-cell {
  color: #1e293b !important;
  font-weight: 600 !important;
}

.cal-day-cell.empty {
  color: transparent !important;
  pointer-events: none;
}

.cal-day-cell.unavailable {
  color: #94a3b8 !important;
  text-decoration: line-through;
  font-weight: 400 !important;
}

.cal-day-cell.available {
  color: #166534 !important;
  font-weight: 700 !important;
}

.cal-day-cell.booked {
  color: #92400e !important;
  font-weight: 700 !important;
}

.cal-day-cell.today {
  color: #92400e !important;
  font-weight: 700 !important;
}

.cal-day-cell.selected {
  color: #0D1117 !important;
  font-weight: 700 !important;
}

/* -- 5. CATEGORIES: 2-column mobile grid ------------------------ */
@media (max-width: 768px) {
  .cats-grid,
  .cats-full-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 10px !important;
  }

  .cat-card {
    padding: 14px 8px !important;
  }

  .cat-icon {
    width: 40px !important;
    height: 40px !important;
    font-size: 1.2rem !important;
    margin-bottom: 8px !important;
  }

  .cat-card .h3-title,
  .cat-card h3 {
    font-size: .76rem !important;
    margin-bottom: 2px !important;
  }

  .cat-card p {
    font-size: .68rem !important;
  }

  /* Form fields stack on mobile */
  .form-row {
    grid-template-columns: 1fr !important;
    gap: 10px !important;
  }

  .form-group,
  .form-control,
  .form-group input,
  .form-group select,
  .form-group textarea {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
  }

  /* Ham btn mobile */
  .ham-btn {
    z-index: 1001 !important;
    pointer-events: auto !important;
  }

  #nav {
    padding-left: 16px !important;
    padding-right: 16px !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow-x: hidden !important;
  }
}
/* ═══════════════════════════════════════════════════════════════
   MOBILE FIX: Footer newsletter form (.fnl-form / .fnl-input-wrap)
   Root cause: .fnl-input-wrap is a flex row that never wraps → input
   and button overflow the screen edge on narrow viewports.
   Fix: stack vertically, full width, symmetric padding.
   Applies to: about.html, certificates.html, any page with footer.
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 600px) {

  /* Footer newsletter card: full width, no side overflow */
  .footer-newsletter-col,
  .footer-newsletter-card {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  /* Stack input + button vertically */
  .fnl-input-wrap {
    flex-direction: column !important;
    gap: 10px !important;
    width: 100% !important;
    max-width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
    box-sizing: border-box !important;
  }

  /* Input fills full width */
  .fnl-input {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
    border-radius: 8px !important;
  }

  /* Button fills full width below input */
  .fnl-btn {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    border-radius: 8px !important;
    text-align: center !important;
  }

  /* Footer main grid: stack all columns */
  .footer-top-grid {
    grid-template-columns: 1fr !important;
    gap: 28px !important;
    padding-left: 16px !important;
    padding-right: 16px !important;
  }

  .footer-main {
    padding-left: 16px !important;
    padding-right: 16px !important;
  }
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE REFACTOR: Viewport Scaling, Card Carousels & Fluid Spacing
   ═══════════════════════════════════════════════════════════════ */

/* 1. Global Viewport & Root Overflow Protection */
html, body {
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden !important;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

*, *::before, *::after {
  box-sizing: border-box;
}

.page,
.sp-page,
#p-home,
#p-browse,
#p-profile,
#p-blog,
#p-categories,
#p-pricing,
main,
section,
.sp-section,
.hero,
.browse-hero,
.page-hero,
.sp-hero,
header,
footer,
nav {
  max-width: 100vw !important;
  box-sizing: border-box !important;
}

/* 2. Responsive Card Grids (Desktop vs Tablet vs Mobile Carousel Slider) */

/* Desktop (>1024px) */
@media (min-width: 1025px) {
  .trainers-grid {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 22px !important;
  }

  .news-grid,
  .blog-grid {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 30px !important;
  }
}

/* Tablet (769px to 1024px) */
@media (min-width: 769px) and (max-width: 1024px) {
  .trainers-grid {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 16px !important;
  }

  .news-grid,
  .blog-grid {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 20px !important;
  }
}

/* Mobile (<768px): Single-Row Horizontal Carousel / Slider for Cards */
@media (max-width: 768px) {
  .trainers-grid,
  .news-grid,
  .blog-grid,
  .testi-grid,
  .events-scroll,
  .how-grid {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    scroll-snap-type: x mandatory !important;
    gap: 16px !important;
    padding-left: 16px !important;
    padding-right: 16px !important;
    padding-bottom: 16px !important;
    padding-top: 8px !important;
    margin-left: -16px !important;
    margin-right: -16px !important;
    width: calc(100% + 32px) !important;
    max-width: calc(100% + 32px) !important;
    box-sizing: border-box !important;
    align-items: stretch !important;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none !important; /* Firefox */
    -ms-overflow-style: none !important; /* IE/Edge */
  }

  .trainers-grid::-webkit-scrollbar,
  .news-grid::-webkit-scrollbar,
  .blog-grid::-webkit-scrollbar,
  .testi-grid::-webkit-scrollbar,
  .events-scroll::-webkit-scrollbar,
  .how-grid::-webkit-scrollbar {
    display: none !important; /* Chrome, Safari, Opera */
  }

  .trainers-grid > *,
  .news-grid > *,
  .blog-grid > *,
  .testi-grid > *,
  .events-scroll > *,
  .how-grid > * {
    flex: 0 0 85vw !important;
    min-width: 270px !important;
    max-width: 320px !important;
    scroll-snap-align: start !important;
    scroll-snap-stop: always !important;
    box-sizing: border-box !important;
    margin: 0 !important;
  }

  /* 3. Fluid Section Padding & Mobile Spacing */
  section,
  .sp-section,
  .bg-fog,
  .bg-cream {
    padding: 36px 16px !important;
    box-sizing: border-box !important;
  }

  .browse-hero,
  .page-hero,
  .sp-hero,
  .hero {
    padding: 50px 16px 36px !important;
    box-sizing: border-box !important;
  }

  .section-hdr,
  .page-hero {
    margin-bottom: 24px !important;
  }

  .section-title,
  .browse-hero h1,
  .page-hero h1,
  .sp-hero h1 {
    font-size: 1.75rem !important;
    line-height: 1.25 !important;
  }

  .section-sub,
  .browse-hero p,
  .page-hero p,
  .sp-hero p {
    font-size: 0.92rem !important;
    line-height: 1.5 !important;
    margin-bottom: 20px !important;
  }

  .browse-layout {
    display: flex !important;
    flex-direction: column !important;
    gap: 20px !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
  }

  .browse-results {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    overflow: visible !important;
  }
}

/* ── Trainer Card Avatar & Image Clipping Fix ── */
.tc {
  overflow: visible !important;
}

.tc-banner {
  border-radius: 16px 16px 0 0;
  overflow: hidden !important;
  position: relative;
}

.tc-body {
  padding-top: 86px !important;
}

.tc-avatar {
  position: absolute !important;
  top: 14px !important;
  left: 50% !important;
  transform: translateX(-50%) !important;
  width: 68px !important;
  height: 68px !important;
  border-radius: 50% !important;
  border: 4px solid #ffffff !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2) !important;
  background: var(--navy, #0B1B32) !important;
  z-index: 10 !important;
  overflow: hidden !important;
}

.tc-avatar img,
.tc-av img,
.prof-av img,
.ud-avatar img,
.user-av-btn img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  object-position: center !important;
  border-radius: 50% !important;
}

/* ── Mobile Nav Drawer & Overlay Perfect Guarantee ── */
.mobile-nav {
  display: flex !important;
  position: fixed !important;
  top: 0 !important;
  right: 0 !important;
  left: auto !important;
  width: 290px !important;
  max-width: 85vw !important;
  height: 100vh !important;
  height: 100dvh !important;
  background: #0B1B32 !important;
  backdrop-filter: blur(20px) !important;
  -webkit-backdrop-filter: blur(20px) !important;
  z-index: 10000 !important;
  flex-direction: column !important;
  padding: 24px 20px !important;
  transform: translateX(100%) !important;
  transition: transform .35s cubic-bezier(.4,0,.2,1) !important;
  box-shadow: -6px 0 25px rgba(0,0,0,0.5) !important;
  overflow-y: auto !important;
}

.mobile-nav.open {
  transform: translateX(0) !important;
}

.nav-overlay {
  display: none;
  position: fixed !important;
  inset: 0 !important;
  z-index: 9999 !important;
  background: rgba(0, 0, 0, 0.65) !important;
  backdrop-filter: blur(3px) !important;
  -webkit-backdrop-filter: blur(3px) !important;
  transition: opacity .3s ease !important;
}

.nav-overlay.open {
  display: block !important;
}

@media (max-width: 768px) {
  #nav {
    padding: 0 10px !important;
    width: 100% !important;
    max-width: 100vw !important;
    box-sizing: border-box !important;
    justify-content: space-between !important;
  }

  #nav .logo {
    font-size: 0.88rem !important;
    gap: 4px !important;
    flex-shrink: 1 !important;
    min-width: 0 !important;
    overflow: hidden !important;
    white-space: nowrap !important;
  }

  #nav .logo img {
    height: 30px !important;
    margin-right: 4px !important;
  }

  .nav-r {
    display: flex !important;
    align-items: center !important;
    gap: 4px !important;
    margin-left: auto !important;
    flex-shrink: 0 !important;
  }

  .notif-btn {
    width: 32px !important;
    height: 32px !important;
    padding: 2px !important;
    flex-shrink: 0 !important;
  }

  .user-avatar-wrap,
  .user-av-btn {
    width: 32px !important;
    height: 32px !important;
    font-size: 0.75rem !important;
    flex-shrink: 0 !important;
  }

  .ham-btn {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    width: 36px !important;
    height: 36px !important;
    padding: 4px !important;
    align-items: center !important;
    justify-content: center !important;
    flex-shrink: 0 !important;
    margin-left: 2px !important;
    z-index: 10001 !important;
    pointer-events: auto !important;
    cursor: pointer !important;
  }

  .ham-btn svg {
    width: 22px !important;
    height: 22px !important;
  }

  /* ── User dropdown: anchor properly to avatar on mobile ── */
  .user-avatar-wrap {
    position: relative !important;
    overflow: visible !important;
  }

  .user-dropdown {
    /* Fixed positioning so it always stays within viewport on mobile */
    position: fixed !important;
    top: calc(var(--nav, 64px) + 8px) !important;       /* just below the nav bar height */
    right: 12px !important;
    left: auto !important;
    width: calc(100vw - 24px) !important;
    max-width: 320px !important;
    border-radius: 16px !important;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3) !important;
    z-index: 99999 !important;
    transform-origin: top right !important;
  }

  .user-dropdown.show {
    transform: translateY(0) scale(1) !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
  }
}

/* ════════════════════════════════════════════════════════════════
   GLOBAL HERO HEADER OVERLAP & PROFILE MENU Z-INDEX OVERRIDES
   ════════════════════════════════════════════════════════════════ */

/* 1. Hero Text Cutoff & Header Overlap Fix */
.hero,
.hero-split,
.page-hero,
.browse-hero,
.sp-hero,
section.hero,
#nav + .hero,
#nav + main .hero {
  padding-top: calc(var(--nav, 70px) + 40px) !important;
  box-sizing: border-box !important;
}

@media (max-width: 768px) {
  .hero,
  .hero-split,
  .page-hero,
  .browse-hero,
  .sp-hero,
  section.hero,
  #nav + .hero,
  #nav + main .hero {
    padding-top: calc(var(--nav, 64px) + 44px) !important;
    box-sizing: border-box !important;
  }
}

/* 2. Container Overflow Fix (ensures dropdown is never clipped by nav bar) */
#nav,
.nav-r,
.user-avatar-wrap {
  overflow: visible !important;
  overflow-x: visible !important;
  overflow-y: visible !important;
  z-index: 10000 !important;
}

/* 3. High Z-Index for Profile Menu Dropdown */
.user-dropdown {
  z-index: 99999 !important;
}

