/* QPOS Auth
   Flat form on night stage. No nested cards. Compact actions. */

:root {
    --qpos-red: #d9272d;
    --qpos-red-hot: #e8353b;
    --qpos-red-deep: #b01f24;
    --qpos-ink: #080b10;
    --qpos-mist: #97a0b2;
    --qpos-paper: #ffffff;
    --qpos-text: #1c2430;
    --qpos-muted: #667085;
    --qpos-line: #e4e7ec;
    --qpos-fill: #f7f8fa;
    --qpos-font-display: "Sora", system-ui, sans-serif;
    --qpos-font-body: "Source Sans 3", system-ui, sans-serif;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    font-size: 16px !important;
}

html,
body {
    height: 100%;
    margin: 0;
}

body.qpos-auth-body {
    font-family: var(--qpos-font-body) !important;
    font-size: 16px !important;
    line-height: 1.5;
    color: var(--qpos-paper);
    background: var(--qpos-ink) !important;
    -webkit-font-smoothing: antialiased;
    margin: 0 !important;
    padding: 0 !important;
}

/* Beat AdminLTE / Argon heading resets on auth pages */
body.qpos-auth-body h1,
body.qpos-auth-body h2,
body.qpos-auth-body h3,
body.qpos-auth-body .h1,
body.qpos-auth-body .h2,
body.qpos-auth-body .h3 {
    font-family: var(--qpos-font-display) !important;
    color: inherit;
}

a {
    color: var(--qpos-red);
    text-decoration: none;
    transition: color 0.15s ease;
}

a:hover,
a:focus {
    color: var(--qpos-red-deep);
    text-decoration: none;
    outline: none;
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: transparent;
    outline: none !important;
}

input,
textarea,
select {
    font-family: inherit;
}

[hidden] {
    display: none !important;
}

/* ========== Stage ========== */
.qpos-auth {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: stretch;
    overflow: hidden;
}

.qpos-auth__stage {
    position: absolute;
    inset: 0;
    z-index: 0;
    background:
        radial-gradient(900px 560px at 12% 85%, rgba(217, 39, 45, 0.28), transparent 58%),
        radial-gradient(700px 480px at 88% 10%, rgba(55, 110, 130, 0.16), transparent 52%),
        linear-gradient(165deg, #06080c 0%, #0e141d 50%, #121a24 100%);
}

.qpos-auth__stage::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 64px 64px;
    mask-image: radial-gradient(ellipse at 35% 45%, black 10%, transparent 70%);
    opacity: 0.7;
    pointer-events: none;
}

