/*
 * Hamilton Township School District
 * OpenText SSPR custom theme
 * Presentation only: native SSPR forms, controls, IDs, and behavior are preserved.
 */

:root {
    --htsd-charcoal: #232529;
    --htsd-charcoal-deep: #17191c;
    --htsd-red: #d51f3d;
    --htsd-red-dark: #ae1831;
    --htsd-ink: #20242a;
    --htsd-muted: #626b76;
    --htsd-border: #cbd1d8;
    --htsd-surface: #ffffff;
    --htsd-page: #eef1f4;
    --htsd-focus: rgba(213, 31, 61, .22);
}

html,
body {
    min-height: 100%;
}

body {
    margin: 0;
    color: var(--htsd-ink);
    background: linear-gradient(135deg, #f6f7f9 0%, var(--htsd-page) 100%);
    font-family: "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 15px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

/* Native SSPR header and company-logo hooks. */
#header,
.header {
    position: relative;
    min-height: 128px;
    box-sizing: border-box;
    padding: 8px 28px 46px;
    border: 0;
    background: linear-gradient(
        to bottom,
        var(--htsd-charcoal) 0,
        var(--htsd-charcoal) 82px,
        var(--htsd-red) 82px,
        var(--htsd-red) 86px,
        #ffffff 86px,
        #ffffff 100%
    );
    box-shadow: 0 2px 10px rgba(0, 0, 0, .18);
}

#header-company-logo,
.header-company-logo {
    position: absolute;
    top: 12px;
    left: max(24px, calc(50% - 380px));
    width: 56px;
    height: 56px;
    margin: 0;
    background: url("hamilton-logo.png") center center / contain no-repeat;
    text-indent: -9999px;
    overflow: hidden;
}

#header::before {
    content: "Hamilton Township School District";
    position: absolute;
    z-index: 2;
    top: 17px;
    left: max(96px, calc(50% - 308px));
    color: #ffffff;
    font-size: 20px;
    font-weight: 650;
    line-height: 1.25;
    letter-spacing: .01em;
    white-space: nowrap;
}

#header::after {
    content: "Self Service Password Reset";
    position: absolute;
    z-index: 2;
    top: 46px;
    left: max(96px, calc(50% - 308px));
    color: rgba(255, 255, 255, .74);
    font-size: 14px;
    font-weight: 500;
    line-height: 1.2;
    letter-spacing: .045em;
    white-space: nowrap;
}

/* Exact native SSPR top navigation: a clean light row below the banner. */
#header-center {
    position: absolute !important;
    top: 86px !important;
    right: 0 !important;
    left: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    width: auto !important;
    height: 42px !important;
    box-sizing: border-box !important;
    padding: 0 max(24px, calc((100% - 760px) / 2)) !important;
    color: var(--htsd-charcoal-deep) !important;
    background: #ffffff !important;
}

#header-center-left,
#header-center-right,
#header-menu-wrapper,
#header-menu,
#header-username-group {
    display: flex !important;
    align-items: center !important;
    height: 42px !important;
    box-sizing: border-box !important;
}

#header-center-left,
#header-center-right {
    position: static !important;
    top: auto !important;
    right: auto !important;
    bottom: auto !important;
    left: auto !important;
    float: none !important;
    margin: 0 !important;
    transform: none !important;
}

#header-center-left {
    min-width: 0;
    flex: 1 1 auto;
}

#header-center-right,
#header-menu-wrapper {
    flex: 0 0 auto;
    gap: 6px;
}

#header-menu-wrapper {
    position: static !important;
    top: auto !important;
    right: auto !important;
    bottom: auto !important;
    left: auto !important;
    margin: 0 !important;
}

#header-page {
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
    color: var(--htsd-charcoal-deep) !important;
    font-size: 18px !important;
    font-weight: 650 !important;
    line-height: 42px !important;
    text-shadow: none !important;
    white-space: nowrap;
}

/* The login card already supplies its own heading. */
body:has(form#login) #header-page {
    display: none !important;
}

#header-menu-wrapper a,
#header-menu a,
#header-username-group a,
#header-username-group,
#header .header-button {
    color: var(--htsd-charcoal-deep) !important;
    text-shadow: none !important;
}

