body {
    background-color: #0f0f0f;
    color: #ffffff;
}

.card {
    background-color: #1a1a1a;
    border-color: #333;
}

.table {
    background-color: #1a1a1a;
    color: #ffffff;
}

section {
    background-color: #0f0f0f;
}

.mega-menu {
    column-count: 2;
    column-gap: 20px;
}
  
.mega-menu .dropdown-item {
    padding: 10px 20px;
    font-size: 16px;
    border-bottom: 1px solid #f1f1f1;
}
  
.mega-menu .dropdown-item:hover {
    background-color: #f8f9fa;
    color: #000;
}

/* Navbar Brand */
.navbar-brand {
    position: relative;
    padding: 8px 16px;
    border-radius: 8px;
    text-shadow: 0 0 5px rgba(255, 255, 255, 0.2);
    background: linear-gradient(45deg, #1a1a1a, #2c2c2c);
    transition: all 0.5s ease;
    overflow: visible; /* Permite que la animación ::after no se recorte */
}

.navbar-brand:hover {
    transform: scale(1.1) translateY(-2px);
    background: linear-gradient(45deg, #2c2c2c, #1a1a1a);
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.3);
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
    letter-spacing: 1px;
}

.navbar-brand i {
    display: inline-block;
    margin: 0 5px;
    transition: all 0.5s ease;
}

.navbar-brand:hover i:first-child {
    transform: rotate(-360deg) scale(1.2);
    color: #ffd700;
}

.navbar-brand:hover i:last-child {
    transform: rotate(360deg) scale(1.2);
    color: #ffd700;
}

.navbar-brand::after {
    content: '';
    position: absolute;
    top: 0;
    right: -10%;
    width: 120%;
    height: 100%;
    background: linear-gradient(90deg, transparent 0%, rgba(255,215,0,0.25) 50%, transparent 100%);
    z-index: 2;
    pointer-events: none;
    transition: right 0.8s cubic-bezier(0.4,0,0.2,1);
}

.navbar-brand:hover::after {
    right: 0;
    transition: right 0.8s cubic-bezier(0.4,0,0.2,1);
}

/* Theme Toggle */
.theme-toggle .btn-outline-light {
    border-radius: 50px;
    width: 40px;
    height: 40px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.theme-toggle .bi {
    font-size: 1.2rem;
    transition: all 0.5s ease;
}

.theme-toggle .btn-check:checked + .btn-outline-light {
    background-color: #ffd700;
    border-color: #ffd700;
    color: #000;
}

.theme-toggle .btn-check:checked + .btn-outline-light .bi {
    transform: rotate(360deg);
}

.theme-toggle .btn-outline-light:hover {
    transform: scale(1.1);
}

/* Hero Section */
.hero {
    position: relative;
    height: 100vh;
    background-color: #000;
    overflow: visible; /* Permite que los textos animados sobresalgan */
}

.hero-content,
.hero-content .row,
.hero-content .col-lg-8,
.hero-content .container {
    overflow: visible !important;
}

.video-container {
    position: absolute;
    width: 100%;
    height: 100%;
    z-index: 0;
    transition: transform 0.3s ease-out;
}

.hero-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.overlay {
    position: absolute;
top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, rgba(0,0,0,0.85), rgba(0,0,0,0.65));
    z-index: 1;
pointer-events: none; /* Esto evita que el overlay interfiera con eventos del mouse */
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-content .text-white {
    color: #ffffff !important;
}

.hero-content .text-white,
.hero-content .hero-title,
.hero-content .hero-text {
    overflow: visible !important;
    padding-left: 0.5rem; /* Da espacio a la izquierda para la P grande */
    margin-left: 0 !important;
}

.hero-text {
    transition-delay: 0.2s;
}

.hero-buttons {
    transition-delay: 0.4s;
}

/* Animation Classes */
.fade-in-up {
    opacity: 1;
    transform: translateY(0);
}

/* Button Hover Effects */
.hero-btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    z-index: 1;
}

.hero-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.2);
    transition: all 0.5s ease;
    z-index: -1;
}


.hero-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}

/* Testimonial Section */
.testimonial-card {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease;
}

.carousel-item.active .testimonial-card {
    opacity: 1;
    transform: translateY(0);
}

.testimonial-author {
    position: relative;
    padding-top: 20px;
}

.testimonial-author::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 50px;
    height: 2px;
    background-color: #ffd700;
}

/* Footer Links */
.footer a {
    text-decoration: none;
    transition: all 0.3s ease;
}