@keyframes qpos-rise {
    from {
        opacity: 0;
        transform: translateY(14px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes qpos-brand-in {
    from {
        opacity: 0;
        transform: translateX(-10px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* ========== Shell ========== */
.qpos-auth__shell {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 1120px;
    margin: 0 auto;
    padding: clamp(1.5rem, 4vw, 3rem);
    display: grid;
    grid-template-columns: 1fr minmax(320px, 420px);
    gap: clamp(2rem, 6vw, 5rem);
    align-items: center;
    min-height: 100vh;
}

.qpos-auth__shell--narrow {
    grid-template-columns: 1fr;
    max-width: 420px;
    align-content: center;
}

.qpos-auth__shell--wide {
    grid-template-columns: minmax(220px, 0.85fr) minmax(0, 560px);
    max-width: 1180px;
}

.qpos-auth__shell--register {
    grid-template-columns: minmax(240px, 0.85fr) minmax(480px, 580px);
    max-width: 1120px;
    gap: clamp(2rem, 5vw, 4rem);
}

/* ========== Brand ========== */
.qpos-auth__brand {
    animation: qpos-brand-in 0.7s ease both;
}

.qpos-auth__tagline {
    font-family: var(--qpos-font-display);
    font-size: clamp(36px, 4vw, 44px) !important;
    font-weight: 600;
    color: #fff;
    max-width: 15ch;
    line-height: 1.2;
    letter-spacing: -0.015em;
    margin: 0 0 16px;
}

.qpos-auth__sub {
    margin: 0;
    color: var(--qpos-mist);
    font-size: 18px !important;
    line-height: 1.55;
    max-width: 36ch;
}

.qpos-auth__meta {
    margin-top: 32px;
    display: flex;
    flex-wrap: wrap;
    gap: 12px 22px;
    color: rgba(151, 160, 178, 0.95);
    font-size: 15px !important;
    font-weight: 500;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.qpos-auth__meta strong {
    color: rgba(255, 255, 255, 0.82);
    font-weight: 600;
}

/* ========== Form surface: single layer, no nested box ========== */
.qpos-auth__panel {
    animation: qpos-rise 0.65s ease 0.08s both;
    background: var(--qpos-paper);
    border-radius: 16px;
    padding: clamp(28px, 3vw, 36px);
    color: var(--qpos-text);
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
    font-size: 16px !important;
}

/* Keep class for markup compatibility, but no visual nesting */
.qpos-auth__panel-inner {
    background: transparent;
    border-radius: 0;
    padding: 0;
}

.qpos-auth__panel-head {
    margin-bottom: 24px;
}

.qpos-auth__panel-head--with-logo {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}

.qpos-auth__panel-logo {
    height: 36px;
    width: auto;
    flex-shrink: 0;
}

.qpos-auth__panel-head h1 {
    font-family: var(--qpos-font-display) !important;
    font-size: 28px !important;
    font-weight: 600 !important;
    color: var(--qpos-text) !important;
    margin: 0 0 6px !important;
    letter-spacing: -0.015em;
    line-height: 1.25 !important;
}

.qpos-auth__panel-head p,
.qpos-wizard__step-desc {
    margin: 0;
    color: var(--qpos-muted) !important;
    font-size: 17px !important;
    line-height: 1.45;
    font-weight: 400 !important;
}

.qpos-auth__form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Underline / soft fill fields, not chunky pills */
.qpos-field label {
    display: block;
    font-size: 15px !important;
    font-weight: 600 !important;
    color: var(--qpos-muted) !important;
    margin-bottom: 8px;
    letter-spacing: 0.01em;
    text-transform: none !important;
}

.qpos-field__control {
    position: relative;
    display: flex;
    align-items: center;
}

.qpos-field__control i,
.qpos-field__control .glyphicon {
    position: absolute;
    left: 0;
    color: #98a2b3;
    font-size: 16px;
    pointer-events: none;
    z-index: 2;
}

.qpos-field input[type="text"],
.qpos-field input[type="email"],
.qpos-field input[type="password"],
.qpos-auth__panel .input100 {
    width: 100%;
    height: 48px;
    border: none;
    border-bottom: 1.5px solid var(--qpos-line);
    border-radius: 0;
    background: transparent;
    padding: 0 0 0 28px;
    font-size: 16px !important;
    font-weight: 400;
    color: var(--qpos-text);
    box-shadow: none !important;
    transition: border-color 0.15s ease;
}

.qpos-field input:focus,
.qpos-auth__panel .input100:focus {
    border-color: var(--qpos-red);
    outline: none;
    box-shadow: none !important;
}

.qpos-field__control:focus-within i {
    color: var(--qpos-red);
}

.qpos-field__error,
.qpos-auth__panel .help-block,
.qpos-auth__panel .text-red {
    display: block;
    margin-top: 0.3rem;
    color: var(--qpos-red-deep) !important;
    font-size: 0.9rem;
}

.qpos-auth__row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 0.15rem;
}

.qpos-auth__row .checkbox,
.qpos-auth__row .icheck,
.qpos-auth__row label {
    margin: 0;
    color: var(--qpos-muted);
    font-size: 16px !important;
    font-weight: 500;
}

.qpos-auth__forgot {
    font-size: 16px !important;
    font-weight: 600;
    color: var(--qpos-red) !important;
}

/* Compact primary action */
.qpos-auth__submit,
.qpos-auth__panel .login100-form-btn,
.qpos-wizard__btn--primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: auto;
    min-width: 140px;
    height: 48px;
    margin-top: 8px;
    padding: 0 22px;
    border-radius: 8px;
    border: none;
    background: var(--qpos-red);
    color: #fff !important;
    font-family: var(--qpos-font-body) !important;
    font-weight: 600 !important;
    font-size: 16px !important;
    letter-spacing: 0;
    text-transform: none !important;
    box-shadow: none;
    transition: background 0.15s ease, transform 0.1s ease;
}

.qpos-auth__submit {
    width: 100%;
}

.qpos-auth__submit:hover,
.qpos-auth__panel .login100-form-btn:hover,
.qpos-wizard__btn--primary:hover {
    background: var(--qpos-red-hot);
    filter: none;
    transform: none;
    box-shadow: none;
    color: #fff !important;
}

.qpos-auth__submit:active,
.qpos-wizard__btn--primary:active {
    background: var(--qpos-red-deep);
    transform: none;
}

.qpos-auth__footer {
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid var(--qpos-line);
    text-align: left;
    color: var(--qpos-muted);
    font-size: 16px !important;
}

.qpos-auth__footer a {
    font-weight: 600;
    color: var(--qpos-red) !important;
}

.qpos-auth__status {
    margin-bottom: 1rem;
    padding: 0.65rem 0.8rem;
    border-radius: 8px;
    background: rgba(217, 39, 45, 0.08);
    border: 1px solid rgba(217, 39, 45, 0.18);
    color: var(--qpos-red-deep);
    font-size: 0.95rem;
}

.qpos-auth__status--ok {
    background: rgba(24, 140, 90, 0.08);
    border-color: rgba(24, 140, 90, 0.2);
    color: #146b45;
}

/* Legacy Colorlib hooks kept minimal */
.limiter,
.container-login100 {
    width: 100%;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 1.5rem;
    background: transparent;
}

.wrap-login100 {
    width: 100%;
    max-width: 920px;
    background: var(--qpos-paper);
    border-radius: 16px;
    overflow: hidden;
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    padding: 1.75rem;
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
}

.login100-pic {
    display: none;
}

.login100-form {
    width: 100%;
}

.login100-form-title {
    font-family: var(--qpos-font-display);
    font-size: 28px !important;
    font-weight: 600;
    color: var(--qpos-text);
    text-align: left;
    width: 100%;
    display: block;
    padding-bottom: 12px;
}

.focus-input100 {
    display: none;
}

.symbol-input100 {
    display: none;
}

.txt1,
.txt2 {
    font-size: 1rem;
    color: var(--qpos-muted);
}

.txt2 {
    color: var(--qpos-red);
    font-weight: 600;
}

.login-page,
.register-page {
    background: transparent !important;
}

/* ========== Register wizard ========== */
.qpos-wizard-form {
    width: 100%;
}

.qpos-wizard__steps {
    display: flex;
    align-items: center;
    gap: 0;
    margin: 0 0 1.5rem;
    padding: 0;
    border: none;
    background: transparent;
}

.qpos-wizard__step {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
    padding: 0;
    border: none;
    background: transparent;
    text-align: left;
    color: var(--qpos-muted);
    opacity: 0.55;
    cursor: default;
    position: relative;
}

.qpos-wizard__step + .qpos-wizard__step {
    padding-left: 0.75rem;
}

.qpos-wizard__step + .qpos-wizard__step::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.7rem;
    width: 0.75rem;
    height: 1px;
    background: var(--qpos-line);
}

.qpos-wizard__step.is-done,
.qpos-wizard__step.is-active {
    opacity: 1;
}

.qpos-wizard__step.is-done {
    cursor: pointer;
}

.qpos-wizard__step-num {
    width: 28px;
    height: 28px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 14px !important;
    font-weight: 600;
    background: var(--qpos-fill);
    color: var(--qpos-muted);
    border: 1px solid var(--qpos-line);
}

.qpos-wizard__step.is-active .qpos-wizard__step-num,
.qpos-wizard__step.is-done .qpos-wizard__step-num {
    background: var(--qpos-red);
    border-color: var(--qpos-red);
    color: #fff;
}

.qpos-wizard__step-label {
    display: flex;
    flex-direction: column;
    min-width: 0;
    line-height: 1.2;
}

.qpos-wizard__step-label strong {
    font-size: 15px !important;
    font-weight: 600;
    color: var(--qpos-text);
}

.qpos-wizard__step-label small {
    display: none;
}

.qpos-wizard {
    position: relative;
    min-height: 240px;
}

.qpos-wizard__pane {
    display: none;
    animation: qpos-rise 0.3s ease both;
}

.qpos-wizard__pane.is-active {
    display: block;
}

.qpos-wizard__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem 1.1rem;
}

.qpos-wizard__field {
    min-width: 0;
}

.qpos-wizard__field--full {
    grid-column: 1 / -1;
}

.qpos-wizard__field label {
    display: block;
    font-size: 15px !important;
    font-weight: 600 !important;
    color: var(--qpos-muted) !important;
    margin-bottom: 8px;
}

.qpos-wizard__field .form-control,
.qpos-wizard__field select.form-control {
    height: 48px;
    font-size: 16px !important;
    border: none;
    border-bottom: 1.5px solid var(--qpos-line);
    border-radius: 0;
    background: transparent;
    box-shadow: none !important;
    padding-left: 10px;
}

.qpos-wizard__field .form-control:focus {
    border-color: var(--qpos-red);
    box-shadow: none !important;
}

.qpos-wizard__field .input-group {
    width: 100%;
    display: flex;
    align-items: stretch;
}

.qpos-wizard__field .input-group-addon {
    background: transparent;
    border: none;
    border-bottom: 1.5px solid var(--qpos-line);
    border-radius: 0;
    color: #98a2b3;
    padding: 0 0.45rem 0 0;
    width: auto;
    min-width: 1.5rem;
}

.qpos-wizard__field .input-group .form-control {
    border-left: none;
}

.qpos-wizard__field.has-error .form-control,
.qpos-wizard__field.has-error .input-group-addon {
    border-bottom-color: var(--qpos-red);
}

.qpos-wizard__field .select2-container {
    width: 100% !important;
}

.qpos-wizard__field .select2-container .select2-selection--single {
    height: 48px !important;
    border: none !important;
    border-bottom: 1.5px solid var(--qpos-line) !important;
    border-radius: 0 !important;
    background: transparent !important;
}

.qpos-wizard__field .select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 48px !important;
    padding-left: 6px;
    color: var(--qpos-text);
    font-size: 16px !important;
}

.qpos-wizard__field .select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 46px !important;
}

.qpos-wizard__note {
    margin: 0.85rem 0 0;
    color: var(--qpos-muted);
    font-size: 1rem;
}

.qpos-wizard__check {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1rem;
    color: var(--qpos-muted);
    font-weight: 500;
}

.qpos-wizard__actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-top: 1.5rem;
    padding-top: 1.15rem;
    border-top: 1px solid var(--qpos-line);
}

