/* Modern custom styles with Bootstrap light theme integration */

/* Global styling enhancements */
body {
    font-family: 'Poppins', 'Roboto', sans-serif;
    line-height: 1.6;
    background-color: #f8f3e6; /* Warm beige background */
    color: #333; /* Darker text for better contrast */
}

.card {
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.15);
    border: none;
    transition: all 0.3s ease;
    margin-bottom: 1.5rem;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.2);
}

/* Enhanced Hero Section */
.hero-section {
    padding: 5rem 0 4rem;
    background: linear-gradient(rgba(234, 190, 132, 0.7), rgba(207, 158, 95, 0.85)), 
                url('../images/family_home.jpg');
    background-size: cover;
    background-position: center;
    position: relative;
    color: #333;
    border-bottom: 5px solid var(--bs-info);
}

/* Form styling improvements */
.form-control, .form-select {
    padding: 0.8rem 1rem;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.form-control:focus, .form-select:focus {
    border-color: var(--bs-info);
    box-shadow: 0 0 0 0.25rem rgba(13, 202, 240, 0.25);
    transform: scale(1.02);
}

.form-label {
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.form-check-input:checked {
    background-color: var(--bs-info);
    border-color: var(--bs-info);
}

/* Button enhancements */
.btn {
    border-radius: 10px;
    padding: 0.6rem 1.5rem;
    font-weight: 500;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    transition: all 0.3s ease;
}

.btn-info, .btn-primary {
    box-shadow: 0 4px 10px rgba(13, 202, 240, 0.3);
}

.btn-info:hover, .btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(13, 202, 240, 0.4);
}

.btn-outline-info:hover, .btn-outline-primary:hover {
    transform: translateY(-3px);
}

/* Feature cards enhancements */
.feature-card {
    height: 100%;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-radius: 16px;
    overflow: hidden;
    padding: 0.5rem;
}

.feature-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.2);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1.2rem;
    color: var(--bs-info);
    background: linear-gradient(120deg, var(--bs-info), var(--bs-primary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Loan comparison cards */
.loan-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-left: 4px solid var(--bs-info);
}

.loan-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.best-rate {
    border: 2px solid var(--bs-success);
    position: relative;
}

.best-rate::before {
    content: "Best Rate";
    position: absolute;
    top: 0;
    right: 2rem;
    background-color: var(--bs-success);
    color: white;
    padding: 0.3rem 1.5rem;
    border-radius: 0 0 10px 10px;
    font-weight: 500;
}

/* Program qualification results styling */
.results-section .card-header {
    background: linear-gradient(90deg, #0f6674, var(--bs-info));
    padding: 1.5rem;
}

.program-card {
    border-radius: 16px;
    overflow: hidden;
}

.program-card.border-success {
    border-left: 4px solid var(--bs-success) !important;
}

.program-card.border-warning {
    border-left: 4px solid var(--bs-warning) !important;
}

.program-card.border-info {
    border-left: 4px solid var(--bs-info) !important;
}

/* Education resource cards */
.resource-card {
    height: 100%;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-radius: 16px;
}

.resource-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
}

/* Crowdfunding options cards */
.crowdfunding-card {
    height: 100%;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-radius: 16px;
}

.crowdfunding-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15);
}

/* Contact section styling */
.contact-section {
    background: linear-gradient(rgba(234, 190, 132, 0.9), rgba(207, 158, 95, 0.95)), 
                url('../images/family_bbq.jpg');
    background-size: cover;
    background-position: center;
    padding: 5rem 0;
    color: #333;
    border-top: 5px solid var(--bs-info);
}

.contact-icon {
    font-size: 2.5rem;
    color: var(--bs-info);
    margin-bottom: 1rem;
}

.agent-img {
    width: 200px;
    height: 200px;
    object-fit: cover;
    border-radius: 50%;
    border: 5px solid var(--bs-info);
    margin-bottom: 1.5rem;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
}

.agent-img:hover {
    transform: scale(1.05);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.4);
}

/* Business Card Styling */
.business-card-container {
    max-width: 400px;
    margin: 2rem auto;
    perspective: 1000px;
}

