@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@400;600;700;800;900&family=Tajawal:wght@300;400;500;700;800;900&display=swap');

:root {
    --primary-color: #c60018; /* Main Red */
    --text-color: #222222;
    --text-muted: #666666;
    --bg-light: #fdfdfd;
    --border-color: #e0e0e0;
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Tajawal', sans-serif;
    direction: rtl;
    background-color: var(--bg-light);
    color: var(--text-color);
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
header {
    background-color: #fff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 100;
}

header .container {
    max-width: 100%;
    padding: 0 40px;
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 62px;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo-img {
    width: 55px;
    height: 55px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.logo-text h1 {
    font-family: 'Cairo', sans-serif;
    font-size: 21px;
    font-weight: 800;
    color: #000;
    line-height: 1.2;
}

.logo-text p {
    font-size: 12px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
}

.nav-links {
    display: flex;
    align-items: center;
}

.nav-links > li {
    display: flex;
    align-items: center;
}

.nav-links > li:not(:last-child) {
    border-left: 1px solid var(--primary-color);
    padding-left: 12px;
    margin-left: 12px;
}

.nav-links a {
    font-weight: 700;
    font-size: 13px;
    color: #444;
    padding: 5px 0;
    position: relative;
    white-space: nowrap;
    display: flex;
    align-items: center;
}

.nav-links a i {
    margin-left: 6px;
    color: var(--primary-color);
    font-size: 14px;
}

/* Dropdown Styles */
.nav-links .dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    background-color: #fff;
    min-width: 160px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    border-radius: 6px;
    padding: 5px 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(15px);
    transition: all 0.3s ease;
    z-index: 100;
    list-style: none;
    display: flex;
    flex-direction: column;
    border-top: 3px solid var(--primary-color);
}

.nav-links .dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu li {
    width: 100%;
}

.dropdown-menu a {
    padding: 10px 15px;
    display: flex;
    width: 100%;
    color: #555;
    transition: background 0.2s;
}

.dropdown-menu a::after {
    display: none !important; /* Hide active underline on dropdown items */
}

.dropdown-menu a:hover {
    background-color: #f8f9fa;
    color: var(--primary-color);
}

.nav-links > li > a:hover, .nav-links > li > a.active {
    color: var(--primary-color);
}

.nav-links a.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--primary-color);
}

.header-left {
    display: flex;
    align-items: center;
    height: 100%;
}

.social-links {
    display: flex;
    align-items: center;
    gap: 15px;
    background-color: var(--primary-color);
    height: 45px;
    padding: 0 35px 0 25px;
    border-radius: 25px 0 0 25px;
    position: relative;
    margin-right: 20px;
    z-index: 1;
}

.social-links::before {
    content: '';
    position: absolute;
    top: 0;
    right: -15px;
    width: 30px;
    height: 100%;
    background-color: var(--primary-color);
    transform: skewX(-25deg);
    z-index: -1;
    border-radius: 0 5px 5px 0;
}

.social-links a {
    color: #fff;
    font-size: 16px;
    transition: opacity 0.3s;
}

.social-links a:hover {
    color: #fff;
    opacity: 0.8;
}

.contact-link {
    font-weight: 700;
    font-size: 13px;
    color: #444;
    white-space: nowrap;
}

/* Hero Section */
.hero {
    position: relative;
    min-height: 580px;
    padding-top: 45px;
    padding-bottom: 50px;
    overflow: hidden;
    background-color: #f5f5f5;
    border-bottom: 6px solid var(--primary-color);
    border-radius: 0 0 40px 40px;
}

.hero-slideshow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: 65% 100%;
    background-position: left bottom;
    background-repeat: no-repeat;
    opacity: 0;
    animation: heroFade 12s infinite;
}

.hero-bg.slide-1 {
    background-image: url('../images/mm.png');
    animation-delay: 0s;
}

.hero-bg.slide-2 {
    background-image: url('../images/slide2.png');
    animation-delay: 6s;
}

@keyframes heroFade {
    0% { opacity: 0; transform: scale(1.03); }
    15% { opacity: 1; transform: scale(1); }
    45% { opacity: 1; transform: scale(1); }
    60% { opacity: 0; transform: scale(0.97); }
    100% { opacity: 0; transform: scale(0.97); }
}

.hero-mask {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, rgba(245,245,245,0) 45%, #f5f5f5 64%, #f5f5f5 100%);
    z-index: 2;
}

.hero .container {
    position: relative;
    z-index: 3;
    width: 100%;
}

.hero-content {
    max-width: 520px;
}

.hero-badge {
    display: inline-block;
    background-color: var(--primary-color);
    color: white;
    padding: 6px 15px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 14px;
    margin-bottom: 20px;
    clip-path: polygon(10% 0, 100% 0, 90% 100%, 0% 100%);
}

.hero h2 {
    font-family: 'Cairo', sans-serif;
    font-size: 65px;
    font-weight: 900;
    line-height: 1.1;
    color: #111;
    margin-bottom: 15px;
}

.hero h2 span {
    color: var(--primary-color);
}

