/* ============================================================
   ShopBase Custom Login — login.css
   Versão 1.0.0
   ============================================================ */

/* ── Reset global da página de login ─────────────────────── */

html,
body.shopbase-login-page {
    margin: 0;
    padding: 0;
    background: #f0f4f8;
    font-family: "DM Sans", sans-serif;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Esconde elementos padrão do WP que não queremos */
body.shopbase-login-page h1,
body.shopbase-login-page #backtoblog,
body.shopbase-login-page #nav {
    display: none !important;
}

body.shopbase-login-page #login {
    padding: 0;
    width: 100%;
    max-width: 100%;
    margin: 0;
}

/* ── Versão do plugin ────────────────────────────────────── */
/* v1.1.0 */

/* ── Canvas de partículas (fundo) ─────────────────────────── */

#sb-particles {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    opacity: 0.35;
}

/* ── Wrapper principal (split-screen) ────────────────────── */

.sb-wrapper {
    display: flex;
    min-height: 100vh;
    position: relative;
    z-index: 1;
}

/* ══════════════════════════════════════════════════════════
   PAINEL ESQUERDO
   ══════════════════════════════════════════════════════════ */

.sb-panel--left {
    flex: 0 0 46%;
    background: linear-gradient(145deg, #0a1628 0%, #0f2456 45%, #0d1f4a 100%);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 3.5rem;
}

/* Blobs decorativos */
.sb-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.18;
    pointer-events: none;
}

.sb-blob--1 {
    width: 420px;
    height: 420px;
    background: radial-gradient(circle, #22D3EE 0%, #1D4ED8 100%);
    top: -120px;
    right: -80px;
    animation: blobFloat1 12s ease-in-out infinite;
}

.sb-blob--2 {
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, #3B82F6 0%, #7C3AED 100%);
    bottom: 80px;
    left: -60px;
    animation: blobFloat2 15s ease-in-out infinite;
}

.sb-blob--3 {
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, #0EA5E9 0%, #2563EB 100%);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation: blobFloat3 10s ease-in-out infinite;
}

@keyframes blobFloat1 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50%       { transform: translate(-20px, 30px) scale(1.1); }
}
@keyframes blobFloat2 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50%       { transform: translate(25px, -20px) scale(1.05); }
}
@keyframes blobFloat3 {
    0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 0.18; }
    50%       { transform: translate(-48%, -52%) scale(1.15); opacity: 0.1; }
}

/* Rings animados */
.sb-rings {
    position: absolute;
    bottom: -60px;
    right: -60px;
    width: 380px;
    height: 380px;
}

.sb-rings span {
    position: absolute;
    inset: 0;
    border: 1.5px solid rgba(34, 211, 238, 0.15);
    border-radius: 50%;
    animation: ringPulse 4s ease-out infinite;
}

.sb-rings span:nth-child(2) { inset: 30px; animation-delay: 0.8s; }
.sb-rings span:nth-child(3) { inset: 60px; animation-delay: 1.6s; }
.sb-rings span:nth-child(4) { inset: 90px; animation-delay: 2.4s; }

@keyframes ringPulse {
    0%   { opacity: 0; transform: scale(0.9); }
    30%  { opacity: 1; }
    100% { opacity: 0; transform: scale(1.2); }
}

/* Hero copy */
.sb-hero {
    position: relative;
    z-index: 2;
    animation: fadeSlideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes fadeSlideUp {
    from { opacity: 0; transform: translateY(24px); }
    to   { opacity: 1; transform: translateY(0); }
}

.sb-hero__eyebrow {
    display: inline-block;
    font-family: "DM Sans", sans-serif;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #22D3EE;
    background: rgba(34, 211, 238, 0.1);
    border: 1px solid rgba(34, 211, 238, 0.25);
    padding: 0.3rem 0.85rem;
    border-radius: 100px;
    margin-bottom: 1.6rem;
}

.sb-hero__title {
    font-family: "Sora", sans-serif;
    font-size: clamp(2rem, 3vw, 2.75rem);
    font-weight: 800;
    line-height: 1.15;
    color: #fff;
    margin: 0 0 1.25rem;
    letter-spacing: -0.02em;
}

.sb-hero__title em {
    font-style: normal;
    background: linear-gradient(90deg, #22D3EE 0%, #60A5FA 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sb-hero__sub {
    font-size: 0.95rem;
    line-height: 1.65;
    color: rgba(255, 255, 255, 0.6);
    margin: 0 0 2.25rem;
}

.sb-hero__sub strong {
    color: #22D3EE;
    font-weight: 600;
}

/* Barra de estatísticas — removida na v1.1.0 */

/* ══════════════════════════════════════════════════════════
   PAINEL DIREITO
   ══════════════════════════════════════════════════════════ */

.sb-panel--right {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem 2rem;
    background: #ffffff;
    position: relative;
    animation: fadeIn 0.6s 0.1s ease both;
}

/* Bloco central que agrupa tudo e fica realmente centralizado */
.sb-panel--right > *,
.sb-panel--right > #login {
    width: 100%;
    max-width: 400px;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

/* Logo */
.sb-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    margin-bottom: 2rem;
    width: 100%;
    max-width: 400px;
}

.sb-logo__img {
    max-width: 160px;
    height: auto;
    display: block;
}

.sb-logo__icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    flex-shrink: 0;
}

