/* ============================================
   AUTH PAGES — Standalone Cacheable Stylesheet
   ============================================ */

/* ---------- BRAND PALETTE ----------
   --primary-navy:   #0F172A
   --accent-emerald: #10B981
   --bg-light:       #F8FAFC
   --card-white:     #FFFFFF
   --text-primary:   #1E293B
   --border-soft:    #E2E8F0
   ---------------------------------- */

/* ============================================
   BASE
   ============================================ */
html.auth-page-html {
    height: 100%;
    background: #fff;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
}
body.auth-page-body {
    min-height: 100vh;
    background: transparent;
    margin: 0;
    padding: 0;
    color: #1E293B;
}

/* ============================================
   AUTH NAVBAR
   ============================================ */
.auth-navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: #fff;
    border-bottom: 1px solid #E2E8F0;
    height: 60px;
    display: flex;
    align-items: center;
    padding: 0 24px;
    justify-content: space-between;
}

.auth-navbar__left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.auth-navbar__brand {
    font-size: 1.125rem;
    font-weight: 800;
    color: #0F172A;
    text-decoration: none;
    letter-spacing: -0.02em;
}
.auth-navbar__brand:hover { color: #0F172A; text-decoration: none; }

.auth-navbar__right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.auth-nav-link {
    color: #1E293B !important;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    transition: color 0.2s;
}
.auth-nav-link:hover {
    color: #10B981 !important;
    text-decoration: none;
}

.auth-nav-register-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 38px;
    padding: 0 18px;
    border-radius: 100px;
    border: 2px solid #0F172A;
    background: transparent;
    color: #0F172A !important;
    font-weight: 700;
    font-size: 0.875rem;
    text-decoration: none;
    transition: background 0.2s, color 0.2s;
}
.auth-nav-register-btn:hover {
    background: #0F172A;
    color: #fff !important;
    text-decoration: none;
}

/* ============================================
   AUTH PAGE WRAPPER
   ============================================ */
.auth-page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.auth-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 80px 16px 48px; /* 80px top to clear the 60px navbar + breathing room */
    gap: 20px;
}

/* ============================================
   AUTH CARD  (Login / Forgot / Reset)
   ============================================ */
.auth-card {
    width: 100%;
    max-width: 420px;
    background: #fff;
    border-radius: 18px;
    padding: 32px 28px 24px;
    box-shadow: 0 4px 6px -1px rgba(15,23,42,0.06), 0 10px 32px -4px rgba(15,23,42,0.10);
    border: 1px solid #E2E8F0;
}

.auth-card-header {
    text-align: center;
    margin-bottom: 24px;
}

.auth-card-logo {
    width: 52px;
    height: 52px;
    border-radius: 12px;
    object-fit: contain;
    margin: 0 auto 12px;
    display: block;
    background: #F8FAFC;
    padding: 4px;
    border: 1px solid #E2E8F0;
}

.auth-card-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: #0F172A;
    color: #10B981;
    font-size: 20px;
    margin: 0 auto 12px;
    box-shadow: 0 4px 14px rgba(15,23,42,0.18);
}

.auth-card-title {
    font-size: 1.375rem;
    font-weight: 800;
    color: #0F172A;
    letter-spacing: -0.02em;
    margin: 0 0 4px;
}

.auth-card-subtitle {
    font-size: 0.875rem;
    font-weight: 500;
    color: #64748b;
    margin: 0;
}

/* ============================================
   REGISTER CARD (wider)
   ============================================ */
.auth-register-card {
    width: 100%;
    max-width: 860px;
    background: #fff;
    border-radius: 18px;
    padding: 36px 36px 28px;
    box-shadow: 0 4px 6px -1px rgba(15,23,42,0.06), 0 10px 32px -4px rgba(15,23,42,0.10);
    border: 1px solid #E2E8F0;
}

.auth-register-card .auth-card-header {
    text-align: center;
    margin-bottom: 24px;
}

/* Section label */
.auth-section-label {
    font-size: 0.75rem;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    margin-bottom: 12px;
    margin-top: 4px;
}

/* Divider */
.auth-divider {
    height: 1px;
    background: #E2E8F0;
    margin: 14px 0 18px;
}

/* ============================================
   FORM ELEMENTS
   ============================================ */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.auth-field-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.auth-label {
    font-size: 0.8125rem;
    font-weight: 600;
    color: #1E293B;
    margin: 0;
}

.auth-input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.auth-input-icon {
    position: absolute;
    left: 13px;
    color: #94a3b8;
    font-size: 13px;
    pointer-events: none;
    z-index: 1;
}

.auth-input {
    width: 100%;
    height: 44px;
    border: 1.5px solid #E2E8F0;
    border-radius: 10px;
    background: #F8FAFC;
    color: #1E293B;
    font-size: 0.9375rem;
    font-weight: 500;
    font-family: 'Inter', sans-serif;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
    padding: 0 14px;
}
.auth-input::placeholder {
    color: #94a3b8;
    font-weight: 400;
}
.auth-input:focus {
    border-color: #10B981;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(16,185,129,0.13);
}

