/* =========================================================
   CONTACT.CSS
   Student Performance Analytics Portal
   Contact Page
   ========================================================= */


/* ==================== PAGE FOUNDATION ==================== */

#main-content {
    width: 100%;
}


/* ==================== CONTACT PAGE HEADER ==================== */

/* main#main-content>.dashboard-header {
    width: min(1180px, calc(100% - 40px));

    margin: 0 auto;

    padding: 42px 20px 24px;

    text-align: center;
}


main#main-content>.dashboard-header h1,
main#main-content>.dashboard-header h2 {
    margin: 0;

    color: #172033;

    font-weight: 700;

    letter-spacing: -0.4px;
}


main#main-content>.dashboard-header h1 {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
}


main#main-content>.dashboard-header h2 {
    font-size: clamp(1.35rem, 3vw, 1.8rem);
}


main#main-content>.dashboard-header p {
    max-width: 680px;

    margin: 10px auto 0;

    color: #64748b;

    font-size: 0.88rem;

    line-height: 1.7;
} */



/* =========================================================
   PROFESSIONAL PAGE HEADER
   Used by Dashboard, Profile, Contact, etc.
   ========================================================= */

.dashboard-header {
    position: relative;

    width: calc(100% - 40px);
    max-width: 1250px;

    margin: 24px auto 30px;

    padding: 48px 40px;

    text-align: center;

    background: linear-gradient(135deg,
            #312e81 0%,
            #4338ca 50%,
            #5b4fd4 100%);

    border-radius: 24px;

    overflow: hidden;

    box-shadow:
        0 20px 45px rgba(49, 46, 129, 0.18),
        0 8px 20px rgba(0, 0, 0, 0.08);

    color: #ffffff;

    isolation: isolate;
}


/* Decorative background circle - left */

.dashboard-header::before {
    content: "";

    position: absolute;

    width: 150px;
    height: 150px;

    left: -35px;
    bottom: -50px;

    border-radius: 50%;

    background: rgba(255, 255, 255, 0.08);

    z-index: -1;
}


/* Decorative background circle - right */

.dashboard-header::after {
    content: "";

    position: absolute;

    width: 180px;
    height: 180px;

    right: -5px;
    top: -55px;

    border-radius: 50%;

    background: rgba(255, 255, 255, 0.10);

    z-index: -1;
}


/* Main heading */

.dashboard-header h1,
.dashboard-header h2 {
    position: relative;

    margin: 0 0 14px;

    text-align: center;

    color: #ffffff;

    font-size: clamp(2rem, 4vw, 3rem);

    font-weight: 700;

    line-height: 1.15;

    letter-spacing: -0.8px;
}


/* Subtitle */

.dashboard-header p {
    position: relative;

    max-width: 850px;

    margin: 0 auto;

    text-align: center;

    color: rgba(255, 255, 255, 0.82);

    font-size: 1.05rem;

    font-weight: 400;

    line-height: 1.7;
}


/* =========================================================
   DARK MODE
   ========================================================= */

body.dark-mode .dashboard-header {
    background: linear-gradient(135deg,
            #1e1b4b 0%,
            #312e81 50%,
            #4338ca 100%);

    box-shadow:
        0 20px 45px rgba(0, 0, 0, 0.35),
        0 8px 20px rgba(0, 0, 0, 0.25);
}

body.dark-mode .dashboard-header::before {
    background: rgba(255, 255, 255, 0.05);
}

body.dark-mode .dashboard-header::after {
    background: rgba(255, 255, 255, 0.07);
}


/* =========================================================
   RESPONSIVE
   ========================================================= */

@media (max-width: 768px) {

    .dashboard-header {
        width: calc(100% - 24px);

        margin: 18px auto 25px;

        padding: 38px 22px;

        border-radius: 20px;
    }

    .dashboard-header h1,
    .dashboard-header h2 {
        font-size: 2rem;
    }

    .dashboard-header p {
        font-size: 0.95rem;
        line-height: 1.6;
    }
}


@media (max-width: 480px) {

    .dashboard-header {
        width: calc(100% - 16px);

        padding: 32px 18px;

        border-radius: 18px;
    }

    .dashboard-header h1,
    .dashboard-header h2 {
        font-size: 1.7rem;
    }

    .dashboard-header p {
        font-size: 0.9rem;
    }
}


/* ==================== CONTACT FORM SECTION ==================== */

#contactSection.form-container {
    width: min(820px, calc(100% - 40px));

    margin: 0 auto 20px;

    display: flex;

    justify-content: center;
}


#contactSection .form-box {
    width: 100%;

    padding: 32px;

    background: #ffffff;

    border: 1px solid #e2e8f0;

    border-radius: 18px;

    box-shadow:
        0 14px 35px rgba(15, 23, 42, 0.08);
}


#contactSection .form-box h2 {
    margin: 0 0 24px;

    color: #1e293b;

    font-size: 1.25rem;

    font-weight: 700;

    text-align: center;
}


/* ==================== FORM ==================== */

#contactForm {
    width: 100%;
}


#contactForm .input-group {
    margin-bottom: 18px;
}


