/* ------------------------------------------------------------------
   OLIHome Auth pages — cloned from OLIBiz's auth UI (Poppins, green +
   gold brand accents, solid form panel with a dot-grid + glow
   background, no card box, leading input icons, accent-bar titles,
   soft-square button, emerald promo carousel with concentric rings
   on the LEFT).
------------------------------------------------------------------ */

:root {
    --auth-page-bg: #eef2ee;         /* neutral fallback behind panels */

    --auth-form-bg: #f6f8f5;         /* form side surface */
    --auth-border: rgba(18, 38, 26, 0.12);
    --auth-input-bg: #ffffff;
    --auth-input-focus-bg: #ffffff;

    --auth-dot: rgba(50, 137, 59, 0.10);           /* dot-grid dots */
    --auth-glow-green: rgba(50, 137, 59, 0.12);    /* corner glow */
    --auth-glow-gold: rgba(184, 137, 47, 0.10);

    --auth-heading: #12261a;
    --auth-text: #55635a;
    --auth-muted: #9aa69d;

    --auth-theme: #32893b;           /* brand green */
    --auth-theme-hover: #1f5e29;     /* brand dark green */
    --auth-theme-light: #84bb4e;     /* brand light green */
    --auth-theme-glow: rgba(50, 137, 59, 0.30);

    --auth-gold: #b8892f;            /* brand gold secondary accent */
    --auth-gold-light: #d4a94a;
    --auth-gold-soft: rgba(184, 137, 47, 0.10);
    --auth-gold-border: rgba(184, 137, 47, 0.35);

    --auth-link: #32893b;
    --auth-link-hover: #1f5e29;

    --auth-danger: #d13c4b;
    --auth-danger-bg: rgba(209, 60, 75, 0.08);
    --auth-danger-border: rgba(209, 60, 75, 0.25);

    --auth-success: #1f5e29;
    --auth-success-bg: rgba(50, 137, 59, 0.08);
    --auth-success-border: rgba(50, 137, 59, 0.25);
    --auth-autofill-text: #12261a;
}

html.dark {
    --auth-form-bg: #0b1710;
    --auth-border: rgba(255, 255, 255, 0.14);
    --auth-input-bg: rgba(255, 255, 255, 0.03);
    --auth-input-focus-bg: rgba(255, 255, 255, 0.05);

    --auth-dot: rgba(255, 255, 255, 0.06);
    --auth-glow-green: rgba(50, 137, 59, 0.22);
    --auth-glow-gold: rgba(212, 169, 74, 0.14);

    --auth-heading: #ffffff;
    --auth-text: #cddbc7;
    --auth-muted: rgba(245, 247, 250, 0.5);

    --auth-link: #9ed373;
    --auth-link-hover: #c2e6a0;

    --auth-danger: #ff8a93;
    --auth-danger-bg: rgba(255, 90, 105, 0.12);
    --auth-danger-border: rgba(255, 90, 105, 0.3);

    --auth-success: #9ed373;
    --auth-success-bg: rgba(158, 211, 115, 0.12);
    --auth-success-border: rgba(158, 211, 115, 0.3);
    --auth-autofill-text: #ffffff;
}

html {
    height: 100%;
    overflow: hidden;
}

body.auth-body {
    height: 100vh;
    margin: 0;
    overflow: hidden;
    font-family: 'Poppins', sans-serif;
    background: var(--auth-page-bg);
    color: var(--auth-text);
}

/* --- Page: emerald promo carousel on the left, form on the right ---
   Pinned to exactly 100vh (not just min-height) so the browser window
   itself never scrolls; if the form content is ever taller than the
   viewport, .auth-form-side's own overflow-y:auto scrolls internally
   instead of the whole page growing past the viewport. */
.auth-page {
    position: relative;
    display: flex;
    height: 100vh;
    box-sizing: border-box;
}

/* ==================================================================
   FORM SIDE (right) — clean dotted surface, no card box
================================================================== */
.auth-form-side {
    position: relative;
    flex: 1 1 54%;
    display: flex;
    padding: 2.5rem 1.5rem;
    box-sizing: border-box;
    overflow-x: hidden;
    overflow-y: auto;
    background-color: var(--auth-form-bg);
    background-image:
        radial-gradient(ellipse 55% 45% at 100% 0%, var(--auth-glow-green), transparent 60%),
        radial-gradient(ellipse 50% 45% at 0% 100%, var(--auth-glow-gold), transparent 60%),
        radial-gradient(var(--auth-dot) 1.1px, transparent 1.3px);
    background-size: auto, auto, 22px 22px;
    background-position: center, center, center;
}

