/* Custom CSS for Form Visibility and Styling */

/* Target the estimate form and contact form specific classes found in index.blade.php */
.estimate_form input,
.estimate_form select,
.estimate_form textarea,
.contact-form-one input,
.contact-form-one select,
.contact-form-one textarea {
    background-color: #ffffff !important;
    border: 1px solid #e5e5e5 !important;
    color: #333333 !important;
    border-radius: 8px !important;
    padding: 12px 15px !important;
    font-size: 16px !important;
    transition: all 0.3s ease !important;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05) !important;
    width: 100%; /* Ensure full width */
}

/* Focus states for better UX */
.estimate_form input:focus,
.estimate_form select:focus,
.estimate_form textarea:focus,
.contact-form-one input:focus,
.contact-form-one select:focus,
.contact-form-one textarea:focus {
    border-color: #ff7f00 !important; /* Matches site primary orange */
    box-shadow: 0 4px 8px rgba(255, 127, 0, 0.1) !important;
    outline: none !important;
    background-color: #fff !important;
}

/* Ensure placeholders are visible and readable */
.estimate_form input::placeholder,
.estimate_form textarea::placeholder,
.contact-form-one input::placeholder,
.contact-form-one textarea::placeholder {
    color: #777777 !important;
    opacity: 1 !important;
}

/* select specific fix to ensure arrow is decent or standard behavior */
.estimate_form select,
.contact-form-one select {
    appearance: auto; /* Let browser handle the arrow */
    cursor: pointer;
}

/* Spacing and layout adjustments */
.contact-form-one .form-group {
    margin-bottom: 20px;
}

/* Button styling refinement if needed (inheriting mostly, just ensuring alignment) */
.estimate_form button[type="submit"],
.contact-form-one button[type="submit"] {
    margin-top: 10px;
    cursor: pointer;
}


/* --- Modern Estimate Section Styles --- */
.rts-modern-estimate-area {
    position: relative;
    background-color: #0c0a0a; /* Dark background as fallback */
    background-image: linear-gradient(rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.85)), url('../images/bg/bg-image-2.jpg'); /* Assuming this image exists or similar */
    background-size: cover;
    background-position: center;
    background-attachment: fixed; /* Parallax effect */
    overflow: hidden;
}

.modern-content {
    position: relative;
    z-index: 2;
    padding-right: 30px;
}

.modern-content .pre-title {
    display: inline-block;
    color: #ff7f00;
    font-size: 16px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 15px;
    background: rgba(255, 127, 0, 0.1);
    padding: 5px 15px;
    border-radius: 30px;
    border: 1px solid rgba(255, 127, 0, 0.2);
}

.modern-content .title-large {
    color: #ffffff;
    font-size: 48px;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 25px;
}

.modern-content .title-large span {
    color: #ff7f00; /* Primary Orange */
    position: relative;
    display: inline-block;
}

.modern-content .title-large span::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 0;
    width: 100%;
    height: 8px;
    background: rgba(255, 127, 0, 0.3);
    z-index: -1;
    transform: skewX(-15deg);
}

.modern-content .disc {
    color: #d1d1d1;
    font-size: 18px;
    line-height: 1.6;
    margin-bottom: 20px;
    font-weight: 300;
}

.modern-form-card {
    background: rgba(255, 255, 255, 0.05); /* Dark Glassmorphism base */
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
    position: relative;
    overflow: hidden;
}

.modern-form-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 127, 0, 0.15) 0%, transparent 60%);
    pointer-events: none;
    z-index: -1;
}

.modern-form-card .card-title {
    color: #ffffff;
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 30px;
    text-align: center;
}

.modern-form-card .card-title span {
    color: #ff7f00;
}

/* Override input styles specifically for this dark card to pop */
.modern-form-card input,
.modern-form-card select,
.modern-form-card textarea {
    background-color: rgba(255, 255, 255, 0.9) !important; /* Slightly transparent white for blend or solid white */
    border: 1px solid transparent !important;
}

.modern-form-card input:focus,
.modern-form-card select:focus,
.modern-form-card textarea:focus {
    background-color: #ffffff !important;
    box-shadow: 0 0 15px rgba(255, 127, 0, 0.3) !important;
}

.modern-form-card .btn-primary {
    width: 100%;
    padding: 15px;
    font-size: 18px;
    background: #ff7f00;
    border: none;
    color: white;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 50px; /* Pill shape */
    transition: all 0.4s ease;
    box-shadow: 0 10px 20px rgba(255, 127, 0, 0.4);
}

.modern-form-card .btn-primary:hover {
    background: #ffffff;
    color: #ff7f00;
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(255, 127, 0, 0.6);
}

@media (max-width: 991px) {
    .modern-content {
        padding-right: 0;
        margin-bottom: 50px;
        text-align: center;
    }
    
    .modern-form-card {
        padding: 30px 20px;
    }
}

/* --- Modern Testimonial Section Styles --- */
.rts-modern-testimonial-area {
    background-color: #f9f9f9;
    position: relative;
}

.testimonial-header {
    text-align: center;
    margin-bottom: 60px;
}