#contactForm .input-group label {
    display: block;

    margin-bottom: 7px;

    color: #334155;

    font-size: 0.8rem;

    font-weight: 600;
}


#contactForm input,
#contactForm select,
#contactForm textarea {
    width: 100%;

    border: 1px solid #d7dee8;

    border-radius: 10px;

    background: #ffffff;

    color: #0f172a;

    font-family: inherit;

    font-size: 0.82rem;

    outline: none;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}


#contactForm input,
#contactForm select {
    min-height: 46px;

    padding: 10px 13px;
}


#contactForm textarea {
    min-height: 145px;

    padding: 12px 13px;

    resize: vertical;

    line-height: 1.6;
}


#contactForm input::placeholder,
#contactForm textarea::placeholder {
    color: #94a3b8;
}


#contactForm input:hover,
#contactForm select:hover,
#contactForm textarea:hover {
    border-color: #a5b4fc;
}


#contactForm input:focus,
#contactForm select:focus,
#contactForm textarea:focus {
    border-color: #4f46e5;

    box-shadow:
        0 0 0 3px rgba(79, 70, 229, 0.09);
}


/* ==================== SELECT ==================== */

#contactPriority {
    cursor: pointer;

    appearance: auto;
}


/* ==================== CHARACTER COUNTER ==================== */

#contactForm small,
#contactMessage+small {
    display: block;

    margin-top: 5px;

    color: #94a3b8;

    font-size: 0.66rem;

    text-align: right;
}


/* ==================== SEND BUTTON ==================== */

#sendMessageBtn {
    width: 100%;

    min-height: 48px;

    margin-top: 4px;

    border: 0;

    border-radius: 10px;

    background: linear-gradient(135deg,
            #312e81,
            #4f46e5);

    color: #ffffff;

    font-family: inherit;

    font-size: 0.84rem;

    font-weight: 600;

    cursor: pointer;

    box-shadow:
        0 7px 16px rgba(49, 46, 129, 0.18);

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease,
        filter 0.2s ease;
}


#sendMessageBtn:hover {
    transform: translateY(-1px);

    box-shadow:
        0 10px 22px rgba(49, 46, 129, 0.23);

    filter: brightness(1.04);
}


#sendMessageBtn:active {
    transform: translateY(0);
}


#sendMessageBtn:focus-visible {
    outline: 3px solid rgba(79, 70, 229, 0.2);

    outline-offset: 3px;
}


/* ==================== CONTACT INFORMATION CARDS ==================== */

main#main-content>.dashboard-cards {
    width: min(1180px, calc(100% - 40px));

    margin: 0 auto 26px;

    display: grid;

    grid-template-columns: repeat(4, minmax(0, 1fr));

    gap: 18px;
}


main#main-content>.dashboard-cards .card {
    min-width: 0;

    padding: 24px;

    background: #ffffff;

    border: 1px solid #e2e8f0;

    border-radius: 16px;

    box-shadow:
        0 10px 25px rgba(15, 23, 42, 0.06);

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease,
        border-color 0.2s ease;
}


main#main-content>.dashboard-cards .card:hover {
    transform: translateY(-3px);

    border-color: #c7d2fe;

    box-shadow:
        0 15px 30px rgba(15, 23, 42, 0.09);
}


main#main-content>.dashboard-cards .card h3 {
    margin: 0 0 12px;

    color: #1e293b;

    font-size: 0.92rem;

    font-weight: 650;
}


main#main-content>.dashboard-cards .card p {
    margin: 0;

    color: #64748b;

    font-size: 0.76rem;

    line-height: 1.75;
}


main#main-content>.dashboard-cards .card h2 {
    margin: 8px 0 0;

    color: #312e81;

    font-size: 1.55rem;

    font-weight: 700;
}


/* ==================== SUPPORT SERVICES ==================== */

#ticketCount {
    color: #4f46e5;
}


/* ==================== LOCATION MAP ==================== */

main#main-content>.dashboard-cards .card iframe {
    display: block;

    width: 100%;

    min-height: 350px;

    border: 0;

    border-radius: 10px;
}


/* Map card */

main#main-content>.dashboard-cards:has(iframe) {
    grid-template-columns: 1fr;
}


main#main-content>.dashboard-cards:has(iframe) .card {
    padding: 14px;
}


/* ==================== NOTIFICATION PANEL ==================== */

#notificationPanel.notification-panel {
    position: fixed;

    top: 82px;

    right: 22px;

    z-index: 5000;

    width: min(380px, calc(100vw - 30px));

    max-height: min(620px, calc(100vh - 105px));

    overflow: hidden;

    display: flex;

    flex-direction: column;

    background: #ffffff;

    border: 1px solid #e2e8f0;

    border-radius: 16px;

    box-shadow:
        0 20px 50px rgba(15, 23, 42, 0.18);

    opacity: 0;

    visibility: hidden;

    transform: translateY(-10px);

    pointer-events: none;

    transition:
        opacity 0.2s ease,
        transform 0.2s ease,
        visibility 0.2s ease;
}