/* Form sits directly on the panel — no card box. Auto margins center it
   vertically when it fits and let it scroll (not clip) when it is taller
   than the viewport. */
.auth-form-wrap {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 400px;
    margin: auto;
    animation: auth-form-rise .7s cubic-bezier(.16, 1, .3, 1);
}

@keyframes auth-form-rise {
    from { opacity: 0; transform: translateY(18px); }
    to   { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
    .auth-form-wrap,
    .auth-promo-ring { animation: none; }
}

/* --- Header: logo --- */
.auth-card-top {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 1rem;
    margin-bottom: 2.5rem;
}

.auth-logo {
    width: 138px;
    height: auto;
}

html.dark .auth-logo {
    filter: brightness(0) invert(1);
}

.auth-card-head {
    margin-bottom: 1.75rem;
}

.auth-title {
    position: relative;
    margin: 0 0 1rem;
    padding-bottom: .85rem;
    font-size: 2.15rem;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -.01em;
    color: var(--auth-heading);
}

/* Short green -> gold accent under the heading (brand marker) */
.auth-title::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 2.75rem;
    height: 3px;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--auth-theme), var(--auth-gold));
}

.auth-title span {
    color: var(--auth-gold);
}

.auth-subtitle {
    margin: 0;
    font-size: .85rem;
    line-height: 1.7;
    color: var(--auth-text);
}

/* --- Form controls: bordered inputs with a leading icon --- */
.auth-field {
    position: relative;
    margin-bottom: 1.1rem;
}

.auth-field-icon {
    position: absolute;
    left: 1.1rem;
    top: 1.7rem;
    transform: translateY(-50%);
    color: var(--auth-muted);
    font-size: .9rem;
    pointer-events: none;
    transition: color .2s ease;
}

.auth-input {
    width: 100%;
    height: 3.4rem;
    padding: 0 1rem 0 2.9rem;
    font-family: inherit;
    font-size: .875rem;
    font-weight: 400;
    color: var(--auth-heading);
    background: var(--auth-input-bg);
    border: 1px solid var(--auth-border);
    border-radius: .8rem;
    outline: none;
    box-sizing: border-box;
    transition: border-color .2s ease, background .2s ease, box-shadow .2s ease;
}

.auth-input:focus {
    border-color: var(--auth-theme);
    background: var(--auth-input-focus-bg);
    box-shadow: 0 0 0 3px var(--auth-theme-glow);
}

.auth-field:focus-within .auth-field-icon {
    color: var(--auth-theme);
}

.auth-input::placeholder {
    color: var(--auth-muted);
}

input.auth-input:-webkit-autofill,
input.auth-input:-webkit-autofill:hover,
input.auth-input:-webkit-autofill:focus {
    -webkit-text-fill-color: var(--auth-autofill-text);
    -webkit-box-shadow: 0 0 0px 1000px var(--auth-input-bg) inset;
    transition: background-color 5000s ease-in-out 0s;
}

.auth-input-group .auth-input {
    padding-right: 3rem;
}

.auth-eye {
    position: absolute;
    right: 1rem;
    top: 1.7rem;
    transform: translateY(-50%);
    border: none;
    background: none;
    padding: 0;
    color: var(--auth-muted);
    font-size: .9rem;
    cursor: pointer;
    transition: color .2s ease;
}

.auth-eye:hover {
    color: var(--auth-theme);
}

.auth-row-end {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: .75rem;
    margin: .25rem 0 1.5rem;
}

.auth-link {
    color: var(--auth-link);
    font-size: .8rem;
    font-weight: 500;
    text-decoration: none;
    transition: color .3s;
}

.auth-link-icon {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
}

.auth-link:hover {
    color: var(--auth-link-hover);
    text-decoration: underline;
    text-decoration-color: var(--auth-gold);
    text-underline-offset: 3px;
}

