/* ==========================================================================
   ZSchool Data — Authentication pages (PEO login / signup)
   Standalone: these pages deliberately do NOT load the site navbar or footer.
   Save as: /peo/css/auth.css
   ========================================================================== */

:root {
    --green:        #0B6B3A;
    --green-deep:   #084A28;
    --green-dark:   #063a1f;
    --copper:       #C8702A;
    --copper-dark:  #a85c20;
    --paper:        #F7F9F8;
    --ink:          #1C2B22;
    --slate:        #5A6B62;
    --line:         #DDE6E1;
    --danger:       #C0392B;
    --danger-bg:    #FDECEA;
    --success:      #1E8449;
    --success-bg:   #EAFAF1;

    --r:            10px;
    --shadow:       0 1px 2px rgba(8,74,40,.04), 0 8px 24px rgba(8,74,40,.06);
}

*, *::before, *::after { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
    height: 100%;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: var(--ink);
    background: var(--paper);
    -webkit-font-smoothing: antialiased;
    font-size: 15px;
    line-height: 1.55;
}

/* ---------- Split layout ---------- */
.auth {
    display: grid;
    grid-template-columns: 42% 58%;
    min-height: 100vh;
}

/* ---------- Left: branded panel ---------- */
.auth__brand {
    position: relative;
    background: var(--green-deep);
    color: #fff;
    padding: 48px 44px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* Signature: topographic contours — the territory an officer administers */
.auth__contours {
    position: absolute;
    inset: 0;
    opacity: .5;
    pointer-events: none;
}

.auth__brandInner {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.brand__mark {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: #fff;
}
.brand__logo {
    width: 44px; height: 44px;
    border-radius: 9px;
    object-fit: cover;
    background: #fff;
    flex-shrink: 0;
}
.brand__name {
    font-family: 'Fraunces', Georgia, serif;
    font-size: 19px;
    font-weight: 600;
    letter-spacing: -.01em;
    line-height: 1.15;
}
.brand__sub {
    font-size: 11px;
    letter-spacing: .10em;
    text-transform: uppercase;
    color: #8FB8A1;
    margin-top: 2px;
}

.brand__body { margin-top: auto; margin-bottom: auto; padding: 40px 0; }

.brand__eyebrow {
    font-size: 11.5px;
    font-weight: 600;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--copper);
    margin-bottom: 14px;
}
.brand__title {
    font-family: 'Fraunces', Georgia, serif;
    font-size: 38px;
    line-height: 1.12;
    font-weight: 600;
    letter-spacing: -.02em;
    margin: 0 0 16px;
}
.brand__lede {
    color: #B9D2C4;
    font-size: 15px;
    max-width: 34ch;
    margin: 0;
}

.brand__list {
    list-style: none;
    margin: 28px 0 0;
    padding: 0;
}
.brand__list li {
    display: flex;
    gap: 11px;
    align-items: flex-start;
    padding: 9px 0;
    color: #CFE3D7;
    font-size: 14px;
    border-top: 1px solid rgba(255,255,255,.09);
}
.brand__list li:first-child { border-top: 0; }
.brand__list svg { flex-shrink: 0; margin-top: 2px; }

.brand__foot {
    font-size: 12px;
    color: #7FA592;
    border-top: 1px solid rgba(255,255,255,.10);
    padding-top: 18px;
}
.brand__foot a { color: #A9C9B6; text-decoration: none; }
.brand__foot a:hover { text-decoration: underline; }

/* ---------- Right: form side ---------- */
.auth__panel {
    display: flex;
    flex-direction: column;
    padding: 40px 5vw;
    overflow-y: auto;
}
.auth__panelInner {
    width: 100%;
    max-width: 520px;
    margin: auto;
    padding: 12px 0;
}
.auth--wide .auth__panelInner { max-width: 660px; }

.auth__back {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 13px;
    color: var(--slate);
    text-decoration: none;
    margin-bottom: 26px;
}
.auth__back:hover { color: var(--green); }

.head__title {
    font-family: 'Fraunces', Georgia, serif;
    font-size: 30px;
    font-weight: 600;
    letter-spacing: -.02em;
    margin: 0 0 7px;
    color: var(--ink);
}
.head__sub {
    color: var(--slate);
    margin: 0 0 28px;
    font-size: 14.5px;
}

/* ---------- Alerts ---------- */
.alert {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    padding: 12px 14px;
    border-radius: var(--r);
    font-size: 14px;
    margin-bottom: 20px;
    border: 1px solid transparent;
}
.alert svg { flex-shrink: 0; margin-top: 2px; }
.alert--error   { background: var(--danger-bg);  border-color: #F2C4BE; color: var(--danger); }
.alert--success { background: var(--success-bg); border-color: #ABE6C6; color: var(--success); }

/* ---------- Form ---------- */
.grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px 18px;
}
.grid .col-2 { grid-column: 1 / -1; }

.field { display: flex; flex-direction: column; }

.field label {
    font-size: 13px;
    font-weight: 600;
    color: var(--ink);
    margin-bottom: 6px;
}
.field .req { color: var(--copper); }

.field input[type=text],
.field input[type=email],
.field input[type=tel],
.field input[type=number],
.field input[type=password],
.field select,
.field textarea {
    width: 100%;
    font: inherit;
    font-size: 14.5px;
    color: var(--ink);
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 11px 13px;
    transition: border-color .15s, box-shadow .15s;
}
.field textarea { resize: vertical; min-height: 76px; }

/* Number inputs: strip the browser spinners so they size like every other
   field. The secret code is an identifier, not a quantity — nobody needs to
   nudge it up and down by one. */
.field input[type=number] {
    -moz-appearance: textfield;
    appearance: textfield;
}
.field input[type=number]::-webkit-outer-spin-button,
.field input[type=number]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.field select {
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' fill='none' stroke='%235A6B62' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 5l4 4 4-4'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 13px center;
    padding-right: 36px;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
    outline: none;
    border-color: var(--green);
    box-shadow: 0 0 0 3px rgba(11,107,58,.12);
}
.field input:disabled,
.field select:disabled {
    background: #F1F4F2;
    color: var(--slate);
    cursor: not-allowed;
}

.field .hint {
    font-size: 12px;
    color: var(--slate);
    margin-top: 5px;
}
.field .err {
    font-size: 12.5px;
    color: var(--danger);
    margin-top: 5px;
    display: none;
}
.field.is-invalid input,
.field.is-invalid select { border-color: var(--danger); }
.field.is-invalid .err { display: block; }

/* Password field with reveal */
.pw { position: relative; }
.pw input { padding-right: 44px; }
.pw__toggle {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: 0;
    padding: 7px;
    cursor: pointer;
    color: var(--slate);
    border-radius: 6px;
    line-height: 0;
}
.pw__toggle:hover { color: var(--green); background: #F1F4F2; }

/* Password strength */
.meter { display: flex; gap: 4px; margin-top: 7px; }
.meter span {
    height: 3px;
    flex: 1;
    background: var(--line);
    border-radius: 2px;
    transition: background .2s;
}
.meter[data-level="1"] span:nth-child(1) { background: #E74C3C; }
.meter[data-level="2"] span:nth-child(-n+2) { background: #E67E22; }
.meter[data-level="3"] span:nth-child(-n+3) { background: #F1C40F; }
.meter[data-level="4"] span { background: var(--success); }

/* ---------- Photo upload ---------- */
.photo {
    display: flex;
    gap: 16px;
    align-items: center;
    padding: 16px;
    border: 1px dashed var(--line);
    border-radius: var(--r);
    background: #fff;
    transition: border-color .15s, background .15s;
}
.photo.is-dragover { border-color: var(--green); background: #F2F8F5; }
.photo__preview {
    width: 74px; height: 74px;
    border-radius: 9px;
    object-fit: cover;
    background: #EEF3F0;
    border: 1px solid var(--line);
    flex-shrink: 0;
}
.photo__meta { min-width: 0; }
.photo__meta strong { display: block; font-size: 14px; margin-bottom: 2px; }
.photo__meta p { margin: 0 0 9px; font-size: 12.5px; color: var(--slate); }
.photo input[type=file] { display: none; }

.btn-file {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font: inherit;
    font-size: 13px;
    font-weight: 600;
    color: var(--green);
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 7px;
    padding: 7px 13px;
    cursor: pointer;
}
.btn-file:hover { border-color: var(--green); background: #F2F8F5; }

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    width: 100%;
    font: inherit;
    font-size: 15px;
    font-weight: 600;
    color: #fff;
    background: var(--copper);
    border: 0;
    border-radius: 9px;
    padding: 13px 20px;
    cursor: pointer;
    transition: background .15s, transform .06s;
    margin-top: 6px;
}
.btn:hover { background: var(--copper-dark); }
.btn:active { transform: translateY(1px); }
.btn:disabled { background: #C7D2CC; cursor: not-allowed; }

/* ---------- Meta rows ---------- */
.row-between {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 4px;
}
.check {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 13.5px;
    color: var(--slate);
    cursor: pointer;
    user-select: none;
}
.check input { accent-color: var(--green); width: 15px; height: 15px; }

.link {
    color: var(--green);
    font-weight: 600;
    text-decoration: none;
    font-size: 13.5px;
}
.link:hover { text-decoration: underline; }

.foot-note {
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid var(--line);
    font-size: 14px;
    color: var(--slate);
    text-align: center;
}

.section-label {
    grid-column: 1 / -1;
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--slate);
    padding-bottom: 4px;
    border-bottom: 1px solid var(--line);
    margin-top: 10px;
}
.section-label:first-child { margin-top: 0; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
    .auth { grid-template-columns: 1fr; min-height: 100%; }
    .auth__brand {
        padding: 26px 24px;
    }
    .auth__brand .brand__body,
    .auth__brand .brand__list,
    .auth__brand .brand__foot { display: none; }
    .auth__panel { padding: 30px 22px 44px; }
}

@media (max-width: 560px) {
    .grid { grid-template-columns: 1fr; }
    .head__title { font-size: 25px; }
    .photo { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
    * { transition: none !important; animation: none !important; }
}