/* Compact list styles for postal codes */
.codes-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.code-item {
    border-bottom: 1px solid #eee;
    padding: 0.75rem 0;
}

.code-item:last-child {
    border-bottom: none;
}

.code-link {
    display: flex;
    align-items: baseline;
    text-decoration: none;
    color: #333;
    transition: color 0.2s;
}

.code-link:hover {
    color: #007bff;
}

.code-number {
    font-weight: 600;
    min-width: 80px;
    margin-right: 1rem;
    font-family: 'Courier New', monospace;
}

.code-info {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
    color: #666;
    font-size: 0.9rem;
    flex-wrap: wrap;
}

.code-info .place {
    font-weight: 500;
}

.code-info .lga {
    color: #888;
}

.code-info .multiple-locations {
    font-weight: 500;
    color: #007bff;
}

.code-info .locations {
    font-style: italic;
}

/* Digit list styles for postal codes index */
.digit-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.digit-item {
    border-bottom: 1px solid #eee;
    padding: 0.75rem 0;
}

.digit-item:last-child {
    border-bottom: none;
}

.digit-link {
    display: flex;
    align-items: baseline;
    text-decoration: none;
    color: #333;
    transition: color 0.2s;
}

.digit-link:hover {
    color: #007bff;
}

.digit-number {
    font-weight: 600;
    min-width: 100px;
    margin-right: 1rem;
    font-family: 'Courier New', monospace;
}

.digit-info {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
    color: #666;
    font-size: 0.9rem;
}

/* Multiple locations styles */
.locations-list {
    display: grid;
    gap: 1.5rem;
    margin-top: 1rem;
}

.location-item {
    background: #f8f9fa;
    padding: 1rem;
    border-radius: 8px;
    border: 1px solid #dee2e6;
}

.location-item h3 {
    color: #212529;
    margin-bottom: 0.75rem;
}

.location-item dl {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0.5rem 1rem;
}

.location-item dt {
    font-weight: 600;
    color: #495057;
}

.location-item dd {
    margin: 0;
}

/* Styling for incomplete/unspecified data */
.unspecified-data {
    color: #6c757d;
    font-style: italic;
}

.unknown-state {
    color: #6c757d;
    font-style: italic;
}

/* Instant Search Styles */
.instant-search-container {
    position: relative;
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
}

#hero-search-input {
    width: 100%;
    padding: 15px 20px;
    font-size: 16px;
    border: 2px solid #ddd;
    border-radius: 30px;
    outline: none;
    transition: border-color 0.3s;
}

#hero-search-input:focus {
    border-color: var(--primary-color);
}

#hero-search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    margin-top: 8px;
    max-height: 400px;
    overflow-y: auto;
    display: none;
    z-index: 1000;
}

.search-result-item {
    padding: 12px 20px;
    cursor: pointer;
    transition: background-color 0.2s;
    display: flex;
    flex-direction: column;
    border-bottom: 1px solid #f0f0f0;
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-item:hover,
.search-result-item.selected {
    background-color: #f5f5f5;
}

.search-result-item strong {
    color: var(--primary-color);
    margin-bottom: 4px;
}

.search-result-item .result-details {
    font-size: 14px;
    color: #666;
}

.no-results {
    padding: 20px;
    text-align: center;
    color: #666;
}

#hero-search-loading {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 12px;
    color: #999;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .instant-search-container {
        max-width: 100%;
    }
    
    #hero-search-input {
        font-size: 16px; /* Prevents zoom on iOS */
    }
    
    #hero-search-results {
        max-height: 300px;
    }
}

/* Section spacing */
section {
    margin-bottom: 3rem;
}

.hero {
    margin-bottom: 3rem;
}

.features {
    margin-bottom: 3rem;
}

.info {
    margin-bottom: 3rem;
}

/* Facilities grid - matching states grid */
.facilities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.facility-state-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.5rem;
    transition: box-shadow 0.3s;
}

