/* ===================================
   NANAIMO FASD SOCIETY - Main Stylesheet
   Premium NPO Design
   =================================== */

/* ===== CSS Variables ===== */
:root {
    /* Colors */
    --primary-color: #1a9cb0;
    --primary-dark: #147a8a;
    --primary-light: #4db8c7;
    --secondary-color: #ff6b35;
    --secondary-dark: #e5522a;
    --accent-color: #4caf50;
    --text-dark: #2c3e50;
    --text-light: #6c757d;
    --bg-light: #f8f9fa;
    --bg-white: #ffffff;
    --border-color: #e0e0e0;

    /* Typography */
    --font-heading: 'Poppins', sans-serif;
    --font-body: 'Open Sans', sans-serif;

    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 3rem;
    --spacing-xl: 4rem;

    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;

    /* Shadows */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.15);
    --shadow-xl: 0 20px 40px rgba(0, 0, 0, 0.2);
}

/* ===== Reset & Base Styles ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-body);
    color: var(--text-dark);
    line-height: 1.6;
    background-color: var(--bg-white);
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-normal);
}

ul {
    list-style: none;
}

/* ===== Typography ===== */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: var(--spacing-sm);
    color: var(--text-dark);
}

h1 {
    font-size: 2.5rem;
}

h2 {
    font-size: 2rem;
}

h3 {
    font-size: 1.75rem;
}

h4 {
    font-size: 1.5rem;
}

h5 {
    font-size: 1.25rem;
}

h6 {
    font-size: 1rem;
}

p {
    margin-bottom: var(--spacing-sm);
}

/* ===== Container ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

/* ===== Header Styles ===== */
.main-header {
    background: var(--bg-white);
    box-shadow: var(--shadow-md);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-top {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    padding: var(--spacing-xs) 0;
    font-size: 0.875rem;
}

.header-top .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.contact-info span {
    margin-right: var(--spacing-md);
}

.contact-info i {
    margin-right: var(--spacing-xs);
}

.social-links a {
    color: white;
    margin-left: var(--spacing-sm);
    font-size: 1.1rem;
    transition: var(--transition-fast);
}

.social-links a:hover {
    color: var(--secondary-color);
    transform: translateY(-2px);
}

.header-main {
    padding: var(--spacing-sm) 0;
}

.header-main .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-section {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.logo svg {
    width: 60px;
    height: 60px;
    filter: drop-shadow(var(--shadow-sm));
}

.site-title h1 {
    font-size: 1.4rem;
    margin: 0;
    color: var(--primary-color);
    font-weight: 700;
    line-height: 1.3;
}

.site-title .tagline {
    font-size: 0.7rem;
    color: var(--text-light);
    margin: 0;
    font-weight: 400;
    white-space: nowrap;
}

/* ===== Navigation - SINGLE LINE REQUIREMENT ===== */
.main-nav {
    flex: 1;
    display: flex;
    justify-content: flex-end;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: nowrap;
    /* CRITICAL: Prevents wrapping */
    white-space: nowrap;
    /* CRITICAL: Keeps items on one line */
}

.nav-menu li a {
    padding: 0.5rem 0.9rem;
    color: var(--text-dark);
    font-weight: 600;
    font-size: 0.9rem;
    border-radius: 6px;
    transition: var(--transition-fast);
    display: inline-block;
}

.nav-menu li a:hover,
.nav-menu li a.active {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    color: white;
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
    padding: var(--spacing-xs);
}

.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background: var(--primary-color);
    border-radius: 2px;
    transition: var(--transition-fast);
}

/* ===== Main Content ===== */
.main-content {
    min-height: 60vh;
}

/* ===== Hero Section ===== */
.hero {
    background: linear-gradient(135deg, rgba(26, 156, 176, 0.95), rgba(20, 122, 138, 0.95)),
        url('../images/hero-bg.jpg') center/cover;
    color: white;
    padding: var(--spacing-xl) 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 30% 50%, rgba(255, 107, 53, 0.2), transparent 50%);
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    margin: 0 auto;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: var(--spacing-md);
    color: white;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    animation: fadeInUp 0.8s ease;
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: var(--spacing-md);
    opacity: 0.95;
    animation: fadeInUp 0.8s ease 0.2s both;
}