.shine-black {
    background: linear-gradient(120deg, #111 40%, #a8a8a8 50%, #111 60%);
    background-size: 200% auto;
    color: transparent !important;
    -webkit-background-clip: text;
    background-clip: text;
    animation: shineText 4s linear infinite;
    display: inline-block;
    padding-bottom: 15px;
    margin-bottom: -15px;
    line-height: 1.4;
}

.shine-red {
    background: linear-gradient(120deg, var(--primary-color) 40%, #ff8a8a 50%, var(--primary-color) 60%);
    background-size: 200% auto;
    color: transparent !important;
    -webkit-background-clip: text;
    background-clip: text;
    animation: shineText 4s linear infinite;
    display: inline-block;
    padding-bottom: 15px;
    margin-bottom: -15px;
    line-height: 1.4;
}

@keyframes shineText {
    to {
        background-position: 200% center;
    }
}

.hero p {
    font-size: 18px;
    color: var(--text-muted);
    margin-bottom: 25px;
    max-width: 500px;
    text-align: center;
    margin-left: auto;
    margin-right: auto;
}

.hero-location {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-weight: 700;
    font-size: 18px;
    color: #222;
    margin-bottom: 30px;
}

.hero-location i {
    color: var(--primary-color);
    font-size: 20px;
}

.hero-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.btn {
    padding: 12px 35px;
    font-family: 'Cairo', sans-serif;
    font-weight: 800;
    font-size: 16px;
    border-radius: 30px;
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid transparent;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn i {
    margin-left: 8px;
    font-size: 18px;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background-color: #a00014;
}

.btn-outline {
    background-color: transparent;
    color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-outline:hover {
    background-color: var(--primary-color);
    color: white;
}

/* Stats Section */
.stats-section {
    margin-top: -40px; /* Overlap hero */
    position: relative;
    z-index: 10;
    margin-bottom: 40px; /* Reduced from 60px */
}

.stats-card {
    background: white;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    display: flex;
    justify-content: space-between;
    padding: 15px 40px; /* Reduced top/bottom padding */
    border: 1px solid var(--border-color);
}

.stat-item {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 15px;
    flex: 1;
    position: relative;
    animation: waveScale 4s infinite ease-in-out;
}

.stat-item:nth-child(1) { animation-delay: 0s; }
.stat-item:nth-child(2) { animation-delay: 1s; }
.stat-item:nth-child(3) { animation-delay: 2s; }
.stat-item:nth-child(4) { animation-delay: 3s; }

@keyframes waveScale {
    0%, 100% { transform: scale(1); }
    12.5% { transform: scale(1.15); }
    25% { transform: scale(1); }
}

.stat-item:not(:last-child)::after {
    content: '';
    position: absolute;
    left: 0;
    top: 10%;
    height: 80%;
    width: 1px;
    background-color: rgba(198, 0, 24, 0.2); /* Light red line */
}

.stat-icon {
    font-size: 55px;
    color: var(--primary-color);
}

.stat-info {
    text-align: right;
}

.stat-info h3 {
    font-family: 'Cairo', sans-serif;
    font-size: 32px;
    font-weight: 800;
    color: var(--primary-color);
    line-height: 1;
    margin-bottom: 5px;
}

.stat-info p {
    font-size: 15px;
    font-weight: 700;
    color: var(--text-muted);
}

/* Sections Global */
.section-wrapper {
    margin-bottom: 60px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.section-title {
    font-family: 'Cairo', sans-serif;
    font-size: 32px;
    font-weight: 800;
    color: var(--primary-color);
}

.view-all-btn {
    background-color: var(--primary-color);
    color: white;
    padding: 8px 20px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 14px;
}

.view-all-btn:hover {
    background-color: #a00014;
    color: white;
}

/* News Section */
.news-slider-container {
    display: flex;
    align-items: center;
    gap: 15px;
}

.slider-arrow {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: white;
    border: 1px solid var(--border-color);
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--primary-color);
    cursor: pointer;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    flex-shrink: 0;
}
.slider-arrow:hover {
    background-color: var(--primary-color);
    color: white;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    flex: 1;
}

.news-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 5px 15px rgba(198,0,24,0.15);
}

.news-img {
    height: 180px;
    position: relative;
}

.news-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.news-date {
    position: absolute;
    bottom: -15px;
    right: 15px;
    background-color: var(--primary-color);
    color: white;
    width: 45px;
    height: 55px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border-radius: 4px;
    font-family: 'Cairo', sans-serif;
    line-height: 1.1;
    z-index: 2;
}

.news-date span { font-size: 20px; font-weight: 800; }
.news-date small { font-size: 12px; }

.news-content {
    padding: 25px 15px 15px;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.news-content h3 {
    font-family: 'Cairo', sans-serif;
    font-size: 14px;
    font-weight: 700;
    color: #111;
    margin-bottom: 15px;
    min-height: 48px;
    text-align: justify;
    line-height: 1.6;
}

.read-more {
    color: var(--primary-color);
    font-weight: 700;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    margin-top: auto;
}
.read-more i { font-size: 12px; }
.read-more:hover { text-decoration: underline; }

/* Galleries */
.galleries-row {
    margin-bottom: 60px;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    flex: 1;
    overflow: hidden;
}

.gallery-item {
    flex: 1;
    height: 140px;
    border-radius: 8px;
    overflow: hidden;
    position: relative;
}
.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-more {
    position: absolute;
    inset: 0;
    background: rgba(198, 0, 24, 0.85);
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    font-family: 'Cairo', sans-serif;
}
.gallery-more span { font-size: 28px; font-weight: 800; }
.gallery-more small { font-size: 16px; }

/* Video Grid */
.video-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    flex: 1;
    overflow: hidden;
}

.video-card {
    flex: 1;
}

.video-item {
    height: 120px;
    border-radius: 8px;
    position: relative;
    margin-bottom: 10px;
}
.video-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    background: rgba(255,255,255,0.3);
    border: 2px solid white;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    color: white;
    font-size: 16px;
}
.video-duration {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0,0,0,0.8);
    color: white;
    font-size: 11px;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 700;
}
.video-title {
    font-size: 13px;
    font-weight: 700;
    color: #111;
    text-align: center;
}

/* Participations and Achievements */
.bottom-sections {
    display: flex;
    gap: 20px;
    margin-bottom: 60px;
}

.half-section {
    flex: 1;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 20px;
}

.half-section-title {
    font-family: 'Cairo', sans-serif;
    font-size: 24px;
    font-weight: 800;
    color: var(--primary-color);
    text-align: center;
    margin-bottom: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

/* Participations Grid */
.parts-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
}
.part-box {
    border: 1px solid var(--border-color);
    border-bottom: 3px solid var(--primary-color);
    border-radius: 8px;
    text-align: center;
    padding: 10px 10px 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 4px 15px rgba(198, 0, 24, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
    position: relative;
    overflow: hidden;
    background: #fff;
}
.part-box:hover {
    box-shadow: 0 8px 25px rgba(198, 0, 24, 0.2);
    transform: translateY(-5px);
}
.part-ribbon {
    position: absolute;
    top: 15px;
    right: -35px;
    background: #c60018;
    color: #fff;
    padding: 5px 40px;
    font-size: 11px;
    font-weight: bold;
    transform: rotate(45deg);
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}
.part-title-bg {
    background: #f9f9f9;
    width: 90%;
    margin: 20px auto 10px;
    padding: 12px;
    border-radius: 5px;
}
.part-box h4 {
    font-size: 13px;
    font-weight: 700;
    color: #333;
    margin: 0;
}
.part-location {
    color: #777;
    font-size: 12px;
    margin-top: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* Achievements Grid */
.achieve-content {
    display: flex;
    gap: 20px;
    align-items: center;
}
.achieve-cup {
    width: 120px;
    flex-shrink: 0;
}
.achieve-cup img {
    width: 100%;
    height: auto;
}
.achieve-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    flex: 1;
}
.achieve-box {
    text-align: right;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    box-shadow: 0 4px 15px rgba(198, 0, 24, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}
.achieve-box:hover {
    box-shadow: 0 8px 25px rgba(198, 0, 24, 0.2);
    transform: translateY(-5px);
}
.achieve-box h3 {
    color: var(--primary-color);
    font-family: 'Cairo', sans-serif;
    font-size: 24px;
    font-weight: 800;
    line-height: 1.2;
}
.achieve-box p {
    font-size: 12px;
    font-weight: 700;
    color: var(--text-muted);
}

.center-btn {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}

/* CTA */
.cta-section {
    background-color: var(--primary-color);
    background-blend-mode: overlay;
    background-size: cover;
    background-position: center;
    border-radius: 10px;
    padding: 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 60px;
    position: relative;
    overflow: hidden;
}
.cta-content, .cta-btn {
    position: relative;
    z-index: 2;
}
.cta-content h2 {
    font-family: 'Cairo', sans-serif;
    font-size: 35px;
    font-weight: 900;
    color: white;
}
.cta-content p {
    color: rgba(255,255,255,0.9);
    font-size: 18px;
}
.cta-btn {
    background: #0f172a;
    color: white;
    font-family: 'Cairo', sans-serif;
    font-size: 20px;
    font-weight: 800;
    padding: 10px 40px;
    border-radius: 4px;
    border: 1px solid #000;
    box-shadow: 0 4px 10px rgba(0,0,0,0.5);
    cursor: pointer;
}

/* Footer */
footer {
    background-color: #f9f9f9;
    padding-top: 50px;
}
.footer-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 30px;
    text-align: center;
}
.footer-title {
    font-family: 'Cairo', sans-serif;
    font-size: 18px;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 20px;
}
.footer-logo-text h2 {
    font-family: 'Cairo', sans-serif;
    font-size: 16px;
    font-weight: 800;
    color: #111;
}
.footer-logo-text p {
    font-size: 14px;
    color: var(--text-muted);
    margin-top: 10px;
}
.footer-links li {
    margin-bottom: 10px;
    font-weight: 700;
    font-size: 14px;
    color: #444;
}
.footer-links li a:hover {
    color: var(--primary-color);
}
.contact-info li {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 10px;
    font-weight: 700;
    font-size: 14px;
    color: #444;
}
.contact-info i {
    color: var(--primary-color);
}
.copyright {
    background-color: var(--primary-color);
    color: white;
    text-align: center;
    padding: 15px;
    font-weight: 700;
    font-size: 14px;
}

/* News Section Custom Styles */
.news-wrapper {
    border: 1px solid #e0e0e0;
    border-top: 5px solid var(--primary-color);
    border-radius: 12px;
    padding: 25px 25px 15px 25px;
    background-color: #ffffff;
    box-shadow: 0 5px 25px rgba(0,0,0,0.05);
    margin-bottom: 40px;
}

.news-footer-link {
    text-align: left;
    margin-top: 15px;
}

.text-link {
    color: var(--primary-color);
    font-weight: 800;
    text-decoration: none;
    font-size: 17px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition);
}

.text-link:hover {
    color: #a00014;
    transform: translateX(-5px);
}

/* News Title Custom Styles */
.news-wrapper .section-header {
    margin-bottom: 20px;
    margin-top: 0;
}

.news-wrapper .section-title {
    font-size: 24px;
    margin: 0;
    padding: 0;
    position: relative;
    display: inline-block;
    padding-bottom: 12px;
}

/* Animated Red Strip */
.news-wrapper .section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    height: 4px;
    background-color: var(--primary-color);
    border-radius: 2px;
    animation: strip-move 1.5s infinite alternate ease-in-out;
}

