/* ============================================================
   SQI LOGIN — OVERHAUL (override layer)
   Add this stylesheet AFTER your existing CSS.
   Rename classes in your Blade template to match the
   new class names below. No existing CSS is touched.
   ============================================================ */

/* ── Fonts ── */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;1,9..40,300&family=DM+Mono:wght@400;500&display=swap');

/* ── Token overrides (map into existing vars where possible) ── */
:root {
    --v2-font: 'DM Sans', sans-serif;
    --v2-mono: 'DM Mono', monospace;

    --v2-bg:        #f0f2f1;
    --v2-surface:   #ffffff;
    --v2-ink:       #111714;
    --v2-muted:     #5e6e67;
    --v2-faint:     #a8b5af;
    --v2-line:      #e0e6e3;

    --v2-brand:     #0b7a70;
    --v2-brand-dk:  #095f58;
    --v2-brand-lt:  #e2f4f2;
    --v2-brand-mid: #c0e8e4;

    --v2-danger:    #c0392b;
    --v2-warn:      #b8690a;

    --v2-r:         14px;
    --v2-r-lg:      22px;
    --v2-r-xl:      32px;

    --v2-ease: cubic-bezier(.22,.61,.36,1);
}

/* ── Shell ── */
.v2-shell {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100dvh;
    padding: 24px 16px;
    font-family: var(--v2-font);
    background: var(--v2-bg);

    /* subtle dot grid */
    background-image: radial-gradient(circle, #c8d6d0 1px, transparent 1px);
    background-size: 28px 28px;
}

/* ── Card ── */
.v2-card {
    width: 100%;
    max-width: 440px;
    background: var(--v2-surface);
    border-radius: var(--v2-r-xl);
    border: 1px solid var(--v2-line);
    overflow: hidden;
    box-shadow:
        0 0 0 1px rgba(0,0,0,.03),
        0 4px 8px rgba(0,0,0,.04),
        0 24px 60px rgba(17, 40, 30, .10);
    animation: v2-rise .5s var(--v2-ease) both;
}

@keyframes v2-rise {
    from { opacity: 0; transform: translateY(18px) scale(.985); }
    to   { opacity: 1; transform: none; }
}

/* ── Card header band ── */
.v2-card__head {
    padding: 32px 32px 28px;
    border-bottom: 1px solid var(--v2-line);
    position: relative;
    overflow: hidden;
}

.v2-card__head::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--v2-brand-lt) 0%, transparent 65%);
    pointer-events: none;
}

/* decorative ring */
.v2-card__head::after {
    content: '';
    position: absolute;
    right: -48px;
    top: -48px;
    width: 180px;
    height: 180px;
    border-radius: 50%;
    border: 32px solid var(--v2-brand-mid);
    opacity: .25;
    pointer-events: none;
}

.v2-brand-row {
    display: flex;
    align-items: center;
    gap: 12px;
    position: relative;
    z-index: 1;
    margin-bottom: 20px;
}

.v2-brand-row img {
    width: 36px;
    height: 36px;
    object-fit: contain;
    flex-shrink: 0;
}

