/* Admin Login — scoped to this page only, does not affect other login pages.
   Light "console" look (teal/indigo accents), intentionally different from the franchisee (frn-) login. */

.adm-page {
    --adm-bg: #f4f7fb;
    --adm-surface: rgba(255, 255, 255, 0.92);
    --adm-surface-2: #f8fafc;
    --adm-border: #e3e8f0;
    --adm-border-strong: #d4dbe6;
    --adm-text: #0f172a;
    --adm-muted: #64748b;
    --adm-accent: #0d9488;
    --adm-accent-2: #6366f1;
    --adm-danger: #dc2626;

    position: relative;
    margin: 0;
    padding: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    font-family: 'Inter', 'Segoe UI', Arial, sans-serif;
    color: var(--adm-text);
    background: var(--adm-bg);
    overflow-x: hidden;
}

.adm-page * {
    box-sizing: border-box;
}

/* ---------- Background ---------- */
.adm-grid-bg {
    position: fixed;
    inset: 0;
    background-image:
        linear-gradient(rgba(100, 116, 139, 0.08) 1px, transparent 1px),
        linear-gradient(90deg, rgba(100, 116, 139, 0.08) 1px, transparent 1px);
    background-size: 44px 44px;
    -webkit-mask-image: radial-gradient(ellipse at center, #000 30%, transparent 75%);
    mask-image: radial-gradient(ellipse at center, #000 30%, transparent 75%);
    pointer-events: none;
    z-index: 0;
}

.adm-glow {
    position: fixed;
    width: 520px;
    height: 520px;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.16;
    pointer-events: none;
    z-index: 0;
}

.adm-glow-1 { background: var(--adm-accent); top: -180px; left: -140px; }
.adm-glow-2 { background: var(--adm-accent-2); bottom: -200px; right: -160px; }

/* ---------- Top bar ---------- */
.adm-topbar {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 22px 40px;
}

.adm-topbar-logo {
    height: 30px;
}

.adm-secure-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    border: 1px solid var(--adm-border);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.8);
    font-family: 'JetBrains Mono', Consolas, monospace;
    font-size: 11px;
    letter-spacing: 0.5px;
    color: var(--adm-muted);
    text-transform: uppercase;
}

.adm-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--adm-accent);
    animation: adm-pulse 2s infinite;
}

@keyframes adm-pulse {
    0% { box-shadow: 0 0 0 0 rgba(20, 184, 166, 0.6); }
    70% { box-shadow: 0 0 0 8px rgba(20, 184, 166, 0); }
    100% { box-shadow: 0 0 0 0 rgba(20, 184, 166, 0); }
}

/* ---------- Card ---------- */
.adm-center {
    position: relative;
    z-index: 1;
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px 16px;
}

.adm-card {
    position: relative;
    width: 100%;
    max-width: 420px;
    padding: 40px 36px 28px;
    background: var(--adm-surface);
    border: 1px solid var(--adm-border);
    border-radius: 18px;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: 0 24px 60px -20px rgba(15, 23, 42, 0.18), 0 2px 6px rgba(15, 23, 42, 0.04);
}

.adm-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 36px;
    right: 36px;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--adm-accent), var(--adm-accent-2), transparent);
}

.adm-card-head {
    text-align: center;
    margin-bottom: 28px;
}

.adm-shield {
    width: 58px;
    height: 58px;
    margin: 0 auto 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    font-size: 26px;
    color: #fff;
    background: linear-gradient(135deg, var(--adm-accent) 0%, var(--adm-accent-2) 100%);
    box-shadow: 0 10px 24px rgba(13, 148, 136, 0.25);
}

.adm-eyebrow {
    display: block;
    font-family: 'JetBrains Mono', Consolas, monospace;
    font-size: 11px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--adm-accent);
    margin-bottom: 8px;
}

.adm-card-head h1 {
    margin: 0 0 8px;
    font-size: 26px;
    font-weight: 700;
    color: var(--adm-text);
}

.adm-card-head p {
    margin: 0;
    font-size: 13px;
    line-height: 1.6;
    color: var(--adm-muted);
}

/* ---------- Fields ---------- */
.adm-field {
    margin-bottom: 18px;
}

.adm-field label {
    display: block;
    margin-bottom: 7px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.4px;
    text-transform: uppercase;
    color: var(--adm-muted);
}