@keyframes strip-move {
    0% { width: 30px; }
    100% { width: 100%; }
}

/* Animated Icon */
.news-wrapper .section-title i {
    display: inline-block;
    color: var(--primary-color);
    animation: icon-pulse 1.5s infinite alternate ease-in-out;
    margin-left: 8px;
}

@keyframes icon-pulse {
    0% { transform: scale(1); }
    100% { transform: scale(1.3); }
}

/* News Card Enhancements */
.news-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.news-card:hover {
    transform: scale(1.03) translateY(-5px);
    box-shadow: 0 15px 35px rgba(198,0,24,0.25);
}

.news-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid #eee;
}

.news-meta .views {
    font-size: 13px;
    color: #777;
    display: flex;
    align-items: center;
    gap: 5px;
}
.news-meta .views i {
    color: var(--primary-color);
}

.news-meta .btn-small {
    background-color: var(--primary-color);
    color: white;
    padding: 6px 15px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: bold;
    text-decoration: none;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 5px;
}
.news-meta .btn-small i {
    font-size: 11px;
}
.news-meta .btn-small:hover {
    background-color: #a00014;
    color: white;
}

/* Oval Frame for View All News */
.news-footer-link .text-link {
    border: 2px solid var(--primary-color);
    padding: 3px 15px; /* Reduced padding */
    border-radius: 50px;
    font-size: 14px; /* Reduced font size */
    transition: all 0.3s ease;
}
.news-footer-link .text-link:hover {
    background-color: var(--primary-color);
    color: white;
    transform: none;
}

