:root {
    --primary-color: #1abc9c; /* The main teal/green */
    --background-color: #f8f9fa;
    --card-bg-color: #ffffff;
    --text-color: #343a40;
    --text-muted: #6c757d;
    --border-color: #dee2e6;
    --header-footer-text: #ffffff;
    --table-header-bg: #343a40;
    --box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

body {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    margin: 0;
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
}

.main-container {
    max-width: 960px;
    margin: 0 auto;
    padding: 30px 15px;
}

/* Header & Footer */
.main-header, .main-footer {
    background-color: var(--primary-color);
    color: var(--header-footer-text);
}

.main-header .header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 960px;
    margin: 0 auto;
    padding: 15px;
}

/* --- THIS IS THE UPDATED LOGO STYLE --- */
.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    gap: 10px; /* Adds space between the icon and the text */
}

.logo span {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--header-footer-text);
}
/* --- END OF LOGO STYLE UPDATE --- */


.main-header nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 15px;
}

.main-header nav a {
    color: var(--header-footer-text);
    text-decoration: none;
    font-weight: 500;
    padding: 5px 10px;
    border-radius: 5px;
    transition: background-color 0.2s;
}

.main-header nav a:hover, .main-header nav a.active {
    background-color: rgba(255, 255, 255, 0.15);
}

.main-footer {
    text-align: center;
    margin-top: 40px;
    padding: 2rem 1rem;
    font-size: 0.9rem;
}

.main-footer p {
    margin: 5px 0;
}

/* Homepage */
.intro-section {
    text-align: center;
    padding: 40px 0;
}

.intro-section h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.intro-section p {
    color: var(--text-muted);
    font-size: 1.1rem;
}

.search-box {
    width: 100%;
    padding: 15px;
    font-size: 1rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    box-shadow: var(--box-shadow);
    margin: 20px 0 40px;
    box-sizing: border-box; /* Ensures padding doesn't affect width */
}
.search-box:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(26, 188, 156, 0.25);
}

.city-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.city-link {
    background-color: var(--card-bg-color);
    padding: 20px;
    text-align: center;
    text-decoration: none;
    color: var(--text-color);
    border-radius: 8px;
    border: 1px solid var(--border-color);
    font-weight: 600;
    transition: all 0.2s ease-in-out;
}

.city-link:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: var(--box-shadow);
}

/* City Page */
.city-header {
    background-color: var(--primary-color);
    color: var(--header-footer-text);
    padding: 40px 20px;
    border-radius: 8px;
    text-align: center;
    margin-bottom: 30px;
}
.city-header h1 {
    margin: 0 0 10px 0;
    font-size: 3rem;
}
.city-header p {
    margin: 0;
    opacity: 0.9;
    font-size: 1.1rem;
}

.countdown-wrapper {
    background: var(--card-bg-color);
    padding: 30px;
    border-radius: 8px;
    box-shadow: var(--box-shadow);
    text-align: center;
    margin-bottom: 30px;
}
.countdown-wrapper p {
    margin: 0;
    color: var(--text-muted);
    font-size: 1.1rem;
}
#next-prayer-name {
    font-weight: bold;
    color: var(--primary-color);
}
#countdown-timer {
    font-size: 3.5rem;
    font-weight: 700;
    letter-spacing: 2px;
    margin: 10px 0;
}

.section-title {
    text-align: center;
    font-size: 1.8rem;
    margin-bottom: 20px;
    font-weight: 600;
}

.today-times {
    background: var(--card-bg-color);
    border-radius: 8px;
    box-shadow: var(--box-shadow);
    margin-bottom: 30px;
    overflow: hidden;
}
.prayer-row {
    display: flex;
    justify-content: space-between;
    padding: 15px 20px;
    border-bottom: 1px solid var(--border-color);
}
.prayer-row:last-child {
    border-bottom: none;
}
.prayer-row span:first-child {
    font-weight: 600;
}
.prayer-row span:last-child {
    font-weight: 500;
}

.share-buttons {
    text-align: center;
    margin-bottom: 40px;
}
.share-btn {
    display: inline-block;
    background-color: #3498db;
    color: white;
    padding: 12px 25px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 600;
    margin: 0 10px;
    transition: background-color 0.2s;
}
.share-btn.facebook {
    background-color: #3b5998;
}
.share-btn.twitter {
    background-color: #1da1f2;
}
.share-btn:hover {
    opacity: 0.9;
}

