/* Seguridad WP — login con marca */

body.swp-login {
    --swp-brand: #f05a28;
    --swp-dark: #27235e;
    --swp-accent: #ffc20f;
    --swp-overlay: 0;
    --swp-radius: 12px;
    background: #fff;
    color: #2b2b33;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    min-height: 100vh;
}

/* ---------- Panel de imagen (diseño dividido) ---------- */
.swp-login-aside {
    position: fixed;
    inset: 0 auto 0 0;
    width: 52vw;
    background-color: var(--swp-dark);
    background-size: cover;
    background-position: right bottom;
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    overflow: hidden;
}
.swp-login-aside::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, var(--swp-overlay));
}
.swp-login-aside-content {
    position: relative;
    padding: 0 7vw 9vh 0;
    text-align: right;
    max-width: 60%;
}
.swp-login-iso {
    width: clamp(120px, 15vw, 240px);
    height: auto;
    display: inline-block;
    filter: drop-shadow(0 10px 24px rgba(0, 0, 0, .25));
    animation: swp-hop 1s cubic-bezier(.3, 1.6, .5, 1) both;
}
.swp-login-tagline {
    margin: 18px 0 0;
    color: #fff;
    font-size: clamp(18px, 1.8vw, 28px);
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: -.01em;
    text-shadow: 0 2px 12px rgba(0, 0, 0, .2);
}
@keyframes swp-hop {
    from { transform: translateY(24px) rotate(-8deg); opacity: 0; }
    to   { transform: none; opacity: 1; }
}
@media (prefers-reduced-motion: reduce) {
    .swp-login-iso { animation: none; }
}

body.swp-layout-split { padding-left: 52vw; box-sizing: border-box; }
body.swp-layout-split #login {
    width: min(380px, 86%);
    padding: 9vh 0 40px;
    margin: 0 auto;
}

/* ---------- Diseño centrado ---------- */
body.swp-layout-centered {
    background: var(--swp-dark);
}
body.swp-layout-centered #login {
    width: min(400px, 92%);
    margin: 7vh auto 30px;
    padding: 36px 34px 26px;
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, .25);
}
body.swp-layout-centered #nav a,
body.swp-layout-centered #backtoblog a { color: var(--swp-dark); }

/* ---------- Marca del sitio ---------- */
/* El logo de WordPress se reemplaza por el bloque .swp-site-brand (logo + nombre del sitio). */
body.swp-login #login h1 { display: none; }

.swp-site-brand { text-align: center; margin: 0 0 24px; }
.swp-site-link {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--swp-dark);
    border-radius: 14px;
}
.swp-site-link:focus { box-shadow: 0 0 0 3px color-mix(in srgb, var(--swp-brand) 30%, transparent); outline: none; }
.swp-site-logo {
    display: block;
    max-width: 240px;
    max-height: 96px;
    width: auto;
    height: auto;
    object-fit: contain;
}
/* SVG sin tamaño propio: les damos una caja para que no colapsen a 0. */
.swp-site-logo[src$=".svg"] { width: 240px; height: 96px; }
/* Ícono del sitio (cuadrado) en lugar de logo. */
.swp-site-brand.is-icon .swp-site-logo { width: 72px; height: 72px; border-radius: 16px; }
.swp-site-brand.is-icon .swp-site-name { font-size: 22px; font-weight: 800; opacity: 1; }
.swp-site-brand.is-dark .swp-site-link { padding: 16px 22px 14px; background: var(--swp-dark); color: #fff; }
.swp-site-name {
    font-size: 15px;
    font-weight: 700;
    letter-spacing: .01em;
    color: inherit;
    opacity: .85;
}
.swp-site-name.is-wordmark { font-size: 26px; font-weight: 800; letter-spacing: -.02em; opacity: 1; line-height: 1.15; }

/* ---------- Marca del estudio (crédito al pie) ---------- */
.swp-studio-credit {
    width: min(380px, 86%);
    margin: 36px auto 28px;
    padding-top: 18px;
    border-top: 1px solid #ececf2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    text-align: center;
    font-size: 11px;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: #8a8a96;
}
.swp-studio-credit img { display: block; height: 34px; width: auto; transition: transform .15s; }
.swp-studio-credit a:hover img { transform: scale(1.04); }
.swp-studio-credit strong { font-size: 14px; color: var(--swp-dark); text-transform: none; letter-spacing: 0; }
body.swp-layout-centered .swp-studio-credit { border-top-color: rgba(255,255,255,.2); color: rgba(255,255,255,.75); }
body.swp-layout-centered .swp-studio-credit strong { color: #fff; }
body.swp-layout-centered .swp-studio-credit img { filter: brightness(0) invert(1); }
.swp-login-title {
    margin: 0 0 6px;
    font-size: 28px;
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -.02em;
    color: var(--swp-dark);
    text-align: center;
}
.swp-login-title::after {
    content: "";
    display: block;
    width: 44px;
    height: 5px;
    margin: 12px auto 0;
    border-radius: 3px;
    background: var(--swp-accent);
}
.swp-login-subtitle {
    margin: 12px 0 22px;
    text-align: center;
    color: #6b6b78;
    font-size: 14px;
}

/* ---------- Formulario ---------- */
body.swp-login #loginform,
body.swp-login #lostpasswordform,
body.swp-login #registerform,
body.swp-login #resetpassform {
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
    overflow: visible;
}
body.swp-login label {
    font-size: 13px;
    font-weight: 600;
    color: #3a3a46;
}
body.swp-login input[type="text"],
body.swp-login input[type="email"],
body.swp-login input[type="password"] {
    min-height: 46px;
    padding: 6px 14px;
    margin: 6px 0 16px;
    font-size: 16px;
    border: 1.5px solid #d9d9e3;
    border-radius: var(--swp-radius);
    background: #fafafc;
    box-shadow: none;
    transition: border-color .15s, box-shadow .15s, background .15s;
}
body.swp-login input[type="text"]:focus,
body.swp-login input[type="email"]:focus,
body.swp-login input[type="password"]:focus {
    border-color: var(--swp-brand);
    background: #fff;
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--swp-brand) 22%, transparent);
    outline: none;
}
body.swp-login .wp-pwd { margin-bottom: 4px; }
body.swp-login .wp-pwd input[type="password"],
body.swp-login .wp-pwd input[type="text"] { margin-bottom: 0; }
body.swp-login .button.wp-hide-pw { height: 46px; min-height: 46px; margin-top: 6px; color: var(--swp-dark); }
body.swp-login .button.wp-hide-pw:focus { border-color: var(--swp-brand); box-shadow: 0 0 0 2px var(--swp-brand); }