/* --- Button: green gradient, soft-square, glow on hover --- */
.auth-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .55rem;
    width: 100%;
    padding: 1.05rem 2rem;
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    letter-spacing: .01em;
    line-height: 1;
    color: #fff;
    text-decoration: none;
    background: linear-gradient(120deg, var(--auth-theme) 0%, var(--auth-theme-hover) 100%);
    border: none;
    border-radius: .85rem;
    cursor: pointer;
    box-sizing: border-box;
    box-shadow: 0 10px 24px -10px var(--auth-theme-glow);
    transition: transform .2s ease, box-shadow .3s ease, filter .3s ease;
}

.auth-btn:hover {
    color: #fff;
    filter: brightness(1.03);
    transform: translateY(-1px);
    box-shadow: 0 16px 34px -12px var(--auth-theme-glow);
}

.auth-btn:active {
    transform: translateY(0);
}

/* --- Support ticket: waving-bot mascot + pill, pinned to the page's
   bottom-right, that opens into an FAQ + chat panel. The trigger pair
   rises in a beat after the form, the bot loops its own wave animation
   (robot.json via lottie-web), and the pill breathes a soft green
   glow while idle as a "we're here" cue. Opening the panel hides the
   trigger and grows the panel upward from the same anchored corner. */
.auth-support-widget {
    position: fixed;
    right: 1.5rem;
    bottom: 1.5rem;
    z-index: 20;
    opacity: 0;
    transform: translateY(14px);
    animation: auth-fab-rise .6s cubic-bezier(.16, 1, .3, 1) .5s forwards;
}

.auth-support-trigger {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: .25rem;
}

/* OLIOne's own "Oliver" AI-chatbot mascot (assets_v2/images/mascot/oliver.svg, copied from
   OLIOne/wwwroot/assets/images/mascot/oliver.svg) - a self-animating SVG (its own embedded SMIL
   loops), plus the same CSS bob wrapper OLIOne's _OliverChatWidget.cshtml applies to it, so this
   widget's trigger reads as the same character rather than a different one-off animation. */
.auth-support-bot {
    width: 130px;
    height: 130px;
    pointer-events: none;
    margin-bottom: -4px;
    object-fit: contain;
    animation: auth-support-bot-bob 3s ease-in-out infinite;
}

@keyframes auth-support-bot-bob {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50%      { transform: translateY(-6%) rotate(-2deg); }
}

@media (prefers-reduced-motion: reduce) {
    .auth-support-bot {
        animation: none;
    }
}

.auth-support-fab {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    padding: .7rem 1.2rem;
    font-family: inherit;
    font-size: .8rem;
    font-weight: 500;
    color: var(--auth-link);
    text-decoration: none;
    background: var(--auth-input-bg);
    border: 1px solid var(--auth-border);
    border-radius: 999px;
    cursor: pointer;
    box-shadow: 0 10px 24px -10px rgba(18, 38, 26, 0.25);
    animation: auth-fab-breathe 3.2s ease-in-out 1.1s infinite;
    transition: color .3s, transform .2s ease, box-shadow .3s ease, background .3s ease;
}

.auth-support-fab:hover {
    color: #fff;
    background: linear-gradient(120deg, var(--auth-theme) 0%, var(--auth-theme-hover) 100%);
    border-color: transparent;
    transform: translateY(-3px) scale(1.03);
    box-shadow: 0 16px 32px -10px var(--auth-theme-glow);
    animation-play-state: paused;
}

@keyframes auth-fab-rise {
    to { opacity: 1; transform: translateY(0); }
}

@keyframes auth-fab-breathe {
    0%, 100% { box-shadow: 0 10px 24px -10px rgba(18, 38, 26, 0.25); }
    50%      { box-shadow: 0 10px 26px -8px var(--auth-theme-glow); }
}

/* --- Support panel: FAQ list + stubbed chat, shown in place of the trigger --- */
.auth-support-panel {
    position: absolute;
    right: 0;
    bottom: 0;
    display: flex;
    flex-direction: column;
    width: min(360px, calc(100vw - 2.5rem));
    height: min(520px, calc(100vh - 3rem));
    background: var(--auth-input-bg);
    border: 1px solid var(--auth-border);
    border-radius: 1.1rem;
    box-shadow: 0 24px 48px -16px rgba(18, 38, 26, 0.35);
    overflow: hidden;
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
    transform-origin: bottom right;
    transform: translateY(10px) scale(.98);
    transition: opacity .25s ease, transform .25s cubic-bezier(.16, 1, .3, 1), visibility 0s linear .25s;
}

