/* CanadaCashHomes Main Stylesheet */

/* Trust Gradient */
.trust-gradient {
    background: linear-gradient(135deg, #374151 0%, #4b5563 100%);
}

.credibility-bg {
    position: relative;
    overflow: hidden;
    min-height: 600px;
}

/* Hero Image Slider Styles */
.hero-slider {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.hero-slide.active {
    opacity: 1;
}

.hero-slide::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(55, 65, 81, 0.45), rgba(75, 85, 99, 0.35));
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-nav {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    display: flex;
    gap: 10px;
}

.hero-dot {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: background 0.3s ease;
}

.hero-dot.active {
    background: rgba(255, 255, 255, 1);
}

.hero-arrows {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    padding: 15px 20px;
    font-size: 24px;
    cursor: pointer;
    z-index: 3;
    transition: background 0.3s ease;
}

.hero-arrows:hover {
    background: rgba(0, 0, 0, 0.7);
}

.hero-prev {
    left: 20px;
}

.hero-next {
    right: 20px;
}

.hero-cta-btn {
    background: linear-gradient(45deg, #ea580c, #dc2626);
    transition: all 0.3s ease;
}

.hero-cta-btn:hover {
    background: linear-gradient(45deg, #dc2626, #b91c1c);
    transform: translateY(-2px);
}

/* Trust card styles */
.trust-card {
    background: white;
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    text-align: center;
    transition: transform 0.3s ease;
}

.trust-card:hover {
    transform: translateY(-5px);
}

.trust-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.trust-title {
    font-size: 1.5rem;
    font-weight: bold;
    color: #1f2937;
    margin-bottom: 1rem;
}

.trust-description {
    color: #6b7280;
    line-height: 1.6;
}

/* Mobile floating call button */
.mobile-call-btn {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: linear-gradient(45deg, #ea580c, #dc2626);
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    z-index: 1000;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* Trust badge spacing - Enhanced visibility */
.trust-badge {
    display: flex !important;
    align-items: center;
    padding: 0.25rem 0.5rem;
    margin: 0 0.25rem;
    flex-shrink: 0;
    white-space: nowrap;
}

/* Trust bar container - ensure visibility */
.trust-bar {
    background-color: #374151 !important;
    color: white !important;
    padding: 0.75rem 0 !important;
    display: block !important;
    width: 100% !important;
}

.trust-content {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    flex-wrap: wrap !important;
    gap: 0.25rem !important;
    font-size: 0.75rem !important;
    font-weight: 500 !important;
}

/* Form validation styles - softer, less aggressive */
.form-error {
    border-color: #f59e0b !important;
    background-color: #fffbeb;
}

.error-message {
    color: #f59e0b;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

.field-feedback.error {
    color: #f59e0b;
    font-weight: 500;
}

/* Loading states */
.loading {
    opacity: 0.7;
    pointer-events: none;
}

.spinner {
    border: 2px solid #f3f3f3;
    border-top: 2px solid #6b7280;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    animation: spin 1s linear infinite;
    display: inline-block;
    margin-right: 10px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Enhanced UX Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes bounceSubtle {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-3px); }
    60% { transform: translateY(-2px); }
}

.animate-fade-in {
    animation: fadeIn 1s ease-out;
}

.animate-bounce-subtle {
    animation: bounceSubtle 2s infinite;
}

/* Enhanced Form Styles */
.form-step {
    transition: all 0.3s ease;
}

.form-step.hidden {
    opacity: 0;
    transform: translateX(20px);
    pointer-events: none;
}

.form-step.active {
    opacity: 1;
    transform: translateX(0);
}

.form-field {
    transition: all 0.3s ease;
    color: #111827 !important;
    background-color: white !important;
}

.form-field:focus {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    color: #111827 !important;
    background-color: white !important;
}

.form-field::placeholder {
    color: #6b7280 !important;
}

/* Form Labels and Text */
.form-field-container label {
    color: #111827 !important;
    font-weight: 600 !important;
}

/* Button Text Visibility */
.property-type-btn,
.condition-btn,
.timeline-btn,
.reason-btn {
    color: #111827 !important;
    background-color: white !important;
}

.property-type-btn:hover,
.condition-btn:hover,
.timeline-btn:hover,
.reason-btn:hover {
    color: #ea580c !important;
    background-color: #fff7ed !important;
}

.field-valid {
    animation: fadeIn 0.3s ease;
}

.field-feedback {
    transition: all 0.3s ease;
}

.field-feedback.error {
    color: #ef4444;
}

.field-feedback.success {
    color: #10b981;
}

/* Property Type Selection */
.property-type-btn.selected,
.condition-btn.selected,
.timeline-btn.selected,
.reason-btn.selected {
    background-color: #ea580c !important;
    border-color: #ea580c !important;
    color: white !important;
}

/* Step-specific styling to ensure proper visibility */
.form-step-2 .property-type-btn.selected {
    background-color: #f3f4f6 !important;
    border-color: #d1d5db !important;
    color: #6b7280 !important;
    opacity: 0.7;
}

/* Enhanced Form Validation States */
.form-success {
    border-color: #10b981 !important;
    background-color: #f0fdf4;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
    color: #374151 !important;
}

.form-warning {
    border-color: #f59e0b !important;
    background-color: #fffbeb;
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.1);
    color: #374151 !important;
}

.form-error {
    color: #374151 !important;
}

.field-feedback.success {
    color: #10b981;
    font-weight: 500;
}

.field-feedback.warning {
    color: #f59e0b;
    font-weight: 500;
}

/* Shake animation for errors */
@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-3px); }
    20%, 40%, 60%, 80% { transform: translateX(3px); }
}

/* Form Status Messages - Enhanced Visibility */
.form-status {
    margin-top: 1.5rem !important;
    margin-bottom: 1.5rem !important;
}

.form-status > div {
    font-size: 1.1rem !important;
    font-weight: 600 !important;
    padding: 1.5rem 1rem !important;
    border-radius: 0.75rem !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15) !important;
    animation: fadeIn 0.5s ease !important;
}