/* News Description text */
.news-desc {
    font-size: 13px;
    color: #555;
    margin-top: 5px;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Galleries Split Layout */
.galleries-split-container {
    display: flex;
    gap: 30px;
    margin-bottom: 40px;
}

.galleries-split-container > .galleries-row.news-wrapper {
    flex: 1;
    margin-bottom: 0;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.galleries-split-container > .galleries-row.news-wrapper .news-slider-container {
    flex: 1;
    display: flex;
    align-items: center; /* Keep arrows centered vertically */
}

@media (max-width: 991px) {
    .galleries-split-container {
        flex-direction: column;
    }
}

/* Album Info Overlay */
.album-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 15px 12px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0) 100%);
    color: white;
    display: flex;
    flex-direction: column;
    gap: 4px;
    transition: all 0.3s ease;
}

.album-info .album-name {
    margin: 0;
    font-size: 14px;
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0,0,0,0.8);
    color: #ffffff;
}

.album-info .album-count {
    font-size: 12px;
    color: #d1d1d1;
    display: flex;
    align-items: center;
    gap: 5px;
}

.album-info .album-count i {
    color: var(--primary-color);
}

.gallery-item:hover .album-info {
    background: linear-gradient(to top, rgba(198, 0, 24, 0.95) 0%, rgba(198, 0, 24, 0.2) 100%);
}

.gallery-item:hover .album-info .album-count i {
    color: #ffffff;
}

/* Achieve Box Icons */
.achieve-box .icon {
    font-size: 35px;
    color: var(--primary-color);
    margin-bottom: 0;
    display: block;
}

/* CTA Section Background Enhancements */
.cta-section {
    background-color: var(--primary-color);
    background-image: 
        linear-gradient(to right, rgba(198, 0, 24, 0.9), rgba(198, 0, 24, 0.9)),
        url('../images/mm.png');
    background-size: cover, 150%;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    overflow: hidden;
    margin-bottom: 40px;
    z-index: 1;
}

/* Background watermarks for bottom sections */
#achievements-section, #participations-section {
    position: relative;
    overflow: hidden;
    z-index: 1;
}

