/* ── Sancal Hub Theme — main.css ─────────────────────────────────── */

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

/* ── Reset & base ────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --bg:      #07090e;
    --surface: #0f111a;
    --border:  #1e2235;
    --accent:  #00d4ff;
    --purple:  #6c5ce7;
    --green:   #00e676;
    --text:    #e0e0e0;
    --muted:   #6b7280;
    --radius:  16px;
    --font-display: 'Syne', sans-serif;
    --font-body:    'DM Sans', sans-serif;
}

html, body {
    height: 100%;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-body);
    font-size: 15px;
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* ── Background animado ──────────────────────────────────────────── */
.shub-bg {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.shub-bg-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(0,212,255,.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0,212,255,.04) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 40%, transparent 100%);
}

.shub-bg-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    animation: orb-drift 12s ease-in-out infinite alternate;
}
.orb-1 {
    width: 600px; height: 600px;
    background: radial-gradient(circle, rgba(0,212,255,.18) 0%, transparent 70%);
    top: -200px; left: -200px;
    animation-delay: 0s;
}
.orb-2 {
    width: 500px; height: 500px;
    background: radial-gradient(circle, rgba(108,92,231,.22) 0%, transparent 70%);
    bottom: -150px; right: -150px;
    animation-delay: -4s;
}
.orb-3 {
    width: 300px; height: 300px;
    background: radial-gradient(circle, rgba(0,230,118,.1) 0%, transparent 70%);
    top: 50%; left: 50%;
    transform: translate(-50%,-50%);
    animation-delay: -8s;
}

@keyframes orb-drift {
    0%   { transform: translate(0,0) scale(1); }
    33%  { transform: translate(40px,-30px) scale(1.05); }
    66%  { transform: translate(-20px,40px) scale(.95); }
    100% { transform: translate(30px,20px) scale(1.02); }
}

.orb-3 { animation: orb-drift-center 16s ease-in-out infinite alternate; }
@keyframes orb-drift-center {
    0%   { transform: translate(-50%,-50%) scale(1); }
    100% { transform: translate(-45%,-55%) scale(1.15); }
}

.shub-bg-noise {
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.03'/%3E%3C/svg%3E");
    background-repeat: repeat;
    background-size: 256px 256px;
    opacity: .4;
}

/* ── Layout principal ────────────────────────────────────────────── */
.shub-login-body {
    min-height: 100vh;
    display: flex;
    align-items: stretch;
}

.shub-login-wrap {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1fr 480px;
    min-height: 100vh;
    width: 100%;
}

/* ── Coluna esquerda: branding ───────────────────────────────────── */
.shub-login-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px;
    position: relative;
}

.shub-brand-inner {
    max-width: 520px;
    width: 100%;
}

/* Logo */
.shub-logo-wrap {
    margin-bottom: 56px;
    animation: fade-up .8s ease both;
}

.shub-logo-text {
    display: flex;
    align-items: center;
    gap: 2px;
    font-family: var(--font-display);
    font-size: 28px;
    font-weight: 800;
    color: #fff;
    letter-spacing: -.5px;
}
.shub-logo-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px; height: 40px;
    background: linear-gradient(135deg, var(--accent), var(--purple));
    border-radius: 10px;
    font-size: 20px;
    font-weight: 800;
    color: #fff;
    margin-right: 8px;
    box-shadow: 0 0 20px rgba(0,212,255,.4);
}
.shub-logo-accent { color: var(--accent); }

/* custom-logo do WordPress */
.shub-logo-wrap .custom-logo-link img {
    max-height: 52px;
    width: auto;
    filter: brightness(1.1);
}

/* Headline */
.shub-brand-headline {
    animation: fade-up .8s .1s ease both;
}

