/* =========================================================
   NEW PATIENT FORM PAGE
========================================================= */

.patient-form-page {
    background: #f7faf9;
}

.patient-form-container {
    width: min(1180px, 90%);
    margin: 0 auto;
}


/* =========================================================
   HERO
========================================================= */

.patient-form-hero {
    padding: 70px 20px 45px;
    text-align: center;
    background: #fff;
}

.patient-form-hero .eyebrow {
    margin-bottom: 12px;
}

.patient-form-hero h1 {
    font-size: clamp(2rem, 4vw, 3rem);
    margin: 0 0 18px;
}

.patient-form-intro {
    max-width: 720px;
    margin: 0 auto;
    line-height: 1.7;
    color: #5f6f6b;
    font-size: 1.05rem;
}


/* =========================================================
   FORM SECTION
========================================================= */

.patient-form-section {
    padding: 40px 0 80px;
}


/* Allows multiple forms in the future */
.forms-list {
    display: flex;
    flex-direction: column;
    gap: 25px;
}


/* =========================================================
   FORM DOCUMENT CARD
========================================================= */

.form-document-card {
    background: #fff;
    border: 1px solid #e3ece9;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.06);
    transition: box-shadow 0.25s ease, transform 0.25s ease;
}

.form-document-card:hover {
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.08);
}


/* =========================================================
   DOCUMENT HEADER
========================================================= */

.form-document-header {
    padding: 25px 30px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 25px;
}


/* =========================================================
   DOCUMENT INFORMATION
========================================================= */

.form-document-info {
    display: flex;
    align-items: center;
    gap: 18px;
    min-width: 0;
}

.pdf-icon {
    width: 55px;
    height: 55px;

    flex-shrink: 0;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 10px;

    background: #eef7f5;
    color: var(--teal);

    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.form-document-info h2 {
    margin: 0 0 6px;

    font-size: 1.25rem;
    line-height: 1.3;
}

.form-document-info p {
    margin: 0;

    color: #6c7976;
    line-height: 1.5;
    font-size: 0.95rem;
}


/* =========================================================
   FORM ACTION BUTTONS
========================================================= */

.form-actions {
    display: flex;
    align-items: center;
    gap: 10px;

    flex-shrink: 0;
}

.form-actions .btn {
    white-space: nowrap;
    cursor: pointer;
}

.view-form-btn {
    font-family: inherit;
}

.form-download-btn {
    white-space: nowrap;
}


/* =========================================================
   PDF VIEWER CONTAINER
   Hidden by default
========================================================= */

.pdf-viewer-container {
    display: none;

    width: 100%;

    background: #eef2f1;

    border-top: 1px solid #e3ece9;
}


/* Display when View Form is clicked */
.pdf-viewer-container.active {
    display: block;
}


/* =========================================================
   PDF VIEWER HEADER
========================================================= */

.pdf-viewer-header {
    min-height: 50px;

    padding: 10px 20px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 20px;

    background: #f5f8f7;

    border-bottom: 1px solid #e3ece9;
}

.pdf-viewer-header strong {
    color: #354743;
    font-size: 0.95rem;
}


/* =========================================================
   CLOSE PDF BUTTON
========================================================= */

.close-pdf-btn {
    padding: 7px 12px;

    border: 0;
    border-radius: 6px;

    background: transparent;

    color: #5d6c68;

    font-family: inherit;
    font-size: 14px;
    font-weight: 600;

    cursor: pointer;

    transition:
        background-color 0.2s ease,
        color 0.2s ease;
}

.close-pdf-btn:hover {
    background: #e8efed;
    color: var(--teal);
}


/* =========================================================
   PDF IFRAME
========================================================= */

.pdf-viewer-container iframe {
    width: 100%;
    height: 750px;

    display: block;

    border: 0;

    background: #eef2f1;
}


/* =========================================================
   PDF FALLBACK
========================================================= */

.pdf-fallback {
    display: none;

    padding: 30px 20px;

    text-align: center;

    background: #f8faf9;
}

.pdf-fallback p {
    max-width: 600px;

    margin: 0 auto 18px;

    color: #66736f;

    line-height: 1.6;
}


/* =========================================================
   RESPONSIVE - TABLET
========================================================= */

@media (max-width: 768px) {

    .patient-form-hero {
        padding: 50px 20px 35px;
    }

    .patient-form-section {
        padding: 25px 0 60px;
    }

    .patient-form-container {
        width: 92%;
    }


    /* Form Card */

    .form-document-header {
        padding: 22px;

        flex-direction: column;
        align-items: flex-start;
    }


    /* Actions */

    .form-actions {
        width: 100%;
    }

    .form-actions .btn {
        flex: 1;
        text-align: center;
    }


    /* PDF */

    .pdf-viewer-container iframe {
        height: 600px;
    }
}


/* =========================================================
   RESPONSIVE - MOBILE
========================================================= */

@media (max-width: 520px) {

    .patient-form-hero {
        padding: 40px 18px 30px;
    }

    .patient-form-hero h1 {
        font-size: 2rem;
    }

    .patient-form-intro {
        font-size: 0.95rem;
    }


    /* Document Info */

    .form-document-info {
        align-items: flex-start;
    }

    .pdf-icon {
        width: 48px;
        height: 48px;
        font-size: 11px;
    }

    .form-document-info h2 {
        font-size: 1.1rem;
    }

    .form-document-info p {
        font-size: 0.9rem;
    }


    /* Buttons */

    .form-actions {
        flex-direction: column;
    }

    .form-actions .btn {
        width: 100%;
    }


    /* PDF */

    .pdf-viewer-header {
        padding: 10px 15px;
    }

    /*
     * Embedded PDFs may not work consistently
     * on all mobile browsers.
     */
    .pdf-viewer-container iframe {
        height: 500px;
    }
}