#notificationPanel.active,
#notificationPanel[aria-hidden="false"] {
    opacity: 1;

    visibility: visible;

    transform: translateY(0);

    pointer-events: auto;
}


#notificationPanel .notification-header {
    display: flex;

    align-items: center;

    justify-content: space-between;

    padding: 16px 18px;

    border-bottom: 1px solid #e2e8f0;
}


#notificationPanel .notification-header h3 {
    margin: 0;

    color: #1e293b;

    font-size: 0.9rem;
}


#closeNotifications {
    width: 34px;
    height: 34px;

    border: 0;

    border-radius: 8px;

    background: #f1f5f9;

    color: #64748b;

    cursor: pointer;
}


#closeNotifications:hover {
    background: #fee2e2;

    color: #dc2626;
}


#notificationSearch {
    margin: 12px 14px;

    width: calc(100% - 28px);

    min-height: 40px;

    padding: 9px 12px;

    border: 1px solid #d7dee8;

    border-radius: 9px;

    background: #f8fafc;

    color: #0f172a;

    font-family: inherit;

    font-size: 0.75rem;

    outline: none;
}


#notificationSearch:focus {
    border-color: #4f46e5;

    box-shadow:
        0 0 0 3px rgba(79, 70, 229, 0.08);
}


#notificationList {
    flex: 1;

    overflow-y: auto;

    padding: 4px 14px 14px;
}


/* ==================== DARK THEME ==================== */

.dark-theme main#main-content>.dashboard-header h1,
.dark-theme main#main-content>.dashboard-header h2 {
    color: #f8fafc;
}


.dark-theme main#main-content>.dashboard-header p {
    color: #94a3b8;
}


.dark-theme #contactSection .form-box,
.dark-theme main#main-content>.dashboard-cards .card {
    background: #111827;

    border-color: #334155;

    box-shadow:
        0 15px 35px rgba(0, 0, 0, 0.22);
}


.dark-theme #contactSection .form-box h2,
.dark-theme #contactForm .input-group label,
.dark-theme main#main-content>.dashboard-cards .card h3 {
    color: #e2e8f0;
}


.dark-theme #contactForm input,
.dark-theme #contactForm select,
.dark-theme #contactForm textarea {
    background: #1e293b;

    border-color: #334155;

    color: #f8fafc;
}


.dark-theme #contactForm input::placeholder,
.dark-theme #contactForm textarea::placeholder {
    color: #64748b;
}


.dark-theme #contactForm small,
.dark-theme main#main-content>.dashboard-cards .card p {
    color: #94a3b8;
}


.dark-theme main#main-content>.dashboard-cards .card h2 {
    color: #a5b4fc;
}


.dark-theme main#main-content>.dashboard-cards .card:hover {
    border-color: #4f46e5;

    box-shadow:
        0 15px 35px rgba(0, 0, 0, 0.28);
}


.dark-theme #notificationPanel.notification-panel {
    background: #111827;

    border-color: #334155;
}


.dark-theme #notificationPanel .notification-header {
    border-bottom-color: #334155;
}


.dark-theme #notificationPanel .notification-header h3 {
    color: #f8fafc;
}


.dark-theme #closeNotifications {
    background: #1e293b;

    color: #94a3b8;
}


.dark-theme #closeNotifications:hover {
    background: #7f1d1d;

    color: #fecaca;
}


.dark-theme #notificationSearch {
    background: #1e293b;

    border-color: #334155;

    color: #f8fafc;
}


/* ==================== RESPONSIVE ==================== */

@media (max-width: 1000px) {

    main#main-content>.dashboard-cards {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

}


@media (max-width: 700px) {

    main#main-content>.dashboard-header {
        width: min(100% - 28px, 700px);

        padding: 30px 12px 18px;
    }


    #contactSection.form-container {
        width: calc(100% - 28px);
    }


    #contactSection .form-box {
        padding: 24px 20px;
    }


    main#main-content>.dashboard-cards {
        width: calc(100% - 28px);

        grid-template-columns: 1fr;

        gap: 14px;
    }


    main#main-content>.dashboard-cards .card {
        padding: 20px;
    }


    #notificationPanel.notification-panel {
        top: 70px;

        right: 14px;

        width: calc(100vw - 28px);
    }

}


@media (max-width: 480px) {

    main#main-content>.dashboard-header h1 {
        font-size: 1.7rem;
    }


    main#main-content>.dashboard-header h2 {
        font-size: 1.3rem;
    }


    main#main-content>.dashboard-header p {
        font-size: 0.78rem;
    }


    #contactSection .form-box {
        padding: 22px 16px;

        border-radius: 14px;
    }


    #contactSection .form-box h2 {
        font-size: 1.1rem;
    }


    #contactForm input,
    #contactForm select {
        min-height: 44px;
    }


    #contactForm textarea {
        min-height: 125px;
    }


    main#main-content>.dashboard-cards .card iframe {
        min-height: 280px;
    }

}


/* ==================== ACCESSIBILITY ==================== */

@media (prefers-reduced-motion: reduce) {

    #sendMessageBtn,
    main#main-content>.dashboard-cards .card,
    #notificationPanel {
        transition: none;
    }

}