.business-card {
    background: linear-gradient(135deg, #0f2027, #203a43, #2c5364);
    color: white;
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
    position: relative;
    transition: all 0.5s ease;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.business-card:hover {
    transform: translateY(-10px) rotateY(5deg);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.business-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, 
                rgba(255, 255, 255, 0.15) 0%, 
                rgba(255, 255, 255, 0) 60%);
    pointer-events: none;
}

.business-card-header {
    display: flex;
    align-items: center;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    padding-bottom: 1rem;
}

.business-card-header img {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    border: 3px solid var(--bs-info);
    margin-right: 1rem;
    object-fit: cover;
}

.business-card-name {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
    color: white;
}

.business-card-title {
    font-size: 0.9rem;
    color: var(--bs-info);
    margin: 0.2rem 0 0;
    opacity: 0.9;
}

.business-card-content {
    display: flex;
}

.business-card-info {
    flex: 1;
}

.business-card-qr {
    flex: 0 0 120px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: white;
    padding: 10px;
    border-radius: 10px;
    height: 120px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.business-card-qr img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.business-card-contact {
    list-style: none;
    padding: 0;
    margin: 0 0 1rem;
}

.business-card-contact li {
    margin-bottom: 0.7rem;
    display: flex;
    align-items: center;
}

.business-card-contact li i {
    margin-right: 0.8rem;
    color: var(--bs-info);
    width: 20px;
    text-align: center;
}

.business-card-footer {
    margin-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    padding-top: 1rem;
    font-size: 0.8rem;
    text-align: center;
    color: rgba(255, 255, 255, 0.7);
}

/* Business Card Image Container */
.business-card-img-container {
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
    transition: all 0.5s ease;
    position: relative;
}

.business-card-img-container:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

/* Video styling */
.video-container {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
    position: relative;
}

/* Face2Face Realty Branding */
.realty-brand {
    color: #0d6efd;
    font-weight: 600;
    font-size: 1.1rem;
}

/* Testimonial section */
.testimonial-card {
    border-left: 4px solid var(--bs-info);
    border-radius: 16px;
}

.testimonial-img {
    width: 70px;
    height: 70px;
    object-fit: cover;
    border-radius: 50%;
    border: 3px solid var(--bs-info);
}

/* Success stories section */
.card-img-top {
    height: 200px;
    object-fit: cover;
}

/* Custom footer */
.footer {
    padding: 3rem 0 2rem;
    margin-top: 0;
    background-color: #222222;
    color: #fff;
    border-top: 1px solid rgba(207, 158, 95, 0.3);
}

/* Animations */
.fade-in {
    animation: fadeIn 1s ease-in;
}

.slide-up {
    animation: slideUp 0.8s ease-out;
}

@keyframes fadeIn {
    0% { opacity: 0; }
    100% { opacity: 1; }
}

@keyframes slideUp {
    0% { transform: translateY(30px); opacity: 0; }
    100% { transform: translateY(0); opacity: 1; }
}

/* Animated Loan Comparison Slider */
.rate-visualization-container {
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.15);
    margin: 2rem 0;
    padding: 2rem;
    position: relative;
    background: #fff;
    border: 1px solid #ddd;
}

.rate-slider-container {
    margin: 3rem 0;
    position: relative;
    height: 300px;
}

.rate-types {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.rate-type {
    flex: 1;
    text-align: center;
    padding: 0.5rem;
    margin: 0 0.25rem;
    border-radius: 10px;
    cursor: pointer;
    border: 1px solid transparent;
    transition: all 0.3s ease;
}

.rate-type:hover, .rate-type.active {
    transform: translateY(-5px);
    border-color: var(--bs-info);
    background-color: rgba(13, 202, 240, 0.1);
}

.rate-type .rate-value {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--bs-info);
}

.rate-type .rate-name {
    font-size: 0.85rem;
    color: #666;
}

.rate-type.active .rate-name {
    color: #333;
    font-weight: bold;
}

.rate-visualization {
    position: relative;
    height: 200px;
    width: 100%;
    border-radius: 16px;
    overflow: hidden;
    background: #f0f0f0;
    border: 1px solid #ddd;
}

.rate-bar {
    position: absolute;
    bottom: 0;
    border-radius: 6px 6px 0 0;
    width: 12%;
    transition: all 1s cubic-bezier(0.68, -0.55, 0.27, 1.55);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: center;
    font-weight: bold;
    font-size: 0.85rem;
    background: linear-gradient(to top, var(--bar-color), rgba(255,255,255,0.3));
}

.rate-bar.conventional { --bar-color: var(--bs-primary); left: 10%; }
.rate-bar.fha { --bar-color: var(--bs-success); left: 28%; }
.rate-bar.va { --bar-color: var(--bs-danger); left: 46%; }
.rate-bar.usda { --bar-color: var(--bs-warning); left: 64%; }
.rate-bar.naca { --bar-color: var(--bs-info); left: 82%; }

.rate-label {
    padding: 0.5rem;
    color: white;
    position: absolute;
    width: 100%;
    text-align: center;
    top: -30px;
    font-size: 0.75rem;
    font-weight: 600;
}

.rate-value-display {
    color: white;
    padding: 0.4rem;
    border-radius: 4px;
    background-color: var(--bar-color);
    margin-bottom: 0.5rem;
}

.rate-bar:hover {
    z-index: 10;
    filter: brightness(1.2);
    box-shadow: 0 0 20px rgba(255,255,255,0.2);
}

/* Loan amount slider styles */
.loan-amount-slider {
    margin: 2rem 0;
}

.loan-slider-container {
    position: relative;
    padding: 1rem 0;
}

.loan-slider-input {
    -webkit-appearance: none;
    width: 100%;
    height: 10px;
    border-radius: 5px;
    background: linear-gradient(to right, var(--bs-info) 0%, var(--bs-primary) 100%);
    outline: none;
    padding: 0;
    margin: 0;
}

.loan-slider-input::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 25px;
    height: 25px;
    border-radius: 50%;
    background: white;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(0,0,0,0.3);
    transition: all 0.3s ease;
}