.auth-input-icon-left  { padding-left: 38px; }
.auth-input-icon-right { padding-right: 42px; }

/* Select */
select.auth-input {
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
}

/* Eye toggle */
.auth-eye-btn {
    position: absolute;
    right: 10px;
    background: none;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    font-size: 14px;
    padding: 4px;
    display: flex;
    align-items: center;
    transition: color 0.2s;
}
.auth-eye-btn:hover { color: #10B981; }

/* Errors */
.auth-error {
    color: #EF4444;
    font-size: 0.75rem;
    font-weight: 500;
    margin-top: 2px;
}
.has-error .auth-input {
    border-color: #EF4444;
    background: #fef2f2;
}

/* ============================================
   REMEMBER ME ROW
   ============================================ */
.auth-remember-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: -2px;
}
.auth-remember-row input[type="checkbox"] {
    width: 16px;
    height: 16px;
    border-radius: 4px;
    accent-color: #10B981;
    cursor: pointer;
}
.auth-remember-row label {
    font-size: 0.875rem;
    font-weight: 500;
    color: #1E293B;
    cursor: pointer;
    user-select: none;
    margin: 0;
}

/* Password / Forgot row */
.auth-field-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* ============================================
   PRIMARY BUTTON
   ============================================ */
.auth-btn-primary {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 46px;
    border-radius: 12px;
    font-size: 0.9375rem;
    font-weight: 700;
    color: #fff;
    background: #0F172A;
    border: none;
    cursor: pointer;
    transition: background 0.2s, box-shadow 0.2s, transform 0.15s;
    box-shadow: 0 4px 14px rgba(15,23,42,0.22);
    font-family: 'Inter', sans-serif;
    margin-top: 6px;
}
.auth-btn-primary:hover {
    background: #1e293b;
    box-shadow: 0 6px 20px rgba(15,23,42,0.28);
    transform: translateY(-1px);
}
.auth-btn-primary:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(16,185,129,0.35);
}
.auth-btn-primary .accent-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #10B981;
    margin-right: 10px;
    flex-shrink: 0;
}

/* ============================================
   TEXT LINKS
   ============================================ */
