/* ===================================================================
   Total Fitness Gym — Main Stylesheet
   Author: Total Fitness Gym
   Structure:
     01. Design Tokens (colors, fonts, shadows)
     02. Base & Typography
     03. Buttons
     04. Preloader
     05. Navigation
     06. Hero
     07. Sections & Cards
     08. Counters / Stats
     09. Programs & Pricing
     10. Trainers
     11. Testimonials
     12. Gallery & Lightbox
     13. Forms & Contact
     14. FAQ / Accordion
     15. Footer
     16. Floating Buttons, Cookie Banner, Back to Top
     17. Animation Utilities
   =================================================================== */

/* ---------- 01. Design Tokens ---------- */
:root {
  --power-black: #0b0b0b;
  --steel-gray: #242424;
  --steel-gray-2: #1a1a1a;
  --volt: #ffd400;
  --electric-red: #ff3131;
  --white: #ffffff;
  --light-gray: #cfcfcf;
  --border: rgba(255, 255, 255, 0.08);

  --font-head: "Bebas Neue", "Oswald", Impact, sans-serif;
  --font-body: "Poppins", "Inter", Arial, sans-serif;

  --glow: 0 0 24px rgba(255, 212, 0, 0.45);
  --shadow-card: 0 18px 50px rgba(0, 0, 0, 0.55);
  --radius: 14px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------- 02. Base & Typography ---------- */
* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background-color: var(--power-black);
  color: var(--light-gray);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.75;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

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

h1, h2, h3, h4, h5, h6, .display-head {
  font-family: var(--font-head);
  color: var(--white);
  letter-spacing: 1.5px;
  line-height: 1.05;
  text-transform: uppercase;
}

h1 { font-size: clamp(2.8rem, 7vw, 6rem); }
h2 { font-size: clamp(2.1rem, 4.6vw, 3.8rem); }
h3 { font-size: clamp(1.4rem, 2.4vw, 2rem); }

p { margin-bottom: 1rem; }

a { color: var(--volt); text-decoration: none; transition: color .3s var(--ease); }
a:hover { color: var(--white); }

.text-volt { color: var(--volt) !important; }
.text-red { color: var(--electric-red) !important; }
.text-light-gray { color: var(--light-gray) !important; }
.bg-black-power { background-color: var(--power-black) !important; }
.bg-steel { background-color: var(--steel-gray-2) !important; }

.section { padding: 96px 0; position: relative; }
.section-sm { padding: 64px 0; }

.eyebrow {
  display: inline-block;
  font-family: var(--font-body);
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .35em;
  text-transform: uppercase;
  color: var(--volt);
  margin-bottom: .75rem;
}

.section-title { margin-bottom: 1rem; }
.section-title span { color: var(--volt); }

.lead-muted { color: var(--light-gray); max-width: 620px; }

.divider {
  width: 68px; height: 4px; background: var(--volt);
  border-radius: 4px; margin: 18px 0 28px;
}
.text-center .divider, .mx-auto.divider { margin-left: auto; margin-right: auto; }

/* ---------- 03. Buttons ---------- */
.btn {
  font-family: var(--font-body);
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  font-size: .82rem;
  padding: 14px 30px;
  border-radius: 6px;
  border: 2px solid transparent;
  transition: all .35s var(--ease);
}
.btn-volt {
  background: var(--volt);
  color: var(--power-black);
  border-color: var(--volt);
}
.btn-volt:hover {
  background: var(--white);
  border-color: var(--white);
  color: var(--power-black);
  box-shadow: var(--glow);
  transform: translateY(-3px);
}
.btn-outline-light-2 {
  border-color: rgba(255, 255, 255, .55);
  color: var(--white);
  background: transparent;
}
.btn-outline-light-2:hover {
  background: var(--white);
  color: var(--power-black);
  transform: translateY(-3px);
}
.btn-red { background: var(--electric-red); border-color: var(--electric-red); color: var(--white); }
.btn-red:hover { box-shadow: 0 0 24px rgba(255, 49, 49, .5); transform: translateY(-3px); color: var(--white); }

/* ---------- 04. Preloader ---------- */
#preloader {
  position: fixed; inset: 0; z-index: 9999;
  background: var(--power-black);
  display: flex; align-items: center; justify-content: center;
  transition: opacity .6s ease, visibility .6s ease;
}
#preloader.loaded { opacity: 0; visibility: hidden; }
.loader-bar {
  width: 180px; height: 3px; background: var(--steel-gray); overflow: hidden; border-radius: 3px;
}
.loader-bar::after {
  content: ""; display: block; width: 40%; height: 100%;
  background: var(--volt); animation: loaderSlide 1.1s infinite var(--ease);
}
@keyframes loaderSlide { 0% { transform: translateX(-100%); } 100% { transform: translateX(350%); } }