.footer a:hover {
    color: #ffd700 !important;
    transform: translateY(-3px);
    display: inline-block;
}

.footer .bi {
    transition: all 0.3s ease;
}

.footer a:hover .bi {
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

.social-link {
    font-family: 'Righteous', cursive;
}

/* Footer Styles */
.footer {
    margin-bottom: 0;
    margin-top: auto;
}

/* Class Card */
.class-card {
    background: #212529;  /* Bootstrap's bg-dark color */
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.card-img-wrapper {
    height: 200px;
    position: relative;
    overflow: hidden;
}

.card-img-wrapper::before {
    content: none; /* Removemos el overlay adicional */
}

.card-img-wrapper {
    position: relative;
    overflow: hidden;
}

.class-item:nth-child(3n+1) .card-img-wrapper {
    height: 300px;
}

.class-item:nth-child(3n+2) .card-img-wrapper {
    height: 400px;
}

.class-item:nth-child(3n+3) .card-img-wrapper {
    height: 250px;
}

.card-img-top {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.card-img-overlay {
    background: linear-gradient(to top, rgba(0,0,0,0.7), transparent);
    opacity: 1;
    transform: translateY(0);
    transition: all 0.3s ease;
    color: white;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.class-details {
    font-size: 0.9rem;
    background-color: rgba(0,0,0,0.5);
    padding: 0.5rem;
    border-radius: 8px;
    backdrop-filter: blur(4px);
}

.class-card .card-body {
    background: #212529;  /* Same as card background */
}

.class-card .card-title {
    color: #ffd700;
    font-size: 1.5rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.8);
    margin-bottom: 0.5rem;
}

.class-card .card-text {
    color: white;
    font-weight: 500;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.8);
    margin-bottom: 1rem;
}

/* Counter Section */
.counter-section {
    position: relative;
    background: linear-gradient(rgba(33, 37, 41, 0.95), rgba(33, 37, 41, 0.95));
}

.counter-item {
    padding: 2rem;
    transition: all 0.3s ease;
}

.counter-item:hover {
    transform: translateY(-10px);
}

.counter {
    font-size: 3rem;
    font-weight: 700;
    color: #ffffff;
}

.counter::after {
    content: "+";
    font-size: 2rem;
    position: relative;
    top: -0.5rem;
    margin-left: 0.2rem;
}

/* Card Image Overlay */
.card {
    background: #212529;
    border: none;
    border-radius: 0;
    margin: 0;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Hover Effects */
.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.3);
}

.card:hover .card-img-top {
    transform: scale(1.1);
}

.card-img-wrapper {
    position: relative;
    overflow: hidden;
    height: 350px;
}

.card-img-top {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.3);
}

.card:hover .card-img-top {
    transform: scale(1.1);
}

.card-img-overlay {
    background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    opacity: 0;
    transition: opacity 0.3s ease;
    color: white;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
    padding: 1.5rem;
}

.card:hover .card-img-overlay {
    opacity: 1;
}

.class-details {
    font-size: 0.9rem;
    background-color: rgba(0,0,0,0.5);
    padding: 0.5rem;
    border-radius: 8px;
    backdrop-filter: blur(4px);
}

/* Grid Layout y Cards */
.gallery-container {
    padding: 0;
    margin: 0;
}

.row.gallery {
    margin: 0;
    --bs-gutter-x: 0.5rem;
}

.card {
    margin-bottom: 0.5rem;
    background: #212529;
    border: none;
    border-radius: 0;
}

/* Alturas optimizadas para las cards */
.col-md-8 .card-img-wrapper { height: 400px; }
.col-md-6 .card-img-wrapper { height: 300px; }
.col-md-4 .card-img-wrapper { height: 300px; }

/* Ajustes específicos para crear layout visual balanceado */
.gallery .col-md-8:first-child .card-img-wrapper { height: 450px; }
.gallery .col-md-4:nth-child(2) .card-img-wrapper { height: 400px; }
.gallery .col-md-8:nth-child(3) .card-img-wrapper { height: 350px; }
.gallery .col-md-4:nth-child(4) .card-img-wrapper { height: 390px; }
.gallery .col-md-6:nth-child(5) .card-img-wrapper { height: 300px; }
.gallery .col-md-6:nth-child(6) .card-img-wrapper { height: 380px; }

/* Altura base y overrides específicos */
.card-img-wrapper {
    height: 300px;
}

