﻿/* FiftyPlus Brand Colors */
:root {
    /* Brand Colors - From your Tailwind config */
    --primary: #3A6C5D;
    --secondary: #B9FB9F;
    --body: #000000;
    --background: #F7FBFE;
    --pattern: #C9CBBF;
    /* Override Bootstrap primary */
    --bs-primary: #3A6C5D;
    --bs-primary-rgb: 58, 108, 93;
    --bs-secondary: #B9FB9F;
    --bs-secondary-rgb: 185, 251, 159;
    /* Custom grays */
    --gray-400: #9CA3AF;
    --gray-500: #6B7280;
    --gray-600: #4B5563;
    --gray-800: #1F2937;
}

/* Emergency mobile overflow fix */
html, body {
    overflow-x: hidden;
    max-width: 100%;
}

.container-xl {
    max-width: 100%;
    padding-left: 15px;
    padding-right: 15px;
}

@media (max-width: 575.98px) {
    .container-xl {
        padding-left: 10px;
        padding-right: 10px;
    }

    .row {
        margin-left: 0;
        margin-right: 0;
    }
}

/* Typography - FiftyPlus Fonts */
body {
    font-family: 'Open Sans', sans-serif;
    font-size: 1rem;
    line-height: 1.5;
}

h1, h2, h3, h4, h5, h6, .font-heading {
    font-family: 'Montserrat', sans-serif;
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Navigation Styles */
.navbar-custom {
    height: 72px; /* Increased from 64px to 72px for larger nav items */
    z-index: 1050;
}

@media (min-width: 992px) {
    .navbar-custom {
        height: 88px; /* Increased from 80px to 88px for larger nav items */
    }
}

.navbar-logo {
    height: 40px;
    width: auto;
    max-width: 200px;
}

@media (min-width: 992px) {
    .navbar-logo {
        height: 50px;
        width: auto;
        max-width: 250px;
    }
}

.nav-link-custom {
    transition: all 0.3s ease;
    font-size: 1.125rem; /* Increased from 1rem to 1.125rem (18px) */
    padding: 0.75rem 1.25rem; /* Increased padding for larger click area */
    font-weight: 400; /* Make text slightly bolder */
    border-radius: 0.375rem; /* Rounded corners */
    position: relative;
}

.nav-link-custom:hover {
    transition: all 0.3s ease;
    font-weight: 700;
}

.nav-link-custom:active {
    font-weight: 700;
}

/* Secondary Outline Button */
.btn-secondary-outline {
    background-color: var(--bs-primary);
    color: var(--bs-secondary);
    border: 2px solid var(--bs-secondary);
    border-radius: 0.375rem;
    padding: 0.75rem 1.5rem;
    font-weight: 500;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s ease;
}

.btn-secondary-outline:hover {
    background-color: var(--bs-secondary);
    color: var(--bs-primary);
    text-decoration: none;
}

.btn-secondary-outline:active {
    transform: scale(0.98);
}

/* CTA Button Styles */
.btn-cta {
    padding: 0.625rem 1.5rem; /* py-2.5 px-6 */
    border-radius: 0.375rem;
    transition: all 0.2s ease;
    transform: scale(1);
}

    .btn-cta:hover {
        transform: scale(1.05);
        box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    }

/* Universal Button Grow Animation */
.btn,
a.btn,
button.btn {
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    transform: scale(1);
}

.btn:hover,
a.btn:hover,
button.btn:hover,
.btn:focus,
a.btn:focus,
button.btn:focus {
    transform: scale(1.05);
    box-shadow: 0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -2px rgba(0,0,0,0.04);
}

/* Example: Join Us button in layout */
.btn-joinus {
    /* Inherit the grow effect from .btn */
    /* Optionally, add more custom styles here */
}

/* Mobile Menu Transitions */
.navbar-collapse {
    transition: all 0.3s ease-in-out;
}

/* Main Content Padding */
.main-content {
    padding-top: 72px; /* Increased to match new navbar height */
}

@media (min-width: 992px) {
    .main-content {
        padding-top: 88px; /* Increased to match new navbar height on larger screens */
    }
}

/* Footer Styles */
.footer-custom {
    background-color: var(--body) !important;
}

.footer-link {
    text-decoration: none;
    transition: color 0.2s ease;
}

    .footer-link:hover {
        color: var(--secondary) !important;
    }

.social-link {
    transition: color 0.2s ease;
}

    .social-link:hover {
        color: var(--secondary) !important;
    }

/* Custom Bootstrap Overrides */
.btn-primary {
    background-color: var(--primary);
    border-color: var(--primary);
    color: white;
}

    .btn-primary:hover,
    .btn-primary:focus,
    .btn-primary:active {
        background-color: color-mix(in srgb, var(--primary) 85%, black);
        border-color: color-mix(in srgb, var(--primary) 85%, black);
        color: white;
    }

/* Secondary Button Overrides */
.btn-secondary {
    background-color: var(--secondary) !important;
    border-color: var(--secondary) !important;
    color: #222 !important;
}

    .btn-secondary:hover,
    .btn-secondary:focus,
    .btn-secondary:active {
        background-color: color-mix(in srgb, var(--secondary) 85%, black) !important;
        border-color: color-mix(in srgb, var(--secondary) 85%, black) !important;
        color: #222 !important;
    }

/* Utility classes for secondary color */
.border-secondary {
    border-color: var(--secondary) !important;
}

.text-secondary {
    color: var(--secondary) !important;
}

.text-primary {
    color: var(--primary) !important;
}

.bg-primary {
    background-color: var(--primary) !important;
}

/* Custom spacing utilities */
.gap-3 {
    gap: 1rem;
}

.gap-4 {
    gap: 1.5rem;
}

/* Responsive typography */
@media (min-width: 576px) {
    .container-xl {
        max-width: 1140px;
    }
}

/* Mobile menu spacing adjustments */
@media (max-width: 991.98px) {
    .navbar-nav .nav-link {
        padding: 0.75rem 0; /* Increased mobile padding */
    }

    .navbar-collapse {
        padding: 1.5rem 0;
    }
}

/* Desktop navbar spacing */
@media (min-width: 992px) {
    .navbar-nav .nav-link {
        margin: 0 0.5rem; /* Add horizontal spacing between nav items */
    }
}

/* Custom border colors to match theme */
.border-secondary {
    border-color: var(--gray-800) !important;
}

/* Text muted override for better contrast */
.text-muted {
    color: var(--gray-400) !important;
}

/* Footer bottom border */
.footer-custom .border-top {
    border-color: var(--gray-800) !important;
}

/* Home Page Specific Styles */

/* Hero Section */
.hero-section {
    min-height: 80vh;
    padding: 6rem 0 4rem 0;
}

.hero-subtitle {
    max-width: 32rem;
}

.text-white-75 {
    color: rgba(255, 255, 255, 0.8) !important;
}

.text-white-80 {
    color: rgba(255, 255, 255, 0.8) !important;
}

.text-white-90 {
    color: rgba(255, 255, 255, 0.9) !important;
}

.hero-btn,
.hero-btn-outline {
    transition: all 0.3s ease;
    transform: scale(1);
}

    .hero-btn:hover,
    .hero-btn-outline:hover {
        transform: scale(1.05);
        box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    }

/* Trust Signals */
.trust-signals {
    flex-wrap: wrap;
}

.trust-icon {
    width: 16px;
    height: 16px;
}

@media (min-width: 576px) {
    .trust-icon {
        width: 20px;
        height: 20px;
    }
}

.trust-text {
    font-size: 0.75rem;
}

@media (min-width: 576px) {
    .trust-text {
        font-size: 0.875rem;
    }
}

@media (min-width: 992px) {
    .trust-text {
        font-size: 1rem;
    }
}

.trust-divider {
    width: 1px;
    height: 1.5rem;
    background-color: #d1d5db;
}

/* Problem Section */
.problem-section {
    padding: 5rem 0;
}

.problem-subtitle {
    max-width: 48rem;
}

.problem-card {
    background-color: var(--background);
    border-radius: 1rem;
    transition: transform 0.3s ease;
}

    .problem-card:hover {
        transform: scale(1.05);
    }

.solution-card {
    background-color: var(--primary);
    border-radius: 1rem;
    transition: transform 0.3s ease;
}

    .solution-card:hover {
        transform: scale(1.05);
    }

/* About Section */
.about-section {
    padding: 5rem 0;
}

.journey-subtitle {
    max-width: 48rem;
}

.pillar-card {
    background-color: var(--background);
    transition: transform 0.3s ease;
}

    .pillar-card:hover {
        transform: scale(1.05);
    }

.pillar-icon {
    width: 4rem;
    height: 4rem;
}

/* Testimonials Section */
.testimonials-section {
    padding: 5rem 0;
}

.testimonials-subtitle {
    max-width: 48rem;
}

.testimonial-card {
    background-color: var(--background);
}

.testimonial-avatar {
    width: 12rem;
    height: 12rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

/* Services Section */
.services-section {
    padding: 4rem 0 6rem 0;
}

.service-card {
    background-color: var(--background);
    transition: all 0.3s ease;
    transform: scale(1);
}

    .service-card:hover {
        transform: scale(1.05);
        border-color: var(--primary) !important;
    }

.service-card-featured {
    background-color: var(--background);
    transition: all 0.3s ease;
    transform: scale(1.05);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

    .service-card-featured:hover {
        transform: scale(1.1);
    }

.recommended-badge {
    z-index: 10;
}

.service-features .small {
    font-size: 0.875rem;
}

/* Different Section */
.different-section {
    padding: 4rem 0 6rem 0;
}

.different-subtitle {
    max-width: 48rem;
}

.fiftyplus-way-card {
    background-color: var(--background);
}

.transform-cta {
    transition: all 0.2s ease;
    transform: scale(1);
}

    .transform-cta:hover {
        transform: scale(1.05);
        box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    }

/* Location Section */
.location-section {
    padding: 4rem 0 6rem 0;
}

/* Contact Section */
.contact-section {
    background-color: var(--background);
    padding: 4rem 0 6rem 0;
}

.contact-btn {
    transition: all 0.2s ease;
}

    .contact-btn:hover {
        background-color: color-mix(in srgb, var(--primary) 85%, black);
    }

/* Bootstrap carousel customizations */
.carousel-control-prev-icon,
.carousel-control-next-icon {
    background-color: var(--primary);
    border-radius: 50%;
    padding: 0.75rem;
}

.carousel-indicators [data-bs-target] {
    background-color: var(--primary);
}

/* Fix carousel horizontal scrollbar - comprehensive solution */
.testimonials-section {
    overflow-x: hidden;
    width: 100%;
}

    .testimonials-section .container-xl {
        overflow-x: hidden;
        max-width: 100%;
    }

#testimonialCarousel {
    overflow: hidden;
    width: 100%;
    max-width: 100%;
}

.carousel-inner {
    overflow: hidden;
    width: 100%;
}

.carousel-item {
    overflow-x: hidden;
    width: 100%;
}

.testimonial-card {
    overflow-x: hidden;
    width: 100%;
    max-width: 100%;
}

    /* Ensure rows don't overflow */
    .testimonial-card .row {
        margin-left: 0;
        margin-right: 0;
        width: 100%;
    }

        .testimonial-card .row > * {
            padding-left: 0.75rem;
            padding-right: 0.75rem;
        }

.carousel-control-prev,
.carousel-control-next {
    width: 40px;
    height: 40px;
    top: 50%;
    transform: translateY(-50%);
    opacity: 0.8;
    z-index: 5;
}

.carousel-control-prev {
    left: 5px;
}

.carousel-control-next {
    right: 5px;
}

/* More aggressive mobile fixes */
@media (max-width: 575.98px) {
    .carousel-control-prev,
    .carousel-control-next {
        display: none;
    }

    .testimonial-card {
        padding: 1rem !important;
    }

        .testimonial-card .row {
            margin: 0 !important;
        }

        .testimonial-card .col-lg-3,
        .testimonial-card .col-lg-9 {
            padding-left: 0.5rem !important;
            padding-right: 0.5rem !important;
        }

    /* Make indicators more prominent on mobile when controls are hidden */
    .carousel-indicators {
        margin-bottom: 0;
    }

        .carousel-indicators [data-bs-target] {
            width: 12px;
            height: 12px;
            margin: 0 4px;
        }
}

/* Prevent any element from causing overflow */
.testimonials-section * {
    max-width: 100%;
    box-sizing: border-box;
}

/* Responsive adjustments */
@media (max-width: 767.98px) {
    .hero-section {
        min-height: 70vh;
        padding: 4rem 0 3rem 0;
    }

    .problem-section,
    .about-section,
    .testimonials-section {
        padding: 3rem 0;
    }

    .services-section,
    .different-section,
    .location-section,
    .contact-section {
        padding: 3rem 0 4rem 0;
    }
}

/* Custom focus styles using primary brand color */
.form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.2rem rgba(58, 108, 93, 0.25);
}

.form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.2rem rgba(58, 108, 93, 0.25);
}

