/* Competitions Hero Section - Premium Dark Theme */
.competitions-hero-section {
    position: relative;
    padding: 220px 0 140px;
    overflow: hidden;
    background: #020811;
    color: white;
}

.competitions-hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(circle at 20% 30%, rgba(31, 143, 255, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(0, 240, 255, 0.1) 0%, transparent 50%),
        linear-gradient(180deg, rgba(2, 8, 17, 0) 0%, #020811 100%);
    z-index: 0;
    pointer-events: none;
}

/* Animated Floating Elements Container */
.competitions-hero-elements {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}

/* Floating Icons */
.comp-float-icon {
    position: absolute;
    color: rgba(255, 255, 255, 0.05);
    z-index: 1;
    animation: compFloat ease-in-out infinite;
}

.comp-float-icon.trophy {
    top: 15%;
    left: 10%;
    font-size: 4rem;
    animation-duration: 8s;
    color: rgba(255, 215, 0, 0.1);
}

.comp-float-icon.code {
    top: 25%;
    right: 15%;
    font-size: 3rem;
    animation-duration: 10s;
    animation-delay: 1s;
    color: rgba(0, 240, 255, 0.1);
}

.comp-float-icon.medal {
    bottom: 20%;
    left: 15%;
    font-size: 2.5rem;
    animation-duration: 9s;
    animation-delay: 2s;
}

.comp-float-icon.target {
    bottom: 30%;
    right: 25%;
    font-size: 3rem;
    animation-duration: 11s;
    animation-delay: 0.5s;
    color: rgba(31, 143, 255, 0.1);
}

/* Text Styles */
.competitions-hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
}

.competitions-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 10px 25px;
    border-radius: 50px;
    color: var(--accent-cyan);
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 2rem;
    backdrop-filter: blur(10px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    animation: compBadgePulse 3s infinite;
}

.competitions-hero-title {
    font-size: 4.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    letter-spacing: -1px;
}

.competitions-hero-title span {
    display: block;
    opacity: 0;
    transform: translateY(30px);
    animation: compTitleLoad 0.8s cubic-bezier(0.215, 0.610, 0.355, 1.000) forwards;
}

.competitions-hero-title span:nth-child(1) {
    animation-delay: 0.2s;
    background: linear-gradient(90deg, #fff, #a5a5a5);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.competitions-hero-title span:nth-child(2) {
    animation-delay: 0.4s;
    background: linear-gradient(90deg, #1F8FFF, #00F0FF);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    text-shadow: 0 0 30px rgba(31, 143, 255, 0.3);
}

.competitions-hero-subtitle {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 3rem;
    line-height: 1.6;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    opacity: 0;
    animation: fadeIn 1s ease forwards 0.8s;
}

/* Call to Action Buttons */
.competitions-cta-group {
    display: flex;
    justify-content: center;
    gap: 20px;
    opacity: 0;
    animation: fadeIn 1s ease forwards 1s;
}

.btn-comp-primary {
    background: var(--primary-blue);
    border: none;
    color: white;
    padding: 15px 40px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    box-shadow: 0 10px 25px rgba(31, 143, 255, 0.3);
}

.btn-comp-primary:hover {
    transform: translateY(-3px);
    background-color: var(--primary-blue-dark);
    box-shadow: 0 15px 35px rgba(31, 143, 255, 0.5);
    color: white;
}

.btn-comp-outline {
    background: transparent;
    border: 2px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 15px 40px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.btn-comp-outline:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: white;
    transform: translateY(-3px);
    color: white;
}

/* Status Tabs - Glassmorphism */
.status-tabs-section {
    margin-top: -60px;
    position: relative;
    z-index: 10;
    padding-bottom: 4rem;
}

.status-tab-btn {
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(0, 0, 0, 0.05);
    color: #555;
    padding: 20px;
    border-radius: 20px;
    width: 100%;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    height: 100%;
}

.status-tab-btn i {
    font-size: 1.2rem;
    color: var(--primary-blue);
    transition: all 0.3s ease;
}

.status-tab-btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(31, 143, 255, 0.15);
}

.status-tab-btn.active {
    background: white;
    border-color: var(--primary-blue);
    color: var(--primary-blue);
    box-shadow: 0 15px 35px rgba(31, 143, 255, 0.2);
    position: relative;
    overflow: hidden;
}

.status-tab-btn.active::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--primary-blue);
}

/* Animations */
@keyframes compFloat {

    0%,
    100% {
        transform: translateY(0px) rotate(0deg);
    }

    50% {
        transform: translateY(-20px) rotate(5deg);
    }
}

@keyframes compBadgePulse {

    0%,
    100% {
        transform: scale(1);
        box-shadow: 0 4px 15px rgba(31, 143, 255, 0.3);
    }

    50% {
        transform: scale(1.05);
        box-shadow: 0 0 25px rgba(31, 143, 255, 0.5);
    }
}

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

@keyframes fadeIn {
    to {
        opacity: 1;
    }
}

