/* =============================================
   YaEstá Auth Styles - Custom Login System
   ============================================= */

/* ============ AUTH PAGE LAYOUT ============ */
.yaesta-auth-page { min-height: calc(100vh - 200px); display: flex; align-items: center; justify-content: center; padding: 20px; }

.yaesta-auth-container {
    display: grid;
    grid-template-columns: 420px 1fr;
    max-width: 900px;
    width: 100%;
    min-height: 580px;
    background: var(--ye-white, #fff);
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0,0,0,0.1);
}

.yaesta-auth-container-small {
    grid-template-columns: 1fr;
    max-width: 480px;
}

/* ============ BRAND PANEL ============ */
.yaesta-auth-brand {
    background: linear-gradient(135deg, #16213E 0%, #0F3460 60%, #1A1A2E 100%);
    color: #fff;
    padding: 48px 36px;
    display: flex;
    align-items: center;
}

.yaesta-auth-brand-content { width: 100%; }
.yaesta-auth-logo { font-size: 52px; margin-bottom: 12px; }
.yaesta-auth-brand h1 { font-size: 36px; font-weight: 800; margin: 0 0 8px; }
.yaesta-auth-brand h1 span { color: #FF4136; }
.yaesta-auth-brand > .yaesta-auth-brand-content > p { opacity: 0.7; font-size: 18px; margin: 0 0 36px; }

.yaesta-auth-features { display: flex; flex-direction: column; gap: 16px; }
.yaesta-auth-feature {
    display: flex; align-items: center; gap: 12px;
    padding: 12px 16px; background: rgba(255,255,255,0.08);
    border-radius: 12px; font-size: 15px; font-weight: 500;
}
.yaesta-auth-feature span { font-size: 22px; }

/* ============ FORM PANEL ============ */
.yaesta-auth-form-wrap {
    padding: 48px 40px;
    display: flex;
    align-items: center;
    overflow-y: auto;
}

.yaesta-auth-form-centered { justify-content: center; }
.yaesta-auth-form-inner { width: 100%; max-width: 380px; }
.yaesta-auth-form-inner h2 { font-size: 28px; margin: 0 0 4px; color: #1F2937; }
.yaesta-auth-subtitle { color: #6B7280; margin: 0 0 28px; font-size: 15px; }

/* ============ FORM FIELDS ============ */
.yaesta-auth-form { display: flex; flex-direction: column; gap: 18px; }
.yaesta-auth-field { display: flex; flex-direction: column; gap: 6px; }
.yaesta-auth-field label { font-size: 14px; font-weight: 600; color: #374151; }
.yaesta-auth-field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

.yaesta-auth-input-wrap {
    display: flex; align-items: center; gap: 8px;
    border: 2px solid #E5E7EB; border-radius: 12px;
    padding: 0 14px; transition: all 0.2s; background: #fff;
}
.yaesta-auth-input-wrap:focus-within { border-color: #FF4136; box-shadow: 0 0 0 3px rgba(255,65,54,0.1); }
.yaesta-auth-input-icon { font-size: 18px; opacity: 0.5; flex-shrink: 0; }

.yaesta-auth-input-wrap input {
    flex: 1; border: none; outline: none; padding: 14px 0; font-size: 15px;
    font-family: inherit; background: transparent; color: #1F2937;
}
.yaesta-auth-input-wrap input::placeholder { color: #9CA3AF; }

.yaesta-auth-input, .yaesta-auth-select {
    width: 100%; padding: 14px 16px; border: 2px solid #E5E7EB; border-radius: 12px;
    font-size: 15px; font-family: inherit; transition: all 0.2s; background: #fff;
}
.yaesta-auth-input:focus, .yaesta-auth-select:focus { border-color: #FF4136; outline: none; box-shadow: 0 0 0 3px rgba(255,65,54,0.1); }

.yaesta-auth-toggle-pass {
    background: none; border: none; cursor: pointer; font-size: 18px;
    opacity: 0.4; transition: all 0.2s; padding: 4px;
}
.yaesta-auth-toggle-pass:hover { opacity: 0.8; }

/* ============ ROLE SELECTOR ============ */
.yaesta-role-selector { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.yaesta-role-option { cursor: pointer; }
.yaesta-role-option input { display: none; }
.yaesta-role-card {
    display: flex; flex-direction: column; align-items: center; gap: 6px;
    padding: 14px 8px; border: 2px solid #E5E7EB; border-radius: 12px;
    transition: all 0.2s; text-align: center;
}
.yaesta-role-option input:checked + .yaesta-role-card {
    border-color: #FF4136; background: rgba(255,65,54,0.04);
    box-shadow: 0 0 0 3px rgba(255,65,54,0.1);
}
.yaesta-role-icon { font-size: 28px; }
.yaesta-role-name { font-size: 12px; font-weight: 600; color: #374151; line-height: 1.3; }

.yaesta-auth-extra-fields { animation: slideDown 0.3s ease; }
@keyframes slideDown { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }

/* ============ OPTIONS ============ */
.yaesta-auth-options { display: flex; justify-content: space-between; align-items: center; }
.yaesta-auth-checkbox { display: flex; align-items: center; gap: 8px; font-size: 14px; color: #6B7280; cursor: pointer; }
.yaesta-auth-checkbox input { width: 16px; height: 16px; accent-color: #FF4136; }
.yaesta-auth-link { font-size: 14px; color: #FF4136; font-weight: 500; text-decoration: none; }
.yaesta-auth-link:hover { color: #E0301E; text-decoration: underline; }

/* ============ BUTTONS ============ */
.yaesta-auth-btn {
    display: flex; align-items: center; justify-content: center;
    width: 100%; padding: 15px 24px; border: none; border-radius: 12px;
    font-size: 16px; font-weight: 700; font-family: inherit;
    cursor: pointer; transition: all 0.2s; text-decoration: none;
    background: #FF4136; color: #fff;
}
.yaesta-auth-btn:hover { background: #E0301E; color: #fff; transform: translateY(-1px); box-shadow: 0 4px 12px rgba(255,65,54,0.3); }
.yaesta-auth-btn:active { transform: translateY(0); }

.yaesta-auth-btn-outline {
    background: transparent; color: #374151;
    border: 2px solid #E5E7EB;
}
.yaesta-auth-btn-outline:hover { border-color: #FF4136; color: #FF4136; background: transparent; box-shadow: none; }

.yaesta-auth-btn-secondary { background: #374151; }
.yaesta-auth-btn-secondary:hover { background: #1F2937; }

.yaesta-auth-btn:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

/* ============ DIVIDER ============ */
.yaesta-auth-divider {
    display: flex; align-items: center; gap: 16px;
    margin: 24px 0; color: #9CA3AF; font-size: 14px;
}
.yaesta-auth-divider::before, .yaesta-auth-divider::after {
    content: ''; flex: 1; height: 1px; background: #E5E7EB;
}

/* ============ ALERTS ============ */
.yaesta-auth-alert {
    padding: 12px 16px; border-radius: 10px; font-size: 14px;
    font-weight: 500; margin-bottom: 16px;
}
.yaesta-auth-alert a { color: inherit; text-decoration: underline; }
.yaesta-auth-alert-danger { background: #FEE2E2; color: #991B1B; border: 1px solid #FECACA; }
.yaesta-auth-alert-success { background: #D1FAE5; color: #065F46; border: 1px solid #A7F3D0; }
.yaesta-auth-alert-info { background: #DBEAFE; color: #1E40AF; border: 1px solid #BFDBFE; }

/* ============ ACCOUNT PAGE ============ */
.yaesta-account-page { max-width: 1100px; margin: 0 auto; padding: 24px 20px; }
.yaesta-account-layout { display: grid; grid-template-columns: 280px 1fr; gap: 32px; }

.yaesta-account-sidebar {
    background: var(--ye-white, #fff); border-radius: 16px;
    padding: 24px; box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    height: fit-content; position: sticky; top: 90px;
}

.yaesta-account-user-card { text-align: center; margin-bottom: 24px; padding-bottom: 24px; border-bottom: 1px solid #E5E7EB; }
.yaesta-account-avatar {
    width: 72px; height: 72px; border-radius: 50%;
    background: linear-gradient(135deg, #FF4136, #FF6B63);
    color: #fff; font-size: 28px; font-weight: 800;
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 12px;
}
.yaesta-account-user-card h3 { margin: 0 0 4px; font-size: 18px; }
.yaesta-account-role { font-size: 13px; color: #6B7280; background: #F3F4F6; padding: 4px 12px; border-radius: 20px; }

.yaesta-account-nav { display: flex; flex-direction: column; gap: 4px; }
.yaesta-account-nav-item {
    display: block; padding: 10px 16px; border-radius: 10px;
    font-size: 14px; font-weight: 500; color: #374151;
    text-decoration: none; transition: all 0.2s;
}
.yaesta-account-nav-item:hover { background: #F3F4F6; color: #FF4136; }
.yaesta-account-nav-item.active { background: rgba(255,65,54,0.08); color: #FF4136; font-weight: 700; }
.yaesta-account-nav-logout { color: #991B1B; margin-top: 8px; }
.yaesta-account-nav-logout:hover { background: #FEE2E2; color: #991B1B; }

.yaesta-account-main { display: flex; flex-direction: column; gap: 24px; }
.yaesta-account-section {
    background: var(--ye-white, #fff); border-radius: 16px;
    padding: 28px; box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}
.yaesta-account-section h2 { margin: 0 0 20px; font-size: 20px; }
.yaesta-account-info { color: #9CA3AF; font-size: 13px; }

/* ============ RESPONSIVE ============ */
@media (max-width: 768px) {
    .yaesta-auth-container { grid-template-columns: 1fr; min-height: auto; }
    .yaesta-auth-brand { display: none; }
    .yaesta-auth-form-wrap { padding: 32px 24px; }
    .yaesta-role-selector { grid-template-columns: 1fr; }
    .yaesta-auth-field-row { grid-template-columns: 1fr; }
    .yaesta-account-layout { grid-template-columns: 1fr; }
    .yaesta-account-sidebar { position: static; }
}

/* Password Match Indicators */
.yaesta-pw-match, .yaesta-pw-match-ok, .yaesta-pw-no-match, .yaesta-pw-strength {
    font-size: 13px; font-weight: 500; margin-top: 6px; padding: 4px 0;
}
.yaesta-pw-match-ok { color: #065F46; }
.yaesta-pw-no-match { color: #991B1B; }