.archive-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--card-bg-color);
    box-shadow: var(--box-shadow);
    border-radius: 8px;
    overflow: hidden;
}
.archive-table th, .archive-table td {
    padding: 12px 15px;
    text-align: center;
}
.archive-table thead {
    background-color: var(--table-header-bg);
    color: var(--header-footer-text);
}
.archive-table tbody tr {
    border-bottom: 1px solid var(--border-color);
}
.archive-table tbody tr:last-child {
    border-bottom: none;
}
.archive-table tbody tr:nth-of-type(even) {
    background-color: #f8f9fa;
}

/* Added Content Sections */
.content-section, .suggestions-section {
    background-color: var(--card-bg-color);
    padding: 30px;
    border-radius: 8px;
    box-shadow: var(--box-shadow);
    margin: 40px 0;
}

.content-section p {
    line-height: 1.8;
    color: var(--text-muted);
    max-width: 800px;
    margin: 15px auto; /* Center the paragraphs */
    text-align: center;
}

/* Generic page content for contact/privacy/sitemap pages */
.page-content {
    background-color: var(--card-bg-color);
    padding: 30px;
    border-radius: 8px;
    box-shadow: var(--box-shadow);
    margin: 30px 0;
}
.page-content h1 {
    text-align: center;
}
.sitemap-list {
    list-style-type: none;
    padding: 0;
    columns: 2;
}
.sitemap-list a {
    text-decoration: none;
    color: var(--primary-color);
    display: block;
    padding: 8px;
    border-radius: 4px;
}
.sitemap-list a:hover {
    background-color: #f1f1f1;
}

@media (max-width: 600px) {
    .sitemap-list {
        columns: 1;
    }
}


/* =================================== */
/*  Responsive & Hamburger Menu Styles */
/* =================================== */

/* --- Hamburger Menu Icon --- */
.hamburger-menu {
    display: none; /* Hidden by default on desktop */
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 24px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 10;
}

.hamburger-menu span {
    width: 30px;
    height: 3px;
    background-color: white;
    border-radius: 5px;
    transition: all 0.3s linear;
    transform-origin: 1px;
}

/* Animate hamburger to an 'X' when active */
.hamburger-menu.active span:nth-child(1) {
    transform: rotate(45deg);
}
.hamburger-menu.active span:nth-child(2) {
    opacity: 0;
    transform: translateX(20px);
}
.hamburger-menu.active span:nth-child(3) {
    transform: rotate(-45deg);
}


/* --- Media Queries --- */

/* Tablet and smaller devices (<= 768px) */
@media (max-width: 768px) {
    .main-header .header-content {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
    
    .hamburger-menu {
        display: flex;
    }

    #main-nav {
        display: none;
        position: absolute;
        top: 70px;
        left: 0;
        width: 100%;
        background-color: var(--primary-color);
        box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    }
    
    #main-nav.nav-active {
        display: block;
    }

    #main-nav ul {
        flex-direction: column;
        width: 100%;
    }

    #main-nav li {
        text-align: center;
    }

    #main-nav a {
        display: block;
        padding: 15px;
        width: 100%;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    #main-nav li:last-child a {
        border-bottom: none;
    }

    .city-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .city-header h1 {
        font-size: 2.2rem;
    }

    #countdown-timer {
        font-size: 2.8rem;
    }
    
    .archive-table {
        font-size: 0.9rem;
    }
    
    .archive-table th, .archive-table td {
        padding: 8px 5px;
    }
}


/* Mobile devices (<= 480px) */
@media (max-width: 480px) {
    .city-grid {
        grid-template-columns: 1fr;
    }

    .share-buttons {
        display: flex;
        flex-direction: column;
        gap: 10px;
        align-items: center;
    }

    .share-btn {
        width: 80%;
        margin: 0;
    }
    
    .city-header h1 {
        font-size: 1.8rem;
    }
    
    #countdown-timer {
        font-size: 2.2rem;
    }
    
    .section-title {
        font-size: 1.5rem;
    }
}