.facility-state-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.facility-state-card h2 {
    margin-bottom: 1rem;
    font-size: 1.25rem;
}

.facility-state-card h2 a {
    color: var(--primary-color);
    text-decoration: none;
}

.facility-state-card h2 a:hover {
    text-decoration: underline;
}

.facility-info p {
    margin: 0.5rem 0;
    color: #666;
}

.facility-types p {
    font-size: 0.9rem;
    margin: 0.25rem 0;
}

/* Filter section */
.filter-section {
    margin: 3rem 0;
}

.filter-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
}

.filter-btn {
    padding: 0.5rem 1rem;
    background: #f5f5f5;
    border: 1px solid #ddd;
    border-radius: 20px;
    text-decoration: none;
    color: #333;
    transition: all 0.3s;
}

.filter-btn:hover {
    background: #e0e0e0;
}

.filter-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* Global Styles */
:root {
    --primary-color: #008751; /* Nigerian green */
    --secondary-color: #ffffff; /* Nigerian white */
    --accent-color: #00632c; /* Darker green */
    --text-color: #333333;
    --light-gray: #f5f5f5;
    --medium-gray: #e0e0e0;
    --dark-gray: #666666;
    --shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
    --border-radius: 4px;
    --container-width: 1200px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: #f9f9f9;
    font-size: 16px;
}

/* Responsive Typography */
h1 {
    font-size: 2.25rem;
    font-weight: 600;
}

h2 {
    font-size: 1.875rem;
    font-weight: 600;
}

h3 {
    font-size: 1.5rem;
    font-weight: 600;
}

h4 {
    font-size: 1.25rem;
    font-weight: 600;
}

h5 {
    font-size: 1.125rem;
    font-weight: 600;
}

h6 {
    font-size: 1rem;
    font-weight: 600;
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 15px;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--accent-color);
}

h1, h2, h3, h4, h5, h6 {
    margin-bottom: 1rem;
    line-height: 1.3;
}

p {
    margin-bottom: 1rem;
}

img {
    max-width: 100%;
    height: auto;
}

ul {
    list-style-type: none;
}

.button {
    display: inline-block;
    background-color: var(--primary-color);
    color: var(--secondary-color);
    padding: 0.6rem 1.2rem;
    border-radius: var(--border-radius);
    transition: var(--transition);
    border: none;
    cursor: pointer;
    font-weight: 500;
    text-align: center;
}

.button:hover {
    background-color: var(--accent-color);
    color: var(--secondary-color);
}

