/* Aliceville Adult Family Home - Custom Styles */

:root {
    --priFont: 'Open Sans', sans-serif;
    --secFont: 'Gabarito', sans-serif;
    --priColor: #205a76; /* Brand Blue/Teal */
    --secColor: #7bb39a; /* Brand Sage */
    --terColor: #f4b25f; /* Brand Gold */
    --darkColor: #23313a;
    --lightColor: #f1f5f8;
    --white: #ffffff;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
    font-family: var(--priFont);
    color: var(--darkColor);
    line-height: 1.8;
    overflow-x: hidden;
    font-size: 16px;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--secFont);
    font-weight: 800;
}

/* --- Bootstrap Overrides --- */
.bg-primary { background-color: var(--priColor) !important; }
.bg-secondary { background-color: var(--secColor) !important; }
.bg-dark { background-color: var(--darkColor) !important; }
.text-primary { color: var(--priColor) !important; }
.text-secondary { color: var(--secColor) !important; }
.text-ter { color: var(--terColor) !important; }

.btn-primary {
    background-color: var(--priColor) !important;
    border-color: var(--priColor) !important;
    color: var(--white) !important;
}
.btn-primary:hover {
    background-color: var(--darkColor) !important;
    transform: translateY(-3px);
}
.btn-secondary {
    background-color: var(--secColor) !important;
    border-color: var(--secColor) !important;
    color: var(--white) !important;
}
.btn-secondary:hover {
    background-color: var(--priColor) !important;
    transform: translateY(-3px);
}
.btn-ter {
    background-color: var(--terColor) !important;
    border-color: var(--terColor) !important;
    color: var(--darkColor) !important;
    font-weight: 700;
}
.btn-ter:hover {
    background-color: var(--white) !important;
    border-color: var(--white) !important;
    color: var(--priColor) !important;
    transform: translateY(-3px);
}

/* Override standard link blue */
a {
    color: var(--priColor);
    text-decoration: none;
    transition: var(--transition);
}
a:hover { color: var(--secColor); }

/* Section Spacing */
.section-padding { padding: 40px 0; }
@media (max-width: 768px) { 
    .section-padding { padding: 25px 0; } 
    .hero-content h1 { font-size: 1.8rem; }
    .hero-subheadline { font-size: 1rem; margin-bottom: 1rem; }
    .hero-text { font-size: 0.85rem; }
    .service-card { padding: 1.5rem 1rem; }
    .service-icon { width: 50px; height: 50px; font-size: 1.5rem; margin-bottom: 1rem; border-radius: 12px; }
}

/* Header & Nav */
.top-bar { background-color: var(--priColor); font-size: 0.9rem; font-weight: 600; padding: 10px 0 !important; }
.navbar { padding: 2rem 0; transition: var(--transition); }
.main-header.scrolled .navbar { padding: 0.6rem 0; box-shadow: 0 5px 20px rgba(0,0,0,0.1); }
.main-header.scrolled .navbar-brand img { height: 60px !important; }
.logo-main { transition: var(--transition); }

.nav-link {
    font-weight: 700;
    color: var(--darkColor) !important;
    padding: 0.5rem 1rem !important;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 0.5px;
    transition: var(--transition);
}
.main-header.scrolled .nav-link { padding: 0.5rem 0.8rem !important; }
.nav-link i { display: none; margin-right: 5px; color: var(--secColor); }
.main-header.scrolled .nav-link i { display: inline-block; font-size: 0.9rem; }
.nav-link:hover, .nav-link.active { color: var(--priColor) !important; }

/* Hero Sections */
.hero-section {
    min-height: 90vh;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    color: var(--white);
    position: relative;
    padding: 120px 0;
}
.hero-content { padding: 50px 0; }
.hero-btns { margin-top: 30px; }
.hero-content h1 { font-size: clamp(1.6rem, 3.5vw, 2.4rem); margin-bottom: 0.8rem; text-shadow: 2px 2px 10px rgba(0,0,0,0.4); line-height: 1.2; }
.hero-content h2 { font-size: clamp(1.4rem, 3vw, 2rem); margin-bottom: 0.8rem; text-shadow: 2px 2px 10px rgba(0,0,0,0.4); line-height: 1.2; }
.hero-subheadline { color: var(--terColor); font-weight: 700; font-size: clamp(0.95rem, 1.3vw, 1.1rem); text-transform: none; margin-bottom: 0.8rem; letter-spacing: 0; }
.hero-text { font-size: clamp(0.85rem, 1.1vw, 1rem); max-width: 800px; line-height: 1.5; margin-bottom: 1.5rem !important; }

.internal-hero { padding: 80px 0 50px; background-size: cover; background-position: center; color: var(--white); text-align: center; }
.internal-hero h1 { font-size: clamp(2.5rem, 6vw, 4rem); }

