/* ─── Login Page — TSS Whiz Digital ─── */

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

:root {
    --g1: #062924;
    --g2: #0a3d36;
    --g3: #0d9488;
    --g4: #059669;
    --accent: #2dd4bf;
    --white: #ffffff;
    --form-bg: #ffffff;
    --text-dark: #0f172a;
    --text-mid: #475569;
    --text-light: #94a3b8;
    --border: #e2e8f0;
    --input-bg: #f8fafc;
    --danger: #ef4444;
    --radius-md: 12px;
    --radius-lg: 20px;
}

html, body {
    height: 100%;
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    background: var(--g1);
    overflow: hidden;
}

/* ─── ROOT LAYOUT ─── */
.page {
    display: flex;
    height: 100vh;
}

/* ═══════════════════════════════
   LEFT PANEL
═══════════════════════════════ */
.left {
    flex: 1 1 0;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.left-bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 90% 70% at 0% 0%,    #0d9488 0%, transparent 55%),
        radial-gradient(ellipse 70% 60% at 100% 0%,  #065f46 0%, transparent 55%),
        radial-gradient(ellipse 80% 80% at 50% 110%, #064e3b 0%, transparent 60%),
        linear-gradient(160deg, #062924 0%, #0a3d36 100%);
    animation: bgShift 16s ease-in-out infinite alternate;
}
@keyframes bgShift {
    0%   { filter: brightness(1)    hue-rotate(0deg);  }
    50%  { filter: brightness(1.06) hue-rotate(5deg);  }
    100% { filter: brightness(.96)  hue-rotate(-3deg); }
}

.left-dots {
    position: absolute;
    inset: 0;
    background-image: radial-gradient(circle, rgba(255,255,255,.07) 1px, transparent 1px);
    background-size: 32px 32px;
}

.blob {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(45,212,191,.15), transparent 70%);
    animation: blobFloat 10s ease-in-out infinite alternate;
}
.blob-a { width: 520px; height: 520px; top: -200px; right: -160px; animation-delay: 0s; }
.blob-b { width: 340px; height: 340px; bottom: -80px; left: -80px;  animation-delay: 3s; }
.blob-c { width: 200px; height: 200px; top: 45%; left: 55%;         animation-delay: 6s; }
@keyframes blobFloat {
    from { transform: translate(0, 0) scale(1); }
    to   { transform: translate(0, -30px) scale(1.06); }
}

.left-inner {
    position: relative;
    z-index: 2;
    height: 100%;
    display: flex;
    flex-direction: column;
    padding: 44px 56px;
}

.left-logo img {
    height: 38px;
    filter: brightness(0) invert(1);
    opacity: .9;
}

.left-hero {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 48px 0 32px;
}

/* Live system pill */
.pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255,255,255,.1);
    border: 1px solid rgba(255,255,255,.15);
    border-radius: 100px;
    padding: 5px 14px 5px 10px;
    color: var(--accent);
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    margin-bottom: 24px;
    backdrop-filter: blur(6px);
    width: fit-content;
}
.pill-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent);
    animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%       { opacity: .5; transform: scale(.7); }
}

.left-hero h1 {
    font-size: clamp(2.2rem, 3.2vw, 3.4rem);
    font-weight: 800;
    color: var(--white);
    line-height: 1.12;
    letter-spacing: -.03em;
    margin-bottom: 18px;
}
.left-hero h1 em {
    font-style: normal;
    color: var(--accent);
}

.left-hero .desc {
    font-size: .95rem;
    color: rgba(255,255,255,.55);
    line-height: 1.65;
    max-width: 400px;
    margin-bottom: 40px;
}

/* Stats */
.stats { display: flex; align-items: center; }
.stat-item {
    display: flex;
    flex-direction: column;
    padding: 0 28px 0 0;
}
.stat-item:not(:first-child) {
    padding-left: 28px;
    border-left: 1px solid rgba(255,255,255,.12);
}
.stat-val {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--white);
    line-height: 1;
    letter-spacing: -.01em;
}
.stat-lbl {
    font-size: .68rem;
    font-weight: 600;
    color: rgba(255,255,255,.38);
    text-transform: uppercase;
    letter-spacing: .09em;
    margin-top: 5px;
}

/* Bottom: StayConnected + logos */
.left-bottom {
    border-top: 1px solid rgba(255,255,255,.08);
    padding-top: 28px;
}
.stay {
    font-size: .78rem;
    font-weight: 700;
    letter-spacing: .18em;
    text-transform: uppercase;
    color: rgba(255,255,255,.38);
    margin-bottom: 20px;
}
.stay span { color: var(--accent); }

.partners {
    display: flex;
    align-items: center;
    gap: 36px;
}
.partner-lbl {
    font-size: .64rem;
    font-weight: 600;
    color: rgba(255,255,255,.25);
    text-transform: uppercase;
    letter-spacing: .1em;
    white-space: nowrap;
}
.partner-divider {
    width: 1px;
    height: 24px;
    background: rgba(255,255,255,.1);
}
.partner-logos {
    display: flex;
    align-items: center;
    gap: 32px;
}
.partner-logos a,
.partner-logos span {
    display: flex;
    align-items: center;
    opacity: .55;
    transition: opacity .25s;
    text-decoration: none;
}
.partner-logos a:hover,
.partner-logos span:hover { opacity: 1; }
.partner-logos img {
    height: 32px;
    width: auto;
    display: block;
    filter: brightness(0) invert(1);
}

