/**
 * Wewirx Ninja — shared brand styles (aligned with Wewirx-LMS Portal / theme_wewirx)
 */
:root {
    --bg-primary: #f8fafc;
    --wl-brand-primary: #50e3c2;
    --wl-brand-accent: #3dd4b0;
    --wl-brand-primary-hover: #3dd4b0;
    --wl-mint-dark: #0d9488;
    --wl-mint-soft: rgba(80, 227, 194, 0.12);
    --wl-sidebar-bg: #0b1117;
    --wl-sidebar-active: #50e3c2;
    --wl-surface: #ffffff;
    --wl-surface-muted: #f4f6f8;
    --wl-text: #0f172a;
    --wl-text-muted: #64748b;
    --wl-border: #e2e8f0;
    --wl-radius: 12px;
    --wl-radius-lg: 16px;
    --wl-shadow: 0 1px 3px rgba(15, 23, 42, 0.06), 0 8px 24px rgba(15, 23, 42, 0.06);
    --wl-font: 'Cairo', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

.wl-system-sender {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    border-radius: 8px;
    background: var(--wl-surface-muted, #f4f6f8);
    border: 1px solid var(--wl-border, #e2e8f0);
    font-size: 14px;
    font-weight: 600;
    color: var(--wl-text, #0f172a);
    letter-spacing: -0.01em;
}

body.wl-client,
body.wl-staff {
    font-family: var(--wl-font);
    color: var(--wl-text);
    background: var(--bg-primary);
}

body.wl-staff.wl-workspace #wl-main,
body.wl-staff.wl-workspace #pjax-container,
body.wl-staff.wl-workspace #content,
body.wl-staff.wl-workspace input,
body.wl-staff.wl-workspace select,
body.wl-staff.wl-workspace textarea,
body.wl-staff.wl-workspace button,
body.wl-staff.wl-workspace .button {
    font-family: var(--wl-font);
}

body.wl-client a,
body.wl-staff a {
    color: var(--wl-mint-dark);
}

body.wl-client a:hover,
body.wl-staff a:hover {
    color: var(--wl-link-hover, #0f766e);
}

/* —— Client portal header —— */
body.wl-client #header {
    height: 56px;
    background: var(--wl-surface);
    border-bottom: 1px solid var(--wl-border);
    box-shadow: none;
}

body.wl-client #header #logo img {
    max-height: 40px;
    max-width: 200px;
}

body.wl-client #nav li a {
    color: var(--wl-text);
    font-weight: 500;
}

body.wl-client #nav li a:hover {
    color: var(--wl-mint-dark);
    background: var(--wl-mint-soft);
    border-radius: 8px;
}

body.wl-client #content {
    background: transparent;
}

body.wl-client .main-content,
body.wl-client #landing_page .main-content {
    background: var(--wl-surface);
    border: 1px solid var(--wl-border);
    border-radius: var(--wl-radius);
    box-shadow: var(--wl-shadow);
}

body.wl-client #footer {
    background: var(--wl-surface-muted);
    border-top: 1px solid var(--wl-border);
    color: var(--wl-text-muted);
}

body.wl-client #footer a {
    color: var(--wl-mint-dark);
}

/* —— Buttons (client) —— */
body.wl-client .green.button,
body.wl-client .green.button:visited,
body.wl-staff .green.button,
body.wl-staff .green.button:visited,
body.wl-staff input[type="submit"].green,
body.wl-login-body input[type="submit"].submit,
body.wl-login-body button[type="submit"] {
    background: var(--wl-brand-primary) !important;
    border: 1px solid var(--wl-brand-primary) !important;
    color: var(--wl-sidebar-bg) !important;
    border-radius: 8px !important;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(80, 227, 194, 0.25);
}

body.wl-client .green.button:hover,
body.wl-staff .green.button:hover,
body.wl-login-body input[type="submit"].submit:hover {
    background: var(--wl-brand-primary-hover) !important;
    border-color: var(--wl-brand-primary-hover) !important;
    color: var(--wl-sidebar-bg) !important;
}

body.wl-client .button,
body.wl-staff .button {
    border-radius: 8px;
}