/* Hero Slider */
.hero-slider .carousel-item {
    height: 55vh;
    min-height: 450px;
    background-size: cover;
    background-position: center;
}
.hero-slider .hero-container {
    height: 100%;
    display: flex;
    align-items: center;
    color: var(--white);
}

/* Trust Strip */
.trust-strip { background: var(--white); box-shadow: 0 20px 50px rgba(0,0,0,0.12); margin-top: -40px; border-radius: 25px; overflow: hidden; position: relative; z-index: 10; }
.trust-item { padding: 20px 5px; font-weight: 800; text-transform: uppercase; font-size: 0.65rem; letter-spacing: 0.3px; border-right: 1px solid #f0f0f0; text-align: center; line-height: 1.2; }
.trust-item:last-child { border-right: none; }
.trust-item i { font-size: 1.6rem; color: #205A76 !important; margin-bottom: 12px; display: block; }
@media (max-width: 991px) {
    .trust-strip { margin-top: 0; border-radius: 0; }
    .trust-item { border-bottom: 1px solid #f0f0f0; padding: 15px 5px; font-size: 0.6rem; }
    .trust-item:nth-child(even) { border-right: none; }
}

/* Cascading Images - Refined */
.image-cascade { position: relative; height: 600px; padding: 20px; }
.rounded-stylish { border-radius: 40px; border: 8px solid var(--white); box-shadow: 0 15px 35px rgba(0,0,0,0.12); transition: var(--transition); }
.rounded-stylish:hover { transform: translateY(-10px) scale(1.05); z-index: 10 !important; box-shadow: 0 30px 60px rgba(0,0,0,0.25); border-color: var(--terColor); }
.img-1 { width: 65%; position: absolute; top: 0; right: 0; z-index: 4; border-radius: 60px 20px 60px 20px; }
.img-2 { width: 60%; position: absolute; top: 120px; left: 0; z-index: 3; border-radius: 20px 60px 20px 60px; }
.img-3 { width: 55%; position: absolute; bottom: 80px; right: 5%; z-index: 2; border-radius: 60px 20px 60px 20px; }
.img-4 { width: 50%; position: absolute; bottom: 0; left: 5%; z-index: 1; border-radius: 20px 60px 20px 60px; }

@media (max-width: 991px) {
    .image-cascade { height: 500px; margin-top: 30px; }
    .img-1 { width: 70%; top: 0; }
    .img-2 { width: 65%; top: 100px; }
    .img-3 { width: 60%; bottom: 60px; }
    .img-4 { width: 55%; bottom: 0; }
}

/* Floating Contact & Back to Top - FIXED CSS */
.floating-contact {
    position: fixed !important;
    right: 25px !important;
    bottom: 100px !important;
    z-index: 9999 !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
}

.fc-item {
    width: 60px !important;
    height: 60px !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: var(--white) !important;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3) !important;
    font-size: 24px !important;
    transition: var(--transition) !important;
}
.fc-item:hover { transform: scale(1.1) rotate(5deg) !important; color: var(--white) !important; }
.fc-item.phone { background-color: var(--priColor) !important; }
.fc-item.whatsapp { background-color: #25d366 !important; }
.fc-item.email { background-color: var(--secColor) !important; }

#back-to-top {
    position: fixed !important;
    right: 25px !important;
    bottom: 30px !important;
    width: 60px !important;
    height: 60px !important;
    z-index: 9999 !important;
    display: none;
    border-radius: 50% !important;
}

/* Accessibility */
.accessibility-widget { position: fixed !important; left: 25px !important; bottom: 30px !important; z-index: 9999 !important; }
.accessibility-widget #acc-toggle { width: 60px; height: 60px; border-radius: 50%; }
.acc-menu { position: absolute; bottom: 75px; left: 0; background: var(--white); width: 280px; border-radius: 20px; box-shadow: 0 10px 30px rgba(0,0,0,0.2); }
.hide { display: none !important; }

/* Footer & CTA */
.footer-cta-bar { background-color: var(--secColor) !important; padding: 80px 0; color: white !important; text-align: center; }
.footer-cta-bar h2 { color: white !important; font-weight: 800; margin-bottom: 2rem !important; }
.footer-cta-bar p { font-size: 1.25rem; opacity: 0.95; margin-bottom: 2.5rem !important; }

.main-footer { background-color: var(--darkColor); color: white; margin-top: 0; }
.footer-content { padding-top: 60px; padding-bottom: 60px; }
.main-footer h3.h5 { margin-top: 0; margin-bottom: 2.5rem; position: relative; padding-bottom: 15px; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; }
.main-footer h3.h5::after { content: ''; position: absolute; left: 0; bottom: 0; width: 40px; height: 3px; background: var(--secColor); }

@media (max-width: 768px) {
    .footer-links-cols { display: flex; flex-wrap: wrap; }
    .footer-links-cols li { width: 50%; }
}

.footer-social { display: flex; gap: 15px; margin-top: 25px; }
.footer-social a { 
    width: 45px; height: 45px; background: rgba(255,255,255,0.08); 
    display: flex; align-items: center; justify-content: center; 
    border-radius: 50%; color: white; transition: var(--transition); 
    font-size: 1.2rem;
}
.footer-social a:hover { background: var(--secColor); transform: translateY(-5px); color: white; }

.footer-partners { display: flex; align-items: center; gap: 25px; margin-top: 40px; }
.footer-partners img { height: 50px; filter: grayscale(1) brightness(2); opacity: 0.5; transition: var(--transition); }
.footer-partners a:hover img { opacity: 1; filter: none; transform: scale(1.05); }

/* Utility Classes */
.bg-light { background-color: var(--lightColor) !important; }
.text-pri { color: var(--priColor) !important; }
.text-sec { color: var(--secColor) !important; }
.section-tag { color: var(--secColor); font-weight: 900; text-transform: uppercase; letter-spacing: 2px; display: block; margin-bottom: 1.5rem; }
.rounded-25 { border-radius: 25px; }

/* Lightbox */
.gallery-lightbox { display: none; position: fixed; z-index: 3000; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.95); backdrop-filter: blur(5px); align-items: center; justify-content: center; }
.lightbox-content { max-width: 90%; max-height: 80vh; border: 10px solid var(--white); border-radius: 10px; }
.close-lightbox { position: absolute; top: 20px; right: 30px; color: var(--white); font-size: 40px; cursor: pointer; }

/* Home Preview Cards */
.home-preview-card { transition: var(--transition); }
.home-preview-card:hover { transform: translateY(-10px); }
.home-preview-card:hover img { transform: scale(1.1); }
.home-preview-card img { transition: var(--transition); }

.preview-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0.2) 50%, transparent 100%);
    z-index: 2;
}