body.swp-login .forgetmenot { float: none; margin: 14px 0 0; }
body.swp-login input[type="checkbox"]:checked::before { filter: hue-rotate(0); }
body.swp-login input[type="checkbox"]:focus { border-color: var(--swp-brand); box-shadow: 0 0 0 2px color-mix(in srgb, var(--swp-brand) 30%, transparent); }

body.swp-login .submit { margin-top: 6px; }
body.swp-login .button-primary,
body.swp-login .button.button-large {
    float: none;
    width: 100%;
    min-height: 48px;
    margin-top: 14px;
    font-size: 16px;
    font-weight: 700;
    border: 0;
    border-radius: var(--swp-radius);
    background: var(--swp-brand);
    color: #fff;
    text-shadow: none;
    box-shadow: 0 6px 16px color-mix(in srgb, var(--swp-brand) 35%, transparent);
    transition: transform .1s, filter .15s;
}
body.swp-login .button-primary:hover,
body.swp-login .button-primary:focus {
    background: var(--swp-brand);
    filter: brightness(.93);
    color: #fff;
}
body.swp-login .button-primary:focus-visible { outline: 3px solid var(--swp-accent); outline-offset: 2px; }
body.swp-login .button-primary:active { transform: translateY(1px); }

/* Cloudflare Turnstile */
body.swp-login .swp-turnstile { margin: 10px 0 4px; min-height: 65px; }

/* ---------- Mensajes ---------- */
body.swp-login #login_error,
body.swp-login .message,
body.swp-login .notice {
    margin: 0 0 18px;
    border-radius: 10px;
    box-shadow: none;
    border: 0;
    border-left: 4px solid var(--swp-brand);
    background: #fff4ef;
    font-size: 13px;
}
body.swp-login #login_error { border-left-color: #d63638; background: #fdf0f0; }
body.swp-login .message, body.swp-login .notice-info { border-left-color: var(--swp-dark); background: #f2f2f8; }

/* ---------- Enlaces ---------- */
body.swp-login #nav,
body.swp-login #backtoblog {
    margin: 18px 0 0;
    padding: 0;
    text-align: center;
    font-size: 13px;
}
body.swp-login #nav a,
body.swp-login #backtoblog a,
body.swp-login .privacy-policy-link {
    color: var(--swp-dark);
    text-decoration: none;
    font-weight: 600;
}
body.swp-login #nav a:hover,
body.swp-login #backtoblog a:hover { color: var(--swp-brand); text-decoration: underline; }
body.swp-login .privacy-policy-page-link { margin: 24px 0 0; }

body.swp-login .language-switcher { margin-top: 20px; }

/* ---------- Móvil ---------- */
@media (max-width: 900px) {
    /* En pantallas chicas la imagen queda como franja decorativa: el logotipo ya incluye la rana. */
    .swp-login-aside {
        position: relative;
        width: 100%;
        height: 120px;
        background-position: center 70%;
    }
    .swp-login-aside-content { display: none; }
    body.swp-layout-split { padding-left: 0; }
    body.swp-layout-split #login { padding-top: 32px; }
    .swp-site-logo { max-height: 72px; }
    .swp-studio-credit { margin-top: 24px; }
}