.adm-input-group {
    position: relative;
    display: flex;
    align-items: center;
    background: var(--adm-surface-2);
    border: 1px solid var(--adm-border-strong);
    border-radius: 10px;
    transition: border-color .2s, box-shadow .2s;
}

.adm-input-group:focus-within {
    background: #fff;
    border-color: var(--adm-accent);
    box-shadow: 0 0 0 3px rgba(13, 148, 136, 0.15);
}

.adm-input-icon {
    width: 44px;
    text-align: center;
    color: var(--adm-muted);
    font-size: 15px;
}

.adm-input-group:focus-within .adm-input-icon {
    color: var(--adm-accent);
}

.adm-input-group input {
    flex: 1;
    min-width: 0;
    height: 46px;
    padding: 0 12px 0 0;
    border: 0;
    outline: 0;
    background: transparent;
    color: var(--adm-text);
    font-family: inherit;
    font-size: 14px;
}

.adm-input-group input::placeholder {
    color: #94a3b8;
}

.adm-input-group input:-webkit-autofill {
    -webkit-text-fill-color: var(--adm-text);
    -webkit-box-shadow: 0 0 0 1000px #fff inset;
    caret-color: var(--adm-text);
}

.adm-toggle-pass {
    width: 44px;
    height: 46px;
    border: 0;
    background: transparent;
    color: var(--adm-muted);
    cursor: pointer;
    font-size: 15px;
}

.adm-toggle-pass:hover {
    color: var(--adm-text);
}

.adm-page .text-danger,
.adm-page .field-validation-error {
    display: block;
    margin-top: 6px;
    font-size: 12px;
    color: var(--adm-danger);
}

.adm-validation-summary ul {
    margin: 0 0 18px;
    padding: 10px 14px;
    list-style: none;
    font-size: 13px;
    color: var(--adm-danger);
    background: rgba(220, 38, 38, 0.06);
    border: 1px solid rgba(220, 38, 38, 0.25);
    border-radius: 10px;
}

.adm-validation-summary.validation-summary-valid {
    display: none;
}

/* ---------- Remember + submit ---------- */
.adm-row-between {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 4px 0 22px;
}

.adm-remember {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--adm-muted);
    cursor: pointer;
    user-select: none;
}

.adm-remember input {
    width: 16px;
    height: 16px;
    accent-color: var(--adm-accent);
    cursor: pointer;
}

.adm-submit-btn {
    width: 100%;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border: 0;
    border-radius: 10px;
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    color: #fff;
    cursor: pointer;
    background: linear-gradient(135deg, var(--adm-accent) 0%, var(--adm-accent-2) 100%);
    box-shadow: 0 10px 22px rgba(99, 102, 241, 0.22);
    transition: transform .15s, box-shadow .15s, filter .15s;
}

.adm-submit-btn .fa-arrow-right {
    transition: transform .15s;
}

.adm-submit-btn:hover {
    filter: brightness(1.08);
    box-shadow: 0 14px 28px rgba(99, 102, 241, 0.3);
}

.adm-submit-btn:hover .fa-arrow-right {
    transform: translateX(3px);
}

.adm-submit-btn:active {
    transform: translateY(1px);
}

.adm-submit-btn:disabled,
.adm-submit-btn.is-loading {
    cursor: not-allowed;
    opacity: .75;
    filter: none;
    box-shadow: none;
    transform: none;
}

.adm-submit-btn .adm-btn-loading {
    display: none;
    align-items: center;
    gap: 10px;
}

.adm-submit-btn.is-loading .adm-btn-label {
    display: none;
}

.adm-submit-btn.is-loading .adm-btn-loading {
    display: inline-flex;
}

.adm-card-foot {
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid var(--adm-border);
    text-align: center;
    font-family: 'JetBrains Mono', Consolas, monospace;
    font-size: 11px;
    color: var(--adm-muted);
}

.adm-card-foot .fa {
    color: var(--adm-accent);
    margin-right: 4px;
}

/* ---------- Footer ---------- */
.adm-footer {
    position: relative;
    z-index: 1;
    padding: 18px 16px 24px;
    text-align: center;
    font-size: 12px;
    color: var(--adm-muted);
}

/* ---------- Responsive ---------- */
@media (max-width: 575px) {
    .adm-topbar { padding: 16px; }
    .adm-topbar-logo { height: 24px; }
    .adm-secure-pill { font-size: 10px; padding: 5px 10px; }
    .adm-card { padding: 32px 22px 22px; border-radius: 14px; }
    .adm-card-head h1 { font-size: 22px; }
}
