/*
 * modernStyle.css
 * Brand-aligned CSS foundation for the AkClientWeb portal UI modernization.
 *
 * Strategy:
 *   - Declares CSS custom properties (variables) for the AK brand palette.
 *   - Provides utility/override classes that layer on top of Bootstrap 5
 *     and the existing legacy stylesheets (StyleSheet.css, baseStyle.css, etc.)
 *   - Does NOT remove any existing rules; it supplements them so the app
 *     continues to work during the phased migration.
 *   - Phase 3 work replaces the table-based main.master layout with
 *     Bootstrap grid/flex; at that point this file becomes the primary sheet.
 */

/* ============================================================
   1. BRAND CUSTOM PROPERTIES
   ============================================================ */
:root {
    --ak-blue:          #0072BC;
    --ak-blue-dark:     #00579a;
    --ak-blue-light:    #e8f3fb;
    --ak-nav-bg:        #E0E1E3;
    --ak-text:          #222222;
    --ak-text-muted:    #666666;
    --ak-white:         #ffffff;
    --ak-border:        #c8c9ca;
    --ak-error:         #c0392b;
    --ak-success:       #27ae60;
    --ak-font:          Verdana, Geneva, Arial, Helvetica, sans-serif;
    --ak-font-size:     8.5pt;
    --ak-radius:        4px;
    --ak-shadow:        0 2px 8px rgba(0, 114, 188, 0.12);
}

/* ============================================================
   2. GLOBAL RESETS & BASE
   ============================================================ */
*, *::before, *::after {
    box-sizing: border-box;
}

body {
    font-family: var(--ak-font);
    font-size: var(--ak-font-size);
    color: var(--ak-text);
    background-color: #f4f6f8;
    margin: 0;
    padding: 0;
}

a {
    color: var(--ak-blue);
    text-decoration: none;
}
a:hover {
    color: var(--ak-blue-dark);
    text-decoration: underline;
}

/* ============================================================
   3. HEADER / TOP BAR  (Phase 3 Bootstrap replacement)
   ============================================================ */

/* The .ak-topbar class will wrap the future Bootstrap navbar */
.ak-topbar {
    background-color: var(--ak-blue);
    padding: 0 16px;
    display: flex;
    align-items: center;
    height: 48px;
    gap: 12px;
}

.ak-topbar a,
.ak-topbar span {
    color: var(--ak-white);
    font-size: 8pt;
    font-weight: bold;
    text-decoration: none;
}

.ak-topbar a:hover {
    text-decoration: underline;
    color: var(--ak-white);
}

/* Brand logo strip */
.ak-logo-strip {
    background-color: var(--ak-white);
    border-bottom: 2px solid #000;
    padding: 6px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* ============================================================
   4. SIDE NAVIGATION  (Phase 3 Bootstrap replacement)
   ============================================================ */

.ak-sidebar {
    background-color: var(--ak-nav-bg);
    min-height: calc(100vh - 110px);
    padding: 16px 10px;
    width: 150px;
    flex-shrink: 0;
    border-right: 1px solid var(--ak-border);
}

.ak-sidebar .nav-section-title {
    font-family: var(--ak-font);
    font-size: 8pt;
    font-weight: bold;
    color: var(--ak-text);
    margin-top: 14px;
    margin-bottom: 4px;
    display: block;
}

.ak-sidebar .nav-item a {
    font-family: var(--ak-font);
    font-size: 8pt;
    color: var(--ak-text);
    display: block;
    padding: 2px 0 2px 12px;
    text-decoration: none;
    position: relative;
}

.ak-sidebar .nav-item a::before {
    content: "\25BA"; /* small right-pointing triangle replaces GIF bullet */
    color: var(--ak-blue);
    font-size: 6pt;
    position: absolute;
    left: 0;
    top: 3px;
}

.ak-sidebar .nav-item a:hover {
    color: var(--ak-blue);
    text-decoration: underline;
}

/* ============================================================
   5. MAIN CONTENT AREA
   ============================================================ */

.ak-content {
    flex: 1;
    padding: 12px 16px;
    background-color: var(--ak-white);
    min-width: 0; /* prevents flex blowout */
}

.ak-layout {
    display: flex;
    align-items: flex-start;
}

/* ============================================================
   6. LOGIN PAGE CARD  (used by the modernized login.aspx)
   ============================================================ */

.ak-login-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #e8f3fb 0%, #f4f6f8 100%);
    padding: 24px;
}

.ak-login-card {
    background: var(--ak-white);
    border-radius: 8px;
    box-shadow: var(--ak-shadow);
    padding: 40px 48px;
    width: 100%;
    max-width: 420px;
}

.ak-login-card .ak-logo {
    display: block;
    margin: 0 auto 24px auto;
    max-width: 180px;
}