.auth-support-widget.is-open .auth-support-panel {
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0) scale(1);
    transition: opacity .25s ease, transform .25s cubic-bezier(.16, 1, .3, 1);
}

.auth-support-widget.is-open .auth-support-trigger {
    visibility: hidden;
}

.support-panel-header {
    display: flex;
    align-items: flex-start;
    gap: .65rem;
    padding: 1rem 1.1rem;
    background: linear-gradient(120deg, var(--auth-theme) 0%, var(--auth-theme-hover) 100%);
    color: #fff;
    flex-shrink: 0;
}

.support-panel-avatar {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    flex-shrink: 0;
    font-size: .85rem;
    background: rgba(255, 255, 255, 0.18);
    border-radius: 50%;
}

.support-panel-title {
    display: flex;
    flex-direction: column;
    gap: .15rem;
    flex: 1;
    min-width: 0;
}

.support-panel-title strong {
    font-size: .92rem;
}

.support-panel-title span {
    font-size: .74rem;
    color: rgba(255, 255, 255, 0.85);
}

.support-panel-close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    flex-shrink: 0;
    color: #fff;
    background: transparent;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transition: background .2s ease;
}

.support-panel-close:hover {
    background: rgba(255, 255, 255, 0.18);
}

.support-panel-body {
    flex: 1;
    min-height: 0;
    padding: 1rem 1.1rem;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: .7rem;
}

.support-msg {
    max-width: 88%;
    padding: .55rem .8rem;
    font-size: .82rem;
    line-height: 1.45;
    border-radius: .9rem;
}

.support-msg-bot {
    align-self: flex-start;
    color: var(--auth-heading);
    background: var(--auth-form-bg);
    border: 1px solid var(--auth-border);
    border-bottom-left-radius: .3rem;
}

.support-msg-user {
    align-self: flex-end;
    color: #fff;
    background: linear-gradient(120deg, var(--auth-theme) 0%, var(--auth-theme-hover) 100%);
    border-bottom-right-radius: .3rem;
}

.support-faq-list {
    display: flex;
    flex-direction: column;
    gap: .4rem;
}

.support-faq {
    border: 1px solid var(--auth-border);
    border-radius: .7rem;
    overflow: hidden;
}

.support-faq-question {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .5rem;
    width: 100%;
    padding: .6rem .8rem;
    font-family: inherit;
    font-size: .78rem;
    font-weight: 500;
    text-align: left;
    color: var(--auth-heading);
    background: var(--auth-form-bg);
    border: none;
    cursor: pointer;
}

.support-faq-question i {
    flex-shrink: 0;
    font-size: .7rem;
    color: var(--auth-muted);
    transition: transform .25s ease;
}

.support-faq.is-open .support-faq-question i {
    transform: rotate(180deg);
}

.support-faq-answer {
    max-height: 0;
    padding: 0 .8rem;
    font-size: .78rem;
    line-height: 1.5;
    color: var(--auth-text);
    overflow: hidden;
    transition: max-height .25s ease, padding .25s ease;
}

.support-faq.is-open .support-faq-answer {
    max-height: 160px;
    padding: .6rem .8rem .75rem;
}

.support-panel-divider {
    padding-top: .2rem;
    font-size: .72rem;
    text-align: center;
    color: var(--auth-muted);
}

/* --- Support panel: real ticket submission form (Category, Inquiry Type, Subject,
   Description, Name, Email/Phone) - mirrors OLIOne's own /CMN/Tickets/Create fields,
   just laid out for the widget's narrow width. --- */
.support-ticket-form,
.support-ticket-form * {
    box-sizing: border-box;
}

.support-ticket-form {
    display: flex;
    flex-direction: column;
    gap: .55rem;
    padding-top: .2rem;
}

.support-ticket-row {
    display: flex;
    flex-direction: column;
    gap: .35rem;
}

.support-ticket-row-split {
    flex-direction: row;
    gap: .5rem;
}

.support-ticket-row-split .support-ticket-input {
    flex: 1;
    min-width: 0;
}