#header-menu-wrapper a,
#header-menu a,
#header .header-button {
    position: static !important;
    top: auto !important;
    right: auto !important;
    bottom: auto !important;
    left: auto !important;
    float: none !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    min-width: 38px;
    min-height: 38px;
    box-sizing: border-box;
    margin: 0 !important;
    padding: 7px 9px !important;
    border-radius: 6px;
    line-height: 1 !important;
    text-decoration: none !important;
}

#localeSelectionMenu,
#localeSelectionMenu .pwm-icon {
    position: static !important;
    top: auto !important;
    right: auto !important;
    bottom: auto !important;
    left: auto !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    line-height: 1 !important;
    vertical-align: middle !important;
}

#header-menu-wrapper a:hover,
#header-menu a:hover,
#header .header-button:hover {
    color: var(--htsd-red-dark) !important;
    background: #f1f3f5 !important;
}

#header-menu-wrapper svg,
#header-menu svg,
#header-menu-wrapper .pwm-icon,
#header-menu .pwm-icon,
#header .header-button .pwm-icon {
    color: var(--htsd-charcoal-deep) !important;
    fill: currentColor !important;
    stroke: currentColor !important;
}

#header-menu-wrapper a:hover .pwm-icon,
#header-menu a:hover .pwm-icon,
#header .header-button:hover .pwm-icon {
    color: var(--htsd-red-dark) !important;
}

/* Suppress SSPR's original page title/subtitle in the banner. The custom page
   heading below replaces this copy; logo and language controls stay visible. */
#header h1,
#header h2,
#header h3,
#header p,
#header .title,
#header .subtitle,
#header .page-title,
#header .page-subtitle,
#header .header-title,
#header .header-subtitle,
#header #header-title,
#header #header-subtitle,
#header #header-page-title,
#header #header-page-subtitle,
.header h1,
.header h2,
.header h3,
.header p,
.header .title,
.header .subtitle,
.header .page-title,
.header .page-subtitle,
.header .header-title,
.header .header-subtitle {
    display: none !important;
}

/* Some SSPR 4.x builds place the banner copy beside or immediately after the
   header instead of nesting it inside #header. Match those title hooks globally. */
#header-title,
#header-subtitle,
#header-page-title,
#header-page-subtitle,
#page-header-title,
#page-header-subtitle,
.header-title,
.header-subtitle,
.header-page-title,
.header-page-subtitle,
.page-header-title,
.page-header-subtitle,
[id*="header" i][id*="title" i],
[id*="header" i][id*="subtitle" i],
[class*="header" i][class*="title" i],
[class*="header" i][class*="subtitle" i] {
    display: none !important;
    visibility: hidden !important;
    width: 0 !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
}

#header a:focus,
.header a:focus {
    outline: 2px solid var(--htsd-red);
    outline-offset: 3px;
}

/* Center the principal native SSPR content containers. */
#centerbody,
#centerBody,
#content,
.centerbody,
.main-content,
.page-content {
    position: relative;
    width: auto;
    max-width: 560px;
    margin: 44px auto;
    padding: 0 20px;
    box-sizing: border-box;
}

/* Login-page branding copy. These generated labels do not alter the native form. */
#centerbody::before,
#centerBody::before,
#content::before {
    content: none;
    display: none;
}

#centerbody::after,
#centerBody::after,
#content::after {
    content: none;
    display: none;
}

#centerbody > form::before,
#centerBody > form::before,
#content > form::before {
    content: "Please Sign In";
    display: block;
    margin: 0 0 8px;
    color: var(--htsd-charcoal-deep);
    font-size: 25px;
    font-weight: 700;
    line-height: 1.3;
    text-align: left;
}

#centerbody label:first-of-type::before,
#centerBody label:first-of-type::before,
#content label:first-of-type::before {
    content: "Username format: Last name followed by first initial.\A Do not use your full email address.";
    display: block;
    margin: 0 0 20px;
    padding: 11px 13px;
    border-left: 4px solid var(--htsd-red);
    border-radius: 6px;
    color: var(--htsd-charcoal-deep);
    background: #fff1f3;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.5;
    white-space: pre-line;
}

