/* ==== UPDATED: SPLASH SCREEN STYLES ==== */
#splash-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: var(--primary-color); 
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease-out, visibility 0.5s ease-out;
}
#splash-screen.splash-hidden {
    opacity: 0;
    visibility: hidden;
}
.splash-logo {
    font-family: var(--font-primary);
    font-size: 2.5rem;
    font-weight: 700;
    color: white; 
    display: flex;
    justify-content: center;
    align-items: center;
    --face-height: 40px; 
}
.country-cube-container {
    display: inline-block;
    height: var(--face-height);
    overflow: hidden;
    margin-left: 0.25rem;
    text-align: left;
}
.country-cube {
    display: block;
    color: var(--accent-color); 
    animation: rollCountries 5s ease-in-out forwards;
}
.country-face {
    height: var(--face-height);
    line-height: var(--face-height);
}
@keyframes rollCountries {
    0%, 15% { transform: translateY(0); }
    20%, 35% { transform: translateY(calc(var(--face-height) * -1)); }
    40%, 55% { transform: translateY(calc(var(--face-height) * -2)); }
    60%, 75% { transform: translateY(calc(var(--face-height) * -3)); }
    80%, 100% { transform: translateY(calc(var(--face-height) * -4)); }
}
.loader {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(255, 255, 255, 0.2);
    border-top-color: white;
    border-radius: 50%;
    margin-top: 2rem;
    animation: spin 1s linear infinite;
}
@keyframes spin {
    to { transform: rotate(360deg); }
}
@media (max-width: 480px) {
    .splash-logo {
        font-size: 2rem; 
        --face-height: 32px;
    }
}

/* ==== GLOBAL STYLES & VARIABLES ==== */
:root {
    --background-color: #ffffff;
    --primary-color: #046b3c; /* Dark Green */
    --accent-color: #79c0a4; /* Mint Green */
    --text-color: #333333;
    --light-text-color: #f0f0f0;
    --border-color: #e0e0e0;
    --font-primary: 'Poppins', sans-serif;
    --font-secondary: 'Cairo', sans-serif;
}
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
body {
    font-family: var(--font-primary);
    background-color: var(--background-color);
    color: var(--text-color);
    -webkit-font-smoothing: antialiased;
}
.container {
    margin: 0 auto;
    padding-bottom: 80px; /* Space for sticky footer */
}
a {
    text-decoration: none;
    color: var(--primary-color);
}

/* ==== HEADER ==== */
.sticky-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
}
.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
}
.logo h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-color);
}
.logo span {
    color: var(--accent-color);
    font-weight: 600;
}
.widgets {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.8rem;
}
.widget-item {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    color: #555;
}
.widget-item i {
    color: var(--accent-color);
}
#country-switcher {
    border: none;
    background: transparent;
    font-family: var(--font-primary);
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
}
#country-switcher:focus {
    outline: none;
}

/* ==== HERO SECTION ==== */
.hero-section {
    position: relative;
    height: 60vh;
    display: flex;
    align-items: flex-end;
    padding: 1.5rem;
    background-size: cover;
    background-position: center bottom;
    color: var(--light-text-color);
    transition: background-image 0.5s ease-in-out;
}
#splash-screen {
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

#splash-screen.splash-hidden {
    opacity: 0;
    visibility: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0));
}
.hero-content {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}
.hero-content h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: white;
    margin-bottom: 0.2rem;
}
.hero-content p {
    font-size: 1rem;
    color: var(--light-text-color);
    margin-bottom: 1.5rem;
}
.hero-uae { background-image: url('...'); }
.hero-saudi { background-image: url('...'); }
.hero-bahrain { background-image: url('...'); }
.hero-qatar { background-image: url('...'); }
.hero-europe { background-image: url('...'); }
.featured-card {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(5px);
    border-radius: 12px;
    padding: 1rem;
    display: flex;
    gap: 1rem;
    align-items: center;
    color: var(--text-color);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    max-width: 500px;
}
.featured-text span {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--primary-color);
    display: block;
    margin-bottom: 0.25rem;
}
.featured-text h3 { font-size: 1.1rem; margin-bottom: 0.25rem; }
.featured-text p { font-size: 0.9rem; color: #555; margin-bottom: 0.75rem; }
.featured-text a { font-weight: 600; font-size: 0.9rem; }
.featured-image img {
    width: 80px;
    height: 80px;
    border-radius: 8px;
    object-fit: cover;
}

/* ==== CONTENT SECTIONS ==== */
.content-section {
    padding: 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
}
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}
.section-header h2 {
    font-size: 1.4rem;
    font-weight: 600;
}
.section-header i {
    margin-right: 0.5rem;
    color: var(--primary-color);
}
.view-all {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--accent-color);
}
.horizontal-scroll {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    padding-bottom: 1rem;
    scrollbar-width: none;
}
.horizontal-scroll::-webkit-scrollbar {
    display: none;
}

