/* =================================== */
/*          Global Styles              */
/* =================================== */
:root {
    --primary-color: #1abc9c; /* Teal/Turquoise */
    --secondary-color: #4a4a4a;
    --highlight-color: #f39c12; /* Yellow for active prayer */
    --light-bg: #f8f9fa;
    --border-color: #dee2e6;
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: #f7fcfc;
    color: var(--secondary-color);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

main {
    flex-grow: 1;
}

/* =================================== */
/*             Header                  */
/* =================================== */
.navbar-brand {
    font-weight: 600;
    color: #34495e !important;
    display: flex;
    align-items: center;
}
.navbar-brand img {
    margin-right: 10px;
}

.breadcrumb-item a {
    text-decoration: none;
    color: var(--primary-color);
}

/* =================================== */
/*       Homepage (City Grid)          */
/* =================================== */
.city-card-wrapper {
    transition: transform 0.2s ease-in-out;
}
.city-card-wrapper:hover {
    transform: translateY(-5px);
}
.card-link {
    text-decoration: none;
    color: inherit;
}
.city-card {
    border: 1px solid var(--border-color);
    transition: box-shadow 0.3s, border-color 0.3s;
}
.city-card:hover {
    box-shadow: 0 8px 20px rgba(0,0,0,0.1) !important;
    border-color: var(--primary-color);
}
.city-card .card-title {
    color: var(--primary-color);
    font-weight: 500;
}

/* =================================== */
/*      City Prayer Times Page         */
/* =================================== */
.prayer-cards-container {
    background-color: #fff;
    padding: 1rem;
    border-radius: 0.5rem;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    flex-wrap: wrap; /* Allow cards to wrap on smaller screens */
}
.prayer-card {
    flex: 1;
    padding: 1rem 0.5rem;
    border-radius: 0.375rem;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}
.prayer-card h6 {
    color: #7f8c8d;
    font-size: 0.9rem;
    text-transform: uppercase;
    font-weight: 500;
}
.prayer-card .time {
    color: #2c3e50;
    margin-bottom: 0.5rem;
}
.prayer-card .remaining-time {
    font-size: 0.8rem;
    color: #fff;
    background-color: var(--highlight-color);
    padding: 0.2rem 0.5rem;
    border-radius: 1rem;
    display: none; /* Hidden by default */
}

/* Active Prayer Card */
.prayer-card.active-prayer {
    background-color: var(--highlight-color);
    color: #fff;
}
.prayer-card.active-prayer h6 {
    color: rgba(255, 255, 255, 0.9);
}
.prayer-card.active-prayer .time {
    color: #fff;
}
.prayer-card.active-prayer .remaining-time {
    display: inline-block; /* Show only on active card */
    background-color: rgba(0, 0, 0, 0.15);
}

/* Timetable */
.namaz-timetable .table {
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}
.namaz-timetable .today-row {
    background-color: #e8f8f5; /* Light teal */
    font-weight: bold;
    color: var(--primary-color);
}
.table > :not(caption) > * > * {
    padding: 1rem 0.5rem; /* Better padding for table cells */
    vertical-align: middle;
}

/* Other Cities Buttons */
.city-link-btn {
    border: 1px solid var(--border-color);
    color: var(--secondary-color);
    transition: all 0.2s ease-in-out;
    font-weight: 500;
}
.city-link-btn:hover {
    background-color: var(--primary-color);
    color: #fff;
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* =================================== */
/*             Footer                  */
/* =================================== */
footer .text-muted {
    transition: color 0.2s ease-in-out;
}
footer a.text-muted:hover {
    color: var(--primary-color) !important;
}

@media (max-width: 767px) {
    .prayer-card {
        flex-basis: 30%; /* 3 cards per row on mobile */
        margin-bottom: 1rem;
    }
}