/* Base Styles */
:root {
    --primary-color: #2563eb;
    --primary-dark: #1d4ed8;
    --secondary-color: #1e40af;
    --text-color: #1f2937;
    --light-gray: #f3f4f6;
    --medium-gray: #9ca3af;
    --dark-gray: #4b5563;
    --white: #ffffff;
    --focus-outline: 2px solid #3b82f6;
    --focus-outline-offset: 2px;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --transition: all 0.3s ease;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--white);
}

.container {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Skip link styles for keyboard navigation */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--primary-color);
    color: white;
    padding: 8px;
    z-index: 100;
    transition: top 0.3s;
}

.skip-link:focus {
    top: 0;
}

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

a:focus-visible {
    outline: var(--focus-outline);
    outline-offset: var(--focus-outline-offset);
    border-radius: 2px;
}

button:focus-visible,
[tabindex="0"]:focus-visible {
    outline: var(--focus-outline);
    outline-offset: var(--focus-outline-offset);
    border-radius: 4px;
}

ul {
    list-style: none;
}

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

/* Header */
.header {
    background-color: var(--white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 1rem 0;
}

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

.logo a {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--text-color);
    text-decoration: none;
    letter-spacing: -1px;
    line-height: 1.1;
}

.main-nav ul {
    display: flex;
    gap: 2rem;
}

.main-nav a {
    font-weight: 500;
    color: var(--dark-gray);
    position: relative;
    padding: 0.5rem 0;
}

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

.main-nav a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background-color: var(--primary-color);
    transition: var(--transition);
}

.main-nav a:hover::after,
.main-nav a:focus::after {
    width: 100%;
}

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.mobile-menu-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--text-color);
    margin: 5px 0;
    transition: var(--transition);
}

/* Hero Section */
.hero {
    position: relative;
    padding: 5rem 0 4rem;
    text-align: center;
    color: white;
    background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.7)), url('../images/hero-bg.jpg') no-repeat center center/cover;
    background-attachment: fixed;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
}

.hero .container {
    position: relative;
    z-index: 2;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.hero h1 {
    font-size: 3.5rem;
    margin: -0.5rem auto 1.5rem;
    max-width: 1000px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: -0.5px;
    transform: translateY(-0.5em);
}

.hero-intro {
    font-size: 1.5rem;
    max-width: 800px;
    margin: 0 auto 2.5rem;
    line-height: 1.4;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
    font-weight: 400;
}

@media (max-width: 1024px) {
    .stats {
        flex-wrap: wrap;
        max-width: 800px;
    }
    
    .stat {
        min-width: 120px;
        margin-bottom: 1rem;
    }
}

@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.5rem;
        padding: 0 1rem;
    }
    
    .stats {
        gap: 1rem;
    }
    
    .stat {
        padding: 0.8rem 0.5rem;
        min-width: 90px;
    }
    
    .stat-number {
        font-size: 1.5rem;
    }
    
    .stat-label {
        font-size: 0.8rem;
    }
}

.stats {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin: 3rem auto 0;
    flex-wrap: nowrap;
    max-width: 1200px;
    padding: 0 1rem;
}

.stat {
    text-align: center;
    background: rgba(255, 255, 255, 0.1);
    padding: 1rem 1.2rem;
    border-radius: 8px;
    backdrop-filter: blur(5px);
    min-width: 100px;
    flex: 1;
    max-width: 200px;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.2s ease, background 0.2s ease;
}

.clickable-stat {
    position: relative;
    overflow: hidden;
}

.clickable-stat .click-effect {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.4);
    transform: scale(0);
    pointer-events: none;
    width: 100px;
    height: 100px;
    margin-top: -50px;
    margin-left: -50px;
    opacity: 0;
    transition: opacity 0.6s, transform 0.6s;
}

.clickable-stat:active {
    transform: scale(0.95);
}

.click-arrow {
    position: absolute;
    bottom: 6px;
    right: 8px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.8);
    opacity: 0.7;
    transition: all 0.3s ease;
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-5px);
    }
    60% {
        transform: translateY(-3px);
    }
}

.clickable-stat:hover .click-arrow {
    opacity: 1;
    transform: scale(1.1);
}