.form-status .bg-green-100 {
    background-color: #dcfce7 !important;
    border: 2px solid #16a34a !important;
    color: #15803d !important;
}

.form-status .bg-red-100 {
    background-color: #fef2f2 !important;
    border: 2px solid #dc2626 !important;
    color: #dc2626 !important;
}

/* Building Bars Logo - Gray Theme */
.building-bars-logo {
    display: flex;
    align-items: flex-end;
    height: 32px;
    gap: 2px;
}

.bar {
    background: linear-gradient(to bottom, #6b7280, #4b5563);
    border-radius: 2px 2px 0 0;
}

.bar-1 { width: 3px; height: 16px; }
.bar-2 { width: 3px; height: 22px; }
.bar-3 { width: 3px; height: 32px; }
.bar-4 { width: 3px; height: 28px; }
.bar-5 { width: 3px; height: 20px; }
.bar-6 { width: 3px; height: 26px; }
.bar-7 { width: 3px; height: 14px; }

/* Footer Building Bars Logo */
footer .building-bars-logo {
    display: flex;
    align-items: flex-end;
    height: 24px;
    gap: 2px;
}

footer .bar {
    background: linear-gradient(to bottom, #9ca3af, #6b7280);
    border-radius: 2px 2px 0 0;
}

footer .bar-1 { width: 2px; height: 12px; }
footer .bar-2 { width: 2px; height: 16px; }
footer .bar-3 { width: 2px; height: 24px; }
footer .bar-4 { width: 2px; height: 20px; }
footer .bar-5 { width: 2px; height: 14px; }
footer .bar-6 { width: 2px; height: 18px; }
footer .bar-7 { width: 2px; height: 10px; }

/* Mobile Responsiveness */
@media (max-width: 640px) {
    .trust-badge {
        margin: 0.125rem;
        padding: 0.125rem 0.25rem;
        font-size: 0.7rem;
    }
    
    .trust-content {
        font-size: 0.7rem !important;
        gap: 0.125rem !important;
    }
}

/* Enhanced Mobile Responsiveness */
@media (max-width: 768px) {
    .hero-arrows {
        padding: 10px 15px;
        font-size: 18px;
    }
    
    .hero-prev {
        left: 10px;
    }
    
    .hero-next {
        right: 10px;
    }
    
    .form-field {
        font-size: 16px; /* Prevents zoom on iOS */
    }
    
    /* Mobile Logo Adjustments */
    .building-bars-logo {
        height: 24px;
        gap: 1px;
    }
    
    .bar-1 { width: 2px; height: 12px; }
    .bar-2 { width: 2px; height: 16px; }
    .bar-3 { width: 2px; height: 24px; }
    .bar-4 { width: 2px; height: 20px; }
    .bar-5 { width: 2px; height: 14px; }
    .bar-6 { width: 2px; height: 18px; }
    .bar-7 { width: 2px; height: 10px; }
    
    /* Mobile Form Improvements */
    .hero-content .grid {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }
    
    .form-step .grid {
        grid-template-columns: 1fr !important;
        gap: 1rem !important;
    }
    
    /* Mobile Hero Text */
    .hero-title {
        font-size: 2.5rem !important;
        line-height: 1.1 !important;
        margin-bottom: 1.5rem !important;
    }
    
    .hero-description {
        font-size: 1.1rem !important;
        margin-bottom: 1.5rem !important;
    }
    
    /* Mobile Form Container - Fixed overlap with floating button */
    #hero-form {
        padding: 1.5rem !important;
        margin-top: 2rem;
        margin-bottom: 100px !important; /* Space for floating call button */
    }
    
    /* Mobile Button Improvements */
    .hero-cta-btn {
        padding: 1rem 1.5rem !important;
        font-size: 1rem !important;
        width: 100%;
        text-align: center;
    }
    
    /* Mobile Form Fields */
    .form-field {
        padding: 0.875rem !important;
        font-size: 1rem !important;
    }
    
    /* Mobile Property Type Buttons */
    .property-type-btn {
        min-height: 44px;
        padding: 0.75rem !important;
    }
    
    /* Mobile Sticky Call Button */
    .mobile-sticky-call {
        position: fixed;
        bottom: 20px;
        right: 20px;
        z-index: 1000;
        width: 60px;
        height: 60px;
        border-radius: 50%;
        background: linear-gradient(45deg, #ea580c, #dc2626);
        box-shadow: 0 4px 12px rgba(0,0,0,0.3);
        display: flex;
        align-items: center;
        justify-content: center;
        animation: pulse 2s infinite;
    }
    
    .mobile-sticky-cta {
        position: fixed;
        bottom: 20px;
        left: 20px;
        right: 80px;
        z-index: 1000;
        background: #374151;
        color: white;
        padding: 12px 16px;
        border-radius: 25px;
        font-weight: 600;
        text-center;
        box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    }
    
    /* Additional mobile body spacing to prevent overlap with floating button */
    body {
        padding-bottom: 100px;
    }
    
    /* Hero section mobile adjustment */
    .credibility-bg {
        padding-bottom: 120px !important;
    }
    
    /* Mobile hero image slider - ensure images display */
    .hero-slide {
        background-attachment: scroll !important; /* Fix for mobile */
        background-size: cover !important;
        background-position: center center !important;
        min-height: 100vh !important;
    }
    
    /* Ensure hero background displays on mobile devices */
    @supports (-webkit-touch-callout: none) {
        .hero-slide {
            background-attachment: scroll !important;
        }
    }
}