/* Primera fila */
.gallery .col-md-6:first-child .card-img-wrapper { height: 450px; }
.gallery .col-md-4:nth-child(2) .card-img-wrapper { height: 450px; }
.gallery .col-md-2:nth-child(3) .card-img-wrapper { height: 450px; }

/* Segunda fila */
.gallery .col-md-4:nth-child(4) .card-img-wrapper { height: 350px; }
.gallery .col-md-5:nth-child(5) .card-img-wrapper { height: 350px; }
.gallery .col-md-3:nth-child(6) .card-img-wrapper { height: 350px; }

/* Tercera fila */
.gallery .col-md-4:nth-child(7) .card-img-wrapper { height: 400px; }
.gallery .col-md-8:last-child .card-img-wrapper { height: 400px; }

/* Contenedor principal */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
    /* overflow: hidden; */ /* <-- Eliminar o comentar esta línea */
}

.form-check-label {
    cursor: pointer;
    transition: color 0.3s ease;
}

.form-check-input:checked + .form-check-label {
    color: #ffd700 !important;
    text-shadow: 0 0 5px rgba(255, 215, 0, 0.3);
}

/* Trainer Cards */
.trainers-section {
    background: #212529;
    color: white;
}

.trainer-card {
    perspective: 1000px;
    height: 400px;
    margin-bottom: 30px;
}

.trainer-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.8s;
    transform-style: preserve-3d;
    cursor: pointer;
}

.trainer-card:hover .trainer-card-inner {
    transform: rotateY(180deg);
}

.trainer-card-front, .trainer-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 15px;
    overflow: hidden;
    background: #2c2c2c;
}

.trainer-card-front {
    color: white;
}

.trainer-card-back {
    transform: rotateY(180deg);
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.trainer-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
    padding: 20px;
}

.trainer-icon {
    font-size: 2rem;
    color: #ffd700;
    margin: 10px 0;
}

.trainer-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Skill Bars */
.skill {
    margin-bottom: 15px;
    text-align: left;
}

.skill span {
    display: block;
    margin-bottom: 5px;
}

.progress {
    height: 8px;
    background: #444;
    border-radius: 4px;
    overflow: hidden;
}

.progress-bar {
    width: 0;
    height: 100%;
    background: #ffd700;
    transition: width 1s ease-in-out;
}

/* Rating Stars */
.trainer-rating {
    color: #ffd700;
    font-size: 1.2rem;
    margin-top: 15px;
}
/* Pricing Section Styles */
.pricing-card {
    position: relative;
    padding-top: 1rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
    opacity: 1 !important; /* Forzar visibilidad */
}

.popular-badge {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
}

.popular-badge .badge {
    font-size: 0.9rem;
    padding: 0.5rem 1rem;
    color: black;
}

.pricing-card .card-title,
.pricing-card .card-body,
.pricing-card ul li,
.pricing-amount,
.pricing-amount .currency,
.pricing-amount .amount,
.pricing-amount .period {
    color: #ffffff !important;
}

.pricing-amount .period {
    font-size: 1rem;
    opacity: 0.8;
}

.pricing-amount {
    font-size: 2.5rem;
    font-weight: bold;
}