/* ---------- 05. Navigation ---------- */
.navbar-tfg {
  background: transparent;
  padding: 20px 0;
  transition: background .4s var(--ease), padding .4s var(--ease), box-shadow .4s var(--ease);
}
.navbar-tfg.scrolled {
  background: rgba(11, 11, 11, .94);
  backdrop-filter: blur(10px);
  padding: 10px 0;
  box-shadow: 0 8px 30px rgba(0, 0, 0, .6);
}
.navbar-tfg .navbar-brand { display: flex; align-items: center; gap: 10px; }
.navbar-tfg .navbar-brand img { height: 42px; width: auto; }
.brand-text {
  font-family: var(--font-head); color: var(--white);
  font-size: 1.5rem; letter-spacing: 2px; line-height: 1;
}
.brand-text small { display: block; font-family: var(--font-body); font-size: .55rem; letter-spacing: .3em; color: var(--volt); }
.navbar-tfg .nav-link {
  color: var(--light-gray);
  font-weight: 500; font-size: .82rem; text-transform: uppercase; letter-spacing: .12em;
  margin: 0 .55rem; position: relative; padding: .5rem 0;
}
.navbar-tfg .nav-link::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 2px; width: 0;
  background: var(--volt); transition: width .35s var(--ease);
}
.navbar-tfg .nav-link:hover, .navbar-tfg .nav-link.active { color: var(--white); }
.navbar-tfg .nav-link:hover::after, .navbar-tfg .nav-link.active::after { width: 100%; }
.navbar-toggler { border-color: var(--border); }
.navbar-toggler:focus { box-shadow: none; }

/* Breadcrumbs */
.page-banner {
  padding: 190px 0 90px;
  background: linear-gradient(rgba(11,11,11,.82), rgba(11,11,11,.95)), url("../images/about-facility.jpg") center/cover no-repeat fixed;
  text-align: center;
}
.breadcrumb { justify-content: center; --bs-breadcrumb-divider-color: var(--light-gray); margin: 0; }
.breadcrumb-item + .breadcrumb-item::before { color: var(--volt); }
.breadcrumb-item a { color: var(--light-gray); font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; }
.breadcrumb-item.active { color: var(--volt); font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; }

/* ---------- 06. Hero ---------- */
.hero {
  position: relative; min-height: 100vh;
  display: flex; align-items: center;
  overflow: hidden;
}
.hero-media { position: absolute; inset: 0; z-index: 0; }
.hero-media video, .hero-media img {
  width: 100%; height: 100%; object-fit: cover;
}
.hero-overlay {
  position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(90deg, rgba(11,11,11,.95) 0%, rgba(11,11,11,.75) 45%, rgba(11,11,11,.4) 100%);
}
.hero-content { position: relative; z-index: 2; padding-top: 90px; }
.hero h1 span { color: var(--volt); display: block; }
.hero .hero-sub { font-size: 1.05rem; max-width: 560px; color: var(--light-gray); }
.hero-scroll {
  position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%);
  z-index: 3; color: var(--light-gray); font-size: .7rem; letter-spacing: .3em; text-transform: uppercase;
}
.hero-scroll i { display: block; margin-top: 8px; color: var(--volt); animation: floaty 2s infinite ease-in-out; }
@keyframes floaty { 0%,100% { transform: translateY(0); } 50% { transform: translateY(8px); } }

/* ---------- 07. Sections & Cards ---------- */
.card-tfg {
  background: var(--steel-gray-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 34px 28px;
  height: 100%;
  transition: transform .4s var(--ease), border-color .4s var(--ease), box-shadow .4s var(--ease);
}
.card-tfg:hover {
  transform: translateY(-10px);
  border-color: var(--volt);
  box-shadow: var(--shadow-card);
}
.card-icon {
  width: 58px; height: 58px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255, 212, 0, .12); color: var(--volt);
  font-size: 1.4rem; margin-bottom: 18px;
}
.card-tfg h3 { font-size: 1.35rem; margin-bottom: .5rem; }

.img-zoom { overflow: hidden; border-radius: var(--radius); }
.img-zoom img { transition: transform .8s var(--ease); width: 100%; display: block; }
.img-zoom:hover img { transform: scale(1.08); }