.qpos-wizard__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 48px;
    min-width: 120px;
    padding: 0 20px;
    border-radius: 8px;
    font-family: var(--qpos-font-body) !important;
    font-size: 16px !important;
    font-weight: 600 !important;
    border: none;
    cursor: pointer;
    transition: background 0.15s ease;
}

.qpos-wizard__btn--ghost {
    background: transparent;
    color: var(--qpos-muted);
    margin-right: auto;
    min-width: auto;
    padding: 0 0.5rem;
}

.qpos-wizard__btn--ghost:hover {
    color: var(--qpos-text);
    background: transparent;
}

.qpos-wizard__btn--primary {
    flex: 0 0 auto;
    width: auto;
}

.qpos-wizard__btn.login100-form-btn {
    width: auto;
    height: 48px;
    margin-top: 0;
    text-transform: none;
    letter-spacing: 0;
    box-shadow: none;
}

.qpos-signup {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem 1.25rem;
}

.qpos-signup__full {
    grid-column: 1 / -1;
}

.qpos-signup__legal {
    margin: 1rem 0 0;
    padding: 0;
    font-size: 13px !important;
    line-height: 1.45;
    color: var(--qpos-muted);
}

.qpos-signup__legal strong {
    color: var(--qpos-text);
    font-weight: 600;
}