.support-ticket-col {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: .35rem;
}

.support-ticket-optional {
    font-weight: 400;
    color: var(--auth-muted);
}

.support-ticket-label {
    font-size: .74rem;
    font-weight: 500;
    color: var(--auth-muted);
}

.support-ticket-select,
.support-ticket-input {
    width: 100%;
    padding: .55rem .75rem;
    font-family: inherit;
    font-size: .8rem;
    color: var(--auth-heading);
    background: var(--auth-form-bg);
    border: 1px solid var(--auth-border);
    border-radius: .7rem;
    outline: none;
    transition: border-color .2s ease;
}

.support-ticket-select:focus,
.support-ticket-input:focus {
    border-color: var(--auth-theme);
}

.support-ticket-textarea {
    resize: vertical;
    min-height: 2.4rem;
}

.support-ticket-inquiry {
    display: flex;
    gap: .5rem;
}

.support-ticket-attachments {
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
}

.support-ticket-attachments:empty {
    display: none;
}

.support-ticket-file-chip {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    max-width: 100%;
    padding: .3rem .4rem .3rem .7rem;
    font-size: .74rem;
    color: var(--auth-heading);
    background: var(--auth-form-bg);
    border: 1px solid var(--auth-border);
    border-radius: 999px;
}

.support-ticket-file-chip span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 10rem;
}

.support-ticket-file-remove {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.2rem;
    height: 1.2rem;
    padding: 0;
    color: var(--auth-muted);
    background: none;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: .7rem;
}

.support-ticket-file-remove:hover {
    color: #d9534f;
    background: var(--auth-border);
}

.support-ticket-attach-btn {
    align-self: flex-start;
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    padding: .45rem .9rem;
    font-family: inherit;
    font-size: .76rem;
    font-weight: 500;
    color: var(--auth-heading);
    background: var(--auth-form-bg);
    border: 1px solid var(--auth-border);
    border-radius: 999px;
    cursor: pointer;
    transition: background .2s ease;
}

.support-ticket-attach-btn:hover {
    background: var(--auth-border);
}

.support-ticket-radio {
    display: flex;
    align-items: center;
    gap: .35rem;
    padding: .4rem .75rem;
    font-size: .78rem;
    color: var(--auth-heading);
    background: var(--auth-form-bg);
    border: 1px solid var(--auth-border);
    border-radius: 999px;
    cursor: pointer;
    transition: border-color .2s ease, color .2s ease, background .2s ease;
}

.support-ticket-radio input {
    accent-color: var(--auth-theme);
}

.support-ticket-radio:has(input:checked) {
    color: var(--auth-theme);
    background: var(--auth-input-bg);
    border-color: var(--auth-theme);
}

.support-ticket-error {
    display: none;
    font-size: .74rem;
    color: #d64545;
}

.support-ticket-error.is-visible {
    display: block;
}

/* --- "New Ticket" trigger (inside the slide-out panel, opens the modal below) --- */
.support-new-ticket-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .4rem;
    width: 100%;
    padding: .6rem .9rem;
    font-family: inherit;
    font-size: .8rem;
    font-weight: 500;
    color: #fff;
    background: linear-gradient(120deg, var(--auth-theme) 0%, var(--auth-theme-hover) 100%);
    border: none;
    border-radius: 999px;
    cursor: pointer;
    transition: transform .2s ease, filter .2s ease;
}

.support-new-ticket-btn:hover {
    filter: brightness(1.05);
    transform: translateY(-1px);
}

/* --- New Ticket modal - mirrors OLIOne's CSG/Tickets/Lists "New Ticket" modal chrome (icon-chip
   header + title/subtitle, close X, footer Cancel/Submit) as a plain overlay, since this layout
   carries no Bootstrap. Lives as a sibling of the widget so its centered/dimmed overlay isn't
   clipped by the widget's own narrow panel. --- */
.support-modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 30;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background: rgba(18, 38, 26, 0.45);
    opacity: 0;
    visibility: hidden;
    transition: opacity .2s ease, visibility 0s linear .2s;
}

.support-modal-backdrop.is-open {
    opacity: 1;
    visibility: visible;
    transition: opacity .2s ease;
}

