/* ============================================
   BRIDGEWELL HOUSING SOLUTIONS - STYLESHEET
   Color Scheme: Navy Blue (#1a3a52), Warm Brown (#8b6f47), White (#ffffff)
   ============================================ */

/* === ROOT VARIABLES === */
:root {
    --navy-blue: #1a3a52;
    --navy-dark: #0f2537;
    --navy-light: #2d5573;
    --warm-brown: #8b6f47;
    --brown-light: #a68a5e;
    --brown-dark: #6b5536;
    --white: #ffffff;
    --off-white: #f8f9fa;
    --light-gray: #e9ecef;
    --medium-gray: #6c757d;
    --text-dark: #2c3e50;
    --success: #28a745;
    --shadow: rgba(26, 58, 82, 0.1);
    --shadow-hover: rgba(26, 58, 82, 0.2);
    
    --font-serif: 'Merriweather', serif;
    --font-sans: 'Open Sans', sans-serif;
    
    --transition: all 0.3s ease;
}

/* === RESET & BASE STYLES === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-sans);
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--white);
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-serif);
    font-weight: 700;
    line-height: 1.3;
    color: var(--navy-blue);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

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

ul {
    list-style: none;
}

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

/* === CONTAINER === */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* === NAVIGATION === */
#navbar {
    background: var(--white);
    box-shadow: 0 2px 10px var(--shadow);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    transition: var(--transition);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 20px;
}

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

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-links li a {
    color: var(--navy-blue);
    font-weight: 600;
    font-size: 0.95rem;
    transition: var(--transition);
    padding: 0.5rem 0;
    border-bottom: 2px solid transparent;
}

.nav-links li a:hover {
    color: var(--warm-brown);
    border-bottom-color: var(--warm-brown);
}

.btn-nav {
    background: var(--warm-brown);
    color: var(--white) !important;
    padding: 0.6rem 1.5rem !important;
    border-radius: 5px;
    border: none !important;
}

.btn-nav:hover {
    background: var(--brown-dark);
    transform: translateY(-2px);
}

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--navy-blue);
    cursor: pointer;
}

/* === BUTTONS === */
.btn {
    display: inline-block;
    padding: 0.9rem 2rem;
    border-radius: 5px;
    font-weight: 600;
    text-align: center;
    transition: var(--transition);
    cursor: pointer;
    border: 2px solid transparent;
    font-family: var(--font-sans);
}

.btn-primary {
    background: var(--navy-blue);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--navy-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px var(--shadow-hover);
}

.btn-secondary {
    background: transparent;
    color: var(--white);
    border: 2px solid var(--white);
}

.btn-secondary:hover {
    background: var(--white);
    color: var(--navy-blue);
}

.btn-brown {
    background: var(--warm-brown);
    color: var(--white);
}

.btn-brown:hover {
    background: var(--brown-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px var(--shadow-hover);
}

/* === HERO SECTION === */
.hero {
    position: relative;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--navy-blue) 0%, var(--navy-light) 100%);
    margin-top: 80px;
    padding: 4rem 0;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><circle cx="50" cy="50" r="40" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="2"/></svg>');
    opacity: 0.3;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 30% 50%, rgba(139, 111, 71, 0.15) 0%, transparent 50%);
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    color: var(--white);
}

.hero-title {
    font-size: 3.5rem;
    color: var(--white);
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.hero-subtitle {
    font-size: 1.4rem;
    margin-bottom: 2.5rem;
    opacity: 0.95;
    font-weight: 300;
}

.hero-buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* === MISSION SECTION === */
.mission {
    background: var(--warm-brown);
    color: var(--white);
    padding: 4rem 0;
}

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

.mission h2 {
    color: var(--white);
    margin-bottom: 1.5rem;
    font-size: 2.2rem;
}

.mission-statement {
    font-size: 1.2rem;
    line-height: 1.8;
    font-weight: 300;
}

/* === SERVICES OVERVIEW === */
.services-overview {
    padding: 5rem 0;
    background: var(--off-white);
}

.section-title {
    text-align: center;
    margin-bottom: 3rem;
    font-size: 2.5rem;
    position: relative;
    padding-bottom: 1rem;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: var(--warm-brown);
    border-radius: 2px;
}

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

.service-card {
    background: var(--white);
    padding: 2.5rem 2rem;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 4px 20px var(--shadow);
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 30px var(--shadow-hover);
}

.service-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--navy-blue), var(--navy-light));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
}

