:root {
    --primary-color: #0047ab;
    --bg-color: #f2f4f7;
    --text-main: #1c1c1e;
    --text-muted: #6e6e73;
    --card-bg: #ffffff;
    --border-radius: 16px;
    --shadow: 0 4px 12px rgba(0,0,0,0.05);
    --alert-bg: #d32f2f;
    --border-color: #eee;
    --nav-bg: rgba(255, 255, 255, 0.95);
}

/* Dark Mode Variables */
body.dark-mode {
    --primary-color: #60a5fa; /* Πιο φωτεινό μπλε για σκούρο φόντο */
    --bg-color: #121212;
    --text-main: #f2f2f7;
    --text-muted: #a1a1aa;
    --card-bg: #1e1e24;
    --shadow: 0 4px 12px rgba(0,0,0,0.3);
    --border-color: #333;
    --nav-bg: rgba(30, 30, 36, 0.95);
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; transition: background-color 0.3s, color 0.3s; }

body { background-color: var(--bg-color); color: var(--text-main); padding-bottom: 80px; }

/* Ticker */
.ticker { background-color: var(--alert-bg); color: white; padding: 10px 15px; display: flex; align-items: center; gap: 10px; font-size: 0.85rem; font-weight: bold; position: sticky; top: 0; z-index: 1000; }
.ticker.hidden { display: none; }
.ticker-label { white-space: nowrap; background: rgba(0,0,0,0.2); padding: 2px 8px; border-radius: 4px; }
.ticker-wrap { overflow: hidden; width: 100%; }
.ticker-move { display: inline-block; white-space: nowrap; padding-left: 100%; animation: ticker 15s linear infinite; }
.ticker-move a { color: white; text-decoration: underline; }
@keyframes ticker { 0% { transform: translate3d(0, 0, 0); } 100% { transform: translate3d(-100%, 0, 0); } }

/* Header */
header { text-align: center; padding: 30px 20px 20px; background-color: var(--bg-color); }
.header-content { display: flex; align-items: center; justify-content: center; gap: 10px; margin-bottom: 5px; color: var(--primary-color); }
header h1 { font-size: 2rem; font-weight: 800; letter-spacing: -0.5px; }
header p { color: var(--text-muted); font-size: 0.95rem; }

/* Tabs */
.tab-content { display: none; }
.tab-content.active { display: block; animation: fadeIn 0.3s; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: translateY(0); } }

/* Main Content */
.main-content { padding: 15px; max-width: 600px; margin: 0 auto; display: flex; flex-direction: column; gap: 15px; }

/* Cards */
.card { background-color: var(--card-bg); border-radius: var(--border-radius); box-shadow: var(--shadow); padding: 20px; overflow: hidden; }
.card-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 15px; border-bottom: 1px solid var(--border-color); padding-bottom: 10px; }
.header-title { display: flex; align-items: center; gap: 8px; color: var(--primary-color); }
.header-title h2 { font-size: 1.1rem; font-weight: 700; color: var(--text-main); }
.badge { background-color: rgba(0, 71, 171, 0.1); color: var(--primary-color); font-size: 0.75rem; font-weight: 600; padding: 4px 10px; border-radius: 20px; }
.timestamp { font-size: 0.75rem; color: var(--text-muted); }

/* Buttons */
.primary-btn { width: 100%; padding: 14px; background: var(--primary-color); color: white; border: none; border-radius: 12px; font-size: 1rem; font-weight: 600; cursor: pointer; display: flex; justify-content: center; align-items: center; }
.primary-btn:active { opacity: 0.8; }
.helper-text { font-size: 0.85rem; color: var(--text-muted); text-align: center; margin-top: 10px; }

/* Weather */
.weather-main { display: flex; align-items: center; justify-content: space-between; }
.temp-large { font-size: 3rem; font-weight: bold; color: var(--text-main); }
.weather-details p { font-size: 0.9rem; color: var(--text-muted); margin-bottom: 4px; }

