/* General Styles */
:root {
    --primary-color: #000000;
    --secondary-color: #e0e0e0;
    --brand-red: #e30613;
    --brand-green: #00a859;
    --text-light: #b0b0b0;
    --dark-color: #212529;
    --white: #ffffff;
    --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Figtree', sans-serif;
    line-height: 1.6;
    color: var(--dark-color);
}

/* Skip to main content link for accessibility */
.skip-to-main {
    position: absolute;
    left: -9999px;
    z-index: 999;
}

.skip-to-main:focus {
    left: 50%;
    transform: translateX(-50%);
    top: 10px;
    background: var(--primary-color);
    color: white;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 5px;
}

/* Header Styles */
.header-top {
    font-size: 0.9rem;
}

.header-top a:hover {
    opacity: 0.8;
}

/* Navigation Styles */
.navbar {
    transition: all 0.3s ease;
}

.navbar-brand {
    font-size: 1.5rem;
    transition: transform 0.3s ease;
}

.navbar-brand:hover {
    transform: scale(1.05);
}

.nav-link {
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 50%;
    background-color: var(--primary-color);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 80%;
}

/* Main Content */
main {
    min-height: calc(100vh - 200px);
}

/* Section Styles */
.section {
    padding: 80px 0;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    width: 60%;
    height: 3px;
    background: var(--primary-color);
    bottom: -10px;
    left: 20%;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--secondary-color);
    margin-bottom: 3rem;
}

/* Card Styles */
.card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: none;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

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

.card-img-top {
    height: 250px;
    object-fit: cover;
}

/* Button Styles */
.btn {
    padding: 10px 30px;
    font-weight: 500;
    transition: all 0.3s ease;
}

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

.btn-primary:hover {
    background-color: #0b5ed7;
    border-color: #0a58ca;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* Footer Styles */
.footer {
    margin-top: 80px;
}

.footer a:hover {
    color: white !important;
    text-decoration: underline !important;
}

/* Back to Top Button */
#backToTop {
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

#backToTop.show {
    opacity: 1;
    display: block !important;
}

#backToTop:hover {
    transform: scale(1.1);
}

/* Loading Animation */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Form Styles */
.form-control:focus,
.form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

.form-label {
    font-weight: 500;
    margin-bottom: 0.5rem;
}

/* Alert Styles */
.alert {
    border-radius: 8px;
    border: none;
}

/* Image Styles */
img {
    max-width: 100%;
    height: auto;
}

/* Responsive Styles */
@media (max-width: 991px) {
    .section {
        padding: 60px 0;
    }

    .section-title {
        font-size: 2rem;
    }

    .navbar-nav {
        padding: 20px 0;
    }

    .nav-link::after {
        display: none;
    }
}

@media (max-width: 767px) {
    .section {
        padding: 40px 0;
    }

    .section-title {
        font-size: 1.75rem;
    }

    .header-top {
        font-size: 0.8rem;
    }
}

/* Accessibility Improvements */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* Focus Styles for Keyboard Navigation */
a:focus,
button:focus,
input:focus,
textarea:focus,
select:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Print Styles */
@media print {
    .navbar,
    .footer,
    #backToTop {
        display: none;
    }
}
