/* Modern Contact Page Styles - Cinematic Experience */

/* Card Containers */
.contact-info-wrapper {
    background: #ffffff;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.06);
    border: 1px solid rgba(0, 0, 0, 0.02);
    height: 100%;
}

/* Contact Info Text */
.contact-info h2 {
    font-family: var(--font-heading);
    color: var(--color-text-primary);
    font-size: 2rem;
    position: relative;
    padding-bottom: 15px;
    margin-bottom: 25px;
}

.contact-info h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background: var(--color-accent);
}

.info-item {
    margin-bottom: 25px;
}

.info-item h4 {
    color: var(--color-accent);
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 5px;
}

.info-item p {
    color: var(--color-text-secondary);
    line-height: 1.6;
}

/* Map Rounded Corners */
.map-placeholder iframe {
    border-radius: 8px;
    filter: grayscale(20%);
    transition: filter 0.3s ease;
}

.map-placeholder:hover iframe {
    filter: grayscale(0%);
}

/* =========================================================
   CINEMATIC SLIDING & CONTENT ANIMATION
========================================================= */

.contact-form-col {
    display: flex;
    justify-content: center;
    align-items: stretch;
    perspective: 1000px;
}

/* MAIN WRAPPER */
.contact-wrapper {
    display: flex;
    position: relative;
    width: 100%;
    min-height: 480px;
    /* Reduced from 580px */
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.1);
    scroll-margin-top: 100px;
    /* Fix for fixed navbar hiding top content */
}

/* PANELS */
.form-panel,
.overlay-panel {
    top: 0;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    transition: transform 0.8s cubic-bezier(0.77, 0, 0.175, 1);
    /* Luxury easing */
}

/* LEFT : FORM PANEL */
.form-panel {
    flex: 0 0 50%;
    max-width: 50%;
    width: 50%;
    background: #ffffff;
    padding: 30px 40px;
    /* Reduced top/bottom padding */
    z-index: 2;
}

/* RIGHT : OVERLAY PANEL */
.overlay-panel {
    flex: 0 0 50%;
    max-width: 50%;
    width: 50%;
    position: relative;
    overflow: hidden;
    color: #ffffff;
    padding: 30px 40px;
    /* Reduced top/bottom padding */
    text-align: center;
    align-items: center;
    z-index: 5;
}

/* Background Image via Pseudo-element (Zoom Effect) */
.overlay-panel::before {
    content: "";
    position: absolute;
    top: 0;
    left: -25%;
    width: 150%;
    height: 100%;
    background: linear-gradient(135deg, rgba(134, 63, 29, 0.85) 0%, rgba(107, 66, 66, 0.9) 100%),
        url('../images/interiorherosection.png');
    background-size: cover;
    background-position: center;
    z-index: -1;
    transform: translateX(0);
    transition: transform 0.8s cubic-bezier(0.77, 0, 0.175, 1);
}

.form-panel select {
    width: 100%;
    margin-bottom: 12px;
    /* Reduced */
    padding: 14px 18px;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
    background: #f9f9f9;
    font-size: 0.95rem;
    color: #444;
}

/* === CONTENT STAGGER ANIMATIONS === */
/* Initially Visible Content inside Panels */
.form-panel>*,
.overlay-content>* {
    transition: transform 0.6s ease, opacity 0.6s ease;
    /* Default state is visible */
    opacity: 1;
    transform: translateY(0);
}


/* === DESKTOP ANIMATION LOGIC === */
@media (min-width: 992px) {

    /* Active State: Form Moves Right */
    .contact-wrapper.active .form-panel {
        transform: translateX(100%);
    }

    /* Active State: Overlay Moves Left */
    .contact-wrapper.active .overlay-panel {
        transform: translateX(-100%);
    }

    /* Parallax & Zoom on Overlay Background */
    .contact-wrapper.active .overlay-panel::before {
        transform: translateX(10%) scale(1.1);
        /* Subtle zoom + pan */
    }

    /* === STAGGERED CONTENT REVEAL === */
    /* When active, manipulate opacity/transform for effect */

    /* HIDE FORM CONTENT when it moves (optional, or just slide) */
    /* Let's make the form content Fade Out slightly as it slides away? No, keep it simple. */

    /* ANIMATE OVERLAY CONTENT entrance */
    .contact-wrapper.active .overlay-content h2 {
        animation: slideUpFade 0.8s forwards 0.2s;
    }

    .contact-wrapper.active .overlay-content p {
        animation: slideUpFade 0.8s forwards 0.3s;
    }

    .contact-wrapper.active .overlay-content button {
        animation: slideUpFade 0.8s forwards 0.4s;
    }

    @keyframes slideUpFade {
        from {
            opacity: 0;
            transform: translateY(30px);
        }

        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
}


/* CONTENT STYLING */
.form-panel h2 {
    font-family: var(--font-heading);
    color: var(--color-text-primary);
    font-size: 2rem;
    margin-bottom: 10px;
}

.form-panel p {
    color: var(--color-text-secondary);
    margin-bottom: 30px;
    font-size: 1rem;
}

/* LUXURY FORM ELEMENTS (Underline Style) */
.form-panel input,
.form-panel select,
.form-panel textarea {
    width: 100%;
    margin-bottom: 18px;
    /* Reduced */
    padding: 15px 0;
    /* No side padding for sleek text align */
    border-radius: 0;
    border: none;
    border-bottom: 1px solid #d1d1d1;
    background: transparent;
    font-family: var(--font-body);
    font-size: 1.05rem;
    color: var(--color-text-primary);
    transition: all 0.4s ease;

    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
}

/* Custom Select Arrow */
.form-panel select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23863f1d' d='M6 8.825L1.175 4 2.238 2.938 6 6.7l3.763-3.762L1.175 4z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0 center;
    cursor: pointer;
    color: #555;
}

