/* ==========================================
   KRUSHIVANDANA - CONTACT PAGE
   ========================================== */

.contact-page {
    min-height: 100vh;
    padding: 70px 6% 90px;
    background: #f7faf7;
}


/* ==========================================
   CONTACT INTRO
   ========================================== */

.contact-intro {
    max-width: 760px;
    margin: 0 auto 55px;
    text-align: center;
}

.contact-tag {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    padding: 10px 18px;
    margin-bottom: 18px;

    border-radius: 999px;

    background: #eaf6ea;
    color: #2e7d32;

    font-size: 0.9rem;
    font-weight: 600;
}

.contact-intro h1 {
    margin: 0;

    color: #1f2937;

    font-size: clamp(2.2rem, 4vw, 3.3rem);
    line-height: 1.1;
    font-weight: 700;
    letter-spacing: -1px;
}

.contact-intro h1 span {
    color: #2e7d32;
}

.contact-intro p {
    max-width: 620px;

    margin: 16px auto 0;

    color: #64748b;

    font-size: 1rem;
    line-height: 1.7;
}


/* ==========================================
   MAIN CONTACT WRAPPER
   ========================================== */

.contact-wrapper {
    width: 100%;
    max-width: 1180px;

    min-height: 600px;

    margin: 0 auto;

    display: grid;
    grid-template-columns: 0.85fr 1.15fr;

    border-radius: 28px;
    overflow: hidden;

    background: #ffffff;

    box-shadow:
        0 20px 55px rgba(31, 70, 38, 0.10);
}


/* ==========================================
   LEFT FARM PANEL
   ========================================== */

.contact-farm-panel {
    position: relative;

    padding: 48px 42px;

    display: flex;
    flex-direction: column;

    background:
        radial-gradient(
            circle at 90% 10%,
            rgba(255, 255, 255, 0.12),
            transparent 32%
        ),
        linear-gradient(
            145deg,
            #1f6f2b,
            #2e7d32 55%,
            #245f29
        );

    color: #ffffff;
}

.contact-farm-panel::after {
    content: "🌿";

    position: absolute;

    right: 25px;
    bottom: 15px;

    font-size: 8rem;

    opacity: 0.08;

    pointer-events: none;
}


/* ==========================================
   FARM LABEL
   ========================================== */

.contact-farm-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    width: fit-content;

    padding: 8px 14px;

    border: 1px solid rgba(255, 255, 255, 0.20);

    border-radius: 999px;

    background: rgba(255, 255, 255, 0.08);

    color: #ffffff;

    font-size: 0.85rem;
    font-weight: 600;
}


/* ==========================================
   FARM PANEL TEXT
   ========================================== */

.contact-farm-panel h2 {
    margin: 28px 0 12px;

    color: #ffffff;

    font-size: 2rem;
    line-height: 1.15;
    font-weight: 700;
}

.contact-farm-panel > p {
    max-width: 390px;

    margin: 0 0 35px;

    color: rgba(255, 255, 255, 0.82);

    font-size: 0.98rem;
    line-height: 1.7;
}


/* ==========================================
   CONTACT DETAILS
   ========================================== */

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 22px;

    margin-top: auto;
}

.contact-detail {
    display: flex;
    align-items: flex-start;
    gap: 14px;
}

.contact-detail-icon {
    width: 42px;
    height: 42px;

    flex: 0 0 42px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 12px;

    background: rgba(255, 255, 255, 0.13);

    color: #ffffff;

    font-size: 0.95rem;
}

.contact-detail-text h3 {
    margin: 0 0 4px;

    color: #ffffff;

    font-size: 0.9rem;
    font-weight: 600;
}

.contact-detail-text p {
    margin: 0;

    color: rgba(255, 255, 255, 0.78);

    font-size: 0.9rem;
    line-height: 1.5;
}


/* ==========================================
   RIGHT FORM PANEL
   ========================================== */

.contact-form-panel {
    padding: 48px 50px;

    background: #ffffff;
}


/* ==========================================
   FORM HEADING
   ========================================== */

.contact-form-heading {
    margin-bottom: 28px;
}

.contact-form-heading h2 {
    margin: 0 0 7px;

    color: #1f2937;

    font-size: 1.8rem;
    font-weight: 700;
}

.contact-form-heading p {
    margin: 0;

    color: #64748b;

    font-size: 0.92rem;
}


/* ==========================================
   FORM
   ========================================== */

.contact-form {
    display: grid;
    gap: 18px;
}


/* ==========================================
   TWO COLUMN FORM ROW
   ========================================== */

.contact-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}