/* Travel Routes */
.routes-scroll { display: flex; overflow-x: auto; gap: 12px; padding-bottom: 5px; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; }
.routes-scroll::-webkit-scrollbar { display: none; }
.route-item { flex: 0 0 120px; scroll-snap-align: start; background: var(--bg-color); border: 1px solid var(--border-color); border-radius: 12px; padding: 12px; text-align: center; }
.route-name { font-size: 0.8rem; font-weight: 600; color: var(--text-muted); margin-bottom: 8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.route-time { font-size: 1.4rem; font-weight: bold; color: var(--primary-color); margin-bottom: 2px; }
.route-dist { font-size: 0.75rem; color: var(--text-muted); }

/* Lists */
.eq-list { list-style: none; display: flex; flex-direction: column; gap: 12px; }
.eq-list li { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--border-color); padding-bottom: 10px; }
.eq-list li:last-child { border-bottom: none; padding-bottom: 0; }
.eq-info { font-size: 0.95rem; }
.eq-info strong { font-weight: 600; }
.eq-info small { color: var(--text-muted); font-size: 0.8rem; }
.eq-mag { padding: 6px 10px; border-radius: 8px; font-weight: bold; font-size: 0.85rem; white-space: nowrap; color: white; background-color: #2ecc71; }

/* Traffic Alert Box */
.traffic-alert { background-color: rgba(231, 76, 60, 0.1); border-left: 4px solid #e74c3c; padding: 10px; margin-bottom: 15px; border-radius: 4px; text-align: left; }
.traffic-alert p { color: #e74c3c; font-weight: bold; margin: 0 0 5px 0; font-size: 0.9rem; }
.traffic-alert a { color: #e74c3c; text-decoration: underline; font-size: 0.85rem; }
.traffic-alert small { color: var(--text-muted); font-size: 0.75rem; display: block; margin-top: 5px; }

/* Bottom Navigation */
.bottom-nav { position: fixed; bottom: 0; left: 0; width: 100%; background: var(--nav-bg); backdrop-filter: blur(10px); display: flex; justify-content: space-around; padding: 10px 0 20px; border-top: 1px solid var(--border-color); z-index: 1000; }
.nav-item { display: flex; flex-direction: column; align-items: center; text-decoration: none; color: var(--text-muted); font-size: 0.75rem; gap: 4px; }
.nav-item.active { color: var(--primary-color); font-weight: 600; }

/* Drawer (Side Menu) */
.drawer-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.5); z-index: 1001; opacity: 1; transition: opacity 0.3s; }
.drawer-overlay.hidden { opacity: 0; pointer-events: none; }
.drawer { position: fixed; top: 0; left: 0; width: 80%; max-width: 320px; height: 100%; background: var(--card-bg); z-index: 1002; transform: translateX(0); transition: transform 0.3s ease; box-shadow: 2px 0 10px rgba(0,0,0,0.1); display: flex; flex-direction: column; }
.drawer.hidden { transform: translateX(-100%); }
.drawer-header { display: flex; justify-content: space-between; align-items: center; padding: 20px; border-bottom: 1px solid var(--border-color); }
.drawer-header h2 { font-size: 1.2rem; color: var(--text-main); }
.close-btn { background: none; border: none; font-size: 1.5rem; color: var(--text-muted); cursor: pointer; }
.drawer-content { padding: 20px; overflow-y: auto; flex: 1; }
.drawer-item { display: flex; justify-content: space-between; align-items: center; margin-bottom: 15px; font-weight: 600; }
.drawer-separator { height: 1px; background: var(--border-color); margin: 20px 0; }
.drawer-section h3 { font-size: 1rem; margin-bottom: 10px; color: var(--primary-color); }
.text-input { width: 100%; padding: 12px; border: 1px solid var(--border-color); border-radius: 8px; background: var(--bg-color); color: var(--text-main); font-size: 1rem; }

/* Toggle Switch */
.switch { position: relative; display: inline-block; width: 50px; height: 28px; }
.switch input { opacity: 0; width: 0; height: 0; }
.slider { position: absolute; cursor: pointer; top: 0; left: 0; right: 0; bottom: 0; background-color: #ccc; transition: .4s; }
.slider:before { position: absolute; content: ""; height: 20px; width: 20px; left: 4px; bottom: 4px; background-color: white; transition: .4s; }
input:checked + .slider { background-color: var(--primary-color); }
input:checked + .slider:before { transform: translateX(22px); }
.slider.round { border-radius: 34px; }
.slider.round:before { border-radius: 50%; }