.form-check-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.2rem rgba(58, 108, 93, 0.25);
}

.btn:focus {
    box-shadow: 0 0 0 0.2rem rgba(58, 108, 93, 0.25);
}

/* Validation message styling */
.validation-message {
    color: #dc3545;
    font-size: 0.875rem;
    margin-top: 0.25rem;
    display: block;
}

/* Form validation error styling */
.field-validation-error {
    color: #dc3545;
    font-size: 0.875rem;
    margin-top: 0.25rem;
    display: block;
}

.input-validation-error {
    border-color: #dc3545 !important;
}image.png

.input-validation-error:focus {
    border-color: #dc3545 !important;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25) !important;
}

/* Onboarding form consistent sizing */
.onboarding-card {
    width: 100%;
    max-width: 600px;
}

/* Ensure consistent spacing even without errors */
.onboarding-card .container::before {
    content: '';
    min-height: 20px;
    display: block;
}

/* Ensure footer stays at bottom */
.onboarding-card .text-center.mt-5 {
    margin-top: auto !important;
    padding-top: 2rem;
}

/* Override Bootstrap border-primary with our custom primary color */
.border-primary {
    border-color: var(--primary) !important;
}

/* Custom card border class for secondary color */
.card-border-secondary {
    border: 2px solid var(--secondary) !important;
    border-radius: 0.75rem !important;
}