/* ==========================================
   FORM FIELD
   ========================================== */

.contact-field {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.contact-field label {
    color: #334155;

    font-size: 0.88rem;
    font-weight: 600;
}

.contact-field input,
.contact-field textarea {
    width: 100%;
    box-sizing: border-box;

    border: 1px solid #dce5dd;

    border-radius: 11px;

    background: #f9fbf9;

    color: #1f2937;

    font-family: inherit;
    font-size: 0.93rem;

    outline: none;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}

.contact-field input {
    height: 48px;

    padding: 0 14px;
}

.contact-field textarea {
    min-height: 135px;

    padding: 13px 14px;

    resize: vertical;
}

.contact-field input::placeholder,
.contact-field textarea::placeholder {
    color: #94a3b8;
}


/* ==========================================
   INPUT FOCUS
   ========================================== */

.contact-field input:focus,
.contact-field textarea:focus {
    border-color: #2e7d32;

    background: #ffffff;

    box-shadow:
        0 0 0 3px rgba(46, 125, 50, 0.10);
}


/* ==========================================
   SUBMIT BUTTON
   ========================================== */

.contact-submit {
    width: 100%;

    min-height: 50px;

    margin-top: 4px;

    border: 0;

    border-radius: 12px;

    background: #2e7d32;

    color: #ffffff;

    font-family: inherit;

    font-size: 0.95rem;

    font-weight: 600;

    cursor: pointer;

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}

.contact-submit:hover {
    background: #256b2a;

    transform: translateY(-2px);

    box-shadow:
        0 9px 20px rgba(46, 125, 50, 0.20);
}

.contact-submit i {
    margin-left: 7px;
}


/* ==========================================
   TABLET
   ========================================== */

@media (max-width: 900px) {

    .contact-page {
        padding-left: 4%;
        padding-right: 4%;
    }

    .contact-wrapper {
        grid-template-columns: 1fr;

        max-width: 700px;
    }

    .contact-farm-panel {
        min-height: auto;
    }

    .contact-details {
        margin-top: 20px;
    }

}


/* ==========================================
   MOBILE
   ========================================== */

@media (max-width: 600px) {

    .contact-page {
        padding: 35px 16px 55px;
    }

    .contact-intro {
        margin-bottom: 25px;
    }

    .contact-intro h1 {
        font-size: 2.05rem;
        line-height: 1.12;
    }

    .contact-intro p {
        margin-top: 12px;
        font-size: 0.92rem;
        line-height: 1.55;
    }

    .contact-tag {
        padding: 9px 16px;
        margin-bottom: 15px;
    }

    .contact-wrapper {
        border-radius: 20px;
    }

    .contact-farm-panel {
        padding: 30px 22px;
    }

    .contact-farm-panel h2 {
        margin-top: 24px;
        font-size: 1.7rem;
    }

    .contact-farm-panel > p {
        margin-bottom: 28px;
        font-size: 0.92rem;
        line-height: 1.6;
    }

    .contact-details {
        gap: 18px;
    }

    .contact-detail-text p {
        font-size: 0.88rem;
    }

    .contact-form-panel {
        padding: 30px 22px;
    }

    .contact-form-heading {
        margin-bottom: 22px;
    }

    .contact-form-heading h2 {
        font-size: 1.55rem;
    }

    .contact-form {
        gap: 15px;
    }

    .contact-form-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .contact-field {
        gap: 6px;
    }

    .contact-field input {
        height: 46px;
    }

    .contact-field textarea {
        min-height: 115px;
    }

    .contact-submit {
        min-height: 48px;
    }
}


/* ==========================================
   DESKTOP VIEWPORT OPTIMIZATION
   ========================================== */

@media (min-width: 901px) {

    .contact-page {
        padding: 45px 5% 60px;
    }

    .contact-intro {
        margin-bottom: 35px;
    }

    .contact-intro .contact-tag {
        margin-bottom: 12px;
        padding: 8px 16px;
    }

    .contact-intro h1 {
        font-size: 2.8rem;
    }

    .contact-intro p {
        margin-top: 10px;
        font-size: 0.95rem;
    }

    .contact-wrapper {
        min-height: 0;
    }

    .contact-farm-panel {
        padding: 35px 42px;
    }

    .contact-form-panel {
        padding: 35px 45px;
    }

    .contact-farm-panel h2 {
        margin-top: 22px;
        margin-bottom: 10px;
        font-size: 1.85rem;
    }

    .contact-farm-panel > p {
        margin-bottom: 25px;
        font-size: 0.92rem;
        line-height: 1.55;
    }

    .contact-details {
        gap: 16px;
    }

    .contact-detail-icon {
        width: 38px;
        height: 38px;
        flex-basis: 38px;
    }

    .contact-detail-text p {
        font-size: 0.86rem;
        line-height: 1.4;
    }

    .contact-form-heading {
        margin-bottom: 22px;
    }

    .contact-form-heading h2 {
        font-size: 1.7rem;
    }

    .contact-form {
        gap: 14px;
    }

    .contact-field input {
        height: 44px;
    }

    .contact-field textarea {
        min-height: 115px;
    }

    .contact-submit {
        min-height: 46px;
    }
}




/* ==========================================
   CONTACT FORM VALIDATION
   ========================================== */

.contact-field {
    position: relative;
}

.contact-field input.input-error,
.contact-field textarea.input-error {
    border-color: #dc3545;
    background: #fffafa;
}

.contact-field input.input-error:focus,
.contact-field textarea.input-error:focus {
    border-color: #dc3545;

    box-shadow:
        0 0 0 3px rgba(220, 53, 69, 0.10);
}

.contact-field input.input-success,
.contact-field textarea.input-success {
    border-color: #2e7d32;
}

.field-error {
    display: none;

    margin-top: 2px;

    color: #dc3545;

    font-size: 0.78rem;
    line-height: 1.3;
}

.field-error.show {
    display: block;

    animation: fieldErrorIn 0.2s ease;
}

@keyframes fieldErrorIn {

    from {
        opacity: 0;
        transform: translateY(-3px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }

}


/* ==========================================
   FORM MESSAGE OVERLAY
   ========================================== */

.form-message-overlay {
    position: fixed;

    inset: 0;

    z-index: 9999;

    display: flex;

    align-items: center;
    justify-content: center;

    padding: 20px;

    background: rgba(15, 30, 20, 0.45);

    backdrop-filter: blur(5px);

    opacity: 0;
    visibility: hidden;

    transition:
        opacity 0.25s ease,
        visibility 0.25s ease;
}

.form-message-overlay.show {
    opacity: 1;
    visibility: visible;
}


/* ==========================================
   MESSAGE BOX
   ========================================== */

.form-message-box {
    width: 100%;
    max-width: 400px;

    padding: 34px 30px 30px;

    border-radius: 22px;

    background: #ffffff;

    text-align: center;

    box-shadow:
        0 25px 70px rgba(0, 0, 0, 0.18);

    transform: scale(0.88) translateY(10px);

    transition:
        transform 0.3s ease;
}

.form-message-overlay.show .form-message-box {
    transform: scale(1) translateY(0);
}


/* ==========================================
   MESSAGE ICON
   ========================================== */

.form-message-icon {
    width: 68px;
    height: 68px;

    margin: 0 auto 18px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;

    font-size: 1.7rem;
}

.form-message-box.success .form-message-icon {
    background: #e8f5e9;
    color: #2e7d32;
}

.form-message-box.error .form-message-icon {
    background: #fff0f1;
    color: #dc3545;
}


/* ==========================================
   MESSAGE TEXT
   ========================================== */

.form-message-box h3 {
    margin: 0 0 8px;

    color: #1f2937;

    font-size: 1.35rem;
    font-weight: 700;
}

.form-message-box p {
    margin: 0 auto 24px;

    max-width: 320px;

    color: #64748b;

    font-size: 0.92rem;

    line-height: 1.6;
}


/* ==========================================
   MESSAGE BUTTON
   ========================================== */

.form-message-button {
    min-width: 110px;

    min-height: 44px;

    padding: 0 22px;

    border: none;

    border-radius: 10px;

    background: #2e7d32;

    color: #ffffff;

    font-family: inherit;

    font-size: 0.9rem;

    font-weight: 600;

    cursor: pointer;

    transition:
        background 0.2s ease,
        transform 0.2s ease;
}

.form-message-button:hover {
    background: #256b2a;

    transform: translateY(-1px);
}

.form-message-box.error .form-message-button {
    background: #dc3545;
}

.form-message-box.error .form-message-button:hover {
    background: #c82333;
}


/* ==========================================
   MOBILE
   ========================================== */

@media (max-width: 600px) {

    .form-message-box {
        max-width: 340px;

        padding: 30px 22px 24px;

        border-radius: 20px;
    }

    .form-message-icon {
        width: 60px;
        height: 60px;

        font-size: 1.5rem;
    }

    .form-message-box h3 {
        font-size: 1.25rem;
    }

    .form-message-box p {
        font-size: 0.88rem;
    }

}