/* ==== CARD STYLES ==== */
.trending-card {
    flex: 0 0 280px;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    color: white;
}
.trending-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
}
.trending-card .card-content {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 1rem;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
}
.trending-card .tag {
    background-color: var(--accent-color);
    color: white;
    padding: 0.25rem 0.6rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    display: inline-block;
    margin-bottom: 0.5rem;
}
.trending-card h3 {
    font-size: 1.1rem;
    margin-bottom: 0.25rem;
}
.trending-card p {
    font-size: 0.85rem;
    opacity: 0.9;
}
.promotion-card {
    flex: 0 0 240px;
    height: 160px;
    position: relative;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: flex-end;
    padding: 1rem;
    color: white;
    font-weight: 700;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.7);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}
.promotion-title {
    font-size: 1rem;
}
.news-item {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
    color: inherit;
}
.news-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
}
.news-item img {
    width: 90px;
    height: 90px;
    object-fit: cover;
    border-radius: 8px;
}
.news-content h3 {
    font-size: 1.1rem;
    margin-bottom: 0.25rem;
}
.news-content p {
    font-size: 0.9rem;
    color: #555;
    font-family: var(--font-secondary);
}
.news-meta {
    font-size: 0.8rem;
    color: #999;
    margin-top: 0.5rem;
}
.job-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    margin-bottom: 0.75rem;
    transition: box-shadow 0.3s ease;
}
.job-item:hover {
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}
.job-details h3 { font-size: 1.1rem; }
.job-details p { color: #666; font-size: 0.9rem; }
.job-apply-btn {
    background-color: var(--accent-color);
    color: white;
    padding: 0.6rem 1.2rem;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9rem;
}

/* ==== NEW: INSTAGRAM SLIDER STYLES ==== */
.slider-container {
    position: relative;
    margin: 0 -1.5rem; /* Allow slider to bleed to the edges of the content section */
    padding: 0 1.5rem;
    overflow: hidden;
}
.instagram-slider {
    display: flex;
    gap: 1rem;
    transition: transform 0.5s ease-in-out;
}
.instagram-post {
    flex: 0 0 calc(33.333% - 0.666rem); /* 3 posts, accounting for gap */
    aspect-ratio: 1 / 1;
    border-radius: 8px;
    overflow: hidden;
    position: relative;
}
.instagram-post img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}
.instagram-post:hover img {
    transform: scale(1.05);
}
.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    cursor: pointer;
    z-index: 10;
    box-shadow: 0 2px 5px rgba(0,0,0,0.15);
    transition: background-color 0.2s;
}
.slider-btn:hover {
    background-color: white;
}
.slider-btn.prev { left: 5px; }
.slider-btn.next { right: 5px; }

@media (max-width: 992px) {
    .instagram-post { flex: 0 0 calc(50% - 0.5rem); } /* 2 posts */
}
@media (max-width: 576px) {
    .instagram-post { flex: 0 0 80%; } /* 1+ posts */
}

/* ==== NEW: SOCIAL MEDIA SECTION STYLES ==== */
.social-section {
    text-align: center;
    padding: 2.5rem 1.5rem;
    background-color: #f8f9fa;
    max-width: 1200px;
    margin: 1rem auto 0 auto;
    border-radius: 12px;
}
.social-section p {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-color);
}
.social-link {
    display: inline-flex;
    align-items: center;
    background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
    color: white;
    padding: 0.8rem 1.5rem;
    border-radius: 25px;
    font-weight: 600;
    transition: transform 0.3s ease;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}
.social-link:hover {
    transform: scale(1.05);
}
.social-link i {
    font-size: 1.2rem;
    margin-right: 0.75rem;
}

/* ==== FOOTER ==== */
.sticky-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: var(--background-color);
    border-top: 1px solid var(--border-color);
    z-index: 1000;
}
.bottom-nav {
    display: flex;
    justify-content: space-between; /* better control of spacing */
    align-items: center;
    height: 65px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px; /* optional: adds some padding on sides */
    gap: 35px; /* add spacing between links */
}

.nav-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #999;
    font-size: 0.7rem;
    gap: 4px;
    flex: 1; /* optional: makes links take equal space */
    text-align: center;
}

.nav-link.active {
    color: var(--primary-color);
}
.nav-link i {
    font-size: 1.25rem;
}
.add-button {
    background-color: var(--primary-color);
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: -20px;
    border: 4px solid white;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}
.add-button i {
    font-size: 1.5rem;
}

/* ==== RESPONSIVENESS ==== */
@media (min-width: 768px) {
    .header-content { padding: 1rem 2rem; }
    .hero-section { height: 450px; }
    .hero-content h2 { font-size: 3.5rem; }
    .content-section { padding: 2rem; }
    .widgets .widget-item:not(:first-child) { display: flex; }
}
@media (max-width: 767px) {
    .widgets .widget-item { display: none; }
     #country-switcher { display: block; }
}