.logo-utera { display: flex; align-items: center; gap: 6px; }
.logo-utera svg { width: 28px; height: 28px; }
.logo-utera-text {
    font-size: .95rem;
    font-weight: 800;
    color: rgba(255,255,255,.9);
    letter-spacing: -.01em;
}

/* ═══════════════════════════════
   RIGHT PANEL
═══════════════════════════════ */
.right {
    flex: 0 0 430px;
    background: var(--form-bg);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 56px 48px;
    box-shadow: -20px 0 60px rgba(0,0,0,.25);
    position: relative;
    z-index: 10;
}

.form-wrap { width: 100%; max-width: 320px; }

.form-eyebrow {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: .7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .12em;
    color: var(--g3);
    margin-bottom: 10px;
}
.form-eyebrow::before {
    content: '';
    display: block;
    width: 20px;
    height: 2px;
    background: var(--g3);
    border-radius: 2px;
}

.form-title {
    font-size: 1.9rem;
    font-weight: 800;
    color: var(--text-dark);
    letter-spacing: -.03em;
    line-height: 1.15;
    margin-bottom: 6px;
}
.form-subtitle {
    font-size: .83rem;
    color: var(--text-mid);
    margin-bottom: 36px;
}

/* Fields */
.field { margin-bottom: 18px; }
.field label {
    display: block;
    font-size: .75rem;
    font-weight: 600;
    color: var(--text-mid);
    margin-bottom: 7px;
}
.input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}
.input-icon {
    position: absolute;
    left: 14px;
    width: 17px;
    height: 17px;
    color: var(--text-light);
    pointer-events: none;
    flex-shrink: 0;
    transition: color .2s;
}
.input-wrap input {
    width: 100%;
    height: 48px;
    padding: 0 14px 0 44px;
    background: var(--input-bg);
    border: 1.5px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--text-dark);
    font-size: .88rem;
    outline: none;
    transition: border-color .2s, background .2s, box-shadow .2s;
}
.input-wrap input::placeholder { color: #cbd5e1; }
.input-wrap:focus-within input {
    border-color: var(--g3);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(13,148,136,.1);
}
.input-wrap:focus-within .input-icon { color: var(--g3); }

.pw-toggle {
    position: absolute;
    right: 12px;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-light);
    display: flex;
    align-items: center;
    padding: 0;
    transition: color .2s;
}
.pw-toggle:hover { color: var(--g3); }
.pw-toggle svg { width: 17px; height: 17px; }

/* Alert / Error */
#error-msg { margin-bottom: 16px; min-height: 0; }
.alert {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    padding: 11px 14px;
    border-radius: 10px;
    font-size: .8rem;
    line-height: 1.45;
    animation: fadeIn .2s ease;
}
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-4px); }
    to   { opacity: 1; transform: none; }
}
.alert-error { background: #fef2f2; border: 1px solid #fecaca; color: var(--danger); }
.alert svg { width: 15px; height: 15px; flex-shrink: 0; margin-top: 1px; }

/* Cloudflare Turnstile */
.captcha-wrap {
    margin-bottom: 20px;
    border-radius: var(--radius-md);
    overflow: hidden;
}
.captcha-wrap .cf-turnstile {
    display: flex;
    justify-content: flex-start;
}
.captcha-wrap:has(iframe) {
    border: 1.5px solid var(--border);
    background: var(--input-bg);
    padding: 8px 10px;
    border-radius: var(--radius-md);
}

/* Submit button */
.btn-submit {
    width: 100%;
    height: 50px;
    background: linear-gradient(135deg, var(--g3) 0%, var(--g4) 100%);
    border: none;
    border-radius: var(--radius-md);
    color: #fff;
    font-size: .9rem;
    font-weight: 700;
    letter-spacing: .01em;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    position: relative;
    overflow: hidden;
    transition: transform .15s, box-shadow .2s;
}
.btn-submit::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(255,255,255,.14), transparent);
}
.btn-submit:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 10px 28px rgba(5,150,105,.4);
}
.btn-submit:active:not(:disabled) { transform: translateY(0); }
.btn-submit:disabled { opacity: .7; cursor: not-allowed; }

/* Spinner */
.spin-ring {
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255,255,255,.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin .65s linear infinite;
    display: none;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Form footer */
.form-footer {
    margin-top: 32px;
    text-align: center;
    font-size: .73rem;
    color: var(--text-light);
}
.form-footer a {
    color: var(--g3);
    text-decoration: none;
    font-weight: 600;
}
.form-footer a:hover { text-decoration: underline; }

/* ─── RESPONSIVE ─── */
@media (max-width: 960px) {
    html, body { overflow: auto; }
    .page { flex-direction: column; height: auto; min-height: 100vh; }
    .left  { flex: none; }
    .left-inner { padding: 36px 28px 32px; }
    .left-hero  { padding: 40px 0 24px; }
    .left-hero h1 { font-size: 2rem; }
    .stats { gap: 0; }
    .stat-item { padding: 0 20px 0 0; }
    .stat-item:not(:first-child) { padding-left: 20px; }
    .left-bottom { padding-top: 24px; margin-top: 24px; }
    .partners { gap: 20px; flex-wrap: wrap; }
    .right { flex: none; padding: 44px 28px; box-shadow: none; }
}
@media (max-width: 480px) {
    .right { padding: 36px 20px; }
    .form-wrap { max-width: 100%; }
}