/* Header Styles */
header {
    background-color: var(--secondary-color);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

header .logo img {
    height: 50px;
    width: auto;
}

header nav {
    display: flex;
    align-items: center;
    gap: 0;
}

header nav a {
    color: var(--text-color);
    font-weight: 500;
    padding: 0.5rem 1rem;
    position: relative;
    transition: var(--transition);
}

header nav a:hover {
    color: var(--primary-color);
}

header nav a:not(:last-child)::after {
    content: '|';
    position: absolute;
    right: 0;
    color: #ddd;
    font-weight: 300;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.logo img {
    height: 50px;
    width: auto;
}

.main-nav ul {
    display: flex;
}

.main-nav li {
    margin-left: 1.5rem;
}

.main-nav a {
    color: var(--text-color);
    font-weight: 500;
}

.main-nav a:hover {
    color: var(--primary-color);
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    height: 24px;
    width: 30px;
    cursor: pointer;
}

.mobile-menu-toggle span {
    height: 3px;
    width: 100%;
    background-color: var(--text-color);
    border-radius: 2px;
    transition: var(--transition);
}

.mobile-menu {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    z-index: 99;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    padding: 2rem;
}

.mobile-menu.active {
    opacity: 1;
    visibility: visible;
}

.mobile-menu ul {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
}

.mobile-menu li {
    margin: 1rem 0;
}

.mobile-menu a {
    color: var(--secondary-color);
    font-size: 1.5rem;
    font-weight: 500;
}

/* Hero Section */
.hero {
    background-color: var(--primary-color);
    color: var(--secondary-color);
    padding: 4rem 0;
    margin-bottom: 2rem;
    text-align: center;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.hero h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    margin-left: 2rem;
    margin-right: 2rem;
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    margin-left: 2rem;
    margin-right: 2rem;
}

.search-container {
    max-width: 600px;
    margin: 0 auto;
    position: relative;
}

.search-container form {
    display: flex;
}

.search-container input {
    flex: 1;
    padding: 12px 20px;
    font-size: 1rem;
    border: none;
    border-radius: var(--border-radius) 0 0 var(--border-radius);
}

.search-container button {
    background-color: var(--accent-color);
    color: var(--secondary-color);
    border: none;
    padding: 0 20px;
    cursor: pointer;
    border-radius: 0 var(--border-radius) var(--border-radius) 0;
    font-weight: 500;
}

.search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: var(--secondary-color);
    border-radius: 0 0 var(--border-radius) var(--border-radius);
    box-shadow: var(--shadow);
    z-index: 10;
    max-height: 400px;
    overflow-y: auto;
    display: none;
}

.search-result-item {
    padding: 10px 15px;
    border-bottom: 1px solid var(--medium-gray);
    cursor: pointer;
    transition: var(--transition);
}

.search-result-item:hover {
    background-color: var(--light-gray);
}

.search-result-item:last-child {
    border-bottom: none;
}

/* Browse Sections */
.browse-sections {
    margin: 2rem 0;
}

.browse-section {
    margin-bottom: 3rem;
}

.browse-section h2 {
    text-align: center;
    margin-bottom: 1.5rem;
    color: var(--primary-color);
}

.browse-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.browse-card {
    background-color: var(--secondary-color);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--shadow);
    transition: var(--transition);
    display: block;
}

.browse-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.browse-card h3 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.browse-card p {
    color: var(--dark-gray);
    font-size: 0.9rem;
    margin-bottom: 0;
}

.view-all {
    text-align: center;
}

/* Alphabet Navigation */
.alphabet-nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.alphabet-nav .letter {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    margin: 0.25rem;
    background-color: var(--secondary-color);
    color: var(--primary-color);
    border-radius: var(--border-radius);
    font-weight: 500;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.alphabet-nav .letter:hover {
    background-color: var(--primary-color);
    color: var(--secondary-color);
}

/* Info Section */
.info-section {
    background-color: var(--light-gray);
    padding: 3rem 0;
    margin: 2rem 0;
}

.info-section h2 {
    text-align: center;
    margin-bottom: 2rem;
    color: var(--primary-color);
}

.info-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2rem;
}

.info-text {
    flex: 1;
    max-width: 600px;
}

.info-stats {
    display: flex;
    gap: 1rem;
}

.stat-card {
    background-color: var(--secondary-color);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--shadow);
    text-align: center;
    flex: 1;
    min-width: 120px;
}

.stat-card h3 {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.stat-card p {
    color: var(--dark-gray);
    margin-bottom: 0;
}

.info-actions {
    margin-top: 1.5rem;
}

/* Content Pages */
.page-header {
    background-color: var(--primary-color);
    color: var(--secondary-color);
    padding: 2rem 0;
    margin-bottom: 2rem;
    text-align: center;
}

.page-header h1 {
    margin-bottom: 0.5rem;
}

.content-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

.main-content {
    background-color: var(--secondary-color);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--shadow);
}

.section {
    margin-bottom: 2rem;
}

.section:last-child {
    margin-bottom: 0;
}

.section h2 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--medium-gray);
}

.sidebar {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.sidebar > div {
    background-color: var(--secondary-color);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--shadow);
}

.map-container {
    width: 100%;
}

.map {
    width: 100%;
    height: 300px;
    background-color: var(--light-gray);
    margin-top: 1rem;
    border-radius: var(--border-radius);
}

.info-card h3, .search-card h3, .related-links h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.info-list li {
    margin-bottom: 0.5rem;
}