.sb-logo__text {
    font-family: "Sora", sans-serif;
    font-size: 1.35rem;
    font-weight: 700;
    color: #0f172a;
    letter-spacing: -0.03em;
}

/* Heading acima do form */
.sb-form-heading {
    text-align: center;
    margin-bottom: 1.75rem;
    width: 100%;
    max-width: 400px;
}

.sb-form-heading h2 {
    font-family: "Sora", sans-serif;
    font-size: 1.7rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 0.4rem;
    letter-spacing: -0.03em;
}

.sb-form-heading p {
    font-size: 0.9rem;
    color: #64748b;
    margin: 0;
}

/* ── Formulário do WordPress ────────────────────────────── */

body.shopbase-login-page #loginform {
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
    padding: 0;
    border: none;
    box-shadow: none;
    background: transparent;
}

/* Labels */
body.shopbase-login-page #loginform label {
    font-family: "DM Sans", sans-serif;
    font-size: 0.85rem;
    font-weight: 600;
    color: #374151;
    letter-spacing: 0.01em;
    margin-bottom: 0.45rem;
    display: block;
}

/* Campos de texto */
body.shopbase-login-page #loginform input[type="text"],
body.shopbase-login-page #loginform input[type="password"],
body.shopbase-login-page #loginform input[type="email"] {
    font-family: "DM Sans", sans-serif;
    font-size: 0.9rem;
    color: #0f172a;
    background: #f8fafc;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    padding: 0.75rem 1rem 0.75rem 2.9rem;
    width: 100%;
    box-sizing: border-box;
    transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
    outline: none;
    box-shadow: none;
    height: auto;
    line-height: 1.5;
}

body.shopbase-login-page #loginform input[type="text"]:focus,
body.shopbase-login-page #loginform input[type="password"]:focus,
body.shopbase-login-page #loginform input[type="email"]:focus {
    border-color: #2563EB;
    background: #fff;
    box-shadow: 0 0 0 3.5px rgba(37, 99, 235, 0.12);
}

/* Ícone dentro dos campos */
.sb-field-wrap {
    position: relative;
    margin-bottom: 1.1rem;
}

.sb-field-icon {
    position: absolute;
    left: 0.9rem;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    color: #94a3b8;
    pointer-events: none;
    z-index: 1;
}

/* Botão nativo de mostrar/ocultar senha do WordPress — oculto */
body.shopbase-login-page button.wp-hide-pw,
body.shopbase-login-page .wp-hide-pw {
    display: none !important;
}

/* Container .wp-pwd que o WP injeta em volta do campo senha */
body.shopbase-login-page .wp-pwd {
    display: block;
    width: 100%;
    position: static;
}

body.shopbase-login-page .wp-pwd input[type="password"],
body.shopbase-login-page .wp-pwd input[type="text"],
body.shopbase-login-page #user_pass {
    width: 100% !important;
    box-sizing: border-box !important;
    padding-right: 1rem !important;
}

/* Linha "Lembrar de mim" + "Esqueceu sua senha?" */
body.shopbase-login-page #loginform .forgetmenot {
    float: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

body.shopbase-login-page #loginform .forgetmenot label {
    font-size: 0.84rem;
    font-weight: 500;
    color: #475569;
    margin: 0;
    cursor: pointer;
}