.v2-brand-row__name {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.v2-brand-row__name strong {
    font-size: 13px;
    font-weight: 600;
    color: var(--v2-ink);
    letter-spacing: -.01em;
}

.v2-brand-row__name span {
    font-size: 11px;
    color: var(--v2-muted);
    font-family: var(--v2-mono);
    text-transform: uppercase;
    letter-spacing: .06em;
}

.v2-head__title {
    font-size: clamp(22px, 5.5vw, 28px);
    font-weight: 600;
    color: var(--v2-ink);
    letter-spacing: -.03em;
    line-height: 1.15;
    margin: 0 0 6px;
    position: relative;
    z-index: 1;
}

.v2-head__sub {
    font-size: 14px;
    color: var(--v2-muted);
    margin: 0;
    position: relative;
    z-index: 1;
    line-height: 1.5;
}

/* ── Card body ── */
.v2-card__body {
    padding: 28px 32px 32px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* ── Stats pills (replace the old stat block) ── */
.v2-stats {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.v2-stat {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    font-weight: 500;
    color: var(--v2-brand-dk);
    background: var(--v2-brand-lt);
    border: 1px solid var(--v2-brand-mid);
    border-radius: 100px;
    padding: 4px 10px 4px 8px;
    letter-spacing: .01em;
    line-height: 1;
}

.v2-stat svg {
    width: 13px;
    height: 13px;
    stroke: var(--v2-brand);
    flex-shrink: 0;
}

/* ── Google button ── */
.v2-google-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 12px 16px;
    border-radius: var(--v2-r);
    border: 1px solid var(--v2-line);
    background: var(--v2-surface);
    color: var(--v2-ink);
    font-size: 14px;
    font-weight: 500;
    font-family: var(--v2-font);
    cursor: pointer;
    text-decoration: none;
    transition:
        background .15s,
        border-color .15s,
        box-shadow .15s;
    box-shadow: 0 1px 3px rgba(0,0,0,.06);
}

.v2-google-btn:hover {
    background: #fafbfa;
    border-color: #b8c4be;
    box-shadow: 0 2px 8px rgba(0,0,0,.08);
    text-decoration: none;
}

.v2-google-btn:active {
    transform: scale(.985);
}

.v2-google-btn__icon {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    fill: none !important;
    stroke: none !important;
    stroke-width: 0 !important;
}

.v2-google-btn__icon path {
    stroke: none !important;
    stroke-width: 0 !important;
    stroke-linecap: initial !important;
    stroke-linejoin: initial !important;
}

.v2-google-btn__label {
    display: flex;
    flex-direction: column;
    text-align: left;
    line-height: 1.2;
}

.v2-google-btn__label strong {
    font-size: 13.5px;
}

.v2-google-btn__label small {
    font-size: 11px;
    color: var(--v2-muted);
    font-weight: 400;
}

/* ── Divider ── */
.v2-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 12px;
    color: var(--v2-faint);
    font-weight: 500;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.v2-divider::before,
.v2-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--v2-line);
}

/* ── Form ── */
.v2-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.v2-email-only-note {
    margin-top: 14px;
    padding: 14px 16px;
    border: 1px solid #c7ddd5;
    border-radius: 16px;
    background: #eef8f4;
    color: #245147;
    font-size: 13px;
    line-height: 1.5;
}

.v2-field {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.v2-field__label {
    font-size: 12.5px;
    font-weight: 600;
    color: var(--v2-ink);
    letter-spacing: .01em;
}

.v2-field__input {
    width: 100%;
    height: 44px;
    padding: 0 14px;
    border-radius: var(--v2-r);
    border: 1px solid var(--v2-line);
    background: #f8faf9;
    color: var(--v2-ink);
    font-size: 14px;
    font-family: var(--v2-font);
    outline: none;
    transition: border-color .15s, box-shadow .15s, background .15s;
    -webkit-appearance: none;
}

.v2-field__input::placeholder {
    color: var(--v2-faint);
}

.v2-field__input:focus {
    border-color: var(--v2-brand);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(11, 122, 112, .12);
}

.v2-field__hint {
    font-size: 11.5px;
    color: var(--v2-faint);
    line-height: 1.4;
}

/* ── Password wrapper ── */
.v2-pw-wrap {
    position: relative;
}

.v2-pw-wrap .v2-field__input {
    padding-right: 56px;
}

.v2-pw-toggle {
    position: absolute;
    right: 0;
    top: 0;
    height: 100%;
    padding: 0 14px;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    color: var(--v2-brand);
    font-family: var(--v2-font);
    letter-spacing: .02em;
    text-transform: uppercase;
    transition: color .15s;
}

.v2-pw-toggle:hover {
    color: var(--v2-brand-dk);
}

/* ── Captcha / security field ── */
.v2-security-note {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 10px 12px;
    border-radius: var(--v2-r);
    background: #fffbeb;
    border: 1px solid #f5d97b;
    font-size: 12.5px;
    color: var(--v2-warn);
    line-height: 1.4;
}

/* ── Remember row ── */
.v2-meta-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.v2-checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--v2-muted);
    cursor: pointer;
    user-select: none;
}

