/* ==================== COLOR VARIABLES ==================== */
:root {
    --primary-color: #1F4E6E;    /* Blue */
    --secondary-color: #008080;   /* Teal */
    --accent-color: #C69214;      /* Gold */
    --highlight-color: #FFA500;   /* Orange */
    --dark-color: #000000;        /* Black */
    --light-color: #ffffff;
    --gray-color: #f8f9fa;
}

/* ==================== GLOBAL STYLES ==================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Arial, sans-serif;
    line-height: 1.6;
    color: var(--dark-color);
    overflow-x: hidden;
    position: relative;
}

/* ==================== FIXED Z-INDEX HIERARCHY ==================== */
/* This ensures dropdown menus appear above all content */

/* Force navbar to be on top */
.navbar {
    z-index: 9999 !important;
    position: sticky !important;
    top: 0 !important;
    background-color: var(--primary-color) !important;
    overflow-x: hidden !important;
}

/* Boost dropdown way above everything */
.dropdown-menu {
    z-index: 10000 !important;
    position: absolute !important;
    background: white !important;
    border-radius: 12px !important;
    box-shadow: 0 8px 30px rgba(0,0,0,0.2) !important;
    min-width: 260px !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
    margin-top: 0.5rem !important;
    padding: 0.5rem 0 !important;
    display: none;
}

.dropdown-menu.show {
    display: block !important;
}

/* Fix dropdown positioning */
.navbar-nav .dropdown-menu {
    top: 100% !important;
    left: auto !important;
    right: 0 !important;
}

/* Important Bootstrap fix */
.dropdown {
    position: static !important;
}

/* Ensure dropdown items are properly styled */
.dropdown-item {
    padding: 0.6rem 1.2rem !important;
    font-size: 0.85rem !important;
    color: #2c3e50 !important;
    transition: all 0.2s ease !important;
    cursor: pointer !important;
    background: white !important;
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
}

.dropdown-item:hover {
    background-color: #f8f9fa !important;
    transform: translateX(5px) !important;
    color: var(--accent-color) !important;
}

.dropdown-item i {
    width: 20px;
    font-size: 0.9rem;
    color: var(--secondary-color);
    transition: color 0.2s ease;
}

.dropdown-item:hover i {
    color: var(--accent-color);
}

.dropdown-divider {
    margin: 0.3rem 0 !important;
    background-color: #e9ecef !important;
}

/* Remove any conflicting z-index from other elements */
main, .container, .container-fluid {
    position: relative;
    z-index: auto !important;
}

/* Lower the ticker so it doesn't interfere */
.news-ticker-wrapper {
    z-index: 10 !important;
    position: relative;
}

/* Ensure floating radio doesn't block dropdown */
.floating-radio {
    z-index: 1001 !important;
}

/* Dropdown toggle styling */
.dropdown-toggle {
    cursor: pointer;
}

.dropdown-toggle::after {
    transition: transform 0.2s ease;
}

.dropdown.show .dropdown-toggle::after {
    transform: rotate(180deg);
}

/* Force all dropdown parents to allow overflow */
.navbar,
.navbar-collapse,
.navbar-nav,
.nav-item,
.dropdown {
    overflow: visible !important;
}

/* ==================== HEADER AND NAVIGATION ==================== */
.navbar-dark .navbar-nav .nav-link {
    color: var(--light-color);
    font-weight: 500;
    padding: 0.8rem 1.2rem;
    position: relative;
    z-index: 1;
}

.navbar-dark .navbar-nav .nav-link:hover {
    color: var(--accent-color);
}

/* Navbar brand */
.navbar-brand {
    transition: transform 0.2s;
}

.navbar-brand:hover {
    transform: scale(1.02);
}

/* ==================== BUTTONS AND LINKS ==================== */
.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background-color: #0e3a54;
    border-color: #0e3a54;
}

.btn-accent {
    background-color: var(--accent-color);
    border-color: var(--accent-color);
    color: var(--light-color);
}