.support-modal {
    display: flex;
    flex-direction: column;
    width: min(600px, 100%);
    max-height: calc(100vh - 3rem);
    background: var(--auth-input-bg);
    border-radius: 1.25rem;
    box-shadow: 0 30px 60px -20px rgba(18, 38, 26, 0.45);
    overflow: hidden;
    transform: translateY(12px) scale(.98);
    transition: transform .2s cubic-bezier(.16, 1, .3, 1);
}

.support-modal-backdrop.is-open .support-modal {
    transform: translateY(0) scale(1);
}

.support-modal-header {
    display: flex;
    align-items: flex-start;
    gap: .75rem;
    padding: 1.25rem 1.25rem 1rem;
    flex-shrink: 0;
}

.support-modal-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    flex-shrink: 0;
    font-size: 1.05rem;
    color: var(--auth-theme);
    background: var(--auth-form-bg);
    border-radius: 1rem;
}

.support-modal-title-wrap {
    flex: 1;
    min-width: 0;
}

.support-modal-title {
    margin: 0 0 .15rem;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--auth-heading);
}

.support-modal-subtitle {
    font-size: .78rem;
    color: var(--auth-muted);
}

.support-modal-close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    flex-shrink: 0;
    color: var(--auth-muted);
    background: transparent;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transition: background .2s ease, color .2s ease;
}

.support-modal-close:hover {
    color: var(--auth-heading);
    background: var(--auth-form-bg);
}

.support-modal-body {
    flex: 1;
    min-height: 0;
    padding: 0 1.25rem 1.25rem;
    overflow-y: auto;
}

.support-modal-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: .6rem;
    padding: 1rem 1.25rem;
    border-top: 1px solid var(--auth-border);
    flex-shrink: 0;
}

.support-modal-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .4rem;
    padding: .6rem 1.1rem;
    font-family: inherit;
    font-size: .8rem;
    font-weight: 500;
    border: none;
    border-radius: 999px;
    cursor: pointer;
    transition: transform .2s ease, filter .2s ease, opacity .2s ease, background .2s ease;
}

.support-modal-btn-ghost {
    color: var(--auth-heading);
    background: var(--auth-form-bg);
}

.support-modal-btn-ghost:hover {
    background: var(--auth-border);
}

.support-modal-btn-primary {
    color: #fff;
    background: linear-gradient(120deg, var(--auth-theme) 0%, var(--auth-theme-hover) 100%);
}

.support-modal-btn-primary:hover {
    filter: brightness(1.05);
    transform: translateY(-1px);
}

.support-modal-btn-primary:disabled {
    opacity: .65;
    cursor: not-allowed;
    transform: none;
}

.support-dpa-text {
    margin: 0;
    font-size: .82rem;
    line-height: 1.6;
    color: var(--auth-text);
}

/* Stacked on top of newTicketModalBackdrop - both share .support-modal-backdrop's z-index: 30,
   so this bump keeps the consent gate above the form it's gating rather than relying on DOM order. */
#dpaTicketModalBackdrop {
    z-index: 40;
}

/* --- "Track a Ticket" trigger - same shape as .support-new-ticket-btn, outlined instead of
   filled so the two don't compete for attention. --- */
.support-track-ticket-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .4rem;
    width: 100%;
    margin-top: .5rem;
    padding: .6rem .9rem;
    font-family: inherit;
    font-size: .8rem;
    font-weight: 500;
    color: var(--auth-heading);
    background: transparent;
    border: 1px solid var(--auth-border);
    border-radius: 999px;
    cursor: pointer;
    transition: background .2s ease, border-color .2s ease;
}

.support-track-ticket-btn:hover {
    background: var(--auth-form-bg);
    border-color: var(--auth-theme);
}

/* --- Track a Ticket modal body - search row, then the looked-up ticket's status/conversation/
   reply, hidden until a lookup succeeds. --- */
.track-ticket-search-row {
    display: flex;
    gap: .5rem;
}

.track-ticket-search-row .support-ticket-input {
    flex: 1;
}

.track-ticket-result {
    display: none;
    flex-direction: column;
    gap: .75rem;
    margin-top: 1rem;
}

.track-ticket-result.is-visible {
    display: flex;
}

.track-ticket-header {
    display: flex;
    align-items: center;
    gap: .6rem;
    flex-wrap: wrap;
}