.ak-login-card h2 {
    font-family: var(--ak-font);
    font-size: 13pt;
    color: var(--ak-blue);
    text-align: center;
    margin: 0 0 24px 0;
    font-weight: bold;
}

/* ============================================================
   7. AUTH0 BUTTON
   ============================================================ */

.ak-btn-auth0 {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 11px 20px;
    background-color: var(--ak-blue);
    color: var(--ak-white) !important;
    border: none;
    border-radius: var(--ak-radius);
    font-family: var(--ak-font);
    font-size: 9pt;
    font-weight: bold;
    cursor: pointer;
    text-decoration: none !important;
    transition: background-color 0.2s ease;
}

.ak-btn-auth0:hover {
    background-color: var(--ak-blue-dark);
    color: var(--ak-white) !important;
}

.ak-btn-auth0 svg {
    flex-shrink: 0;
}

/* ============================================================
   8. DIVIDER (login page "or" separator)
   ============================================================ */

.ak-divider {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 20px 0;
    color: var(--ak-text-muted);
    font-size: 7.5pt;
}

.ak-divider::before,
.ak-divider::after {
    content: "";
    flex: 1;
    height: 1px;
    background: var(--ak-border);
}

/* ============================================================
   9. FORM CONTROLS (overrides for Bootstrap 5 + legacy inputs)
   ============================================================ */

.ak-form-label {
    font-family: var(--ak-font);
    font-size: 8pt;
    font-weight: bold;
    color: var(--ak-text);
    margin-bottom: 3px;
    display: block;
}

.ak-form-input {
    font-family: var(--ak-font);
    font-size: 8pt;
    width: 100%;
    padding: 7px 10px;
    border: 1px solid var(--ak-border);
    border-radius: var(--ak-radius);
    color: var(--ak-text);
    background-color: var(--ak-white);
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.ak-form-input:focus {
    outline: none;
    border-color: var(--ak-blue);
    box-shadow: 0 0 0 3px rgba(0, 114, 188, 0.15);
}

/* ============================================================
   10. ALERTS & MESSAGES
   ============================================================ */

.ak-alert {
    font-family: var(--ak-font);
    font-size: 8pt;
    padding: 10px 14px;
    border-radius: var(--ak-radius);
    margin-bottom: 14px;
    border-left: 4px solid transparent;
}

.ak-alert-error {
    background-color: #fdf2f2;
    border-color: var(--ak-error);
    color: var(--ak-error);
}

.ak-alert-info {
    background-color: var(--ak-blue-light);
    border-color: var(--ak-blue);
    color: var(--ak-blue-dark);
}

/* ============================================================
   11. PAGE TITLE / SECTION HEADERS
   ============================================================ */

.ak-page-title {
    font-family: var(--ak-font);
    font-size: 14pt;
    color: var(--ak-blue);
    font-weight: bold;
    margin-bottom: 12px;
}

.ak-section-title {
    font-family: var(--ak-font);
    font-size: 9pt;
    font-weight: bold;
    color: var(--ak-text);
    border-bottom: 1px solid var(--ak-border);
    padding-bottom: 4px;
    margin-bottom: 10px;
}

/* ============================================================
   12. FOOTER
   ============================================================ */

.ak-footer {
    background-color: var(--ak-nav-bg);
    border-top: 2px solid #000;
    padding: 8px 16px;
    font-family: var(--ak-font);
    font-size: 7.5pt;
    color: var(--ak-text-muted);
    text-align: left;
}

/* ============================================================
   13. BOOTSTRAP 5 OVERRIDES  (make BS5 components match AK brand)
   ============================================================ */

/* Primary buttons */
.btn-primary {
    background-color: var(--ak-blue) !important;
    border-color: var(--ak-blue) !important;
}
.btn-primary:hover,
.btn-primary:focus {
    background-color: var(--ak-blue-dark) !important;
    border-color: var(--ak-blue-dark) !important;
}

/* Nav tabs */
.nav-tabs .nav-link.active {
    color: var(--ak-blue) !important;
    border-bottom-color: var(--ak-white) !important;
    font-weight: bold;
}
.nav-tabs .nav-link {
    color: var(--ak-text);
    font-family: var(--ak-font);
    font-size: 8pt;
}

/* Badges */
.badge.bg-ak {
    background-color: var(--ak-blue) !important;
}

/* ============================================================
   14. UTILITY CLASSES
   ============================================================ */

.text-ak-blue   { color: var(--ak-blue) !important; }
.bg-ak-blue     { background-color: var(--ak-blue) !important; }
.bg-ak-nav      { background-color: var(--ak-nav-bg) !important; }
.border-ak      { border-color: var(--ak-border) !important; }
.rounded-ak     { border-radius: var(--ak-radius) !important; }
.shadow-ak      { box-shadow: var(--ak-shadow) !important; }

/* ============================================================
   15. MODERN CLEAN THEME OVERRIDES
   ============================================================ */

:root {
    --ak-font:          "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
    --ak-font-size:     10pt;
    --ak-radius:        8px;
    --ak-shadow:        0 4px 16px rgba(16, 42, 67, 0.08);
    --ak-shadow-sm:     0 1px 3px rgba(16, 42, 67, 0.10);
}

body {
    background-color: #f3f6f9;
    -webkit-font-smoothing: antialiased;
}

/* Top bar */
.ak-topbar {
    background: linear-gradient(90deg, var(--ak-blue-dark) 0%, var(--ak-blue) 100%);
    height: 52px;
    box-shadow: var(--ak-shadow-sm);
}
.ak-topbar a,
.ak-topbar span {
    font-size: 10pt;
    font-weight: 600;
}
.ak-topbar .nav-link {
    border-radius: 999px;
    padding: 4px 14px !important;
    transition: background-color .15s ease;
}
.ak-topbar .nav-link:hover {
    background-color: rgba(255, 255, 255, 0.18);
    text-decoration: none;
}

.ak-logo-strip {
    border-bottom: 1px solid var(--ak-border);
}

/* Sidebar */
.ak-sidebar {
    background-color: var(--ak-white);
    width: 210px;
    padding: 20px 14px;
    border-right: 1px solid #e3e8ee;
}
.ak-sidebar .nav-section-title {
    font-size: 8.5pt;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--ak-text-muted);
    margin-top: 18px;
}
.ak-sidebar .nav-item a {
    font-size: 10pt;
    padding: 7px 12px;
    border-radius: 6px;
    transition: background-color .15s ease, color .15s ease;
}
.ak-sidebar .nav-item a::before {
    display: none;
}
.ak-sidebar .nav-item a:hover {
    background-color: var(--ak-blue-light);
    color: var(--ak-blue-dark);
    text-decoration: none;
}