.btn-accent:hover {
    background-color: #b07c10;
    border-color: #b07c10;
    color: var(--light-color);
}

/* ==================== CARDS AND CONTENT ==================== */
.card {
    border: none;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
}

/* ==================== RADIO PLAYER STYLES ==================== */
.radio-player {
    background: var(--light-color);
    border: 2px solid var(--accent-color);
    border-radius: 8px;
    padding: 2rem;
}

.now-playing {
    background-color: var(--primary-color);
    color: var(--light-color);
    padding: 1rem;
    border-radius: 6px;
}

/* ==================== FOOTER ==================== */
.site-footer {
    background: #222;
    color: #fff;
    font-size: 16px;
}

.site-footer h5 {
    margin-bottom: 15px;
    text-transform: uppercase;
}

.site-footer a {
    color: #bbb;
    transition: color 0.3s ease-in-out;
    text-decoration: none;
}

.site-footer a:hover {
    color: #fff;
    text-decoration: none;
}

.social-icon {
    color: #bbb;
    font-size: 24px;
    transition: color 0.3s ease-in-out, transform 0.3s;
    display: inline-block;
}

.social-icon:hover {
    color: #fff;
    transform: scale(1.1);
}

hr {
    opacity: 0.2;
}

/* ==================== NEWS TICKER ==================== */
.news-ticker-wrapper {
    width: 100%;
    margin: 0;
    padding: 0;
    background: linear-gradient(90deg, #1a1a2e, #16213e);
    border-top: 1px solid rgba(255,255,255,0.1);
    border-bottom: 1px solid rgba(255,255,255,0.1);
    position: relative;
    z-index: 10;
}

.news-ticker {
    white-space: nowrap;
    overflow: hidden;
    position: relative;
    padding: 10px 0;
    margin: 0;
}

.news-ticker .news-container {
    display: inline-block;
    white-space: nowrap;
    animation: marquee 120s linear infinite;
}

.news-ticker .news-item {
    display: inline-block;
    margin-right: 50px;
    padding: 5px 15px;
    font-weight: bold;
    color: whitesmoke;
    text-decoration: none;
    transition: background 0.3s ease, color 0.3s ease;
}

.news-ticker .news-item:hover {
    background: rgba(255, 255, 255, 0.3);
    color: #ff6600;
}

@keyframes marquee {
    from { transform: translateX(100%); }
    to { transform: translateX(-100%); }
}

/* ==================== TRENDING CAROUSEL ==================== */
.w-40 {
    width: 40%;
    min-width: 120px;
}

.w-60 {
    width: 60%;
}

.carousel-item a {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 15px;
    background: white;
    border-radius: 8px;
    transition: background 0.3s ease-in-out;
    text-decoration: none;
}

.carousel-item a:hover {
    background: #f8f9fa;
}

/* ==================== CATEGORIES ==================== */
.category-card {
    border-radius: 10px;
    min-height: 120px;
    display: flex;
    align-items: center;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    background: white;
    padding: 1rem;
}

.category-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
    background-color: var(--light-color);
}

/* Category Image Styling */
.category-img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 5px;
    border: 2px solid var(--highlight-color);
}

/* "Show More" Link */
.show-more-link {
    font-size: 13px;
    text-decoration: none;
    color: var(--highlight-color);
    transition: color 0.3s;
}

.show-more-link:hover {
    color: var(--accent-color);
    text-decoration: underline;
}

/* ==================== FLOATING RADIO ==================== */
.floating-radio {
    position: fixed;
    bottom: 20px;
    right: 20px;       
    padding: 10px 15px;
    border-radius: 90px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    z-index: 1001;
}

.floating-radio a {
    font-size: 14px;
    font-weight: bold;
    border-radius: 90px;
    transition: background 0.3s ease-in-out;
    text-decoration: none;
    display: inline-block;
    padding: 0.6rem 1.2rem;
}