.info-list li:last-child {
    margin-bottom: 0;
}

.input-group {
    display: flex;
}

.input-group input {
    flex: 1;
    padding: 0.6rem;
    border: 1px solid var(--medium-gray);
    border-radius: var(--border-radius) 0 0 var(--border-radius);
}

.input-group button {
    background-color: var(--primary-color);
    color: var(--secondary-color);
    border: none;
    padding: 0 1rem;
    cursor: pointer;
    border-radius: 0 var(--border-radius) var(--border-radius) 0;
}

.related-links ul li {
    margin-bottom: 0.5rem;
}

/* States, LGAs, Localities Lists */
.states-grid, .lga-grid, .locality-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.state-card, .lga-card, .locality-card {
    background-color: var(--secondary-color);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

/* Slimmer state cards on states index */
.states-grid .state-card {
    padding: 1rem 1.25rem;
}

.states-grid .state-card h2 {
    font-size: 1.1rem;
    margin-bottom: 0.75rem;
}

.states-grid .state-card h2 a {
    text-decoration: none;
    transition: color 0.2s ease;
}

.states-grid .state-card h2 a:hover {
    color: #004d2e; /* Darker green for better contrast */
    text-decoration: underline;
    font-weight: 600;
}

/* LGA cards styling similar to state cards */
.lga-grid .lga-card {
    padding: 1rem 1.25rem;
}

.lga-grid .lga-card h3 {
    font-size: 1rem;
    margin-bottom: 0.5rem;
}

.lga-grid .lga-card h3 a {
    text-decoration: none;
    transition: color 0.2s ease;
}

.lga-grid .lga-card h3 a:hover {
    color: #004d2e; /* Darker green for better contrast */
    text-decoration: underline;
    font-weight: 600;
}

/* LGA stats similar to state stats */
.lga-stats {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    font-size: 0.85rem;
    color: #666;
    margin-top: 0.5rem;
}

.lga-stats .stat {
    font-weight: 500;
    white-space: nowrap;
}

.lga-stats .stat:not(:last-child)::after {
    content: " •";
    margin-left: 1rem;
    font-weight: normal;
    color: #ccc;
}

/* State and LGA page summary stats */
.state-summary, .lga-summary {
    display: flex;
    gap: 2rem;
    margin: 1.5rem 0;
    padding: 1.5rem;
    background-color: var(--secondary-color);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
}

.summary-stat {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 2rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 0.25rem;
}

.stat-label {
    display: block;
    font-size: 0.9rem;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* State link on LGA pages */
.state-link {
    margin-top: -0.5rem;
    color: #666;
    font-size: 0.95rem;
}

.state-link a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
}

.state-link a:hover {
    text-decoration: underline;
}

/* Facilities, PO Boxes, and Locations tables */
.facilities-list table,
.po-boxes-list table,
.locations-table table {
    width: 100%;
    margin-top: 1rem;
}

.facilities-list th,
.po-boxes-list th,
.locations-table th {
    background-color: var(--light-gray);
    padding: 0.75rem;
    text-align: left;
    font-weight: 600;
    color: #333;
}

.facilities-list td,
.po-boxes-list td,
.locations-table td {
    padding: 0.75rem;
    border-bottom: 1px solid #eee;
}

.facilities-list tr:last-child td,
.po-boxes-list tr:last-child td,
.locations-table tr:last-child td {
    border-bottom: none;
}

/* Locations table specific styles */
.locations-table {
    margin-bottom: 2rem;
}

.locations-table .location-place {
    font-weight: 500;
}

.locations-table a {
    color: var(--primary-color);
    text-decoration: none;
}

.locations-table a:hover {
    text-decoration: underline;
}

.locations-table .unspecified-data,
.locations-table .unknown-state {
    color: #999;
    font-style: italic;
}

.state-card:hover, .lga-card:hover, .locality-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.state-card h2, .lga-card h3, .locality-card h3 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

/* Simplified state stats */
.state-stats {
    display: flex;
    gap: 1.5rem;
    margin-top: 0.5rem;
    font-size: 0.9rem;
    color: #666;
}

.state-stats .stat {
    font-weight: 500;
}

.state-stats .stat:first-child::after {
    content: " LGAs";
    font-weight: normal;
}

.state-stats .stat:last-child::after {
    content: " codes";
    font-weight: normal;
}

.postal-code-badge {
    display: inline-block;
    background-color: var(--light-gray);
    padding: 0.4rem 0.8rem;
    border-radius: var(--border-radius);
    margin: 0.25rem;
    font-weight: 500;
    transition: var(--transition);
}

.postal-code-badge:hover {
    background-color: var(--primary-color);
    color: var(--secondary-color);
}

.postal-codes-list {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

/* Breadcrumbs */
.breadcrumbs-container {
    margin-bottom: 1.5rem;
}

.breadcrumbs {
    background-color: var(--light-gray);
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
}

.breadcrumbs ol {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
}

.breadcrumbs li {
    display: flex;
    align-items: center;
}

.breadcrumbs li:not(:last-child)::after {
    content: '›';
    margin: 0 0.5rem;
    color: var(--dark-gray);
}

.breadcrumbs a {
    color: var(--primary-color);
}

.breadcrumbs li:last-child {
    color: var(--dark-gray);
}

/* Map Styles */
.map-section {
    margin: 2rem 0;
}

.map-container {
    border: 1px solid var(--medium-gray);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

#map {
    width: 100%;
    height: 400px;
    z-index: 1;
}

@media (max-width: 768px) {
    #map {
        height: 300px;
    }
}

.map-note {
    margin-top: 0.5rem;
    text-align: center;
    color: var(--dark-gray);
    font-style: italic;
}

/* Postal Code Index Styles */
.digit-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 1rem;
}