/* Common SSPR panel/card selectors across supported UI revisions. */
#centerbody > form,
#centerBody > form,
#content > form,
.panel,
.panel-default,
.form-panel,
.login-panel,
.login-wrapper,
.pwm-form,
.pwm-panel {
    box-sizing: border-box;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

#centerbody > form,
#centerBody > form,
#content > form,
.form-panel,
.login-panel,
.login-wrapper,
.pwm-form,
.pwm-panel {
    padding: 34px 38px;
}

.panel-heading,
.title,
h1,
h2 {
    color: var(--htsd-charcoal-deep);
    font-weight: 600;
    letter-spacing: -.015em;
}

h1,
.page-title,
.panel-title {
    margin-top: 0;
    margin-bottom: 20px;
    font-size: 26px;
    line-height: 1.25;
}

.instructions,
.help-block,
.form-text,
.description,
.subtitle {
    color: var(--htsd-muted);
}

label,
.control-label {
    display: inline-block;
    margin-bottom: 7px;
    color: #343a42;
    font-weight: 600;
}

input[type="text"],
input[type="password"],
input[type="email"],
input[type="number"],
input[type="tel"],
select,
textarea,
.form-control {
    width: 100%;
    min-height: 44px;
    box-sizing: border-box;
    padding: 10px 12px;
    color: var(--htsd-ink);
    border: 1px solid var(--htsd-border);
    border-radius: 7px;
    background: #ffffff;
    font: inherit;
    transition: border-color .16s ease, box-shadow .16s ease;
}

input[type="text"]:focus,
input[type="password"]:focus,
input[type="email"]:focus,
input[type="number"]:focus,
input[type="tel"]:focus,
select:focus,
textarea:focus,
.form-control:focus {
    border-color: var(--htsd-red);
    outline: 0;
    box-shadow: 0 0 0 4px var(--htsd-focus);
}

input[type="checkbox"],
input[type="radio"] {
    accent-color: var(--htsd-red);
}

button,
input[type="button"],
input[type="submit"],
.button,
.btn,
.btn-primary {
    min-height: 44px;
    box-sizing: border-box;
    padding: 10px 20px;
    border: 1px solid var(--htsd-red);
    border-radius: 7px;
    color: #ffffff;
    background: var(--htsd-red);
    font: inherit;
    font-weight: 600;
    line-height: 1.25;
    text-shadow: none;
    box-shadow: 0 3px 9px rgba(174, 24, 49, .20);
    cursor: pointer;
    transition: background-color .16s ease, border-color .16s ease, transform .08s ease;
}

button:hover,
input[type="button"]:hover,
input[type="submit"]:hover,
.button:hover,
.btn:hover,
.btn-primary:hover {
    border-color: var(--htsd-red-dark);
    color: #ffffff;
    background: var(--htsd-red-dark);
}

button:active,
input[type="button"]:active,
input[type="submit"]:active,
.button:active,
.btn:active {
    transform: translateY(1px);
}

button:focus,
input[type="button"]:focus,
input[type="submit"]:focus,
.button:focus,
.btn:focus {
    outline: 3px solid var(--htsd-focus);
    outline-offset: 2px;
}

button[disabled],
input[disabled],
.btn[disabled],
.disabled {
    cursor: not-allowed;
    opacity: .58;
}

a {
    color: var(--htsd-red-dark);
    text-decoration-thickness: 1px;
    text-underline-offset: 2px;
}

a:hover,
a:focus {
    color: #831126;
}

.alert,
.message,
.error,
.warning,
.success {
    box-sizing: border-box;
    padding: 12px 14px;
    border-radius: 7px;
}

.error,
.alert-danger {
    border: 1px solid #e1a4ae;
    color: #771328;
    background: #fff1f3;
}

.success,
.alert-success {
    border: 1px solid #9ec9ad;
    color: #18572f;
    background: #f0faf3;
}

#footer,
.footer {
    color: #68717c;
    background: transparent;
    font-size: 13px;
    text-align: center;
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: .01ms !important;
    }
}