body.shopbase-login-page #loginform input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: #2563EB;
    border-radius: 4px;
    cursor: pointer;
    flex-shrink: 0;
}

/* Linha de login (checkbox + forgot) */
body.shopbase-login-page .sb-login-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
}

body.shopbase-login-page #nav {
    display: none !important;
}

/* Link "Esqueceu sua senha?" */
body.shopbase-login-page .sb-forgot-link,
body.shopbase-login-page #login .sb-forgot-link {
    font-size: 0.84rem;
    font-weight: 600;
    color: #2563EB;
    text-decoration: none;
    transition: color 0.2s;
    white-space: nowrap;
}

body.shopbase-login-page .sb-forgot-link:hover { color: #1d4ed8; }

/* Botão Entrar */
body.shopbase-login-page #loginform #wp-submit {
    font-family: "DM Sans", sans-serif;
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    background: linear-gradient(135deg, #2563EB 0%, #1D4ED8 100%);
    color: #fff;
    border: none;
    border-radius: 10px;
    padding: 0.85rem 1.5rem;
    width: 100%;
    height: auto;
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.2s, filter 0.2s;
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35);
    position: relative;
    overflow: hidden;
}

body.shopbase-login-page #loginform #wp-submit::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255,255,255,0.15) 0%, transparent 60%);
    opacity: 0;
    transition: opacity 0.2s;
}

body.shopbase-login-page #loginform #wp-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 22px rgba(37, 99, 235, 0.42);
    filter: brightness(1.06);
}

body.shopbase-login-page #loginform #wp-submit:hover::before { opacity: 1; }

body.shopbase-login-page #loginform #wp-submit:active {
    transform: translateY(0);
    box-shadow: 0 3px 8px rgba(37, 99, 235, 0.25);
}

/* Mensagens de erro */
body.shopbase-login-page #login_error {
    font-family: "DM Sans", sans-serif;
    font-size: 0.85rem;
    background: #fef2f2;
    border-left: 3px solid #ef4444;
    border-radius: 8px;
    color: #b91c1c;
    padding: 0.75rem 1rem;
    margin: 0 auto 1.25rem;
    max-width: 400px;
    width: 100%;
    box-sizing: border-box;
}

body.shopbase-login-page .message,
body.shopbase-login-page .updated {
    font-family: "DM Sans", sans-serif;
    font-size: 0.85rem;
    background: #eff6ff;
    border-left: 3px solid #2563EB;
    border-radius: 8px;
    color: #1e40af;
    padding: 0.75rem 1rem;
    margin: 0 auto 1.25rem;
    max-width: 400px;
    width: 100%;
    box-sizing: border-box;
}

/* Footer do form */
.sb-form-footer {
    margin-top: 1.75rem;
    font-size: 0.84rem;
    color: #94a3b8;
    text-align: center;
}

.sb-form-footer a {
    color: #2563EB;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.2s;
}

.sb-form-footer a:hover { color: #1d4ed8; }

/* ── Divisor "ou" (opcional para futura extensão) ─────────── */

.sb-divider {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin: 1.25rem 0;
    width: 100%;
    max-width: 380px;
}

.sb-divider::before,
.sb-divider::after {
    content: "";
    flex: 1;
    height: 1px;
    background: #e2e8f0;
}

.sb-divider span {
    font-size: 0.75rem;
    color: #94a3b8;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

/* ══════════════════════════════════════════════════════════
   RESPONSIVO
   ══════════════════════════════════════════════════════════ */

@media (max-width: 860px) {
    .sb-wrapper { flex-direction: column; }

    .sb-panel--left {
        flex: 0 0 auto;
        min-height: 260px;
        padding: 2.5rem 2rem;
    }

    .sb-stats { display: none; }

    .sb-hero__title { font-size: 1.75rem; }

    .sb-panel--right {
        padding: 2.5rem 1.75rem;
    }
}

@media (max-width: 480px) {
    .sb-panel--left { display: none; }

    .sb-panel--right {
        padding: 2rem 1.25rem;
        min-height: 100vh;
    }
}

/* ── Ajustes finos de espaçamento no #loginform original ── */

body.shopbase-login-page #loginform p { margin: 0 0 1.1rem; }
body.shopbase-login-page #loginform p:last-of-type { margin-bottom: 0; }
body.shopbase-login-page #loginform .submit { margin-top: 0; padding: 0; }
