/**
 * Auth Styles - pn-console/customer/assets/auth.css
 * Authentication page styles using base.css color tokens
 * 
 * Structure:
 * 1. Common (all pages)
 * 2. Login-specific
 * 3. Signup-specific
 * 4. Forgot Password-specific
 * 5. Responsive
 */

/* =====
   SECTION 1: COMMON STYLES (ALL AUTH PAGES)
   ===== */

/* Backdrop & Container */
.pnc-auth-backdrop {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(to bottom, rgba(132, 125, 238, 0.08) 0%, rgba(255, 255, 255, 0.95) 100%);
    padding: 50px 20px;
    min-height: 80vh;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

.pnc-auth-container {
    width: 100%;
    max-width: 420px;
    margin: 0 auto;
}

/* Glass Card */
.pnc-auth-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(132, 125, 238, 0.08) 100%);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(132, 125, 238, 0.3);
    border-radius: 24px;
    padding: 26px 40px;
    box-shadow: 0 4px 16px rgba(132, 125, 238, 0.15);
    position: relative;
    overflow: visible;
}

/* Header */
.pnc-auth-header {
    text-align: center;
    margin-bottom: 18px;
}

.pnc-brand-identity {
    display: flex;
    justify-content: center;
    margin-bottom: 1px;
}

.pnc-logo {
    max-width: 160px;
    height: auto;
}