.shub-headline {
    font-family: var(--font-display);
    font-size: clamp(42px, 5vw, 68px);
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -2px;
    color: #fff;
    margin-bottom: 20px;
}
.shub-headline-accent {
    background: linear-gradient(90deg, var(--accent), #00a8cc);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.shub-headline-outline {
    -webkit-text-stroke: 2px rgba(255,255,255,.25);
    color: transparent;
}

.shub-tagline {
    font-size: 16px;
    color: var(--muted);
    margin-bottom: 52px;
    font-weight: 300;
    letter-spacing: .3px;
}

/* Features */
.shub-features {
    display: flex;
    flex-direction: column;
    gap: 20px;
    animation: fade-up .8s .2s ease both;
}

.shub-feature {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 16px 20px;
    background: rgba(255,255,255,.03);
    border: 1px solid rgba(255,255,255,.06);
    border-radius: 12px;
    transition: border-color .2s, background .2s;
}
.shub-feature:hover {
    border-color: rgba(0,212,255,.2);
    background: rgba(0,212,255,.04);
}
.shub-feature-icon {
    font-size: 22px;
    flex-shrink: 0;
    margin-top: 1px;
}
.shub-feature div {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.shub-feature strong {
    font-size: 14px;
    font-weight: 600;
    color: #fff;
    font-family: var(--font-display);
}
.shub-feature span {
    font-size: 12px;
    color: var(--muted);
}

/* ── Coluna direita: painel de login ─────────────────────────────── */
.shub-login-panel {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 48px;
    background: rgba(15,17,26,.6);
    border-left: 1px solid var(--border);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.shub-login-card {
    width: 100%;
    max-width: 380px;
    animation: fade-up .8s .15s ease both;
}

.shub-login-card-header {
    text-align: center;
    margin-bottom: 36px;
}

/* Logo pequeno no card (mobile) */
.shub-login-logo-sm {
    display: none;
    justify-content: center;
    margin-bottom: 24px;
}
.shub-logo-text-sm {
    font-family: var(--font-display);
    font-size: 20px;
    font-weight: 800;
    color: #fff;
}
.shub-logo-mark-sm {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px; height: 30px;
    background: linear-gradient(135deg, var(--accent), var(--purple));
    border-radius: 7px;
    font-size: 14px;
    color: #fff;
    margin-right: 6px;
    vertical-align: middle;
}

.shub-login-title {
    font-family: var(--font-display);
    font-size: 26px;
    font-weight: 700;
    color: #fff;
    letter-spacing: -.5px;
    margin-bottom: 6px;
}
.shub-login-subtitle {
    font-size: 14px;
    color: var(--muted);
}

/* ── Mensagem de erro/sucesso ─────────────────────────────────────── */
.shub-login-msg {
    padding: 12px 16px;
    border-radius: 10px;
    font-size: 13px;
    margin-bottom: 20px;
    border-left: 3px solid;
    animation: fade-up .3s ease;
}
.shub-login-msg.error   { background: rgba(255,83,112,.12); border-color: #ff5370; color: #ffcdd2; }
.shub-login-msg.success { background: rgba(0,230,118,.1);  border-color: var(--green); color: #b9f6ca; }

/* ── Form fields ──────────────────────────────────────────────────── */
.shub-form { display: flex; flex-direction: column; gap: 20px; }

.shub-field { display: flex; flex-direction: column; gap: 8px; }

.shub-label {
    font-size: 13px;
    font-weight: 500;
    color: rgba(255,255,255,.7);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.shub-forgot {
    font-size: 12px;
    color: var(--muted);
    text-decoration: none;
    transition: color .2s;
}
.shub-forgot:hover { color: var(--accent); }

.shub-input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.shub-input-icon {
    position: absolute;
    left: 14px;
    color: var(--muted);
    display: flex;
    pointer-events: none;
    transition: color .2s;
}

.shub-input {
    width: 100%;
    background: rgba(255,255,255,.05);
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text);
    font-size: 14px;
    font-family: var(--font-body);
    padding: 13px 44px 13px 42px;
    transition: border-color .2s, background .2s, box-shadow .2s;
    outline: none;
}
.shub-input::placeholder { color: rgba(255,255,255,.2); }
.shub-input:focus {
    border-color: var(--accent);
    background: rgba(0,212,255,.05);
    box-shadow: 0 0 0 3px rgba(0,212,255,.12);
}
.shub-input:focus + .shub-input-icon,
.shub-input-wrap:focus-within .shub-input-icon { color: var(--accent); }

.shub-eye-btn {
    position: absolute;
    right: 14px;
    background: none;
    border: none;
    color: var(--muted);
    cursor: pointer;
    padding: 4px;
    display: flex;
    transition: color .2s;
}
.shub-eye-btn:hover { color: var(--accent); }

/* ── Botão de login ───────────────────────────────────────────────── */
.shub-btn-login {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 14px 24px;
    background: linear-gradient(135deg, var(--accent), #0099bb);
    border: none;
    border-radius: 10px;
    color: #000;
    font-size: 15px;
    font-weight: 700;
    font-family: var(--font-display);
    cursor: pointer;
    letter-spacing: .3px;
    transition: transform .15s, box-shadow .2s, opacity .2s;
    position: relative;
    overflow: hidden;
    margin-top: 4px;
}
.shub-btn-login::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255,255,255,.15), transparent);
    opacity: 0;
    transition: opacity .2s;
}
.shub-btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0,212,255,.35);
}
.shub-btn-login:hover::before { opacity: 1; }
.shub-btn-login:active { transform: translateY(0); }
.shub-btn-login:disabled { opacity: .6; cursor: not-allowed; transform: none; }

.shub-btn-arrow { transition: transform .2s; }
.shub-btn-login:hover .shub-btn-arrow { transform: translateX(4px); }

/* ── Spinner ──────────────────────────────────────────────────────── */
@keyframes spin { to { transform: rotate(360deg); } }
.shub-spinner {
    display: inline-block;
    width: 16px; height: 16px;
    border: 2px solid rgba(0,0,0,.3);
    border-top-color: #000;
    border-radius: 50%;
    animation: spin .6s linear infinite;
}

/* ── Rodapé do card ───────────────────────────────────────────────── */
.shub-login-footer {
    margin-top: 32px;
    text-align: center;
    font-size: 12px;
    color: var(--muted);
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

/* ── Animação de entrada ──────────────────────────────────────────── */
@keyframes fade-up {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ── Divisor decorativo ──────────────────────────────────────────── */
.shub-login-brand::after {
    content: '';
    position: absolute;
    right: 0; top: 10%; bottom: 10%;
    width: 1px;
    background: linear-gradient(to bottom, transparent, var(--border) 30%, var(--border) 70%, transparent);
}

/* ── Responsivo ───────────────────────────────────────────────────── */
@media (max-width: 900px) {
    .shub-login-wrap {
        grid-template-columns: 1fr;
        grid-template-rows: auto 1fr;
    }

    .shub-login-brand {
        display: none;
    }

    .shub-login-panel {
        border-left: none;
        padding: 40px 24px;
        min-height: 100vh;
        align-items: center;
    }

    .shub-login-logo-sm {
        display: flex;
    }

    .shub-login-card {
        max-width: 400px;
        margin: auto;
    }
}

@media (max-width: 1100px) and (min-width: 901px) {
    .shub-login-wrap { grid-template-columns: 1fr 420px; }
    .shub-login-brand { padding: 40px; }
    .shub-headline { font-size: 48px; }
}

/* ── Shake (erro de login) ────────────────────────────────────────── */
@keyframes shub-shake {
    0%, 100% { transform: translateX(0); }
    20%  { transform: translateX(-8px); }
    40%  { transform: translateX(8px); }
    60%  { transform: translateX(-5px); }
    80%  { transform: translateX(5px); }
}
.shub-shake { animation: shub-shake .5s ease; }