/* ==========================================================================
   MASTER STYLESHEET - ASIAN NEWS FLOW
   DYNAMIC LIGHT & DARK MODE SUPPORT
   ========================================================================== */

:root {
    /* Default: Light Mode */
    --bg-main: #ffffff;
    --bg-secondary: #f4f7f6;
    --text-main: #111111;
    --text-muted: #555555;
    --border-color: #e0e0e0;
    --header-bg: #ffffff;
    --topbar-bg: #0044cc;
    --primary-color: #ff0033;
    --secondary-color: #0044cc;
    --card-bg: #ffffff;
    --card-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

[data-theme="dark"] {
    /* Night / Dark Mode */
    --bg-main: #0a0a0a;
    --bg-secondary: #111111;
    --text-main: #ffffff;
    --text-muted: #aaaaaa;
    --border-color: #222222;
    --header-bg: #111111;
    --topbar-bg: #000000;
    --primary-color: #ff0033;
    --secondary-color: #00aaff;
    --card-bg: #151515;
    --card-shadow: 0 5px 15px rgba(0,0,0,0.5);
}

/* Base Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    transition: background-color 0.3s ease, color 0.3s ease;
    overflow-x: hidden;
}

a { text-decoration: none; color: inherit; transition: 0.3s ease; }
a:hover { color: var(--primary-color); }
ul { list-style: none; }

/* ==========================================================================
   HEADER & NAVIGATION (Hindustan Metro Style)
   ========================================================================== */

.top-bar {
    background: var(--topbar-bg);
    color: #ffffff;
    padding: 8px 20px;
    font-size: 13px;
    font-weight: bold;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.main-header {
    background: var(--header-bg);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: background-color 0.3s ease;
}

.navbar-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    max-width: 1300px;
    margin: 0 auto;
}

.brand-logo img {
    max-height: 45px;
    transition: transform 0.3s ease;
}

.desktop-menu {
    display: flex;
    gap: 25px;
    align-items: center;
}

.desktop-menu a {
    color: var(--text-main);
    font-weight: 800;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.desktop-menu a:hover {
    color: var(--primary-color);
}

.nav-actions {
    display: flex;
    gap: 20px;
    align-items: center;
}

.nav-actions i {
    font-size: 18px;
    color: var(--text-main);
    cursor: pointer;
}

.nav-actions i:hover { color: var(--primary-color); }
.mobile-toggle { display: none; font-size: 24px; color: var(--text-main); cursor: pointer; }

/* ==========================================================================
   BREAKING NEWS TICKER
   ========================================================================== */
.breaking-ticker {
    display: flex;
    background: var(--card-bg);
    border-bottom: 1px solid var(--border-color);
}
.ticker-label {
    background: var(--primary-color);
    color: #ffffff;
    font-weight: 900;
    padding: 10px 20px;
    display: flex;
    align-items: center;
    text-transform: uppercase;
    font-size: 14px;
    letter-spacing: 1px;
}
.ticker-content {
    flex-grow: 1;
    overflow: hidden;
    white-space: nowrap;
    padding: 10px;
    font-weight: 700;
    font-size: 15px;
    color: var(--text-main);
}
.ticker-content a { color: var(--text-main); margin-right: 40px; }
.ticker-content a:hover { text-decoration: underline; color: var(--primary-color); }

/* ==========================================================================
   MOBILE SIDEBAR (Off-Canvas Menu)
   ========================================================================== */
.mobile-sidebar {
    position: fixed;
    top: 0; left: -320px;
    width: 280px; height: 100vh;
    background: var(--header-bg);
    z-index: 2000;
    transition: left 0.4s ease;
    overflow-y: auto;
    border-right: 1px solid var(--border-color);
    box-shadow: 5px 0 15px rgba(0,0,0,0.5);
}
.mobile-sidebar.active { left: 0; }
.sidebar-header {
    padding: 20px; display: flex; justify-content: space-between; align-items: center;
    border-bottom: 1px solid var(--border-color);
}
.sidebar-header img { max-height: 35px; }
.close-sidebar { font-size: 24px; color: var(--primary-color); cursor: pointer; }

.sidebar-menu li a {
    display: block; padding: 15px 25px; color: var(--text-main);
    font-size: 15px; font-weight: bold; border-bottom: 1px solid var(--border-color);
    text-transform: uppercase;
}
.sidebar-menu li a:hover { color: var(--primary-color); padding-left: 30px; }

.sidebar-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.7); z-index: 1999; display: none;
}
.sidebar-overlay.active { display: block; }

/* ==========================================================================
   MOBILE BOTTOM APP NAVIGATION
   ========================================================================== */
.bottom-nav {
    display: none;
    position: fixed; bottom: 0; left: 0; width: 100%;
    background: var(--header-bg);
    border-top: 1px solid var(--border-color);
    z-index: 1500; justify-content: space-around; padding: 10px 0;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
}
.bottom-nav-item {
    display: flex; flex-direction: column; align-items: center;
    color: var(--text-muted); font-size: 11px; font-weight: bold;
}
.bottom-nav-item i { font-size: 20px; margin-bottom: 4px; }
.bottom-nav-item.active, .bottom-nav-item:hover { color: var(--primary-color); }

/* ==========================================================================
   RESPONSIVE LOGIC (Tablet & Mobile)
   ========================================================================== */
@media (max-width: 991px) {
    .top-bar { display: none; }
    .desktop-menu { display: none; }
    .mobile-toggle { display: block; }
    .bottom-nav { display: flex; }
    body { padding-bottom: 60px; } /* Space for bottom nav */
}