#achievements-section::before, #achievements-section::after,
#participations-section::before, #participations-section::after {
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    position: absolute;
    color: rgba(198, 0, 24, 0.05); /* Faint red watermark */
    z-index: 0;
    pointer-events: none;
}

/* Achievements Background Images (Cups and Medals) */
#achievements-section::before {
    content: "\f091"; /* Trophy */
    font-size: 250px;
    right: -30px;
    bottom: -40px;
    transform: rotate(-15deg);
}

#achievements-section::after {
    content: "\f5a2"; /* Medal */
    font-size: 180px;
    left: -20px;
    top: 50px;
    transform: rotate(20deg);
}

/* Participations Background Images (Balls and Shields) */
#participations-section::before {
    content: "\f1e3"; /* Football */
    font-size: 280px;
    left: -40px;
    bottom: -50px;
    transform: rotate(25deg);
}

#participations-section::after {
    content: "\f3ba"; /* Shield */
    font-size: 200px;
    right: -20px;
    top: 40px;
    transform: rotate(-15deg);
}

/* Ensure contents are above watermark */
#achievements-section > *, #participations-section > * {
    position: relative;
    z-index: 2;
}

/* --- Mobile Navigation --- */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--primary-color);
    font-size: 28px;
    cursor: pointer;
}

@media (max-width: 991px) {
    .mobile-menu-toggle {
        display: block;
    }
    
    .nav-links {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        width: 100%;
        height: auto;
        background-color: #fff;
        flex-direction: column;
        align-items: stretch;
        padding: 0 15px;
        box-shadow: 0 15px 25px rgba(0,0,0,0.1);
        z-index: 1000;
        gap: 0;
        
        /* Dropdown animation */
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.4s ease, padding 0.4s ease;
    }

    .nav-links.active {
        max-height: 500px; /* enough to show all items */
        padding: 10px 15px 20px 15px;
        overflow-y: auto;
    }

    .header-inner {
        justify-content: space-between;
    }

    /* Bring toggle above the menu */
    .mobile-menu-toggle {
        z-index: 1001;
        position: relative;
    }

    .nav-links li {
        width: 100%;
        margin-left: 0;
        display: block; /* Fix flex layout causing dropdown to sit next to anchor */
    }

    .nav-links a {
        display: block;
        width: 100%;
        padding: 10px 0;
        border-bottom: 1px solid #f0f0f0;
    }

    .dropdown-menu {
        position: static;
        width: 100%;
        opacity: 1;
        visibility: visible;
        box-shadow: none;
        border: none;
        display: none; /* Hide by default in mobile, or show block */
        padding-right: 15px;
        margin-top: 5px;
        background: #fafafa;
    }
    
    .dropdown:hover .dropdown-menu {
        display: block;
    }
}

/* --- Mobile Specific Fixes --- */
@media (max-width: 768px) {
    /* Prevent horizontal scrolling */
    html, body {
        overflow-x: hidden;
        width: 100%;
        max-width: 100vw;
    }

    /* Make stats-card a 2x2 grid */
    .stats-card {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 20px;
        padding: 15px;
    }
    
    .stat-item {
        flex-direction: row;
        text-align: right;
        justify-content: flex-start;
        gap: 10px;
    }

    /* Remove the vertical lines between stats on mobile */
    .stat-item::after {
        display: none !important;
    }

    /* Stack news cards vertically */
    .news-grid {
        grid-template-columns: 1fr !important;
    }
    
    .news-slider-container {
        flex-direction: column;
    }
    
    .slider-arrow {
        display: none !important;
    }

    /* Achievements & Participations responsive */
    .achieve-box {
        flex-direction: column;
        text-align: center;
    }
    
    .parts-grid {
        grid-template-columns: 1fr 1fr;
        gap: 15px;
    }
}

@media (max-width: 768px) {
    /* Hide top bar on mobile */
    .top-bar {
        display: none !important;
    }

    /* Reduce font sizes for mobile */
    .logo-text h1 {
        font-size: 16px;
    }
    .logo-text p {
        font-size: 10px;
    }
    .hero-content h1 {
        font-size: 26px;
    }
    .hero-content p {
        font-size: 14px;
    }
    .section-title {
        font-size: 20px !important;
    }
    .achieve-box h3 {
        font-size: 20px;
    }
    .cta-content h2 {
        font-size: 24px;
    }
    .news-wrapper .section-title {
        font-size: 18px !important;
    }
}

@media (max-width: 768px) {
    /* Hide the social media container completely */
    .header-left {
        display: none !important;
    }

    /* Force the header text onto a single line and resize it */
    .logo-text h1 {
        font-size: 15px !important;
        white-space: nowrap;
    }
    .logo-text p {
        font-size: 9px !important;
        white-space: nowrap;
    }
    
    /* Slightly shrink the logo image to save horizontal space */
    .logo-img {
        width: 42px;
        height: 42px;
    }
    
    /* Adjust spacing */
    .logo-container {
        gap: 10px;
    }
}