.loan-slider-input::-webkit-slider-thumb:hover {
    transform: scale(1.2);
}

.loan-slider-input::-moz-range-thumb {
    width: 25px;
    height: 25px;
    border-radius: 50%;
    background: white;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(0,0,0,0.3);
    transition: all 0.3s ease;
}

.loan-slider-input::-moz-range-thumb:hover {
    transform: scale(1.2);
}

.loan-amount-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--bs-info);
    text-align: center;
    margin: 1rem 0;
    transition: all 0.3s ease;
}

.loan-amount-range {
    display: flex;
    justify-content: space-between;
    margin-top: 0.5rem;
    color: var(--bs-gray-500);
    font-size: 0.8rem;
}

/* Monthly payment visualization */
.payment-visualization {
    margin-top: 3rem;
    position: relative;
}

.payment-circle {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    background: #fff;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.1);
    border: 1px solid #ddd;
    position: relative;
    transition: all 0.5s ease;
}

.payment-amount {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--bs-info);
}

.payment-text {
    font-size: 0.85rem;
    color: #666;
}

.payment-circle::before {
    content: '';
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    border-radius: 50%;
    background: conic-gradient(
        var(--bs-info) 0% var(--payment-percentage, 0%), 
        transparent var(--payment-percentage, 0%) 100%
    );
    opacity: 0.6;
    z-index: -1;
    transition: all 0.5s ease;
}

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

.pulse {
    animation: pulse 2s infinite;
}

.rate-update-time {
    text-align: right;
    font-size: 0.8rem;
    color: var(--bs-gray-500);
    margin-top: 1rem;
}

/* Responsive typography improvements */
@media (max-width: 768px) {
    h1 {
        font-size: 2.2rem;
    }
    h2 {
        font-size: 1.8rem;
    }
    .hero-section {
        padding: 4rem 0 3rem;
    }
    .agent-img {
        width: 160px;
        height: 160px;
    }
}