/* ---------- 08. Counters / Stats ---------- */
.stats-strip {
  background: var(--steel-gray-2);
  border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
}
.stat-item { text-align: center; padding: 34px 10px; }
.stat-number {
  font-family: var(--font-head); font-size: clamp(2.4rem, 5vw, 3.6rem);
  color: var(--volt); line-height: 1;
}
.stat-label {
  font-size: .74rem; letter-spacing: .22em; text-transform: uppercase; color: var(--light-gray);
  margin-top: 8px;
}

/* ---------- 09. Programs & Pricing ---------- */
.program-card {
  position: relative; border-radius: var(--radius); overflow: hidden;
  min-height: 340px; display: flex; align-items: flex-end;
  border: 1px solid var(--border);
}
.program-card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.program-card::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(11,11,11,.15) 20%, rgba(11,11,11,.93) 90%);
}
.program-card:hover img { transform: scale(1.09); }
.program-card .program-body { position: relative; z-index: 2; padding: 26px; }
.program-card h3 { margin-bottom: .25rem; }
.program-card p { font-size: .9rem; margin: 0; }

.price-card {
  background: var(--steel-gray-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 38px 30px; height: 100%;
  transition: transform .4s var(--ease), border-color .4s var(--ease), box-shadow .4s var(--ease);
  position: relative;
}
.price-card:hover { transform: translateY(-10px); border-color: var(--volt); box-shadow: var(--shadow-card); }
.price-card.featured { border-color: var(--volt); background: linear-gradient(180deg, #1f1c0d 0%, var(--steel-gray-2) 60%); }
.price-badge {
  position: absolute; top: 16px; right: 16px;
  background: var(--volt); color: var(--power-black);
  font-size: .65rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase;
  padding: 5px 12px; border-radius: 40px;
}
.price-amount { font-family: var(--font-head); font-size: 3rem; color: var(--white); line-height: 1; }
.price-amount small { font-family: var(--font-body); font-size: .8rem; color: var(--light-gray); letter-spacing: .06em; }
.price-list { list-style: none; padding: 0; margin: 24px 0; }
.price-list li { padding: 8px 0; border-bottom: 1px dashed rgba(255,255,255,.07); font-size: .9rem; }
.price-list li i { color: var(--volt); margin-right: 10px; }

/* ---------- 10. Trainers ---------- */
.trainer-card { position: relative; border-radius: var(--radius); overflow: hidden; }
.trainer-card img { width: 100%; height: 420px; object-fit: cover; transition: transform .8s var(--ease); }
.trainer-card:hover img { transform: scale(1.07); }
.trainer-info {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 24px 22px;
  background: linear-gradient(180deg, transparent, rgba(11,11,11,.95));
}
.trainer-info h3 { font-size: 1.4rem; margin-bottom: 2px; }
.trainer-info span { font-size: .74rem; letter-spacing: .2em; text-transform: uppercase; color: var(--volt); }
.trainer-social { margin-top: 12px; display: flex; gap: 10px; }
.trainer-social a {
  width: 34px; height: 34px; border-radius: 50%;
  border: 1px solid rgba(255,255,255,.25);
  display: flex; align-items: center; justify-content: center; font-size: .8rem; color: var(--white);
  transition: all .3s var(--ease);
}
.trainer-social a:hover { background: var(--volt); border-color: var(--volt); color: var(--power-black); }

/* ---------- 11. Testimonials ---------- */
.testimonial-card {
  background: var(--steel-gray-2); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 34px 30px; height: 100%;
}
.testimonial-card .stars { color: var(--volt); font-size: .85rem; margin-bottom: 14px; }
.testimonial-card p { font-style: italic; color: var(--light-gray); }
.testimonial-meta { display: flex; align-items: center; gap: 12px; margin-top: 18px; }
.avatar-circle {
  width: 46px; height: 46px; border-radius: 50%;
  background: var(--volt); color: var(--power-black);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-head); font-size: 1.2rem;
}
.carousel-indicators [data-bs-target] { background-color: var(--volt); }
.carousel-control-prev-icon, .carousel-control-next-icon { filter: invert(1) grayscale(1); }

/* ---------- 12. Gallery & Lightbox ---------- */
.gallery-filter { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-bottom: 38px; }
.filter-btn {
  background: transparent; border: 1px solid var(--border); color: var(--light-gray);
  padding: 9px 20px; border-radius: 40px;
  font-size: .74rem; letter-spacing: .14em; text-transform: uppercase; font-weight: 600;
  transition: all .3s var(--ease); cursor: pointer;
}
.filter-btn:hover, .filter-btn.active { background: var(--volt); border-color: var(--volt); color: var(--power-black); }

.masonry { column-count: 3; column-gap: 18px; }
.masonry-item { break-inside: avoid; margin-bottom: 18px; position: relative; border-radius: var(--radius); overflow: hidden; cursor: pointer; }
.masonry-item img { width: 100%; display: block; transition: transform .8s var(--ease); }
.masonry-item:hover img { transform: scale(1.08); }
.masonry-caption {
  position: absolute; inset: 0; background: rgba(11,11,11,.72);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  opacity: 0; transition: opacity .4s var(--ease); text-align: center; padding: 20px;
}
.masonry-item:hover .masonry-caption { opacity: 1; }
.masonry-caption h3 { font-size: 1.25rem; margin-bottom: 4px; }
.masonry-caption span { color: var(--volt); font-size: .7rem; letter-spacing: .2em; text-transform: uppercase; }

#lightbox {
  position: fixed; inset: 0; z-index: 9998; background: rgba(5,5,5,.95);
  display: none; align-items: center; justify-content: center; padding: 30px;
}
#lightbox.open { display: flex; }
#lightbox img { max-width: 92vw; max-height: 82vh; border-radius: 10px; }
#lightbox .lb-close, #lightbox .lb-prev, #lightbox .lb-next {
  position: absolute; background: transparent; border: 0; color: var(--white); font-size: 2rem; cursor: pointer;
}
#lightbox .lb-close { top: 20px; right: 28px; }
#lightbox .lb-prev { left: 24px; }
#lightbox .lb-next { right: 24px; }
#lightbox .lb-caption { position: absolute; bottom: 26px; left: 0; right: 0; text-align: center; color: var(--light-gray); font-size: .85rem; }