.track-ticket-status-badge {
    display: inline-flex;
    align-items: center;
    padding: .25rem .65rem;
    font-size: .72rem;
    font-weight: 600;
    border-radius: 999px;
}

.track-ticket-subject {
    font-size: .9rem;
    font-weight: 600;
    color: var(--auth-heading);
}

.track-ticket-desc {
    margin: 0;
    font-size: .82rem;
    line-height: 1.5;
    color: var(--auth-text);
}

.track-ticket-messages {
    display: flex;
    flex-direction: column;
    gap: .5rem;
    max-height: 260px;
    overflow-y: auto;
    padding: .25rem;
}

.track-ticket-reply {
    display: none;
    gap: .5rem;
}

.track-ticket-reply.is-visible {
    display: flex;
}

.track-ticket-reply .support-ticket-input {
    flex: 1;
}

.track-ticket-closed-note {
    display: none;
    margin: 0;
    font-size: .78rem;
    color: var(--auth-muted);
    text-align: center;
}

.track-ticket-closed-note.is-visible {
    display: block;
}

@media (max-width: 480px) {
    .support-modal-backdrop { padding: 1rem; }
}

@media (prefers-reduced-motion: reduce) {
    .support-modal-backdrop,
    .support-modal {
        transition: none;
    }
}

@media (max-width: 480px) {
    .auth-support-widget { right: 1rem; bottom: 1rem; }
}

@media (prefers-reduced-motion: reduce) {
    .auth-support-widget {
        opacity: 1;
        transform: none;
        animation: none;
    }

    .auth-support-fab {
        animation: none;
    }

    .auth-support-panel {
        transition: none;
    }
}

/* --- Footnote --- */
.auth-footnote {
    margin: 1.5rem 0 0;
    text-align: center;
    font-size: .72rem;
    color: var(--auth-muted);
}

.auth-footnote .auth-link {
    font-size: inherit;
    font-weight: 600;
}

/* --- Secondary / ghost button --- */
.auth-btn-ghost {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .55rem;
    width: 100%;
    padding: .95rem 2rem;
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    color: var(--auth-theme);
    background: transparent;
    border: 1.5px solid var(--auth-border);
    border-radius: .85rem;
    cursor: pointer;
    box-sizing: border-box;
    text-decoration: none;
    transition: border-color .2s ease, background .2s ease, color .2s ease;
}

.auth-btn-ghost:hover {
    color: var(--auth-theme-hover);
    border-color: var(--auth-theme);
    background: rgba(50, 137, 59, 0.06);
}

html.dark .auth-btn-ghost:hover {
    background: rgba(132, 187, 78, 0.10);
}

/* --- "or" divider --- */
.auth-divider {
    display: flex;
    align-items: center;
    gap: .75rem;
    margin: 1.25rem 0;
    color: var(--auth-muted);
    font-size: .68rem;
    font-weight: 600;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--auth-border);
}

/* --- Validation --- */
.auth-alert {
    display: flex;
    align-items: flex-start;
    gap: .6rem;
    margin-bottom: 1.25rem;
    padding: .75rem 1rem;
    font-size: .8rem;
    line-height: 1.6;
    color: var(--auth-danger);
    background: var(--auth-danger-bg);
    border: 1px solid var(--auth-danger-border);
    border-radius: .6rem;
}

.auth-alert i {
    margin-top: .2rem;
}

.auth-alert-success {
    color: var(--auth-success);
    background: var(--auth-success-bg);
    border-color: var(--auth-success-border);
}

.auth-field-error {
    display: block;
    margin-top: .35rem;
    font-size: .75rem;
    color: var(--auth-danger);
}