.pricing-card:hover, .pricing-card.active {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

.pricing-amount .currency {
    font-size: 1.5rem;
    vertical-align: top;
    margin-right: 5px;
}

.form-check-input:checked {
    background-color: #ffd700;
    border-color: #ffd700;
}

.pricing-card i.bi {
    transition: all 0.3s ease-out;
}

.pricing-card:hover i.bi {
    transform: scale(1.2) rotate(15deg);
    color: #ffd700;
    text-shadow: 0 0 15px rgba(255, 215, 0, 0.5);
}

/* Contact Form Styles */
.form-control, .form-select {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    color: #ffffff;
}

.form-control:focus, .form-select:focus {
    background-color: rgba(255, 255, 255, 0.15);
    border-color: #ffd700;
    color: #ffffff;
    box-shadow: 0 0 0 0.25rem rgba(255, 215, 0, 0.25);
}

.form-control::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.form-select {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23ffffff' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
    color: #ffffff;
}

.form-select option {
    background-color: #212529;
    color: #ffffff;
}

.form-label {
    color: #ffffff;
}

.invalid-feedback, 
.valid-feedback {
    color: #ffffff;
    text-shadow: 0 0 2px rgba(0, 0, 0, 0.5);
}

.form-floating > label {
    color: rgba(255, 255, 255, 0.8);
}

.form-floating > .form-control:focus ~ label,
.form-floating > .form-control:not(:placeholder-shown) ~ label {
    color: #ffffff;
}

.modal-body {
    color: #ffffff;
}

/* Make validation states more visible on dark background */
.form-control.is-invalid,
.was-validated .form-control:invalid {
    border-color: #dc3545;
    background-color: rgba(220, 53, 69, 0.15);
}

.form-control.is-valid,
.was-validated .form-control:valid {
    border-color: #198754;
    background-color: rgba(25, 135, 84, 0.15);
}

/* Modal custom styles */
.modal-content {
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Blog Styles */
.blog-header {
    background: linear-gradient(rgba(0,0,0,0.7), rgba(0,0,0,0.7)), url('../img/blog-header-bg.jpg');
    background-size: cover;
    background-position: center;
    padding: 100px 0;
}

/* AOS Override Styles */
[data-aos] {
    opacity: 1 !important;
    transform: none !important;
    visibility: visible !important;
    pointer-events: auto !important;
}

[data-aos^=fade][data-aos^=fade].aos-animate {
    opacity: 1 !important;
    transform: translate3d(0,0,0) !important;
}

/* Blog Layout Fixes */
.blog-grid {
    position: relative;
    padding: 2rem 0;
}

.blog-grid .row {
    display: flex;
    flex-wrap: wrap;
}

.blog-grid .col-12 {
    transition: all 0.3s ease;
}

.blog-grid .col-12:has(.article-card[style*="display: none"]) {
    width: 0;
    margin: 0;
    padding: 0;
}

.blog-grid .row {
    position: relative;
    z-index: 1;
}

.comments-section {
    position: relative;
    z-index: 1;
    margin-top: 3rem !important;
    clear: both;
}

.article-card {
    margin-bottom: 2rem;
    height: 100%;
    position: relative;
    z-index: 1;
}

/* Blog Article Cards */
.article-card {
    visibility: visible !important;
    opacity: 1 !important;
    transform: none !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
max-height: 450px;
    min-height: 350px;
}

.article-card .card-img-top {
    height: 180px;
    object-fit: cover;
}

.article-card .card-body {
    height: calc(100% - 180px);
    overflow: hidden;
}

.article-card .card-text {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.article-card:hover {
    transform: translateY(-10px) !important;
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}

.blog-grid .row > div {
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
}

.article-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.article-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}

.author-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #333;
    position: relative;
}

.author-avatar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background-size: cover;
    background-position: center;
}

.comment {
    padding: 1rem;
    margin-bottom: 1rem;
    border-radius: 8px;
    background-color: rgba(255,255,255,0.1);
}

.comment-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    text-align: center;
    background-color: #333;
    position: relative;
    display: flex;           /* Añadido para centrar */
    align-items: center;     /* Añadido para centrar verticalmente */
    justify-content: center; /* Añadido para centrar horizontalmente */
    color: white;
    font-weight: bold;
    border: 2px solid #dc3545; /* Borde rojo */
    box-shadow: 0 0 0 2px rgba(220, 53, 69, 0.3); /* Efecto de glow */
}

.comment-avatar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background-size: cover;
    background-position: center;
}

/* Comment Date & Actions Styles */
.comment-actions a:hover,
.reply-actions a:hover {
    color: #ffd700 !important;
    opacity: 0.8;
    text-shadow: 0 0 5px rgba(255, 215, 0, 0.3);
}

.comment-actions {
    font-size: 0.9rem;
}

.comment-actions a {
    color: #ffd700;
    text-decoration: none;
    margin-right: 1rem;
    cursor: pointer;
}

.comment-actions a:hover {
    text-decoration: underline;
}
.comment-actions a, 
.reply-actions a,
.comment-date,
.text-muted {
    color: #ffd700 !important;
    opacity: 1;
}
/* Tags Filter Animation */
.btn-outline-light {
    transition: all 0.3s ease;
}

.btn-outline-light.active {
    background-color: #ffd700;
    border-color: #ffd700;
    color: #000;
}
/* Article Author Styles */
.article-author {
    display: flex;
    align-items: center;
    margin-top: auto;
    padding-top: 1rem;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.article-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #2c2c2c;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    font-weight: bold;
    text-transform: uppercase;
    border: 2px solid #ffd700;
    margin-right: 1rem;
}

.article-date {
    color: #ffd700;
    font-size: 0.9rem;
}
/* Comment Date Style */
.comment-date {
    color: #ffffff !important;
    opacity: 0.8;
}