/* —— Staff SCP panel —— */
body.wl-staff #container {
    width: 100%;
    max-width: none;
    margin: 0 auto 1.5rem;
    padding: 0 1.5rem;
    box-sizing: border-box;
    background: transparent;
}

body.wl-staff #header {
    display: none;
}

body.wl-workspace #header {
    display: none !important;
}

body.wl-staff #header p#info {
    order: 2;
    float: none !important;
    margin: 0;
    padding: 0;
    max-width: none;
    background: transparent !important;
    border: none !important;
    text-align: right;
    white-space: nowrap;
    flex-shrink: 0;
    color: var(--wl-text-muted);
    font-size: 0.8125rem;
}

body.wl-staff #header p#info a {
    color: var(--wl-mint-dark);
}

body.wl-staff #logo {
    order: 1;
    height: auto;
    max-width: none;
    padding: 0;
    float: none !important;
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

body.wl-staff #logo .valign-helper {
    display: none;
}

body.wl-staff #logo img {
    max-height: 56px;
    max-width: 200px;
    width: auto;
    height: auto;
    display: block;
    object-fit: contain;
}

body.wl-staff #pjax-container {
    width: 100%;
}

body.wl-staff #nav,
body.wl-staff #sub_nav {
    clear: both;
    width: 100%;
    box-sizing: border-box;
    border-left: none !important;
    border-right: none !important;
    height: auto;
    min-height: 2.35rem;
    line-height: 1.5;
    padding: 0.4rem 0.5rem 0;
    margin: 0;
}

body.wl-staff #nav li a {
    padding: 0.45rem 0.9rem;
    display: inline-block;
}

body.wl-staff #nav li.active a {
    color: var(--wl-mint-dark);
    font-weight: 600;
}

body.wl-staff #content {
    width: 100%;
    box-sizing: border-box;
    border-left: none !important;
    border-right: none !important;
    border-top: none !important;
    border-color: var(--wl-border) !important;
    border-bottom: 1px solid var(--wl-border) !important;
    border-radius: 0 0 var(--wl-radius) var(--wl-radius);
    padding: 1.25rem 1.5rem 1.75rem;
    background: var(--wl-surface);
}

body.wl-staff #footer {
    padding: 1rem 0.5rem 1.5rem;
    color: var(--wl-text-muted);
}

body.wl-staff .jb-overflowmenu {
    width: 100%;
    max-width: 100%;
}

body.wl-staff #line-chart-here {
    width: 100% !important;
    box-sizing: border-box;
}

body.wl-staff table.dashboard-stats,
body.wl-staff table.list {
    width: 100%;
}

body.wl-staff #basic_search {
    margin-bottom: 0.5rem;
}

body.wl-staff table.list thead th {
    background: var(--wl-surface-muted) !important;
    color: var(--wl-text);
    border-color: var(--wl-border) !important;
}

body.wl-staff .dialog,
body.wl-staff .tip_box {
    border-radius: var(--wl-radius);
    border-color: var(--wl-border);
    box-shadow: var(--wl-shadow);
}

body.wl-staff input[type="text"],
body.wl-staff input[type="password"],
body.wl-staff select,
body.wl-staff textarea,
body.wl-client input[type="text"],
body.wl-client input[type="password"],
body.wl-client select,
body.wl-client textarea {
    border: 1px solid var(--wl-border);
    border-radius: 8px;
}

body.wl-staff input[type="text"]:focus,
body.wl-staff input[type="password"]:focus,
body.wl-client input[type="text"]:focus,
body.wl-client input[type="password"]:focus {
    border-color: var(--wl-brand-primary);
    outline: none;
    box-shadow: 0 0 0 3px var(--wl-mint-soft);
}

/* —— Staff login (LMS 50/50 split) —— */
body.wl-login-body {
    font-family: var(--wl-font);
    background: var(--wl-surface-muted);
    min-height: 100vh;
    margin: 0;
    text-align: left;
}

body.wl-login-body #wl-login-split {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    position: relative;
    overflow: hidden;
}