/* Service Cards */
.service-card { padding: 3rem 2rem; border-radius: 30px; background: var(--white); border: 1px solid rgba(0,0,0,0.05); transition: var(--transition); height: 100%; display: flex; flex-direction: column; }
.service-card:hover { transform: translateY(-15px); box-shadow: 0 20px 50px rgba(32, 90, 118, 0.15); }
.service-card.bg-primary { background: var(--priColor) !important; color: white !important; }
.service-icon { width: 90px; height: 90px; font-size: 3rem; background: var(--priColor); border-radius: 25px; color: white; display: flex; align-items: center; justify-content: center; margin-bottom: 2rem; flex-shrink: 0; }
.service-card p { display: block !important; visibility: visible !important; opacity: 1 !important; }

@media (max-width: 768px) {
    .service-card { padding: 1.5rem 1rem; }
    .service-card h3 { font-size: 0.95rem; margin-bottom: 0.5rem !important; }
    .service-card p { font-size: 0.75rem; margin-bottom: 1rem !important; }
    .service-icon { width: 50px; height: 50px; font-size: 1.5rem; margin-bottom: 1rem; border-radius: 12px; }
}

@media (min-width: 1600px) { .container { max-width: 100% !important; padding-left: 100px; padding-right: 100px; } }

/* --- Accessibility Modes --- */
body.dark-mode {
    background-color: #121212 !important;
    color: #e0e0e0 !important;
}
body.dark-mode .bg-light, 
body.dark-mode .section-padding,
body.dark-mode .bg-white,
body.dark-mode section:not(.bg-primary):not(.bg-secondary):not(.hero-slider),
body.dark-mode .service-card,
body.dark-mode .location-detail-card,
body.dark-mode .contact-form-card,
body.dark-mode .faq-item,
body.dark-mode .bg-light-soft {
    background-color: #1e1e1e !important;
    color: #e0e0e0 !important;
    border-color: #333 !important;
}
body.dark-mode .text-muted,
body.dark-mode .opacity-75,
body.dark-mode .opacity-90 {
    color: #b0b0b0 !important;
}
body.dark-mode h1, body.dark-mode h2, body.dark-mode h3, body.dark-mode h4, body.dark-mode h5, body.dark-mode h6,
body.dark-mode .text-pri, body.dark-mode .text-primary {
    color: #fff !important;
}
body.dark-mode .navbar {
    background-color: rgba(18, 18, 18, 0.95) !important;
}
body.dark-mode .nav-link {
    color: #fff !important;
}

/* High Contrast Mode */
body.high-contrast {
    background-color: #000 !important;
    color: #fff !important;
}
body.high-contrast * {
    background-color: #000 !important;
    color: #fff !important;
    border-color: #fff !important;
    box-shadow: none !important;
    text-shadow: none !important;
}
body.high-contrast a, 
body.high-contrast button,
body.high-contrast .btn {
    color: #ffff00 !important; /* Yellow for interactive elements */
    border: 2px solid #ffff00 !important;
    background-color: #000 !important;
}
body.high-contrast .btn:hover {
    background-color: #ffff00 !important;
    color: #000 !important;
}
body.high-contrast img {
    filter: grayscale(1) contrast(1.5) !important;
}