.service-icon i {
    font-size: 2rem;
    color: var(--white);
}

.service-card h3 {
    margin-bottom: 1rem;
    color: var(--navy-blue);
}

.service-card p {
    color: var(--medium-gray);
    line-height: 1.7;
}

/* === ABOUT SECTION === */
.about {
    padding: 5rem 0;
    background: var(--white);
}

.about-content {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 4rem;
    align-items: start;
}

.about-text p {
    margin-bottom: 1.5rem;
    line-height: 1.8;
    color: var(--text-dark);
}

.values {
    margin-top: 2.5rem;
    padding: 2rem;
    background: var(--off-white);
    border-radius: 10px;
    border-left: 4px solid var(--warm-brown);
}

.values h3 {
    margin-bottom: 1.5rem;
    color: var(--navy-blue);
}

.values-list li {
    margin-bottom: 1rem;
    display: flex;
    align-items: start;
    gap: 0.8rem;
}

.values-list i {
    color: var(--warm-brown);
    margin-top: 0.3rem;
    font-size: 1.1rem;
}

.stats-box {
    background: linear-gradient(135deg, var(--navy-blue), var(--navy-light));
    padding: 3rem 2rem;
    border-radius: 10px;
    box-shadow: 0 10px 30px var(--shadow-hover);
    position: sticky;
    top: 120px;
}

.stat {
    text-align: center;
    padding: 1.5rem 0;
    border-bottom: 1px solid rgba(255,255,255,0.2);
}

.stat:last-child {
    border-bottom: none;
}

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 900;
    color: var(--white);
    font-family: var(--font-serif);
    margin-bottom: 0.5rem;
}

.stat-label {
    display: block;
    color: rgba(255,255,255,0.9);
    font-size: 1rem;
}

/* === PROGRAM SECTION === */
.program {
    padding: 5rem 0;
    background: var(--off-white);
}

.section-intro {
    text-align: center;
    max-width: 800px;
    margin: -1rem auto 3rem;
    font-size: 1.1rem;
    color: var(--medium-gray);
}

.program-details {
    margin-top: 3rem;
}

.program-item {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 2rem;
    background: var(--white);
    padding: 2.5rem;
    margin-bottom: 2rem;
    border-radius: 10px;
    box-shadow: 0 4px 20px var(--shadow);
    transition: var(--transition);
}

.program-item:hover {
    box-shadow: 0 6px 30px var(--shadow-hover);
    transform: translateX(10px);
}

.program-icon {
    width: 70px;
    height: 70px;
    background: var(--warm-brown);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.program-icon i {
    font-size: 2rem;
    color: var(--white);
}

.program-content h3 {
    margin-bottom: 1rem;
    color: var(--navy-blue);
}

.program-content p {
    margin-bottom: 1rem;
    line-height: 1.7;
    color: var(--text-dark);
}

.program-content ul {
    list-style: none;
    margin-top: 1rem;
}

.program-content ul li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
    color: var(--medium-gray);
}

.program-content ul li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--warm-brown);
    font-weight: bold;
}

/* === PROGRAM PHASES === */
.program-phases {
    margin-top: 4rem;
    padding: 3rem;
    background: var(--white);
    border-radius: 10px;
}

.program-phases h3 {
    text-align: center;
    margin-bottom: 2.5rem;
    font-size: 2rem;
    color: var(--navy-blue);
}

.phases-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 2rem;
}

.phase-card {
    background: linear-gradient(135deg, var(--off-white) 0%, var(--white) 100%);
    padding: 2rem;
    border-radius: 10px;
    border: 2px solid var(--light-gray);
    text-align: center;
    transition: var(--transition);
}