.pnc-auth-header h1 {
    font-size: 1.75rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    margin: 0;
    background: linear-gradient(to right, var(--text-primary) 0%, var(--brand) 50%, var(--text-primary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-transform: uppercase;
}

.pnc-subtitle {
    color: var(--text-secondary);
    font-size: 0.935rem;
    line-height: 1.6;
    margin: 0;
    font-weight: 500;
}

.pnc-subtitle strong {
    color: var(--brand);
    font-weight: 600;
}

/* Alerts */
.pnc-alert-wrapper {
    animation: slideIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.pnc-alert {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 11px 14px;
    border-radius: 12px;
    font-size: 0.875rem;
    line-height: 1.5;
    font-weight: 500;
    margin-bottom: 9px;
}

.pnc-alert:last-child {
    margin-bottom: 0;
}

.pnc-alert svg {
    flex-shrink: 0;
}

.pnc-alert-success {
    background: var(--success-bg);
    color: var(--success-dark);
    border-left: 3px solid var(--success);
}

.pnc-alert-error {
    background: var(--error-bg);
    color: var(--error-dark);
    border-left: 3px solid var(--error);
}

/* Form Structure */
.pnc-auth-form {
    margin: 0 0 18px 0;
}

.pnc-field-group label {
    display: block;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 6px;
    color: var(--text-secondary);
    opacity: 0.9;
}

/* Input Fields */
.pnc-input-root {
    position: relative;
}

.pnc-input-root input {
    width: 100%;
    padding: 11px 12px;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(132, 125, 238, 0.2);
    border-radius: 12px;
    font-size: 1rem;
    outline: none;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    color: var(--text-primary);
    font-family: inherit;
}

.pnc-input-root input:focus {
    border-color: var(--brand);
    border-width: 2px;
    padding: 10px 11px;
    box-shadow: 0 0 0 4px rgba(132, 125, 238, 0.1);
    background: var(--neutral-white);
}

.pnc-input-root input::placeholder {
    color: var(--text-muted);
}

/* Primary Button */
.pnc-btn-primary {
    width: 100%;
    background: var(--brand) !important;
    color: var(--text-on-brand) !important;
    padding: 11px;
    border: none !important;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(132, 125, 238, 0.3);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    font-family: inherit;
}

.pnc-btn-primary:hover {
    background: var(--brand-hover) !important;
    color: #FFF !important;
    transform: translateY(-2px);
    box-shadow: 0 12px 40px rgba(132, 125, 238, 0.28);
}

.pnc-btn-primary:active {
    transform: scale(0.985);
}

.pnc-btn-primary:disabled {
    background: var(--neutral-300);
    color: var(--neutral-500);
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}

.pnc-btn-primary:disabled:hover {
    background: var(--neutral-300);
    transform: none;
    box-shadow: none;
}

.pnc-btn-text {
    display: inline-block;
}

/* Footer Navigation */
.pnc-auth-footer {
    text-align: center;
    margin-top: 18px;
}

.pnc-auth-footer p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin: 0;
}

.pnc-auth-footer a {
    color: var(--brand);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s;
}

.pnc-auth-footer a:hover {
    color: var(--brand-hover);
    text-decoration: underline;
}

/* WordPress Nonce Field */
.pnc-auth-form input[type="hidden"] {
    display: none;
}

/* =====
   SECTION 2: LOGIN-SPECIFIC
   ===== */

.pnc-options-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.pnc-checkbox-wrapper {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    margin: 0;
}

.pnc-checkbox-wrapper input[type="checkbox"] {
    width: auto;
    height: auto;
    cursor: pointer;
    accent-color: var(--brand);
    margin: 0;
}

.pnc-checkbox-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.pnc-link-sm {
    font-size: 0.875rem;
    color: var(--brand);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s;
}

.pnc-link-sm:hover {
    color: var(--brand-hover);
    text-decoration: underline;
}

/* =====
   SECTION 3: SIGNUP-SPECIFIC
   ===== */

/* Password Wrapper */
.pnc-password-wrapper input {
    padding-right: 48px;
}

.pnc-password-wrapper input:focus {
    padding-right: 47px;
}

/* Password Toggle Button */
.pnc-toggle-password {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    padding: 4px;
    cursor: pointer;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s;
}

.pnc-toggle-password:hover {
    color: var(--brand);
}

/* Password Checklist */
.pnc-password-checklist {
    margin-top: 9px;
    padding: 0;
    background: none;
    border: none;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.pnc-password-checklist.pnc-checklist-visible {
    max-height: 200px;
    opacity: 1;
}

.pnc-check {
    font-size: 0.815rem;
    line-height: 1.5;
    color: var(--text-muted);
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    padding-left: 0;
}

.pnc-check::before {
    content: "• ";
    margin-right: 6px;
    font-weight: 600;
}

.pnc-check.pnc-check-visible {
    max-height: 30px;
    opacity: 0.7;
}

/* =====
   SECTION 4: FORGOT PASSWORD-SPECIFIC
   ===== */

.pnc-success-icon-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    margin: 0 auto;
    background: var(--brand);
    border-radius: 50%;
    box-shadow: 0 4px 12px rgba(132, 125, 238, 0.3);
}

.pnc-success-icon-wrapper svg {
    color: var(--text-on-brand);
}

.pnc-notice-box {
    padding: 14px 18px;
    background: rgba(132, 125, 238, 0.05);
    border-left: 3px solid rgba(132, 125, 238, 0.3);
    border-radius: 8px;
}

.pnc-notice-box p {
    font-size: 0.875rem;
    line-height: 1.5;
    color: var(--text-secondary);
    margin: 0 0 8px 0;
}

.pnc-notice-box p:last-child {
    margin-bottom: 0;
}

.pnc-notice-box strong {
    color: var(--text-primary);
    font-weight: 600;
}

.pnc-success-footer {
    margin-top: 18px;
}

.pnc-success-footer .pnc-btn-primary {
    text-decoration: none;
    display: block;
}

/* =====
   SECTION 5: RESPONSIVE (MOBILE)
   ===== */

@media (max-width: 480px) {
    .pnc-auth-backdrop {
        padding: 30px 16px;
    }

    .pnc-auth-card {
        padding: 32px 24px;
        border-radius: 20px;
    }
    
    .pnc-auth-header h1 {
        font-size: 1.5rem;
        letter-spacing: 0.3px;
    }

    .pnc-logo {
        max-width: 64px;
    }
    
    .pnc-options-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .pnc-btn-primary {
        padding: 14px;
        font-size: 0.95rem;
    }
}