/* Placeholder Color */
.form-panel input::placeholder,
.form-panel textarea::placeholder {
    color: #999;
    font-weight: 300;
}

.form-panel textarea {
    resize: none;
    height: 100px;
    padding-top: 20px;
}

/* Focus State - Luxury Reveal */
.form-panel input:focus,
.form-panel select:focus,
.form-panel textarea:focus {
    outline: none;
    border-bottom: 2px solid var(--color-accent);
    background: linear-gradient(to bottom, transparent 95%, rgba(134, 63, 29, 0.03) 100%);
    box-shadow: none;
}

/* SUBMIT BUTTON - HIGH END */
.form-panel button {
    width: 100%;
    padding: 18px;
    background: var(--color-accent);
    color: #ffffff;
    border: 1px solid var(--color-accent);
    border-radius: 4px;
    /* Sharper, more formal */
    font-family: var(--font-heading);
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    margin-top: 20px;
    box-shadow: 0 10px 30px rgba(107, 66, 66, 0.15);
}

.form-panel button:hover {
    background: #502b2b;
    /* Darker luxury */
    border-color: #502b2b;
    transform: translateY(-4px);
    box-shadow: 0 15px 35px rgba(107, 66, 66, 0.25);
    letter-spacing: 3px;
}

/* Overlay Elements */
.overlay-content {
    max-width: 100%;
    position: relative;
    z-index: 10;
}

.overlay-panel h2 {
    font-family: var(--font-heading);
    font-size: 2.4rem;
    margin-bottom: 20px;
    color: #fff;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.overlay-panel p {
    color: rgba(255, 255, 255, 0.95);
    line-height: 1.8;
    margin-bottom: 40px;
    font-size: 1.1rem;
}

.overlay-panel button {
    padding: 14px 36px;
    border-radius: 30px;
    border: 2px solid #ffffff;
    background: transparent;
    color: #ffffff;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.overlay-panel button:hover {
    background: #ffffff;
    color: var(--color-accent);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    transform: translateY(-2px);
}

/* === MOBILE RESPONSIVENESS === */
@media (max-width: 991px) {
    .contact-wrapper {
        display: block;
        position: relative;
        /* Mobile height logic */
    }

    .form-panel {
        width: 100%;
        max-width: 100%;
        flex: none;
        position: relative;
        padding: 40px 20px;
    }

    .overlay-panel {
        width: 100%;
        max-width: 100%;
        flex: none;
        position: absolute;
        top: 0;
        left: 0;
        height: 100%;
        /* Start hidden (off screen right) */
        transform: translateX(100%);
        padding: 40px 20px;
        z-index: 50;
        /* Ensure on top */
    }

    .overlay-panel::before {
        left: 0;
        width: 100%;
        /* No parallax on mobile for performance/simplicity */
        transform: none !important;
    }

    /* Active Animation on Mobile: SLIDE OVER */
    .contact-wrapper.active .form-panel {
        /* Form stays put or slides slightly left for depth */
        transform: translateX(-20%);
        opacity: 0.5;
        /* Dim slightly */
    }

    .contact-wrapper.active .overlay-panel {
        /* Overlay slides in perfectly from right to 0 */
        transform: translateX(0);
        box-shadow: -10px 0 30px rgba(0, 0, 0, 0.2);
        /* Shadow on left edge */
    }
}


.success-message {
    display: none;
    text-align: center;
    margin-top: 30px;
    padding: 25px;
    border-radius: 10px;
    background: #f4fbf6;
    border: 1px solid #cce8d8;
    color: #2f6b4f;
    animation: fadeIn 0.5s ease-in-out;
}

.success-message i {
    font-size: 48px;
    color: #3aa76d;
    margin-bottom: 15px;
}

.success-message h3 {
    margin-bottom: 8px;
    font-weight: 700;
}

.success-message p {
    color: #4a6f5c;
    font-size: 0.95rem;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