.digit-item {
    border: 1px solid var(--medium-gray);
    border-radius: var(--border-radius);
    transition: var(--transition);
}

.digit-item:hover {
    border-color: var(--primary-color);
    box-shadow: var(--shadow);
}

.digit-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.5rem;
    text-decoration: none;
    color: var(--text-color);
}

.digit-number {
    font-weight: 600;
    font-size: 1.1rem;
    color: var(--primary-color);
}

.digit-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--dark-gray);
}

.code-count {
    font-weight: 500;
}

.description {
    font-size: 0.9rem;
}

/* Postal Codes Table */
.postal-codes-table {
    overflow-x: auto;
    margin-bottom: 2rem;
}

.postal-codes-table table {
    width: 100%;
    border-collapse: collapse;
    background-color: var(--secondary-color);
    box-shadow: var(--shadow);
    border-radius: var(--border-radius);
    overflow: hidden;
}

.postal-codes-table th,
.postal-codes-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--light-gray);
}

.postal-codes-table th {
    background-color: var(--primary-color);
    color: var(--secondary-color);
    font-weight: 600;
}

.postal-codes-table tr:last-child td {
    border-bottom: none;
}

.postal-codes-table tr:hover {
    background-color: #f8f8f8;
}

.postal-codes-table .postal-code {
    font-weight: 500;
}

.postal-codes-table .postal-code a {
    color: var(--primary-color);
    text-decoration: none;
}

.postal-codes-table .postal-code a:hover {
    text-decoration: underline;
}

/* Footer */
footer {
    background-color: var(--primary-color);
    color: var(--secondary-color);
    padding: 2rem 0 1rem;
    margin-top: 2rem;
}

.footer-content {
    display: flex;
    flex-direction: column;
}

.footer-links {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.footer-column {
    flex: 1;
    min-width: 200px;
    margin-bottom: 1.5rem;
}

.footer-column h3 {
    color: var(--secondary-color);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.footer-column ul li {
    margin-bottom: 0.5rem;
}

.footer-column a {
    color: rgba(255, 255, 255, 0.8);
}

.footer-column a:hover {
    color: var(--secondary-color);
}

#footer-search-form {
    margin-top: 0.5rem;
}

.footer-bottom {
    text-align: center;
}

.footer-bottom p {
    margin: 0.25rem 0;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.9);
}