.floating-radio a:hover {
    background: var(--accent-color) !important;
    color: white;
}

/* ==================== COMMENTS SECTION ==================== */
.comments-section {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #e9ecef;
}

.comment {
    border: 1px solid #e9ecef;
    border-radius: 8px;
    transition: box-shadow 0.2s ease;
    padding: 1rem;
    margin-bottom: 1rem;
}

.comment:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.reply {
    border-left: 3px solid #007bff;
    background-color: #f8f9fa;
    margin-left: 2rem;
    padding: 0.8rem;
}

.reply-form {
    background-color: #f8f9fa;
    padding: 1rem;
    border-radius: 6px;
    border: 1px solid #dee2e6;
    margin-top: 1rem;
}

/* ==================== AVATAR STYLES ==================== */
.avatar-sm {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
}

.avatar-md {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

.avatar-lg {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
}

/* User link styles */
.user-link {
    text-decoration: none;
    color: inherit;
    transition: color 0.2s ease;
}

.user-link:hover {
    color: #007bff;
}

/* ==================== RADIO BUTTON STYLES FOR NAVBAR ==================== */
.nav-radio-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.8rem 1rem;
    font-weight: 500;
    font-size: 0.9rem;
    text-decoration: none;
    border-radius: 25px;
    transition: all 0.2s ease;
    width: 100%;
    margin-top: 0.5rem;
    border: none;
    cursor: pointer;
}

.nav-radio-btn:hover {
    background-color: #dc3545 !important;
    transform: translateY(-1px);
    text-decoration: none;
    color: white;
}

/* Desktop radio button */
.nav-link.bg-danger {
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
}

.nav-link.bg-danger:hover {
    background-color: #dc3545 !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(220, 53, 69, 0.3);
    color: white;
}

/* Ensure buttons don't have outline on focus */
.nav-radio-btn:focus,
.nav-link.bg-danger:focus,
.floating-radio a:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(220, 53, 69, 0.5);
}

/* ==================== MOBILE DROPDOWN FIX ==================== */
@media (max-width: 991.98px) {
    .dropdown-menu {
        position: absolute !important;
        background: white !important;
        border-radius: 12px !important;
        box-shadow: 0 8px 30px rgba(0,0,0,0.2) !important;
        min-width: 220px !important;
    }
    
    .navbar-nav .dropdown-menu {
        left: auto !important;
        right: 0 !important;
    }
    
    /* Ensure dropdown is above mobile menu */
    .navbar-collapse.show .dropdown-menu {
        z-index: 10001 !important;
    }
    
    .navbar-nav {
        padding: 1rem 0;
    }
    
    .card {
        margin-bottom: 1.5rem;
    }
}

/* ==================== RESPONSIVE DESIGN ==================== */
@media (max-width: 768px) {
    .navbar-nav {
        padding: 1rem 0;
    }
    
    .card {
        margin-bottom: 1.5rem;
    }
    
    .category-card {
        min-height: 100px;
    }
    
    .category-img {
        width: 60px;
        height: 60px;
    }
}

@media (max-width: 576px) {
    .category-card {
        min-height: 80px;
    }
    
    .category-img {
        width: 50px;
        height: 50px;
    }
    
    .floating-radio a {
        padding: 0.5rem 1rem;
        font-size: 12px;
    }
}

/* ==================== UTILITY CLASSES ==================== */
.text-accent {
    color: var(--accent-color);
}

.bg-accent {
    background-color: var(--accent-color);
}

.text-primary-custom {
    color: var(--primary-color);
}

.bg-primary-custom {
    background-color: var(--primary-color);
}

/* ==================== ANIMATIONS ==================== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideIn {
    from {
        transform: translateX(-100%);
    }
    to {
        transform: translateX(0);
    }
}

.fade-in {
    animation: fadeIn 0.3s ease;
}

.slide-in {
    animation: slideIn 0.3s ease;
}
