* {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    font-family: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background-color: #0b1120 !important;
    color: #f8fafc;
    -webkit-font-smoothing: antialiased;
}

.auth-page-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px 16px;
    position: relative;
}

.auth-container {
    width: 100%;
    max-width: 448px;
}

.auth-header {
    text-align: center;
    margin-bottom: 24px;
}

.auth-icon-box {
     display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border-radius: 16px;
    margin-bottom: 12px;
    color: #ffffff;
    transition: all 0.2s ease;
}

.auth-icon-box.icon-admin {
    background-color: #2563eb;
    box-shadow: 0 10px 20px -5px rgba(37, 99, 235, 0.45);
}

.auth-icon-box.icon-titular {
    background-color: #d97706;
    box-shadow: 0 10px 20px -5px rgba(217, 119, 6, 0.45);
}

.auth-badge-row {
    margin-bottom: 10px;
    display: flex;
    justify-content: center;
}

.auth-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 11px;
    border-radius: 9999px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.auth-badge.badge-admin {
    background-color: rgba(59, 130, 246, 0.18);
    color: #93c5fd;
    border: 1px solid rgba(59, 130, 246, 0.4);
}

.auth-badge.badge-titular {
    background-color: rgba(245, 158, 11, 0.18);
    color: #fcd34d;
    border: 1px solid rgba(245, 158, 11, 0.4);
}

.auth-title {
    font-size: 28px;
    font-weight: 800;
    letter-spacing: -0.025em;
    color: #ffffff;
    margin: 0;
    line-height: 1.2;
}

.auth-subtitle {
    font-size: 14px;
    color: #94a3b8;
    margin: 6px 0 0 0;
    font-weight: 400;
}

.auth-card {
    background-color: rgba(30, 41, 59, 0.65);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 28px 32px;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
}

.auth-error {
    margin-bottom: 16px;
    padding: 12px 14px;
    border-radius: 10px;
    background-color: rgba(239, 68, 68, 0.12);
    border: 1px solid rgba(239, 68, 68, 0.35);
    color: #fca5a5;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.4;
}

.auth-field {
    margin-bottom: 16px;
}

.auth-label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 6px;
}

.auth-label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #f8fafc;
    margin-bottom: 6px;
}

.auth-label-row .auth-label {
    margin-bottom: 0;
}

.auth-forgot-btn {
    background: none;
    border: none;
    padding: 0;
    font-size: 12px;
    font-weight: 500;
    color: #60a5fa;
    cursor: pointer;
    text-decoration: none;
    transition: color 0.15s ease;
}

.auth-forgot-btn:hover {
    color: #93c5fd;
    text-decoration: underline;
}

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

.auth-input-icon-left {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    pointer-events: none;
    display: flex;
    align-items: center;
}

.auth-input {
    width: 100%;
    height: 44px;
    padding: 8px 14px 8px 38px;
    font-size: 14px;
    color: #f8fafc !important;
    background-color: rgba(15, 23, 42, 0.55) !important;
    border: 1px solid #334155 !important;
    border-radius: 8px;
    outline: none;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.auth-input.has-right-icon {
    padding-right: 40px;
}

.auth-input:focus {
    border-color: #3b82f6 !important;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.25);
}

.auth-input.input-titular:focus {
    border-color: #f59e0b !important;
    box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.25);
}

.auth-input-eye-btn {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    padding: 4px;
    color: #94a3b8;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.15s ease;
}

.auth-input-eye-btn:hover {
    color: #e2e8f0;
}

.auth-submit-btn {
    width: 100%;
    height: 44px;
    margin-top: 4px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 700;
    color: #ffffff;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background-color 0.15s ease, transform 0.1s ease, box-shadow 0.15s ease;
}

.auth-submit-btn.btn-admin {
    background-color: #2563eb;
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.25);
}

.auth-submit-btn.btn-admin:hover {
    background-color: #3b82f6;
}

.auth-submit-btn.btn-titular {
    background-color: #d97706;
    box-shadow: 0 4px 14px rgba(217, 119, 6, 0.25);
}

.auth-submit-btn.btn-titular:hover {
    background-color: #f59e0b;
}

.auth-card-links {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.auth-links-inline {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    font-size: 12px;
    font-weight: 600;
}

.auth-link-amber {
    color: #fbbf24;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: color 0.15s ease;
    font-size: 12px;
    font-weight: 600;
}

.auth-link-amber:hover {
    color: #fde68a;
    text-decoration: underline;
}

.auth-link-blue {
    color: #60a5fa;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: color 0.15s ease;
    font-size: 12px;
    font-weight: 600;
}

.auth-link-blue:hover {
    color: #93c5fd;
    text-decoration: underline;
}

.auth-link-emerald {
    color: #34d399;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: color 0.15s ease;
    font-size: 12px;
    font-weight: 500;
}

.auth-link-emerald:hover {
    color: #6ee7b7;
    text-decoration: underline;
}

.auth-link-slate {
    color: #94a3b8;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: color 0.15s ease;
    font-size: 12px;
    font-weight: 500;
}

.auth-link-slate:hover {
    color: #cbd5e1;
    text-decoration: underline;
}

.auth-dot-sep {
    color: #475569;
}

.auth-footer {
    margin-top: 22px;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.auth-back-portal {
    color: #94a3b8;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: color 0.15s ease;
}

.auth-back-portal:hover {
    color: #38bdf8;
    text-decoration: underline;
}

.auth-copyright {
    font-size: 12px;
    color: #94a3b8;
    margin: 0;
}