.footer-bottom p:first-child {
    font-weight: 500;
}

.footer-copyright {
    text-align: center;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
}

.footer-copyright a {
    color: var(--secondary-color);
    text-decoration: underline;
}

/* Medium screens and tablets */
@media (max-width: 1024px) {
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.625rem;
    }
    
    h3 {
        font-size: 1.375rem;
    }
    
    h4 {
        font-size: 1.125rem;
    }
    
    h5, h6 {
        font-size: 1rem;
    }
    
    body {
        font-size: 15px;
    }
}

/* Responsive Styles */
@media (max-width: 768px) {
    /* Typography for tablets and small screens */
    h1 {
        font-size: 1.75rem;
    }
    
    h2 {
        font-size: 1.5rem;
    }
    
    h3 {
        font-size: 1.25rem;
    }
    
    h4 {
        font-size: 1.125rem;
    }
    
    h5, h6 {
        font-size: 1rem;
    }
    
    body {
        font-size: 14px;
    }
    header nav {
        display: none;
    }
    
    header .container {
        padding: 0.75rem 0;
    }
    
    header .logo img {
        height: 40px;
    }
    
    .main-nav {
        display: none;
    }
    
    .mobile-menu-toggle {
        display: flex;
    }
    
    .hero {
        padding: 2.5rem 0;
    }
    
    .hero h1 {
        font-size: 1.75rem;
        margin-left: 1.5rem;
        margin-right: 1.5rem;
    }
    
    .hero p {
        font-size: 1.1rem;
        margin-left: 1.5rem;
        margin-right: 1.5rem;
    }
    
    .content-grid {
        grid-template-columns: 1fr;
    }
    
    .info-content {
        flex-direction: column;
    }
    
    .footer-links {
        flex-direction: column;
    }
    
    .footer-column {
        margin-bottom: 2rem;
    }
    
    /* Make table responsive on mobile */
    .postal-codes-table {
        font-size: 0.9rem;
    }
    
    .postal-codes-table th,
    .postal-codes-table td {
        padding: 0.5rem;
    }
}

@media (max-width: 480px) {
    /* Typography for mobile phones */
    h1 {
        font-size: 1.5rem;
    }
    
    h2 {
        font-size: 1.25rem;
    }
    
    h3 {
        font-size: 1.125rem;
    }
    
    h4, h5, h6 {
        font-size: 1rem;
    }
    
    body {
        font-size: 14px;
    }
    
    .hero h1 {
        font-size: 1.5rem;
        margin-left: 1rem;
        margin-right: 1rem;
    }
    
    .hero p {
        font-size: 1rem;
        margin-left: 1rem;
        margin-right: 1rem;
    }
    
    /* Improve readability on small screens */
    .container {
        padding: 0 1rem;
    }
    
    /* Card and section spacing adjustments */
    .state-card, .lga-card, .locality-card {
        padding: 1rem;
    }
    
    .state-summary, .lga-summary {
        flex-direction: column;
        gap: 1rem;
        padding: 1rem;
    }
    
    .summary-stat {
        text-align: left;
    }
    
    /* Table improvements for mobile */
    .postal-codes-table {
        font-size: 0.8rem;
    }
    
    .postal-codes-table th,
    .postal-codes-table td {
        padding: 0.4rem;
    }
    
    .search-container form {
        flex-direction: column;
    }
    
    .search-container input {
        border-radius: var(--border-radius) var(--border-radius) 0 0;
    }
    
    .search-container button {
        border-radius: 0 0 var(--border-radius) var(--border-radius);
        padding: 0.6rem;
    }
    
    .browse-grid {
        grid-template-columns: 1fr;
    }
    
    .alphabet-nav .letter {
        width: 35px;
        height: 35px;
        font-size: 0.9rem;
    }
}