.qpos-field__hint {
    display: block;
    margin-top: 6px;
    font-size: 14px !important;
    color: var(--qpos-muted);
}

.qpos-signup .qpos-field.has-error .input100,
.qpos-signup .qpos-field.has-error .form-control {
    border-bottom-color: var(--qpos-red);
}

.qpos-wizard__actions .qpos-auth__submit {
    width: 100%;
    margin-top: 0;
}

.qpos-auth--register .qpos-auth__panel {
    max-width: 100%;
}

.qpos-auth--register .qpos-auth__panel-head {
    margin-bottom: 1.15rem;
}

.qpos-auth--register .qpos-wizard__actions {
    margin-top: 1.15rem;
    padding-top: 1rem;
}

@media (max-width: 720px) {
    .qpos-signup {
        grid-template-columns: 1fr;
    }
}

.qpos-auth--register .form-control {
    box-shadow: none;
}

.qpos-auth--register h3 {
    font-family: var(--qpos-font-display);
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--qpos-text);
}

.qpos-auth--register fieldset {
    border: none;
    margin: 0;
    padding: 0;
}

/* ========== Responsive ========== */
@media (max-width: 960px) {
    .qpos-auth__shell,
    .qpos-auth__shell--wide,
    .qpos-auth__shell--register {
        grid-template-columns: 1fr;
        max-width: 520px;
        align-content: center;
        gap: 1.5rem;
    }

    .qpos-auth__brand {
        text-align: center;
    }

    .qpos-auth__tagline,
    .qpos-auth__sub {
        max-width: none;
        margin-left: auto;
        margin-right: auto;
    }

    .qpos-auth__meta {
        justify-content: center;
    }

    .qpos-auth__shell--wide {
        max-width: 560px;
    }
}

@media (max-width: 640px) {
    .qpos-wizard__grid {
        grid-template-columns: 1fr;
    }

    .qpos-auth__panel-head h1 {
        font-size: 24px !important;
    }

    .qpos-wizard__step-label strong {
        font-size: 14px !important;
    }
}

@media (prefers-reduced-motion: reduce) {
    .qpos-auth__brand,
    .qpos-auth__panel,
    .qpos-wizard__pane {
        animation: none !important;
    }
}