.phase-card:hover {
    border-color: var(--warm-brown);
    transform: translateY(-5px);
}

.phase-number {
    width: 60px;
    height: 60px;
    background: var(--navy-blue);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    font-weight: 900;
    margin: 0 auto 1.5rem;
    font-family: var(--font-serif);
}

.phase-card h4 {
    margin-bottom: 1rem;
    color: var(--navy-blue);
}

.phase-card p {
    color: var(--medium-gray);
    line-height: 1.6;
    font-size: 0.95rem;
}

/* === RESIDENTS SECTION === */
.residents {
    padding: 5rem 0;
    background: var(--white);
}

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

.expectations, .resources {
    background: var(--off-white);
    padding: 2.5rem;
    border-radius: 10px;
    border-left: 4px solid var(--navy-blue);
}

.resources {
    border-left-color: var(--warm-brown);
}

.expectations h3, .resources h3 {
    margin-bottom: 1.5rem;
    color: var(--navy-blue);
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.expectations h3 i, .resources h3 i {
    color: var(--warm-brown);
}

.expectations p, .resources p {
    margin-bottom: 1.5rem;
    line-height: 1.7;
}

.expectations ul, .resources ul {
    list-style: none;
}

.expectations ul li, .resources ul li {
    padding: 0.7rem 0;
    padding-left: 1.8rem;
    position: relative;
    color: var(--text-dark);
    border-bottom: 1px solid var(--light-gray);
}

.expectations ul li:last-child, .resources ul li:last-child {
    border-bottom: none;
}

.expectations ul li::before, .resources ul li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--navy-blue);
    font-size: 1.5rem;
    line-height: 1;
}

/* === SUCCESS STORIES / TESTIMONIALS === */
.success-stories {
    margin-top: 4rem;
}

.success-stories h3 {
    text-align: center;
    margin-bottom: 1rem;
    font-size: 2rem;
    color: var(--navy-blue);
}

.testimonials {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.testimonial {
    background: linear-gradient(135deg, var(--navy-blue), var(--navy-light));
    padding: 2.5rem;
    border-radius: 10px;
    box-shadow: 0 6px 25px var(--shadow-hover);
    position: relative;
}

.testimonial-content {
    color: var(--white);
}

.quote-icon {
    font-size: 2.5rem;
    opacity: 0.3;
    margin-bottom: 1rem;
}

.testimonial-content p {
    font-size: 1.05rem;
    line-height: 1.8;
    margin-bottom: 1.5rem;
    font-style: italic;
}

.testimonial-author {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255,255,255,0.2);
}

.testimonial-author strong {
    font-weight: 700;
    font-size: 1.05rem;
}

.testimonial-author span {
    font-size: 0.9rem;
    opacity: 0.8;
}

/* === GET INVOLVED SECTION === */
.get-involved {
    padding: 5rem 0;
    background: linear-gradient(135deg, var(--off-white) 0%, var(--white) 100%);
}

.involvement-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.involvement-card {
    background: var(--white);
    padding: 2.5rem;
    border-radius: 10px;
    box-shadow: 0 4px 20px var(--shadow);
    text-align: center;
    transition: var(--transition);
    border: 2px solid transparent;
}

.involvement-card:hover {
    border-color: var(--warm-brown);
    transform: translateY(-8px);
    box-shadow: 0 8px 30px var(--shadow-hover);
}

.involvement-icon {
    width: 80px;
    height: 80px;
    background: var(--warm-brown);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
}

.involvement-icon i {
    font-size: 2rem;
    color: var(--white);
}

.involvement-card h3 {
    margin-bottom: 1rem;
    color: var(--navy-blue);
}

.involvement-card p {
    margin-bottom: 1.5rem;
    line-height: 1.7;
    color: var(--medium-gray);
}

/* === CONTACT SECTION === */
.contact {
    padding: 5rem 0;
    background: var(--white);
}

.contact-content {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 4rem;
    margin-top: 3rem;
}