@media (max-width: 768px) {
    /* Hide the huge title on mobile */
    .hero h2 {
        display: none !important;
    }
    
    /* Adjust hero section height and alignment */
    .hero {
        height: auto !important;
        min-height: auto !important;
        padding-top: 0 !important;
        padding-bottom: 20px !important;
        display: flex;
        align-items: flex-end; /* push text to bottom */
    }
    
    /* Move image to top and resize */
    .hero-bg {
        background-position: center top !important;
        background-size: cover !important;
        height: 250px !important;
        opacity: 0.95;
        -webkit-mask-image: linear-gradient(to bottom, black 40%, transparent 100%) !important;
        mask-image: linear-gradient(to bottom, black 40%, transparent 100%) !important;
    }
    
    /* Fade from bottom to top so text is readable */
    .hero-mask {
        display: none !important;
    }
    
    /* Center and space out the text content */
    .hero-content {
        text-align: center;
        padding-top: 195px !important; /* Pushed text down slightly */
        width: 100%;
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    
    .hero-badge {
        margin-top: 15px !important;
        margin-bottom: 4px !important;
    }
    
    .hero p {
        font-size: 14px !important;
        margin-bottom: 15px !important;
        margin-top: 0 !important;
    }
    
    .hero-location {
        font-size: 14px !important;
        justify-content: center;
        margin-bottom: 20px !important;
    }
}

@media (max-width: 768px) {
    /* Make buttons smaller on mobile and keep them side by side */
    .hero-buttons {
        flex-direction: row !important;
        gap: 10px !important;
    }
    .hero-buttons .btn {
        padding: 8px 15px !important;
        font-size: 13px !important;
        white-space: nowrap;
    }
    .hero-buttons .btn i {
        font-size: 14px !important;
        margin-left: 5px !important;
    }
    
    /* Reduce size of stats */
    .stat-icon {
        font-size: 32px !important;
    }
    .stat-info h3 {
        font-size: 20px !important;
        margin-bottom: 0 !important;
    }
    .stat-info p {
        font-size: 11px !important;
        font-weight: bold;
    }
}

@media (max-width: 768px) {
    /* Add space above stats section on mobile instead of overlapping */
    .stats-section {
        margin-top: 30px !important;
    }
    
    /* Ensure content inside stats is perfectly centered */
    .stat-item {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        text-align: center;
    }
    
    .stat-info {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        text-align: center;
    }
}

@media (max-width: 768px) {
    /* Fix CTA Banner layout for mobile */
    .cta-section {
        flex-direction: column !important;
        text-align: center;
        gap: 25px;
        padding: 30px 20px !important;
    }
    
    .cta-content h2 {
        margin-bottom: 10px;
    }
    
    .cta-btn {
        width: 100%;
        max-width: 200px;
        padding: 10px 25px !important;
        font-size: 16px !important;
        white-space: nowrap;
        margin: 0 auto;
    }
}

@media (max-width: 768px) {
    /* Stack bottom sections vertically on mobile */
    .bottom-sections {
        flex-direction: column !important;
        gap: 30px !important;
    }
    
    .half-section {
        width: 100% !important;
    }
}

@media (max-width: 768px) {
    /* Stack footer columns on mobile */
    .footer-grid {
        grid-template-columns: 1fr !important;
        text-align: center;
        gap: 35px;
    }
    
    /* Center align the contact info list items */
    .contact-info li {
        justify-content: center;
    }
}

@media (max-width: 768px) {
    /* Improve Mobile Menu Appearance */
    .nav-links > li:not(:last-child) {
        border-left: none !important;
        padding-left: 0 !important;
        margin-left: 0 !important;
    }
    
    .nav-links > li {
        width: 100%;
        display: block !important; /* Force block to prevent dropdown floating beside anchor */
    }
    
    .nav-links a {
        display: flex !important;
        align-items: center;
        gap: 15px;
        padding: 15px 10px !important;
        border-bottom: 1px solid #f0f0f0 !important;
        font-size: 15px !important;
        color: #222 !important;
        font-weight: 800;
        width: 100%;
        text-decoration: none;
    }
    
    .nav-links a i {
        margin-left: 0 !important;
        font-size: 18px !important;
        width: 22px;
        text-align: center;
        color: var(--primary-color) !important;
    }
    
    .nav-links a.active {
        color: var(--primary-color) !important;
        background-color: #fff5f6;
        border-radius: 8px;
        border-bottom: none !important;
    }
    
    .nav-links a.active::after {
        display: none !important;
    }
    
    /* Dropdown styling */
    .dropdown-menu {
        position: static !important;
        transform: none !important;
        width: 100% !important;
        opacity: 1 !important;
        visibility: visible !important;
        box-shadow: inset 0 3px 10px rgba(0,0,0,0.02) !important;
        border-top: none !important;
        padding-right: 25px !important;
        padding-top: 5px !important;
        padding-bottom: 5px !important;
        background-color: #fafafa !important;
        border-radius: 0 0 10px 10px;
        margin-top: 0;
        display: none;
    }
    
    /* If currently using hover, let's just make it look like an inline list */
    .nav-links .dropdown:hover .dropdown-menu {
        display: block !important;
    }
    
    .dropdown-menu a {
        padding: 10px !important;
        font-size: 14px !important;
        border-bottom: none !important;
        color: #555 !important;
        font-weight: 700;
    }
    
    .dropdown-menu a i {
        font-size: 14px !important;
    }
}

/* Animated Goal Net / Dot Pattern for Hero */
.hero-net-pattern {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 2;
    background-image: 
        radial-gradient(circle, rgba(255,255,255,1) 2px, transparent 3px),
        radial-gradient(circle, rgba(255,255,255,0.8) 1.5px, transparent 2px),
        radial-gradient(circle, rgba(255,255,255,0.5) 1px, transparent 1.5px);
    background-size: 60px 60px, 90px 90px, 120px 120px;
    background-position: 0 0, 40px 20px, 100px 50px;
    opacity: 0.8;
    filter: drop-shadow(0 0 5px #fff) drop-shadow(0 0 10px rgba(255,255,255,0.8));
    animation: floatingDots 40s linear infinite;
    pointer-events: none;
    /* Mask it to show over the image on the left side */
    -webkit-mask-image: radial-gradient(circle at top left, black 20%, transparent 80%);
    mask-image: radial-gradient(circle at top left, black 20%, transparent 80%);
}

@keyframes floatingDots {
    0% {
        background-position: 0 0, 40px 20px, 100px 50px;
    }
    100% {
        /* Multiples of background-size to loop seamlessly */
        background-position: 600px 600px, -410px 380px, 340px -550px; 
    }
}

@media (max-width: 768px) {
    /* Adjust particles mask for mobile image position */
    .stat-info p {
        font-size: 11px !important;
        font-weight: bold;
    }
}

@media (max-width: 768px) {
    /* Add space above stats section on mobile instead of overlapping */
    .stats-section {
        margin-top: 30px !important;
    }
    
    /* Ensure content inside stats is perfectly centered side-by-side */
    .stat-item {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: center !important;
        text-align: right !important;
        gap: 10px !important;
    }
    
    .stat-info {
        display: flex !important;
        flex-direction: column !important;
        align-items: flex-start !important;
        justify-content: center !important;
        text-align: right !important;
    }
    
    .stat-icon {
        font-size: 30px !important;
    }
    
    .stat-info h3 {
        font-size: 20px !important;
        margin-bottom: 2px !important;
    }
    
    .stat-info p {
        font-size: 11px !important;
    }
    
    /* Swap coach and player stats on mobile */
    .stat-item:nth-child(1) { order: 1; }
    .stat-item:nth-child(2) { order: 3; } /* ظ„ط§ط¹ط¨ ظ…ط³ط¬ظ„ */
    .stat-item:nth-child(3) { order: 2; } /* ظ…ط¯ط±ط¨ ظ…ط¹طھظ…ط¯ */
    .stat-item:nth-child(4) { order: 4; }
}

@media (max-width: 768px) {
    /* Fix CTA Banner layout for mobile */
    .cta-section {
        flex-direction: column !important;
        text-align: center;
        gap: 25px;
        padding: 30px 20px !important;
    }
    
    .cta-content h2 {
        margin-bottom: 10px;
    }
    
    .cta-btn {
        width: 100%;
        max-width: 200px;
        padding: 10px 25px !important;
        font-size: 16px !important;
        white-space: nowrap;
        margin: 0 auto;
    }
}

@media (max-width: 768px) {
    /* Stack bottom sections vertically on mobile */
    .bottom-sections {
        flex-direction: column !important;
        gap: 30px !important;
    }
    
    .half-section {
        width: 100% !important;
    }
}

@media (max-width: 768px) {
    /* Stack footer columns on mobile */
    .footer-grid {
        grid-template-columns: 1fr !important;
        text-align: center;
        gap: 35px;
    }
    
    /* Center align the contact info list items */
    .contact-info li {
        justify-content: center;
    }
}

@media (max-width: 768px) {
    /* Improve Mobile Menu Appearance */
    .nav-links > li:not(:last-child) {
        border-left: none !important;
        padding-left: 0 !important;
        margin-left: 0 !important;
    }
    
    .nav-links > li {
        width: 100%;
        display: block !important; /* Force block to prevent dropdown floating beside anchor */
    }
    
    .nav-links a {
        display: flex !important;
        align-items: center;
        gap: 15px;
        padding: 15px 10px !important;
        border-bottom: 1px solid #f0f0f0 !important;
        font-size: 15px !important;
        color: #222 !important;
        font-weight: 800;
        width: 100%;
        text-decoration: none;
    }
    
    .nav-links a i {
        margin-left: 0 !important;
        font-size: 18px !important;
        width: 22px;
        text-align: center;
        color: var(--primary-color) !important;
    }
    
    .nav-links a.active {
        color: var(--primary-color) !important;
        background-color: #fff5f6;
        border-radius: 8px;
        border-bottom: none !important;
    }
    
    .nav-links a.active::after {
        display: none !important;
    }
    
    /* Dropdown styling */
    .dropdown-menu {
        position: static !important;
        transform: none !important;
        width: 100% !important;
        opacity: 1 !important;
        visibility: visible !important;
        box-shadow: inset 0 3px 10px rgba(0,0,0,0.02) !important;
        border-top: none !important;
        padding-right: 25px !important;
        padding-top: 5px !important;
        padding-bottom: 5px !important;
        background-color: #fafafa !important;
        border-radius: 0 0 10px 10px;
        margin-top: 0;
        display: none;
    }
    
    /* If currently using hover, let's just make it look like an inline list */
    .nav-links .dropdown:hover .dropdown-menu {
        display: block !important;
    }
    
    .dropdown-menu a {
        padding: 10px !important;
        font-size: 14px !important;
        border-bottom: none !important;
        color: #555 !important;
        font-weight: 700;
    }
    
    .dropdown-menu a i {
        font-size: 14px !important;
    }
}

/* Animated Goal Net / Dot Pattern for Hero */
.hero-net-pattern {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 2;
    background-image: 
        radial-gradient(circle, rgba(255,255,255,1) 2px, transparent 3px),
        radial-gradient(circle, rgba(255,255,255,0.8) 1.5px, transparent 2px),
        radial-gradient(circle, rgba(255,255,255,0.5) 1px, transparent 1.5px);
    background-size: 60px 60px, 90px 90px, 120px 120px;
    background-position: 0 0, 40px 20px, 100px 50px;
    opacity: 0.8;
    filter: drop-shadow(0 0 5px #fff) drop-shadow(0 0 10px rgba(255,255,255,0.8));
    animation: floatingDots 40s linear infinite;
    pointer-events: none;
    /* Mask it to show over the image on the left side */
    -webkit-mask-image: radial-gradient(circle at top left, black 20%, transparent 80%);
    mask-image: radial-gradient(circle at top left, black 20%, transparent 80%);
}

@keyframes floatingDots {
    0% {
        background-position: 0 0, 40px 20px, 100px 50px;
    }
    100% {
        /* Multiples of background-size to loop seamlessly */
        background-position: 600px 600px, -410px 380px, 340px -550px; 
    }
}

@media (max-width: 768px) {
    /* Adjust particles mask for mobile image position */
    .hero-net-pattern {
        -webkit-mask-image: radial-gradient(circle at top center, black 15%, transparent 60%) !important;
        mask-image: radial-gradient(circle at top center, black 15%, transparent 60%) !important;
    }
}
@media (max-width: 768px) {
    .container {
        padding: 0 8px !important;
    }
    header .container {
        padding: 0 10px !important;
    }
    .stats-card {
        padding: 10px !important;
    }
    .news-wrapper {
        padding: 15px 5px 10px 5px !important;
    }
    
    /* Reduce Date Badge Size */
    .news-date {
        width: 30px !important;
        height: 40px !important;
        bottom: -10px !important;
        right: 10px !important;
        padding: 2px !important;
    }
    .news-date span {
        font-size: 13px !important;
        line-height: 1 !important;
    }
    .news-date small {
        font-size: 9px !important;
        line-height: 1 !important;
    }
    
    /* Ensure gallery grid and video grid take full width equally */
    .gallery-grid, .video-grid {
        gap: 8px !important;
        width: 100% !important; /* Force grids to span full width */
        grid-template-columns: 1fr !important;
    }
    .video-card {
        padding: 5px !important;
    }
    
    /* Reduce Stats Card Text and Icons */
    .stat-icon {
        font-size: 35px !important;
    }
    .stat-info h3 {
        font-size: 22px !important;
        margin-bottom: 2px !important;
    }
    .stat-info p {
        font-size: 11px !important;
    }
}

/* Breadcrumb Animations */
.icon-bounce {
    animation: bounce 2s infinite;
    display: inline-block;
}
@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-5px); }
    60% { transform: translateY(-3px); }
}
.animated-line {
    position: absolute;
    bottom: 0;
    right: 0;
    height: 3px;
    background-color: var(--primary-color);
    border-radius: 3px;
    animation: expandLine 1.5s ease-in-out infinite alternate;
}
@keyframes expandLine {
    0% { width: 30%; }
    100% { width: 100%; }
}

/* Search Styles */
.search-container {
    position: relative;
    display: flex;
    align-items: center;
}

.search-toggle-btn {
    background: transparent;
    border: none;
    color: var(--primary-color);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 5px;
    transition: var(--transition);
}

.search-toggle-btn:hover {
    color: #000;
}

.search-form {
    position: absolute;
    top: 180%;
    left: 50%;
    transform: translateX(-50%);
    background: #fff;
    border-radius: 25px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    display: flex;
    align-items: center;
    overflow: hidden;
    width: 250px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid var(--border-color);
    z-index: 100;
    pointer-events: none;
}

.search-form.active {
    top: 140%;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.search-input {
    border: none;
    padding: 10px 15px;
    width: 100%;
    outline: none;
    font-family: inherit;
    font-size: 0.9rem;
    background: transparent;
}

.search-submit-btn {
    background: var(--primary-color);
    color: #fff;
    border: none;
    padding: 10px 15px;
    cursor: pointer;
    transition: var(--transition);
}

.search-submit-btn:hover {
    background: #a00013;
}

@media (max-width: 768px) {
    .search-form.active {
        position: fixed;
        top: 70px;
        left: 5%;
        right: 5%;
        width: 90%;
        transform: none;
        z-index: 1000;
    }
}