/* ---------- 13. Forms & Contact ---------- */
.form-control, .form-select {
  background: var(--steel-gray-2);
  border: 1px solid var(--border);
  color: var(--white);
  border-radius: 8px;
  padding: 13px 16px;
  font-size: .92rem;
}
.form-control::placeholder { color: #7b7b7b; }
.form-control:focus, .form-select:focus {
  background: var(--steel-gray-2); color: var(--white);
  border-color: var(--volt); box-shadow: 0 0 0 .18rem rgba(255,212,0,.16);
}
.form-label { color: var(--light-gray); font-size: .76rem; letter-spacing: .14em; text-transform: uppercase; font-weight: 600; }
.form-note { font-size: .78rem; color: #8a8a8a; }
.form-success {
  display: none; background: rgba(255,212,0,.1); border: 1px solid var(--volt);
  color: var(--volt); padding: 12px 16px; border-radius: 8px; font-size: .88rem; margin-top: 14px;
}
.contact-tile {
  background: var(--steel-gray-2); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 26px; height: 100%;
  transition: border-color .35s var(--ease), transform .35s var(--ease);
}
.contact-tile:hover { border-color: var(--volt); transform: translateY(-6px); }
.contact-tile i { color: var(--volt); font-size: 1.3rem; margin-bottom: 12px; display: block; }
.map-frame { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border); line-height: 0; }
.map-frame iframe { width: 100%; height: 420px; border: 0; filter: grayscale(1) invert(.9) contrast(.85); }

/* ---------- 14. FAQ / Accordion ---------- */
.accordion-tfg .accordion-item { background: var(--steel-gray-2); border: 1px solid var(--border); margin-bottom: 12px; border-radius: 10px; overflow: hidden; }
.accordion-tfg .accordion-button {
  background: var(--steel-gray-2); color: var(--white);
  font-weight: 600; font-size: .98rem; box-shadow: none;
}
.accordion-tfg .accordion-button:not(.collapsed) { color: var(--volt); background: #191919; }
.accordion-tfg .accordion-button::after { filter: invert(1); }
.accordion-tfg .accordion-body { color: var(--light-gray); font-size: .92rem; }

/* ---------- CTA Banner ---------- */
.cta-banner {
  background: linear-gradient(rgba(11,11,11,.86), rgba(11,11,11,.9)), url("../images/gallery/strength.jpg") center/cover no-repeat;
  padding: 96px 0; text-align: center;
}

/* ---------- Instagram Feed ---------- */
.ig-tile { position: relative; overflow: hidden; border-radius: 10px; display: block; }
.ig-tile img { width: 100%; height: 190px; object-fit: cover; transition: transform .7s var(--ease); }
.ig-tile:hover img { transform: scale(1.12); }
.ig-tile::after {
  content: "\f16d"; font-family: "Font Awesome 6 Brands";
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  background: rgba(255,212,0,.85); color: var(--power-black); font-size: 1.5rem;
  opacity: 0; transition: opacity .35s var(--ease);
}
.ig-tile:hover::after { opacity: 1; }

/* ---------- Timeline ---------- */
.timeline { position: relative; padding-left: 30px; }
.timeline::before { content: ""; position: absolute; left: 8px; top: 6px; bottom: 6px; width: 2px; background: var(--border); }
.timeline-item { position: relative; padding-bottom: 34px; }
.timeline-item::before {
  content: ""; position: absolute; left: -29px; top: 6px; width: 14px; height: 14px;
  border-radius: 50%; background: var(--volt); box-shadow: 0 0 0 4px rgba(255,212,0,.16);
}
.timeline-year { font-family: var(--font-head); color: var(--volt); font-size: 1.4rem; letter-spacing: 2px; }

/* ---------- 15. Footer ---------- */
.footer { background: var(--steel-gray-2); padding: 76px 0 0; border-top: 1px solid var(--border); }
.footer h4 { font-size: 1.15rem; margin-bottom: 18px; }
.footer ul { list-style: none; padding: 0; }
.footer ul li { margin-bottom: 9px; }
.footer ul li a { color: var(--light-gray); font-size: .9rem; }
.footer ul li a:hover { color: var(--volt); padding-left: 5px; }
.footer-bottom {
  border-top: 1px solid var(--border); margin-top: 54px; padding: 22px 0;
  font-size: .82rem; color: #8a8a8a;
}
.social-row { display: flex; gap: 10px; margin-top: 16px; }
.social-row a {
  width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center; color: var(--light-gray);
  transition: all .3s var(--ease);
}
.social-row a:hover { background: var(--volt); border-color: var(--volt); color: var(--power-black); transform: translateY(-4px); }

/* ---------- 16. Floating buttons / cookie / back to top ---------- */
.float-stack { position: fixed; right: 18px; bottom: 20px; z-index: 900; display: flex; flex-direction: column; gap: 12px; }
.float-btn {
  width: 52px; height: 52px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--white); font-size: 1.25rem; box-shadow: 0 10px 26px rgba(0,0,0,.5);
  transition: transform .3s var(--ease);
}
.float-btn:hover { transform: scale(1.1); color: var(--white); }
.float-wa { background: #25d366; }
.float-call { background: var(--electric-red); }
.float-top { background: var(--volt); color: var(--power-black); border: 0; opacity: 0; pointer-events: none; }
.float-top.show { opacity: 1; pointer-events: auto; }
.float-top:hover { color: var(--power-black); }

#cookieBanner {
  position: fixed; left: 18px; right: 18px; bottom: 18px; z-index: 950;
  background: var(--steel-gray-2); border: 1px solid var(--border); border-radius: 12px;
  padding: 16px 20px; display: none; align-items: center; gap: 16px; flex-wrap: wrap;
  box-shadow: var(--shadow-card);
}
#cookieBanner.show { display: flex; }
#cookieBanner p { margin: 0; font-size: .85rem; flex: 1 1 320px; }

/* ---------- 17. Animation Utilities ---------- */
.reveal { opacity: 0; transform: translateY(34px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.reveal.in-view { opacity: 1; transform: none; }
.reveal-left { opacity: 0; transform: translateX(-40px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.reveal-left.in-view { opacity: 1; transform: none; }
.reveal-right { opacity: 0; transform: translateX(40px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.reveal-right.in-view { opacity: 1; transform: none; }
.delay-1 { transition-delay: .12s; }
.delay-2 { transition-delay: .24s; }
.delay-3 { transition-delay: .36s; }
.delay-4 { transition-delay: .48s; }

.hero-reveal { opacity: 0; transform: translateY(28px); animation: heroUp .9s var(--ease) forwards; }
.hero-reveal.d1 { animation-delay: .15s; }
.hero-reveal.d2 { animation-delay: .35s; }
.hero-reveal.d3 { animation-delay: .55s; }
@keyframes heroUp { to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  .reveal, .reveal-left, .reveal-right, .hero-reveal { opacity: 1; transform: none; }
}