.auth-forgot-link {
    font-size: 0.80rem;
    font-weight: 600;
    color: #10B981;
    text-decoration: none;
    transition: color 0.2s;
}
.auth-forgot-link:hover { color: #059669; text-decoration: underline; }

.auth-text-link {
    font-size: 0.875rem;
    font-weight: 600;
    color: #10B981;
    text-decoration: none;
    transition: color 0.2s;
}
.auth-text-link:hover { color: #059669; text-decoration: underline; }

.auth-back-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    color: #64748b;
    text-decoration: none;
    transition: color 0.2s;
}
.auth-back-link:hover { color: #0F172A; text-decoration: none; }

/* Footer (register/login toggle) */
.auth-footer {
    text-align: center;
    margin-top: 20px;
}
.auth-footer span {
    font-size: 0.875rem;
    color: #64748b;
}
.auth-footer .auth-text-link {
    margin-left: 4px;
}

/* Success banner */
.auth-status-success {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #166534;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: 10px;
    padding: 12px 14px;
    margin-bottom: 16px;
}

/* ============================================
   DEMO PANEL
   ============================================ */
.auth-demo-panel {
    width: 100%;
    max-width: 700px;
    background: #fff;
    border: 1px solid #E2E8F0;
    border-radius: 16px;
    padding: 20px 24px;
    box-shadow: 0 2px 8px rgba(15,23,42,0.06);
}
.auth-demo-panel__title {
    text-align: center;
    margin-bottom: 12px;
}
.auth-demo-panel__title span {
    font-size: 0.875rem;
    font-weight: 700;
    color: #0F172A;
}
.auth-demo-panel__title p {
    font-size: 0.75rem;
    color: #64748b;
    margin: 4px 0 0;
}
.auth-demo-panel__grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
}

.demo-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px;
    border-radius: 8px;
    font-size: 0.8125rem;
    font-weight: 600;
    color: #fff !important;
    text-decoration: none;
    transition: opacity 0.15s, transform 0.15s;
}
.demo-btn:hover { opacity: 0.88; transform: translateY(-1px); text-decoration: none; color: #fff !important; }

.demo-btn-olive   { background: #4d7c0f; }
.demo-btn-maroon  { background: #7c2020; }
.demo-btn-orange  { background: #d97706; }
.demo-btn-purple  { background: #7c3aed; }
.demo-btn-navy    { background: #1e40af; }
.demo-btn-red     { background: #dc2626; }
.demo-btn-dark    { background: #0F172A; }
.demo-btn-woo     { background: #7c5cbf; }
.demo-btn-green   { background: #059669; }

/* ============================================
   OVERRIDES  (DaisyUI / Tailwind / Bootstrap)
   ============================================ */
.tw-text-indigo-500  { color: #0F172A !important; }

.tw-from-indigo-600  { background-color: #10B981 !important; background-image: none !important; }
.tw-to-blue-500      { background-color: #10B981 !important; background-image: none !important; }

.hover\:tw-from-indigo-500:hover { background-color: #059669 !important; background-image: none !important; }
.hover\:tw-to-blue-400:hover     { background-color: #059669 !important; background-image: none !important; }

.tw-dw-btn.tw-dw-btn-primary,
.tw-dw-btn-primary {
    background-color: #10B981 !important;
    border-color: #10B981 !important;
    color: #fff !important;
}
.tw-dw-btn.tw-dw-btn-primary:hover,
.tw-dw-btn-primary:hover {
    background-color: #059669 !important;
    border-color: #059669 !important;
}
.tw-dw-btn.tw-dw-btn-primary:focus-visible,
.tw-dw-btn-primary:focus-visible {
    outline-color: #10B981 !important;
}
.tw-dw-btn.tw-dw-btn-primary.tw-dw-btn-outline,
.tw-dw-btn-primary.tw-dw-btn-outline {
    background-color: transparent !important;
    border-color: #10B981 !important;
    color: #10B981 !important;
}
.tw-dw-btn.tw-dw-btn-primary.tw-dw-btn-outline:hover,
.tw-dw-btn-primary.tw-dw-btn-outline:hover {
    background-color: #10B981 !important;
    color: #fff !important;
}

/* Wizard (Register multi-step) */
.wizard > .content {
    background-color: #fff !important;
    padding: 0 !important;
    margin: 0 !important;
    min-height: auto !important;
}
.action-link { cursor: pointer; }

/* Bootstrap input overrides (for Register wizard in auth.blade.php) */
.input-group {
    display: flex !important;
    width: 100% !important;
    align-items: stretch !important;
}
.input-group-addon {
    background-color: #F1F5F9 !important;
    border: 1.5px solid #E2E8F0 !important;
    border-right: none !important;
    color: #0F172A !important;
    border-radius: 10px 0 0 10px !important;
    padding: 0 16px !important;
    min-width: 48px;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    height: 46px !important;
}
.form-control {
    height: 46px !important;
    border: 1.5px solid #E2E8F0 !important;
    border-radius: 0 10px 10px 0 !important;
    box-shadow: none !important;
    font-family: 'Inter', sans-serif !important;
    color: #1E293B !important;
    font-size: 0.9375rem !important;
    flex: 1 1 auto;
    width: 1% !important;
}
.form-control:focus {
    border-color: #10B981 !important;
    box-shadow: 0 0 0 3px rgba(16,185,129,0.13) !important;
    outline: none !important;
}
.form-group {
    margin-bottom: 20px !important;
}
.form-group label {
    font-size: 0.8125rem !important;
    font-weight: 600 !important;
    color: #1E293B !important;
    margin-bottom: 6px !important;
}

/* Select2 on auth pages */
.select2-container--default .select2-selection--single {
    height: 44px !important;
    border: 1.5px solid #E2E8F0 !important;
    border-radius: 10px !important;
    display: flex !important;
    align-items: center !important;
}
.select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 42px !important;
    color: #1E293B !important;
    padding-left: 16px !important;
    font-size: 0.9375rem !important;
}
.select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 42px !important;
    right: 12px !important;
    display: flex !important;
    align-items: center !important;
}

legend.text-black {
    color: #0F172A !important;
    font-weight: 700 !important;
    border-bottom: 2px solid #10B981 !important;
    padding-bottom: 8px !important;
    margin-bottom: 24px !important;
    font-size: 1.125rem !important;
    margin-top: 10px !important;
}

/* Pattern lock */
.patt-wrap { z-index: 10; }
.patt-circ.hovered { background-color: #cde2f2; border: none; }
.patt-circ.hovered .patt-dots { display: none; }
.patt-circ.e  { transform: rotate(0); }
.patt-circ.s-e{ transform: rotate(45deg); }
.patt-circ.s  { transform: rotate(90deg); }
.patt-circ.s-w{ transform: rotate(135deg); }
.patt-circ.w  { transform: rotate(180deg); }
.patt-circ.n-w{ transform: rotate(225deg); }
.patt-circ.n  { transform: rotate(270deg); }
.patt-circ.n-e{ transform: rotate(315deg); }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
    .auth-navbar {
        padding: 0 16px !important;
    }
    .auth-nav-link:not(.nav-pricing-link) {
        display: none;
    }
    .auth-register-card {
        padding: 28px 20px;
    }
    .auth-content {
        padding-top: 76px;
    }
}

@media (max-width: 480px) {
    .auth-content {
        padding-top: 72px;
        padding-bottom: 32px;
        gap: 16px;
    }
    .auth-card,
    .auth-register-card {
        padding: 24px 18px;
        border-radius: 14px;
    }
    .auth-card-title {
        font-size: 1.25rem;
    }
    .auth-navbar__brand {
        font-size: 1rem !important;
    }
    .auth-nav-register-btn {
        padding: 0 12px;
        height: 34px;
        font-size: 0.75rem;
    }
}