.v2-checkbox input[type="checkbox"] {
    width: 16px !important;
    height: 16px !important;
    border-radius: 4px !important;
    border: 1.5px solid var(--v2-line) !important;
    accent-color: var(--v2-brand) !important;
    cursor: pointer !important;
    flex-shrink: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    appearance: auto !important;
    -webkit-appearance: auto !important;
}

/* ── Submit button (hard reset to override legacy base styles) ── */
.v2-submit,
.v2-submit:link,
.v2-submit:visited {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    width: 100% !important;
    height: 48px !important;
    padding: 0 20px !important;
    border-radius: var(--v2-r) !important;
    border: none !important;
    outline: none !important;
    background: var(--v2-brand) !important;
    background-image: none !important;
    color: #fff !important;
    font-size: 14.5px !important;
    font-weight: 600 !important;
    font-family: var(--v2-font) !important;
    line-height: 1 !important;
    text-align: center !important;
    text-decoration: none !important;
    cursor: pointer !important;
    letter-spacing: -.01em !important;
    box-sizing: border-box !important;
    transition: background .15s, transform .1s, box-shadow .15s !important;
    box-shadow: 0 2px 8px rgba(11,122,112,.3), 0 1px 2px rgba(0,0,0,.08) !important;
    margin-top: 4px !important;
    appearance: none !important;
    -webkit-appearance: none !important;
    opacity: 1 !important;
}

.v2-submit:hover {
    background: var(--v2-brand-dk) !important;
    box-shadow: 0 4px 16px rgba(11,122,112,.35) !important;
    color: #fff !important;
}

.v2-submit:active {
    transform: scale(.975) !important;
}

.v2-submit:focus-visible {
    box-shadow: 0 0 0 3px rgba(11,122,112,.35) !important;
}

.v2-submit svg {
    width: 16px !important;
    height: 16px !important;
    stroke: rgba(255,255,255,.75) !important;
    fill: none !important;
    flex-shrink: 0 !important;
}

/* ── Footer ── */
.v2-card__foot {
    padding: 16px 32px 20px;
    border-top: 1px solid var(--v2-line);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    flex-wrap: wrap;
}

.v2-foot__note {
    font-size: 11.5px;
    color: var(--v2-faint);
    margin: 0;
    line-height: 1.4;
    display: flex;
    align-items: center;
    gap: 5px;
}

.v2-foot__note svg {
    width: 13px;
    height: 13px;
    stroke: var(--v2-faint);
    flex-shrink: 0;
}

.v2-foot__credit {
    font-size: 11px;
    color: var(--v2-faint);
    font-family: var(--v2-mono);
}

.v2-foot__credit a {
    color: var(--v2-brand);
    text-decoration: none;
}

.v2-foot__credit a:hover {
    text-decoration: underline;
}

/* ── Flash / alerts ── */
.v2-flash {
    border-radius: var(--v2-r);
    padding: 10px 14px;
    font-size: 13px;
    line-height: 1.4;
}

.v2-flash--error {
    background: #fff2f1;
    border: 1px solid #f5c0bc;
    color: var(--v2-danger);
}

.v2-flash--success {
    background: #eef8f2;
    border: 1px solid #b0dfc0;
    color: #155e30;
}

/* ── Responsive tweaks ── */
@media (max-width: 480px) {
    .v2-shell {
        padding: 12px 12px;
        align-items: flex-start;
        padding-top: 20px;
    }

    .v2-card {
        border-radius: var(--v2-r-lg);
    }

    .v2-card__head {
        padding: 24px 22px 22px;
    }

    .v2-card__body {
        padding: 22px 22px 26px;
    }

    .v2-card__foot {
        padding: 14px 22px 18px;
    }

    .v2-head__title {
        font-size: 22px;
    }
}