.hero-buttons {
    display: flex;
    gap: var(--spacing-sm);
    justify-content: center;
    flex-wrap: wrap;
    animation: fadeInUp 0.8s ease 0.4s both;
}

/* ===== Buttons ===== */
.btn {
    display: inline-block;
    padding: 0.875rem 2rem;
    font-weight: 600;
    border-radius: 50px;
    transition: var(--transition-normal);
    cursor: pointer;
    border: 2px solid transparent;
    font-size: 1rem;
    text-align: center;
}

.btn-primary {
    background: var(--secondary-color);
    color: white;
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    background: var(--secondary-dark);
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background: white;
    color: var(--primary-color);
    border-color: white;
}

.btn-secondary:hover {
    background: transparent;
    color: white;
    border-color: white;
}

.btn-outline {
    background: transparent;
    color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-outline:hover {
    background: var(--primary-color);
    color: white;
}

/* ===== Section Styles ===== */
.section {
    padding: var(--spacing-xl) 0;
}

.section-light {
    background: var(--bg-light);
}

.section-header {
    text-align: center;
    margin-bottom: var(--spacing-lg);
}

.section-header h2 {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: var(--spacing-sm);
    position: relative;
    display: inline-block;
}

.section-header h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, var(--secondary-color), var(--primary-color));
    border-radius: 2px;
}

.section-header p {
    font-size: 1.125rem;
    color: var(--text-light);
    max-width: 700px;
    margin: var(--spacing-md) auto 0;
}

/* ===== Grid Layouts ===== */
.grid {
    display: grid;
    gap: var(--spacing-md);
}

.grid-2 {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.grid-3 {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.grid-4 {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

/* ===== Card Styles ===== */
.card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-normal);
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.card-img {
    width: 100%;
    height: 250px;
    object-fit: cover;
}

.card-content {
    padding: var(--spacing-md);
}

.card-content h3 {
    color: var(--primary-color);
    margin-bottom: var(--spacing-sm);
}

.card-content p {
    color: var(--text-light);
    margin-bottom: var(--spacing-sm);
}

.card-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: var(--spacing-sm);
    color: white;
    font-size: 1.5rem;
}

/* ===== Stats Section ===== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: var(--spacing-md);
    text-align: center;
}

.stat-item {
    background: white;
    padding: var(--spacing-md);
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
}

.stat-number {
    font-size: 3rem;
    font-weight: 700;
    color: var(--primary-color);
    display: block;
}

.stat-label {
    color: var(--text-light);
    font-size: 1rem;
}

/* ===== Content Sections ===== */
.content-section {
    padding: var(--spacing-lg) 0;
}

.content-wrapper {
    max-width: 900px;
    margin: 0 auto;
}

.content-wrapper h2 {
    color: var(--primary-color);
    margin-top: var(--spacing-lg);
    margin-bottom: var(--spacing-sm);
}

.content-wrapper h3 {
    color: var(--text-dark);
    margin-top: var(--spacing-md);
}

.content-wrapper ul,
.content-wrapper ol {
    margin-left: var(--spacing-md);
    margin-bottom: var(--spacing-sm);
}

.content-wrapper li {
    list-style: disc;
    margin-bottom: var(--spacing-xs);
    color: var(--text-light);
}

.highlight-box {
    background: linear-gradient(135deg, rgba(26, 156, 176, 0.1), rgba(76, 175, 80, 0.1));
    border-left: 4px solid var(--primary-color);
    padding: var(--spacing-md);
    border-radius: 8px;
    margin: var(--spacing-md) 0;
}

/* ===== Image Gallery ===== */
.image-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: var(--spacing-sm);
}

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    aspect-ratio: 1;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition-slow);
}

.gallery-item:hover img {
    transform: scale(1.1);
}

/* ===== Forms ===== */
.form-group {
    margin-bottom: var(--spacing-md);
}

.form-group label {
    display: block;
    margin-bottom: var(--spacing-xs);
    font-weight: 600;
    color: var(--text-dark);
}

.form-control {
    width: 100%;
    padding: 0.875rem;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: var(--transition-fast);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(26, 156, 176, 0.1);
}