/* Reusing this style as a global utility for consistency */
.section-subtitle-pill,
.testimonial-header .sub-title {
    color: #ff7f00;
    font-size: 16px;
    font-weight: 700;
    text-transform: uppercase;
    border: 1px solid rgba(255, 127, 0, 0.2);
    padding: 6px 20px;
    border-radius: 30px;
    display: inline-block;
    margin-bottom: 15px;
    background: rgba(255, 127, 0, 0.05);
}

.testimonial-header .title {
    font-size: 42px;
    font-weight: 800;
    color: #1a1a1a;
    line-height: 1.2;
}

.modern-testimonial-box {
    background: #fff;
    padding: 40px 30px;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    position: relative;
    height: 100%;
    margin-bottom: 30px;
    border: 1px solid transparent;
}

.modern-testimonial-box:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.1);
    border-color: rgba(255, 127, 0, 0.2);
}

.testimonial-stars {
    color: #ffb800; /* Star yellow */
    margin-bottom: 20px;
    font-size: 18px;
}

.testimonial-text {
    font-size: 18px;
    line-height: 1.7;
    color: #555;
    font-style: italic;
    margin-bottom: 25px;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 15px;
}

.author-img {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #ff7f00;
}

.author-info h5 {
    font-size: 18px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 5px;
}

.author-info span {
    font-size: 14px;
    color: #888;
    text-transform: uppercase;
    font-weight: 500;
}

.quote-icon {
    position: absolute;
    top: 30px;
    right: 30px;
    font-size: 60px;
    color: rgba(255, 127, 0, 0.1);
}

/* Ensure iframe video covers the area */
.video-bg-iframe {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100vw;
    height: 100vh;
    transform: translate(-50%, -50%);
    pointer-events: none;
    object-fit: cover;
    z-index: -1;
}

/* Placeholder image overlay */
.video-placeholder {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    z-index: 1; /* On top of iframe which is z-index -1, but wait.. iframe is in .video-bg container. */
    pointer-events: none;
    transition: opacity 1s ease-out;
}

/* Note on z-index:
.video-bg has z-index -1.
If we put placeholder INSIDE .video-bg, it needs positive z-index RELATIVE TO THAT CONTEXT.
We must ensuring .video-bg itself doesn't hide behind body.
Actually, index.blade.php styles say .video-bg { z-index: -1 }.
This is tricky.
If the container is z-index -1, the children are also effectively behind everything else in the main flow (usually).
However, the iframe needs to be behind the content.
So .video-placeholder should be z-index 2 (on top of iframe), and iframe z-index 1 (or default).
Both are inside .video-bg.
*/
.video-bg {
    z-index: -1; /* Keep entire background container behind content */
}

@media (min-aspect-ratio: 16/9) {
    .video-bg-iframe {
        height: 56.25vw;
    }
}
@media (max-aspect-ratio: 16/9) {
    .video-bg-iframe {
        width: 177.78vh;
    }
}

/* --- Image Aspect Ratio Repairs --- */

/* Services Grid Images: enforce uniformity */
.rts-single-offer .thumbnail img {
    width: 100%;
    height: 250px; /* Fixed height for uniform grid */
    object-fit: cover;
    transition: transform 0.3s ease;
}

/* Hover effect for service images */
.rts-single-offer:hover .thumbnail img {
    transform: scale(1.05);
}

/* About Us Section Image: enforce cover and height consistency */
.thumbnail-about-six img {
    width: 100% !important;
    height: 100% !important; 
    min-height: 450px; /* Ensure substantial height to match text content */
    object-fit: cover !important;
    border-radius: 15px !important;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

/* FAQ / Experience Images if any */
.rts-faw-area-2 .thumbanil img {
    object-fit: cover;
    border-radius: 10px;
}

/* --- Normalize Heading Sizes --- */
:root {
    --h1: 42px; /* Reduced from ~66px */
    --h2: 36px; /* Reduced from ~48px */
    --h3: 28px; /* Reduced from ~36px */
    --h4: 24px; /* Reduced from ~30px */
    --h5: 20px; /* Reduced from ~24px */
    --h6: 18px; /* Reduced from ~20px */
}

/* Explicit Overrides just in case */
h1, .h1 { font-size: var(--h1) !important; line-height: 1.3 !important; }
h2, .h2 { font-size: var(--h2) !important; line-height: 1.3 !important; }
h3, .h3 { font-size: var(--h3) !important; line-height: 1.3 !important; }
h4, .h4 { font-size: var(--h4) !important; line-height: 1.4 !important; }
h5, .h5 { font-size: var(--h5) !important; line-height: 1.4 !important; }
h6, .h6 { font-size: var(--h6) !important; line-height: 1.4 !important; }

/* Responsive Adjustments */
@media (max-width: 991px) {
    :root {
        --h1: 36px;
        --h2: 30px;
        --h3: 24px;
        --h4: 20px;
    }
}

@media (max-width: 575px) {
    :root {
        --h1: 30px;
        --h2: 26px;
        --h3: 22px;
        --h4: 18px;
    }
}