@keyframes ripple {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

.stat-number {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    line-height: 1.1;
}

.stat-label {
    font-size: 0.95rem;
    font-weight: 600;
    opacity: 0.9;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Main Content */
.main-content {
    padding: 4rem 0;
}

.category {
    margin-bottom: 4rem;
}

.category h2 {
    font-size: 1.8rem;
    margin: 0 auto 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--light-gray);
    color: var(--text-color);
    text-align: center;
    max-width: 90%;
}

.cards {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    margin-top: 2rem;
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 1.5rem;
}

@media (max-width: 1200px) {
    .cards {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .cards {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .cards {
        grid-template-columns: 1fr;
    }
}

.card {
    background: transparent;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    position: relative;
    aspect-ratio: 4/3; /* Makes it horizontal rectangle */
    display: flex;
    align-items: flex-end;
    padding: 0;
    margin: 0;
}

.card::before {
    content: attr(data-number);
    position: absolute;
    top: 10px;
    left: 10px;
    background-color: rgba(0, 0, 0, 0.7);
    color: white;
    font-size: 0.8rem;
    font-weight: bold;
    padding: 4px 8px;
    border-radius: 4px;
    z-index: 2;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.card:hover {
    transform: scale(1.02);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.card-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--light-gray);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 1;
}

.card h3 {
    position: relative;
    display: block;
    width: 100%;
    margin: 0.5rem 0 1rem;
    padding: 0.6rem 0.5rem;
    font-size: 1.2rem;
    color: white;
    text-align: center;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding: 0.4rem 0.5rem;
    z-index: 2;
    box-sizing: border-box;
    letter-spacing: 0.02em;
    transition: all 0.3s ease;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8);
}

.card:hover h3 {
    transform: scale(1.03);
}

/* Footer */
.footer {
    background-color: #1f2937;
    color: var(--white);
    padding: 4rem 0 2rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.footer-section h3 {
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
    position: relative;
    padding-bottom: 0.75rem;
}

.footer-section h3::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 50px;
    height: 2px;
    background-color: var(--primary-color);
}

.footer-section p {
    margin-bottom: 1rem;
    color: #d1d5db;
}

.footer-section ul li {
    margin-bottom: 0.75rem;
}

.footer-section a {
    color: #d1d5db;
    transition: var(--transition);
}

.footer-section a:hover {
    color: var(--primary-color);
    padding-left: 5px;
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: var(--white);
    font-size: 1.1rem;
    transition: var(--transition);
}

.social-links a:hover {
    background-color: var(--primary-color);
    transform: translateY(-3px);
}

.footer-bottom {
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-bottom p {
    color: #9ca3af;
    font-size: 0.9rem;
}

/* Responsive Styles */
@media (max-width: 992px) {
    .hero h1 {
        font-size: 2.2rem;
    }
    
    .stats {
        gap: 2rem;
    }
}

/* Visually hidden but accessible to screen readers */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Mobile menu styles */
@media (max-width: 768px) {
    .mobile-menu-toggle {
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        width: 30px;
        height: 21px;
        background: transparent;
        border: none;
        cursor: pointer;
        padding: 0;
        z-index: 10;
    }
    
    .mobile-menu-toggle span {
        width: 100%;
        height: 3px;
        background: var(--primary-color);
        border-radius: 3px;
        transition: all 0.3s ease;
    }
    
    .mobile-menu-toggle[aria-expanded="true"] span:nth-child(1) {
        transform: translateY(9px) rotate(45deg);
    }
    
    .mobile-menu-toggle[aria-expanded="true"] span:nth-child(2) {
        opacity: 0;
    }
    
    .mobile-menu-toggle[aria-expanded="true"] span:nth-child(3) {
        transform: translateY(-9px) rotate(-45deg);
    }
    
    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        max-width: 300px;
        height: 100vh;
        background: white;
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
        transition: right 0.3s ease;
        padding: 80px 20px 40px;
        z-index: 5;
    }
    
    .nav-menu.active {
        right: 0;
    }
    
    .nav-menu ul {
        flex-direction: column;
        gap: 1rem;
    }
    
    .main-nav {
        position: fixed;
        top: 80px;
        left: 0;
        width: 100%;
        background-color: var(--white);
        box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
        padding: 1rem 0;
        transform: translateY(-150%);
        transition: var(--transition);
        z-index: 999;
    }
    
    .main-nav.active {
        transform: translateY(0);
    }
    
    .main-nav ul {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .stats {
        gap: 1.5rem;
    }
    
    .stat-number {
        font-size: 1.75rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 576px) {
    .hero {
        padding: 3rem 0;
    }
    
    .hero h1 {
        font-size: 1.75rem;
    }
    
    .stats {
        flex-direction: column;
        gap: 1.5rem;
    }
    
    .card {
        max-width: 100%;
    }
}