/* Responsive Adjustments */
@media (max-width: 992px) {
    .competitions-hero-title {
        font-size: 3.5rem;
    }
}

@media (max-width: 768px) {
    .competitions-hero-section {
        padding-top: 140px;
    }

    .competitions-hero-title {
        font-size: 2.8rem;
    }

    .status-tabs-section {
        margin-top: -30px;
    }

    .competitions-cta-group {
        flex-direction: column;
        align-items: center;
    }

    .btn-comp-primary,
    .btn-comp-outline {
        width: 100%;
        max-width: 300px;
    }
}

/* ============================================
   COMPETITION CARD STYLES (MATCHING COURSE CARDS)
   ============================================ */

.premium-competition-card {
    min-width: 340px;
    max-width: 340px;
    background: #ffffff;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid rgba(0, 0, 0, 0.03);
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    margin: 0 auto;
    /* Center in grid col if needed */
}

.premium-competition-card:hover {
    transform: translateY(-12px) scale(1.02);
    box-shadow: 0 20px 40px rgba(31, 143, 255, 0.15);
    border-color: rgba(31, 143, 255, 0.2);
}

/* Card Header with Image */
.premium-card-header {
    height: 200px;
    position: relative;
    overflow: hidden;
}

.image-container {
    width: 100%;
    height: 100%;
    position: relative;
}

.competition-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s cubic-bezier(0.23, 1, 0.32, 1);
}

.premium-competition-card:hover .competition-image {
    transform: scale(1.1);
}

.image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, transparent 50%, rgba(0, 0, 0, 0.4));
    z-index: 1;
}

/* Badges */
.category-tag {
    position: absolute;
    top: 16px;
    left: 16px;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--primary-blue);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 6px;
}

.status-badge-container {
    position: absolute;
    top: 15px;
    right: 15px;
    z-index: 10;
}

.status-badge {
    padding: 5px 12px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9rem;
    color: #333;
    background: var(--accent-cyan);
    /* Using a bright color for visibility like course price/rating */
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.status-badge.active {
    background: #e6fcf5;
    color: #0ca678;
    border: 1px solid #c3fae8;
}

.status-badge.upcoming {
    background: #e7f5ff;
    color: #1c7ed6;
    border: 1px solid #d0ebff;
}

.status-badge.completed {
    background: #f8f9fa;
    color: #868e96;
    border: 1px solid #e9ecef;
}

/* Card Body */
.premium-card-body {
    padding: 24px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.premium-title {
    font-size: 1.25rem;
    font-weight: 800;
    margin-bottom: 12px;
    color: #0D0D0D;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.premium-description {
    font-size: 0.95rem;
    color: #666;
    margin-bottom: 20px;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex-grow: 1;
}

/* Stats Grid - Compact for this card size */
.stats-grid {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
    padding-top: 15px;
    border-top: 1px solid #f0f0f0;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #666;
    font-size: 0.9rem;
    font-weight: 500;
}

.stat-item i {
    color: var(--primary-blue);
    font-size: 1.1rem;
}

.stat-number {
    font-weight: 700;
    color: #333;
    margin-right: 4px;
}

/* Footer / Action */
.card-footer-action {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
}

.prize-pool {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--primary-blue);
}

.action-btn-small {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: #f8f9fa;
    color: var(--primary-blue);
    border: none;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.premium-competition-card:hover .action-btn-small {
    background: var(--primary-blue);
    color: white;
    transform: rotate(45deg);
    /* Optional effect like course card */
}

/* Animations */
@keyframes cardEntrance {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

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

/* Animations */
@keyframes particleFloat1 {

    0%,
    100% {
        transform: translate(0, 0);
    }

    50% {
        transform: translate(20px, -20px);
    }
}

@keyframes particleFloat2 {

    0%,
    100% {
        transform: translate(0, 0);
    }

    50% {
        transform: translate(-30px, -15px);
    }
}

@keyframes particleFloat3 {

    0%,
    100% {
        transform: translate(0, 0);
    }

    50% {
        transform: translate(15px, -30px);
    }
}

@keyframes orbFloat1 {

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

    50% {
        transform: translate(-20px, 30px) scale(1.1);
    }
}

@keyframes orbFloat2 {

    0%,
    100% {
        transform: translate(0, 0);
    }

    50% {
        transform: translate(30px, -20px);
    }
}

@keyframes badgeEntrance {
    from {
        opacity: 0;
        transform: scale(0.5) translateY(-20px);
    }

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

/* Fix card entrance for Grid */
@keyframes cardEntrance {
    from {
        opacity: 0;
        transform: translateY(50px) scale(0.9);
    }

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

/* Featured Card Enhancements (for HTML section) */
.featured-competition-card {
    background: white !important;
    border: 1px solid rgba(0, 0, 0, 0.06) !important;
    border-radius: 30px !important;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1) !important;
}

.featured-competition-card h3 {
    color: var(--primary-blue) !important;
}

.featured-competition-card .text-muted {
    color: #585a5c !important;
}

.featured-competition-card .text-white {
    color: #333 !important;
}