/* Success Animation Styles */
.success-animation {
    display: flex;
    justify-content: center;
    align-items: center;
}

.checkmark-circle {
    width: 80px;
    height: 80px;
    position: relative;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: scaleIn 0.5s ease-out;
}

.checkmark {
    width: 40px;
    height: 20px;
    border-left: 4px solid white;
    border-bottom: 4px solid white;
    transform: rotate(-45deg);
    animation: checkmark 0.5s ease-out 0.3s both;
}

@keyframes scaleIn {
    0% {
        transform: scale(0);
        opacity: 0;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes checkmark {
    0% {
        opacity: 0;
        transform: rotate(-45deg) scale(0.5);
    }
    100% {
        opacity: 1;
        transform: rotate(-45deg) scale(1);
    }
}

/* Loading Dots Animation */
.loading-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin: 1rem 0;
}

.dot {
    width: 12px;
    height: 12px;
    background: var(--primary);
    border-radius: 50%;
    animation: loadingDots 1.4s infinite ease-in-out;
}

.dot:nth-child(1) { animation-delay: -0.32s; }
.dot:nth-child(2) { animation-delay: -0.16s; }
.dot:nth-child(3) { animation-delay: 0s; }

@keyframes loadingDots {
    0%, 80%, 100% {
        transform: scale(0.8);
        opacity: 0.5;
    }
    40% {
        transform: scale(1);
        opacity: 1;
    }
}

/* Additional spacing consistency */

/* Mobile Navigation Styling */
@media (max-width: 991.98px) {
    .navbar-collapse {
        background-color: white;
        border: 2px solid var(--primary);
        border-radius: 8px;
        margin-top: 8px;
        padding: 1rem;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
        position: relative;
        z-index: 1040;
    }
    
    .navbar-nav .nav-link {
        padding: 0.75rem 0;
        border-bottom: 1px solid #f0f0f0;
    }
    
    .navbar-nav .nav-link:last-child {
        border-bottom: none;
    }
    
    .navbar-nav .nav-link:hover {
        background-color: rgba(58, 108, 93, 0.05);
        border-radius: 4px;
        padding-left: 0.5rem;
        padding-right: 0.5rem;
        margin-left: -0.5rem;
        margin-right: -0.5rem;
    }
    
    .d-lg-none .navbar-nav .nav-link {
        font-weight: 600;
        color: var(--primary) !important;
    }
    
    /* Mobile Login and Join Us Button Styling */
    .mobile-login-link {
        padding: 0.75rem 1rem !important;
        margin: 0.25rem 0;
        border-radius: 0.375rem;
        text-decoration: none;
        font-weight: 600;
        transition: all 0.2s ease;
    }
    
    .mobile-login-link:hover {
        background-color: rgba(58, 108, 93, 0.1);
        color: var(--primary) !important;
    }
    
    .mobile-join-btn {
        padding: 0.75rem 1.5rem !important;
        margin: 0.25rem 0;
        border-radius: 0.375rem;
        font-weight: 600;
        transition: all 0.2s ease;
        white-space: nowrap;
    }
    
    .mobile-join-btn:hover {
        transform: scale(1.02);
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    }
    
    /* Ensure proper spacing for mobile navigation items */
    .navbar-nav .d-flex {
        flex-direction: column;
        width: 100%;
    }
    
    .navbar-nav .d-flex .nav-link,
    .navbar-nav .d-flex .btn {
        margin: 0.25rem 0;
        width: 100%;
        text-align: center;
    }
}