textarea.form-control {
    resize: vertical;
    min-height: 150px;
}

/* ===== Footer Styles ===== */
.main-footer {
    background: linear-gradient(135deg, #1a2332, #2c3e50);
    color: white;
    margin-top: var(--spacing-xl);
}

.footer-content {
    padding: var(--spacing-xl) 0 var(--spacing-md);
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--spacing-md);
}

.footer-section h3,
.footer-section h4 {
    color: white;
    margin-bottom: var(--spacing-sm);
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-sm);
}

.footer-logo svg {
    width: 50px;
    height: 50px;
}

.footer-section p {
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.8;
}

.registry-info {
    font-size: 0.875rem;
    margin-top: var(--spacing-sm);
}

.footer-links li {
    margin-bottom: var(--spacing-xs);
}

.footer-links a {
    color: rgba(255, 255, 255, 0.8);
    transition: var(--transition-fast);
}

.footer-links a:hover {
    color: var(--secondary-color);
    padding-left: 5px;
}

.footer-contact li {
    display: flex;
    align-items: flex-start;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-sm);
    color: rgba(255, 255, 255, 0.8);
}

.footer-contact i {
    color: var(--primary-light);
    margin-top: 3px;
}

.footer-social {
    display: flex;
    gap: var(--spacing-sm);
    margin-top: var(--spacing-sm);
}

.footer-social a {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-fast);
}

.footer-social a:hover {
    background: var(--secondary-color);
    transform: translateY(-3px);
}

.footer-bottom {
    background: rgba(0, 0, 0, 0.2);
    padding: var(--spacing-md) 0;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
    margin: 0;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.875rem;
}

.footer-bottom a {
    color: var(--primary-light);
}

.footer-bottom a:hover {
    color: var(--secondary-color);
}

/* ===== Animations ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* ===== Responsive Design ===== */
@media (max-width: 1024px) {
    .nav-menu li a {
        padding: 0.5rem 0.7rem;
        font-size: 0.85rem;
    }
}

@media (max-width: 768px) {

    /* Mobile Navigation */
    .mobile-menu-toggle {
        display: flex;
    }

    .main-nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        background: white;
        box-shadow: var(--shadow-xl);
        transition: var(--transition-normal);
        padding: var(--spacing-xl) var(--spacing-md);
        z-index: 999;
    }

    .main-nav.active {
        right: 0;
    }

    .nav-menu {
        flex-direction: column;
        align-items: flex-start;
        gap: 0;
    }

    .nav-menu li {
        width: 100%;
        border-bottom: 1px solid var(--border-color);
    }

    .nav-menu li a {
        display: block;
        padding: var(--spacing-sm);
        width: 100%;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .hero p {
        font-size: 1rem;
    }

    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.75rem;
    }

    h3 {
        font-size: 1.5rem;
    }

    .section {
        padding: var(--spacing-md) 0;
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 var(--spacing-sm);
    }

    .hero-buttons {
        flex-direction: column;
    }

    .btn {
        width: 100%;
    }

    .contact-info span {
        display: block;
        margin-bottom: var(--spacing-xs);
    }

    .header-top .container {
        flex-direction: column;
        text-align: center;
        gap: var(--spacing-xs);
    }

    .social-links {
        margin-top: var(--spacing-xs);
    }
}

/* ===== Utility Classes ===== */
.text-center {
    text-align: center;
}

.text-primary {
    color: var(--primary-color);
}

.text-secondary {
    color: var(--secondary-color);
}

.mt-1 {
    margin-top: var(--spacing-sm);
}

.mt-2 {
    margin-top: var(--spacing-md);
}

.mt-3 {
    margin-top: var(--spacing-lg);
}

.mb-1 {
    margin-bottom: var(--spacing-sm);
}

.mb-2 {
    margin-bottom: var(--spacing-md);
}

.mb-3 {
    margin-bottom: var(--spacing-lg);
}

.py-1 {
    padding: var(--spacing-sm) 0;
}

.py-2 {
    padding: var(--spacing-md) 0;
}

.py-3 {
    padding: var(--spacing-lg) 0;
}