.contact-form-container h3, .contact-info h3 {
    margin-bottom: 2rem;
    color: var(--navy-blue);
}

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

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.form-group label {
    font-weight: 600;
    color: var(--navy-blue);
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 0.9rem;
    border: 2px solid var(--light-gray);
    border-radius: 5px;
    font-family: var(--font-sans);
    font-size: 1rem;
    transition: var(--transition);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--warm-brown);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.form-message {
    padding: 1rem;
    border-radius: 5px;
    margin-top: 1rem;
    display: none;
    text-align: center;
    font-weight: 600;
}

.form-message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
    display: block;
}

.form-message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
    display: block;
}

.contact-info {
    background: var(--off-white);
    padding: 2.5rem;
    border-radius: 10px;
}

.contact-item {
    display: flex;
    gap: 1.5rem;
    padding: 1.5rem 0;
    border-bottom: 1px solid var(--light-gray);
}

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

.contact-item i {
    font-size: 1.5rem;
    color: var(--warm-brown);
    width: 30px;
    flex-shrink: 0;
}

.contact-item strong {
    display: block;
    color: var(--navy-blue);
    margin-bottom: 0.3rem;
}

.contact-item p {
    color: var(--medium-gray);
    line-height: 1.6;
}

.emergency-note {
    background: linear-gradient(135deg, var(--navy-blue), var(--navy-light));
    color: var(--white);
    padding: 1.5rem;
    border-radius: 8px;
    margin-top: 2rem;
    display: flex;
    gap: 1rem;
    align-items: start;
}

.emergency-note i {
    font-size: 1.5rem;
    color: var(--white);
    margin-top: 0.2rem;
}

.emergency-note p {
    color: var(--white);
    line-height: 1.6;
}

/* === FOOTER === */
.footer {
    background: var(--navy-blue);
    color: var(--white);
    padding: 3rem 0 1.5rem;
}

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

.footer-logo {
    height: 50px;
    margin-bottom: 1rem;
    filter: brightness(0) invert(1);
}

.footer-section p {
    margin-top: 1rem;
    opacity: 0.9;
    line-height: 1.6;
}

.footer-section h4 {
    color: var(--white);
    margin-bottom: 1.5rem;
    font-size: 1.2rem;
}

.footer-section ul {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.footer-section ul li a {
    color: rgba(255,255,255,0.8);
    transition: var(--transition);
}

.footer-section ul li a:hover {
    color: var(--warm-brown);
    padding-left: 5px;
}

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

.social-links 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);
}

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

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 2rem;
    text-align: center;
    opacity: 0.8;
}

/* === SCROLL TO TOP BUTTON === */
.scroll-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--warm-brown);
    color: var(--white);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px var(--shadow-hover);
    transition: var(--transition);
    z-index: 999;
}

.scroll-top:hover {
    background: var(--brown-dark);
    transform: translateY(-5px);
}

.scroll-top.visible {
    display: flex;
}

/* === RESPONSIVE DESIGN === */

@media (max-width: 968px) {
    .nav-links {
        position: fixed;
        top: 80px;
        left: 0;
        right: 0;
        background: var(--white);
        flex-direction: column;
        padding: 2rem;
        box-shadow: 0 4px 20px var(--shadow);
        transform: translateX(-100%);
        transition: var(--transition);
    }
    
    .nav-links.active {
        transform: translateX(0);
    }
    
    .mobile-menu-toggle {
        display: block;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
    }
    
    .about-content {
        grid-template-columns: 1fr;
    }
    
    .stats-box {
        position: static;
    }
    
    .contact-content {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }
}

@media (max-width: 768px) {
    h1 { font-size: 2rem; }
    h2 { font-size: 1.7rem; }
    h3 { font-size: 1.3rem; }
    
    .hero {
        min-height: 500px;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: stretch;
    }
    
    .program-item {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .logo img {
        height: 45px;
    }
    
    .container {
        padding: 0 15px;
    }
    
    .section-title {
        font-size: 1.8rem;
    }
    
    .hero-title {
        font-size: 1.7rem;
    }
    
    .service-card, .involvement-card {
        padding: 2rem 1.5rem;
    }
}