.auth-field-error:empty {
    display: none;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ==================================================================
   PROMO SIDE (left) — emerald carousel with concentric rings
================================================================== */
.auth-promo-side {
    position: relative;
    order: -1;                       /* move carousel to the left */
    flex: 1 1 46%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 3.5rem;
    color: #fff;
    overflow: hidden;
    box-sizing: border-box;
    background:
        radial-gradient(circle at 85% 12%, rgba(212, 169, 74, 0.22), transparent 42%),
        radial-gradient(circle at 12% 92%, rgba(132, 187, 78, 0.20), transparent 45%),
        linear-gradient(150deg, #0d3a1c 0%, #1b5a2b 55%, #0f4020 100%);
}

/* Concentric ring outlines drifting behind the copy */
.auth-promo-ring {
    position: absolute;
    z-index: 0;
    border-radius: 50%;
    border: 1.5px solid rgba(255, 255, 255, 0.10);
    pointer-events: none;
    animation-timing-function: ease-in-out;
    animation-iteration-count: infinite;
    animation-direction: alternate;
}

.auth-promo-ring-1 {
    width: 34rem; height: 34rem;
    top: -10rem; right: -12rem;
    border-color: rgba(255, 255, 255, 0.12);
    animation-name: auth-ring-drift-1;
    animation-duration: 24s;
    animation-delay: -5s;
}

.auth-promo-ring-2 {
    width: 22rem; height: 22rem;
    top: -4rem; right: -4rem;
    border-color: rgba(212, 169, 74, 0.28);   /* gold ring accent */
    animation-name: auth-ring-drift-2;
    animation-duration: 19s;
    animation-delay: -9s;
}

.auth-promo-ring-3 {
    width: 16rem; height: 16rem;
    bottom: -5rem; left: -5rem;
    border-color: rgba(255, 255, 255, 0.10);
    animation-name: auth-ring-drift-3;
    animation-duration: 27s;
    animation-delay: -3s;
}

@keyframes auth-ring-drift-1 {
    0%   { transform: translate(0, 0) scale(1); }
    100% { transform: translate(-26px, 20px) scale(1.05); }
}

@keyframes auth-ring-drift-2 {
    0%   { transform: translate(0, 0) scale(1); }
    100% { transform: translate(18px, 24px) scale(.95); }
}

@keyframes auth-ring-drift-3 {
    0%   { transform: translate(0, 0) scale(1); }
    100% { transform: translate(22px, -18px) scale(1.07); }
}

.auth-promo-logo {
    position: relative;
    z-index: 1;
    width: 150px;
    height: auto;
    margin-bottom: 3.5rem;
    filter: brightness(0) invert(1);
}

.auth-promo-slides {
    position: relative;
    z-index: 1;
    min-height: 15rem;
}

.auth-promo-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: opacity .6s ease, transform .6s ease, visibility .6s;
}

.auth-promo-slide.is-active {
    position: relative;
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.auth-promo-kicker {
    display: inline-block;
    margin-bottom: 1rem;
    font-size: .72rem;
    font-weight: 600;
    letter-spacing: .18em;
    text-transform: uppercase;
    color: var(--auth-gold-light);
}

.auth-promo-title {
    margin: 0 0 1.25rem;
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1.2;
}

.auth-promo-text {
    margin: 0;
    max-width: 26rem;
    font-size: .95rem;
    font-weight: 300;
    line-height: 1.8;
    color: rgba(255, 255, 255, 0.85);
}

.auth-promo-dots {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: .6rem;
    margin-top: 2.5rem;
}

.auth-promo-dot {
    width: 9px;
    height: 9px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    padding: 0;
    cursor: pointer;
    transition: width .3s, background .3s, border-radius .3s;
}

.auth-promo-dot.is-active {
    width: 2rem;
    border-radius: 5px;
    background: var(--auth-gold-light);   /* gold pill for the active slide */
}

@media (max-width: 991px) {
    .auth-promo-side { display: none; }
    .auth-form-side { flex-basis: 100%; }
}

/* Shorter laptop screens: the default spacing above is tuned for tall
   viewports and can end up a few px taller than 100vh, which trips
   .auth-form-side's overflow-y:auto fallback. Tighten the vertical
   rhythm here so the form keeps fitting within the viewport instead
   of scrolling. */
@media (max-height: 820px) {
    .auth-form-side { padding-top: 1.5rem; padding-bottom: 1.5rem; }
    .auth-card-top { margin-bottom: 1.25rem; }
    .auth-logo { width: 110px; }
    .auth-card-head { margin-bottom: 1.1rem; }
    .auth-title { margin-bottom: .6rem; padding-bottom: .6rem; font-size: 1.75rem; }
    .auth-field { margin-bottom: .75rem; }
    .auth-row-end { margin: .25rem 0 1rem; }
    .auth-divider { margin: .85rem 0; }
    .auth-footnote { margin-top: 1rem; }
}