@media (min-width: 960px) {
    body.wl-login-body #wl-login-split {
        flex-direction: row;
    }
}

body.wl-login-body .wl-login-form-side {
    flex: 1 1 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--wl-surface-muted);
    padding: 2rem 1.5rem;
    position: relative;
    z-index: 2;
}

body.wl-login-body .wl-login-visual,
body.wl-login-body #brickwall.wl-login-visual {
    flex: 1 1 50%;
    min-height: 240px;
    position: relative;
    top: auto;
    left: auto;
    right: auto;
    bottom: auto;
    z-index: 1;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
}

@media (max-width: 959px) {
    body.wl-login-body .wl-login-visual {
        display: none;
    }
}

body.wl-login-body #loginBox {
    position: relative;
    left: auto;
    top: auto;
    margin: 0 auto;
    width: 100%;
    max-width: 400px;
    padding: 2rem 1.75rem 1.5rem;
    text-align: center;
    background: var(--wl-surface);
    border: 1px solid var(--wl-border);
    border-radius: var(--wl-radius-lg);
    box-shadow: var(--wl-shadow);
}

body.wl-login-body #loginBox:after {
    display: none;
}

body.wl-login-body #blur {
    display: none;
}

body.wl-login-body #logo a {
    height: auto;
    line-height: normal;
    margin-bottom: 1.5rem;
}

body.wl-login-body #logo a img {
    max-height: 80px;
    max-width: 220px;
}

body.wl-login-body h3#login-message {
    color: #dc2626;
    font-size: 0.875rem;
    font-weight: 500;
}

body.wl-login-body form {
    width: 100%;
    max-width: none;
}

body.wl-login-body fieldset input {
    width: 100%;
    margin-bottom: 1rem;
    padding: 0.65rem 0.75rem;
    font-size: 0.9375rem;
    background: var(--wl-surface);
    border: 1px solid var(--wl-border);
    border-radius: var(--wl-radius);
    color: var(--wl-text);
}

body.wl-login-body fieldset input:focus {
    border-color: var(--wl-brand-primary);
    box-shadow: 0 0 0 3px var(--wl-mint-soft);
    outline: none;
}

body.wl-login-body input[type="submit"].submit,
body.wl-login-body button[type="submit"],
body.wl-login-body button.submit.button {
    width: 100%;
    height: auto;
    line-height: 1.4;
    padding: 0.7rem 1rem;
    font-size: 0.9375rem;
    margin-top: 0.25rem;
    float: none !important;
    background: var(--wl-brand-primary) !important;
    border: 1px solid var(--wl-brand-primary) !important;
    color: var(--wl-sidebar-bg) !important;
    border-radius: 8px !important;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(80, 227, 194, 0.25);
}

body.wl-login-body button.submit.button:hover,
body.wl-login-body input[type="submit"].submit:hover {
    background: var(--wl-brand-primary-hover) !important;
    border-color: var(--wl-brand-primary-hover) !important;
    color: var(--wl-sidebar-bg) !important;
}

body.wl-login-body #company {
    position: static;
    width: auto;
    margin: 1.25rem auto 0;
    left: auto;
    bottom: auto;
    font-size: 0.75rem;
    color: var(--wl-text-muted);
}

body.wl-login-body #company .content {
    background: transparent;
    box-shadow: none;
    text-shadow: none;
    color: var(--wl-text-muted);
    padding: 0;
}

body.wl-login-body #company .wl-powered-by-ninja {
    margin: 0.45rem 0 0;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--wl-mint-dark, #0d9488);
    letter-spacing: 0.02em;
}

body.wl-login-body #poweredBy {
    position: fixed;
    bottom: 12px;
    right: 12px;
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid var(--wl-border);
    border-radius: 999px;
    color: var(--wl-text-muted);
    box-shadow: var(--wl-shadow);
    text-shadow: none;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    padding: 6px 14px;
}

body.wl-login-body #poweredBy.wl-powered-by-ninja {
    color: var(--wl-text, #0f172a);
}

body.wl-login-body div.banner {
    color: var(--wl-text-muted);
    font-size: 0.875rem;
}
