﻿
:root {
    --primary: #087e9c;
    --primary-dark: #075985;
    --text-dark: #173b59;
    --text-muted: #8493a0;
}

* {
    box-sizing: border-box;
}

html, body {
    min-height: 100%;
    margin: 0;
}

body {
    font-family: 'Segoe UI', Roboto, Arial, sans-serif;
    background: linear-gradient(-45deg, #075985, #087e9c, #0e7490, #164e78);
    background-size: 400% 400%;
    animation: forgotGradient 15s ease infinite;
}

/* Background decoration */

.forgot-background {
    position: fixed;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

.forgot-shape {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, .10);
    animation: forgotFloat 12s ease-in-out infinite;
}

.forgot-shape-one {
    width: 300px;
    height: 300px;
    top: -100px;
    left: -70px;
}

.forgot-shape-two {
    width: 230px;
    height: 230px;
    right: 5%;
    bottom: -80px;
    animation-delay: -4s;
}

.forgot-shape-three {
    width: 110px;
    height: 110px;
    top: 55%;
    left: 10%;
    animation-delay: -7s;
}

/* Main wrapper */

.forgot-wrapper {
    position: relative;
    z-index: 1;
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 25px 15px;
}

.forgot-card {
    width: 100%;
    max-width: 1050px;
    border: none;
    border-radius: 20px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 25px 65px rgba(0, 25, 55, .25);
    animation: forgotCardEntrance .8s cubic-bezier(.2,.8,.2,1) both;
}

/* Form section */

.forgot-form-section {
    height: 100%;
    padding: clamp(25px, 4vh, 42px) clamp(22px, 3.5vw, 42px);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.forgot-branding {
    text-align: center;
    margin-bottom: 25px;
    animation: forgotFadeDown .8s ease both;
}

.forgot-logo-container {
    width: 85px;
    height: 85px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: #f0f7fb;
    border-radius: 50%;
    margin: 0 auto 12px;
    box-shadow: 0 5px 20px rgba(8, 126, 156, .12);
    transition: transform .3s ease;
}

    .forgot-logo-container:hover {
        transform: scale(1.07) rotate(3deg);
    }

.forgot-logo {
    width: 75%;
    height: 75%;
    object-fit: contain;
}

.forgot-university-name {
    font-size: 23px;
    font-weight: 800;
    color: var(--text-dark);
    margin: 0;
}

.forgot-campus-name {
    display: inline-block;
    margin-top: 8px;
    padding: 5px 16px;
    border-radius: 25px;
    background: #e8f6fb;
    color: var(--primary-dark);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 2px;
}

/* Heading */

.forgot-heading {
    text-align: center;
    margin-bottom: 25px;
    animation: forgotFadeUp .7s ease .15s both;
}

    .forgot-heading h2 {
        font-size: 23px;
        font-weight: 750;
        color: var(--text-dark);
        margin-bottom: 8px;
    }

    .forgot-heading p {
        color: var(--text-muted);
        font-size: 13px;
        line-height: 1.7;
        margin: 0;
    }

/* Inputs */

.forgot-form-group {
    margin-bottom: 19px;
    animation: forgotFadeUp .7s ease .2s both;
}

.forgot-form-label {
    display: block;
    color: #34495e;
    font-size: 13px;
    font-weight: 650;
    margin-bottom: 8px;
}

.forgot-input-group {
    display: flex;
    border-radius: 9px;
    overflow: hidden;
    transition: box-shadow .25s ease;
}

    .forgot-input-group:focus-within {
        box-shadow: 0 0 0 4px rgba(8, 126, 156, .12);
    }

.forgot-input-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 14px;
    color: var(--primary);
    background: #f1f6fa;
    border: 1px solid #dce5ed;
    border-right: none;
}

.forgot-input {
    min-width: 0;
    width: 100%;
    padding: 12px;
    font-size: 13px;
    color: #34495e;
    border: 1px solid #dce5ed;
    border-left: none;
    outline: none;
    box-shadow: none;
    transition: border-color .2s ease;
}

    .forgot-input:focus {
        border-color: #dce5ed;
    }

    .forgot-input::placeholder {
        color: #a5b1bc;
    }

.forgot-validation {
    display: block;
    color: #dc3545;
    font-size: 12px;
    margin-top: 5px;
}

.forgot-validation-summary {
    background: #fff1f1;
    border: 1px solid #ffd6d6;
    border-radius: 8px;
    padding: 10px 13px;
    margin-bottom: 16px;
    font-size: 12px;
}

    .forgot-validation-summary ul {
        margin: 0;
        padding-left: 18px;
    }

/* Security note */

.forgot-security-note {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    padding: 13px;
    border: 1px solid #dcecf4;
    background: #f0f8fc;
    color: #527185;
    border-radius: 9px;
    font-size: 12px;
    line-height: 1.6;
    margin: 4px 0 22px;
    animation: forgotFadeUp .7s ease .3s both;
}

    .forgot-security-note i {
        color: var(--primary);
        font-size: 17px;
        flex-shrink: 0;
    }

/* Buttons */

.forgot-button-row {
    display: flex;
    gap: 12px;
    animation: forgotFadeUp .7s ease .4s both;
}

.forgot-submit-btn {
    position: relative;
    flex: 1;
    padding: 12px;
    border: none;
    border-radius: 9px;
    color: #fff;
    background: linear-gradient(120deg, #087e9c, #075985);
    font-size: 13px;
    font-weight: 700;
    transition: transform .25s ease, box-shadow .25s ease;
}

    .forgot-submit-btn:hover {
        color: #fff;
        background: linear-gradient(120deg, #075985, #064b70);
        transform: translateY(-2px);
        box-shadow: 0 8px 18px rgba(7, 89, 133, .22);
    }

    .forgot-submit-btn:disabled {
        opacity: .7;
        cursor: not-allowed;
        transform: none;
    }

.forgot-back-btn {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    padding: 11px 18px;
    border: 1px solid #dce5ed;
    border-radius: 9px;
    color: #526779;
    background: #fff;
    font-size: 13px;
    font-weight: 650;
    text-decoration: none;
    transition: all .25s ease;
}

    .forgot-back-btn:hover {
        background: #f1f6fa;
        color: var(--primary-dark);
        border-color: #b8d8e5;
    }

    .forgot-back-btn.disable-click {
        pointer-events: none;
        opacity: .5;
    }

/* Image section */

.forgot-image-section {
    position: relative;
    min-height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    background: linear-gradient(145deg, #eaf6fc, #dceef7);
}

.forgot-image-circle {
    position: absolute;
    width: min(85%, 390px);
    aspect-ratio: 1;
    border: 1px solid rgba(8, 126, 156, .14);
    border-radius: 50%;
    animation: forgotCirclePulse 5s ease-in-out infinite;
}

    .forgot-image-circle::before {
        content: "";
        position: absolute;
        inset: 28px;
        border: 1px dashed rgba(8, 126, 156, .18);
        border-radius: 50%;
    }

.forgot-image-content {
    position: relative;
    z-index: 1;
    width: 100%;
    text-align: center;
    padding: 25px;
    animation: forgotImageEntrance 1s ease .25s both;
}

    .forgot-image-content img {
        width: 100%;
        max-width: 430px;
        max-height: 360px;
        object-fit: contain;
        filter: drop-shadow(0 12px 18px rgba(20, 60, 85, .12));
        animation: forgotImageFloat 5s ease-in-out infinite;
    }

    .forgot-image-content h3 {
        font-size: 21px;
        font-weight: 750;
        color: var(--text-dark);
        margin-top: 20px;
    }

    .forgot-image-content p {
        max-width: 290px;
        margin: 8px auto 0;
        color: #71869a;
        font-size: 12px;
        line-height: 1.7;
    }

/* Footer */

.forgot-footer {
    padding: 13px;
    background: #f8fafc;
    border-top: 1px solid #edf1f5;
    text-align: center;
    color: #8493a0;
    font-size: 11px;
}

    .forgot-footer i {
        color: var(--primary);
    }

/* Animations */

@keyframes forgotGradient {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

@keyframes forgotCardEntrance {
    from {
        opacity: 0;
        transform: translateY(30px) scale(.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes forgotFadeDown {
    from {
        opacity: 0;
        transform: translateY(-15px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes forgotFadeUp {
    from {
        opacity: 0;
        transform: translateY(15px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes forgotFloat {
    0%, 100% {
        transform: translateY(0) rotate(0);
    }

    50% {
        transform: translateY(-25px) rotate(10deg);
    }
}

@keyframes forgotImageFloat {
    0%, 100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

@keyframes forgotCirclePulse {
    0%, 100% {
        transform: scale(1);
        opacity: .7;
    }

    50% {
        transform: scale(1.05);
        opacity: 1;
    }
}

@keyframes forgotImageEntrance {
    from {
        opacity: 0;
        transform: translateX(25px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Responsive */

@media (max-width: 991px) {
    .forgot-form-section {
        padding: 30px;
    }
}

@media (max-width: 767px) {
    .forgot-wrapper {
        padding: 15px 10px;
    }

    .forgot-card {
        max-width: 480px;
        border-radius: 16px;
    }

    .forgot-form-section {
        padding: 28px 23px;
    }

    .forgot-image-section {
        display: none;
    }
}

@media (max-width: 400px) {
    .forgot-form-section {
        padding: 22px 17px;
    }

    .forgot-logo-container {
        width: 65px;
        height: 65px;
    }

    .forgot-university-name {
        font-size: 20px;
    }

    .forgot-heading h2 {
        font-size: 21px;
    }

    .forgot-button-row {
        flex-direction: column;
    }

    .forgot-back-btn {
        padding: 11px;
    }
}

/* Short screens */

@media (max-height: 700px) and (min-width: 768px) {
    .forgot-wrapper {
        padding-top: 10px;
        padding-bottom: 10px;
    }

    .forgot-form-section {
        padding-top: 18px;
        padding-bottom: 18px;
    }

    .forgot-branding {
        margin-bottom: 13px;
    }

    .forgot-logo-container {
        width: 60px;
        height: 60px;
    }

    .forgot-heading {
        margin-bottom: 15px;
    }

    .forgot-form-group {
        margin-bottom: 12px;
    }

    .forgot-security-note {
        margin-bottom: 13px;
        padding: 9px;
    }
}

/* Accessibility */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
        scroll-behavior: auto !important;
    }
}

/* =========================================
   FIX: REMOVE PAGE SCROLLBAR
========================================= */

html,
body {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    overflow: hidden !important;
}

body {
    min-height: 100vh;
    min-height: 100dvh;
}

.forgot-wrapper {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    min-height: 0 !important;
    padding: 15px 20px !important;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.forgot-card {
    width: 100%;
    max-width: 1050px;
    max-height: calc(100dvh - 30px);
    margin: 0 auto;
    overflow: hidden;
}

    .forgot-card .row {
        min-height: 0;
    }

.forgot-form-section {
    padding: 25px 35px !important;
}

.forgot-image-section {
    min-height: 0 !important;
    height: 100%;
}

/* Smaller laptops */
@media (max-height: 750px) {
    .forgot-form-section {
        padding: 15px 30px !important;
    }

    .forgot-card {
        max-height: calc(100dvh - 20px);
    }

    .forgot-logo {
        max-height: 55px;
    }
}

/* Mobile screens */
@media (max-width: 991.98px) {
    .forgot-wrapper {
        padding: 10px !important;
    }

    .forgot-card {
        max-width: 520px;
    }

    .forgot-form-section {
        padding: 25px 22px !important;
    }
}

@media (max-width: 480px) {
    .forgot-form-section {
        padding: 20px 16px !important;
    }
}