/* Content area */
.ak-content {
    background-color: transparent;
    padding: 24px 28px;
}

/* Cards */
.card {
    border: 1px solid #e3e8ee;
    border-radius: 12px;
    box-shadow: var(--ak-shadow);
}

/* Tabs as pills */
.nav-tabs {
    border-bottom: 1px solid #e3e8ee;
    gap: 4px;
}
.nav-tabs .nav-link {
    font-size: 10pt;
    border: none;
    border-bottom: 3px solid transparent;
    border-radius: 6px 6px 0 0;
    padding: 10px 18px;
    background: transparent;
}
.nav-tabs .nav-link:hover {
    background-color: var(--ak-blue-light);
}
.nav-tabs .nav-link.active {
    background: transparent !important;
    border-bottom: 3px solid var(--ak-blue) !important;
    color: var(--ak-blue) !important;
}

/* Tables */
.table {
    background: var(--ak-white);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--ak-shadow-sm);
}
.table > thead > tr > th,
.table > thead.table-dark > tr > th,
.table > thead.table-light > tr > th {
    --bs-table-bg: var(--ak-blue);
    --bs-table-color: var(--ak-white);
    --bs-table-bg-state: transparent;
    --bs-table-bg-type: transparent;
    background-color: var(--ak-blue) !important;
    color: var(--ak-white) !important;
    box-shadow: none;
    font-size: 9pt;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .04em;
    border-color: var(--ak-blue-dark);
    vertical-align: middle;
}
.table > thead > tr > th a {
    color: var(--ak-white);
}
.table-hover > tbody > tr:hover > * {
    background-color: var(--ak-blue-light);
}

/* Buttons and inputs */
.btn {
    border-radius: var(--ak-radius);
    font-weight: 600;
}
.btn-primary {
    background-color: var(--ak-blue);
    border-color: var(--ak-blue);
}
.btn-primary:hover {
    background-color: var(--ak-blue-dark);
    border-color: var(--ak-blue-dark);
}
.form-control, .form-select {
    border-radius: var(--ak-radius);
    border-color: #d5dbe3;
}

/* Footer */
.ak-footer {
    color: var(--ak-text-muted);
    text-align: center;
    padding: 16px;
    font-size: 9pt;
}

/* Login */
.login-page {
    padding: 48px 24px;
    background:
}
.login-card {
    max-width: 460px;
    margin: 0 auto;
    border: none;
    border-radius: 16px;
    border-top: 4px solid var(--ak-blue);
    box-shadow: 0 10px 40px rgba(16, 42, 67, 0.15);
}
.login-card .card-title {
    color: var(--ak-blue-dark);
    font-weight: 700;
}
.login-card .card-body {
    padding: 2.5rem 2.5rem !important;
}
.login-card .btn {
    padding: 11px 20px;
}
