/* Modern, clean visual system overrides.
   Loaded last via ~/Content/css bundle to apply consistently. */

   :root {
    /* Palette (primary derived from existing brand) */
    /* Darkened slightly for WCAG AA contrast with white text */
    --ui-primary: #4f46e5;
    --ui-primary-600: #4338ca;
    --ui-primary-700: #3730a3;
    --ui-on-primary: #ffffff;
  
    /* Figma CTA gradient (approved) */
    --ui-cta-grad-start: #16a34a;
    --ui-cta-grad-end: #22c55e;
    --ui-cta-shadow: rgba(22, 163, 74, 0.30);
  
    --ui-bg: #f6f7fb;
    --ui-surface: #ffffff;
    --ui-surface-2: #f1f3f9;
    --ui-border: rgba(17, 24, 39, 0.12);
    --ui-text: #111827;
    --ui-text-muted: #6b7280;
  
    /* Typography */
    --ui-font-sans: Inter, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif;
    --ui-leading: 1.5;
  
    /* Base-8 spacing */
    --s-1: 8px;
    --s-2: 16px;
    --s-3: 24px;
    --s-4: 32px;
    --s-6: 48px;
    --s-8: 64px;
  
    /* Shape + elevation */
    --ui-radius: 10px; /* 8–12px target */
    --ui-radius-sm: 8px;
    --ui-shadow-sm: 0 1px 2px rgba(17, 24, 39, 0.06), 0 1px 1px rgba(17, 24, 39, 0.04);
    --ui-shadow-md: 0 10px 22px rgba(17, 24, 39, 0.10), 0 2px 6px rgba(17, 24, 39, 0.06);
  }
  
  html, body {
    font-family: var(--ui-font-sans);
    line-height: var(--ui-leading);
    color: var(--ui-text);
    background: var(--ui-bg);
  }
  
  html { overflow-x: hidden; }
  body { overflow-x: hidden; }
  
  /* Clear size hierarchy */
  h1, .h1 { font-size: 2rem; line-height: 1.2; letter-spacing: -0.01em; }
  h2, .h2 { font-size: 1.5rem; line-height: 1.25; letter-spacing: -0.008em; }
  h3, .h3 { font-size: 1.25rem; line-height: 1.3; }
  body { font-size: 1rem; }
  small, .small { font-size: 0.875rem; color: var(--ui-text-muted); }
  
  /* Links */
  a { color: var(--ui-primary); }
  a:hover { color: var(--ui-primary-600); }
  
  /* Smooth interactions (200–300ms ease) */
  * {
    scroll-behavior: smooth;
  }
  a,
  button,
  .btn,
  .form-control,
  .form-select,
  .dropdown-menu,
  .card {
    transition: color 220ms ease, background-color 220ms ease, border-color 220ms ease,
                box-shadow 220ms ease, transform 220ms ease, opacity 220ms ease, filter 220ms ease;
  }
  
  /* Focus states for keyboard users */
  :focus { outline: none; }
  :focus-visible {
    outline: 3px solid rgba(79, 70, 229, 0.35);
    outline-offset: 2px;
  }
  
  /* Spacing normalization */
  .container.body-content { padding-top: var(--s-3); padding-bottom: var(--s-4); }
  
  /* Keep reading width comfortable while staying responsive (overrides GlobalStyle 1800px) */
  .container { max-width: 1440px; }
  
  /* Remove legacy hard clamp that breaks modern forms */
  input, select, textarea { max-width: none; }
  
  /* Form controls */
  .form-control, .form-select, textarea.form-control, input.form-control {
    border-radius: var(--ui-radius-sm);
    border-color: var(--ui-border);
    box-shadow: none;
  }
  .form-control:hover, .form-select:hover {
    border-color: rgba(17, 24, 39, 0.22);
  }
  .form-control:focus, .form-select:focus {
    border-color: rgba(105, 108, 255, 0.55);
    box-shadow: 0 0 0 0.2rem rgba(105, 108, 255, 0.18);
  }
  
  /* Inline validation (jQuery unobtrusive + Bootstrap) */
  .field-validation-error,
  .validation-summary-errors {
    color: #b42318;
  }
  .input-validation-error,
  .invaild-error,
  .has-error .form-control,
  .has-error input,
  .has-error select,
  .has-error textarea {
    border-color: rgba(180, 35, 24, 0.65) !important;
    box-shadow: 0 0 0 0.2rem rgba(180, 35, 24, 0.12);
  }
  .has-error .error-label,
  .error-label {
    color: #b42318;
    font-size: 0.875rem;
    margin-top: 6px;
  }
  
  /* Placeholder readability */
  ::placeholder { color: rgba(107, 114, 128, 0.85); }
  
  /* Disabled / loading states */
  .btn:disabled,
  .btn.disabled,
  button:disabled,
  input:disabled,
  select:disabled,
  textarea:disabled {
    opacity: 0.65;
    cursor: not-allowed !important;
  }
  .btn.is-loading {
    position: relative;
    pointer-events: none;
  }
  .btn.is-loading::after {
    content: "";
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.6);
    border-top-color: rgba(255, 255, 255, 1);
    border-radius: 50%;
    display: inline-block;
    margin-left: 10px;
    vertical-align: middle;
    animation: ui-spin 0.8s linear infinite;
  }
  @keyframes ui-spin { to { transform: rotate(360deg); } }
  
  /* Buttons */
  .btn {
    border-radius: var(--ui-radius-sm);
    font-weight: 600;
  }
  .btn-primary {
    background-color: var(--ui-primary);
    border-color: var(--ui-primary);
    box-shadow: 0 10px 18px rgba(79, 70, 229, 0.22);
  }
  .btn-primary:hover { background-color: var(--ui-primary-600); border-color: var(--ui-primary-600); }
  .btn-primary:active, .btn-primary.active { background-color: var(--ui-primary-700); border-color: var(--ui-primary-700); }
  .btn-primary:focus, .btn-primary.focus {
    box-shadow: 0 0 0 0.2rem rgba(79, 70, 229, 0.22), 0 10px 18px rgba(79, 70, 229, 0.22);
  }
  
  /* Cards + surfaces */
  .card,
  .modal-content,
  .dropdown-menu {
    border-radius: var(--ui-radius);
    border-color: rgba(17, 24, 39, 0.10);
    background: var(--ui-surface);
  }
  .card { box-shadow: var(--ui-shadow-sm); }
  .dropdown-menu, .modal-content { box-shadow: var(--ui-shadow-md); }
  
  /* Tables: keep functionality; improve readability */
  .table,
  table.table {
    color: var(--ui-text);
  }
  .table > thead > tr > th {
    color: var(--ui-text-muted) !important;
    font-weight: 700;
    text-transform: none !important;
  }
  .table thead th {
    color: var(--ui-text-muted);
    font-weight: 700;
    text-transform: none;
    letter-spacing: 0;
  }
  .table-striped tbody tr:nth-of-type(odd) {
    background-color: rgba(17, 24, 39, 0.02);
  }
  
  /* Order page layout helpers */
  .ui-order-toolbar {
    margin-bottom: var(--s-2);
    position: relative;
  }
  
  .ui-order-toolbar .navbar {
    padding: 0;
    margin-bottom: 0;
    gap: 10px;
    flex-wrap: wrap;
  }
  
  .ui-order-toolbar .nav-item,
  .ui-order-toolbar .dropdown,
  .ui-order-toolbar .form-control {
    min-height: 38px;
  }
  
  .ui-order-toolbar .form-control {
    border-color: rgba(17, 24, 39, 0.18);
    background: linear-gradient(180deg, #ffffff 0%, #f9fafc 100%);
  }
  
  .ui-order-toolbar-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
  }
  
  /* ── Admin Batch 2 shared page pattern (Figma 9:2) ── */
  .ui-admin-intro {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 16px;
  }
  
  .ui-admin-intro-copy {
    display: flex;
    flex-direction: column;
    gap: 6px;
  }
  
  .ui-admin-intro-label {
    font-size: 0.82rem;
    font-weight: 600;
    color: #607086;
    margin: 0;
  }
  
  .ui-admin-intro-title {
    font-size: 1.88rem;
    font-weight: 700;
    color: #102033;
    margin: 0;
    letter-spacing: -0.01em;
  }
  
  .ui-admin-intro-desc {
    font-size: 0.88rem;
    color: #607086;
    margin: 0;
  }
  
  .ui-admin-badges {
    display: flex;
    gap: 10px;
    flex-shrink: 0;
    align-items: center;
  }
  
  .ui-admin-badge {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 999px;
    border: 1px solid #d7deea;
    font-size: 0.78rem;
    font-weight: 500;
    white-space: nowrap;
  }
  
  .ui-admin-badge--green {
    background: #ecfdf3;
    color: #15803d;
  }
  
  .ui-admin-badge--default {
    background: #f8fbff;
    color: #102033;
  }
  
  .ui-admin-toolbar {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 18px;
    border: 1px solid #d7deea;
    border-radius: 20px;
    background: #ffffff;
    margin-bottom: 16px;
    flex-wrap: wrap;
  }
  
  .ui-admin-toolbar .form-control,
  .ui-admin-toolbar input[type="text"] {
    border: 1px solid #d7deea;
    border-radius: 10px;
    padding: 8px 14px;
    font-size: 0.84rem;
    color: #102033;
    background: #ffffff;
    min-width: 160px;
  }
  
  .ui-admin-toolbar .form-control:focus,
  .ui-admin-toolbar input[type="text"]:focus {
    border-color: #1d4ed8;
    box-shadow: 0 0 0 2px rgba(29, 78, 216, 0.12);
  }
  
  .ui-admin-toolbar-spacer {
    flex: 1;
  }
  
  .ui-admin-cta {
    background: #1d4ed8 !important;
    color: #ffffff !important;
    border: 1px solid #1d4ed8 !important;
    border-radius: 12px !important;
    padding: 10px 18px !important;
    font-weight: 600 !important;
    font-size: 0.88rem !important;
    white-space: nowrap;
  }
  
  .ui-admin-cta:hover {
    background: #1e40af !important;
    border-color: #1e40af !important;
    color: #ffffff !important;
  }
  
  .ui-admin-table-frame {
    border: 1px solid #d7deea;
    border-radius: 16px;
    overflow: hidden;
    background: #ffffff;
  }
  
  .ui-admin-table-frame .table {
    margin: 0;
  }
  
  .ui-admin-table-frame .table > thead > tr > th {
    background: #f8fbff;
    border-bottom: 1px solid #d7deea;
    color: #607086;
    font-size: 0.78rem;
    font-weight: 600;
    padding: 14px 16px;
    text-transform: none;
    letter-spacing: 0;
  }
  
  .ui-admin-table-frame .table > tbody > tr > td {
    padding: 14px 16px;
    font-size: 0.88rem;
    color: #102033;
    border-bottom: 1px solid #f0f3f8;
  }
  
  .ui-admin-table-frame .table > tbody > tr:hover {
    background: rgba(29, 78, 216, 0.03);
  }
  
  .ui-admin-stat-card {
    border: 1px solid #d7deea;
    border-radius: 16px;
    padding: 18px;
    background: #ffffff;
    margin-top: 16px;
  }
  
  .ui-admin-stat-top {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
  }
  
  .ui-admin-stat-label {
    font-size: 0.88rem;
    color: #102033;
  }
  
  .ui-admin-stat-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 999px;
    border: 1px solid #d7deea;
    font-size: 0.72rem;
    font-weight: 500;
    color: #dc2626;
    background: #fef2f2;
  }
  
  .ui-admin-stat-value {
    font-size: 1.8rem;
    font-weight: 800;
    color: #102033;
    line-height: 1.1;
  }
  
  .ui-admin-stat-meta {
    font-size: 0.82rem;
    color: #607086;
    margin-top: 6px;
  }
  
  .ui-admin-workflow {
    display: flex;
    gap: 16px;
    margin-bottom: 16px;
  }
  
  .ui-admin-workflow-step {
    flex: 1;
    border: 1px solid #d7deea;
    border-radius: 16px;
    padding: 18px;
    background: #ffffff;
  }
  
  .ui-admin-workflow-step h4 {
    font-size: 1rem;
    font-weight: 700;
    color: #102033;
    margin: 0 0 8px;
  }
  
  .ui-admin-workflow-step p {
    font-size: 0.84rem;
    color: #607086;
    margin: 0 0 14px;
  }
  
  @media (max-width: 768px) {
    .ui-admin-intro {
      flex-direction: column;
      gap: 10px;
    }
  
    .ui-admin-toolbar {
      flex-direction: column;
      align-items: stretch;
    }
  
    .ui-admin-workflow {
      flex-direction: column;
    }
  }
  
  .ui-order-panel {
    padding: var(--s-2);
    border: 1px solid rgba(17, 24, 39, 0.08);
    border-radius: 12px;
    background:
      linear-gradient(180deg, rgba(79, 70, 229, 0.04) 0%, rgba(79, 70, 229, 0.01) 46%, #ffffff 100%);
  }
  
  /* My Order / Task List / AIS QA alignment with the Figma draft board */
  .ui-myorder-page {
    max-width: 1280px;
  }
  
  .ui-myorder-page .ui-ops-title {
    margin-bottom: 6px;
  }
  
  .ui-myorder-subtitle {
    margin: 0 0 14px;
    color: #64748b;
    font-size: 0.94rem;
  }
  
  /* My Order: actions row */
  .ui-myorder-actions-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 14px;
  }
  
  .ui-myorder-actions-left {
    display: flex;
    align-items: center;
    gap: 8px;
  }
  
  .ui-myorder-actions-right {
    display: flex;
    align-items: center;
    gap: 8px;
  }
  
  .ui-myorder-cta-btn {
    background: #4f46e5 !important;
    color: #ffffff !important;
    border: 1px solid #4f46e5 !important;
    border-radius: 12px !important;
    padding: 10px 18px !important;
    font-weight: 600 !important;
    font-size: 0.88rem !important;
  }
  
  .ui-myorder-cta-btn:hover {
    background: #4338ca !important;
    border-color: #4338ca !important;
    color: #ffffff !important;
  }
  
  /* My Order: filter panel */
  .ui-myorder-filter-panel {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 14px 18px;
    border: 1px solid #d9dfea;
    border-radius: 18px;
    background: #ffffff;
    margin-bottom: 14px;
  }
  
  .ui-myorder-pills {
    display: flex;
    flex: 1;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
  }
  
  .ui-myorder-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 12px;
    border-radius: 999px;
    border: 1px solid #d9dfea;
    font-size: 0.78rem;
    font-weight: 500;
    cursor: pointer;
    transition: box-shadow 0.15s;
  }
  
  .ui-myorder-pill input[type="checkbox"] {
    display: none;
  }
  
  .ui-myorder-pill--green {
    background: #ecfdf5;
    color: #059669;
  }
  
  .ui-myorder-pill--amber {
    background: #fff7ed;
    color: #d97706;
  }
  
  .ui-myorder-pill--indigo {
    background: #eef2ff;
    color: #4f46e5;
  }
  
  .ui-myorder-pill:has(input:checked) {
    box-shadow: 0 0 0 2px currentColor;
  }
  
  .ui-myorder-filter-right {
    display: flex;
    align-items: center;
    gap: 10px;
  }
  
  .ui-myorder-dropdown-pill {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 999px;
    border: 1px solid #d9dfea;
    background: #f8faff;
    font-size: 0.78rem;
    font-weight: 500;
    color: #1f2937;
    text-decoration: none !important;
  }
  
  .ui-myorder-search {
    width: 200px;
    padding: 8px 14px;
    border-radius: 10px;
    border: 1px solid #d9dfea;
    background: #ffffff;
    font-size: 0.84rem;
    color: #1f2937;
    outline: none;
  }
  
  .ui-myorder-search:focus {
    border-color: #4f46e5;
    box-shadow: 0 0 0 2px rgba(79, 70, 229, 0.15);
  }
  
  /* My Order: empty state */
  .ui-myorder-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    padding: 48px 20px;
  }
  
  .ui-myorder-empty-icon {
    width: 64px;
    height: 64px;
    border-radius: 20px;
    background: #eef2ff;
  }
  
  .ui-myorder-empty-title {
    font-size: 1.12rem;
    font-weight: 700;
    color: #1f2937;
    margin: 0;
  }
  
  .ui-myorder-empty-desc {
    font-size: 0.84rem;
    color: #6b7280;
    margin: 0;
  }
  
  @media (max-width: 768px) {
    .ui-myorder-filter-panel {
      flex-direction: column;
      align-items: flex-start;
    }
  
    .ui-myorder-actions-row {
      flex-direction: column;
      align-items: flex-start;
      gap: 10px;
    }
  }
  
  .ui-task-list-subtitle {
    margin: 0;
    color: #64748b;
    font-size: 0.94rem;
  }
  
  .ui-task-list-actions-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 10px;
    margin-bottom: 6px;
  }
  
  .ui-task-list-actions-desc {
    color: #6b7280;
    font-size: 0.84rem;
  }
  
  .ui-task-list-metrics,
  .ui-competition-metrics {
    margin-top: 10px;
    margin-bottom: 8px;
  }
  
  .ui-task-metric-card,
  .ui-qa-metric-card {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-height: 108px;
    padding: 14px 16px;
    border-radius: 14px;
    border: 1px solid rgba(15, 23, 42, 0.10);
    background: linear-gradient(180deg, #ffffff 0%, #f8faff 100%);
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.06);
  }
  
  .ui-task-metric-label,
  .ui-qa-metric-label {
    font-size: 0.78rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #64748b;
    font-weight: 700;
  }
  
  .ui-task-metric-value,
  .ui-qa-metric-value {
    font-size: 1.9rem;
    line-height: 1.1;
    color: #0f172a;
    font-weight: 800;
  }
  
  .ui-task-metric-meta,
  .ui-qa-metric-meta {
    font-size: 0.82rem;
    color: #94a3b8;
  }
  
  .ui-task-list-page .ui-ops-shell,
  .ui-competition-page .ui-ops-shell,
  .ui-myorder-page .ui-ops-shell {
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.95);
  }
  
  .ui-task-list-page .ui-ops-table-frame,
  .ui-competition-page .ui-ops-table-frame,
  .ui-myorder-page .ui-ops-table-frame {
    border-radius: 16px;
  }
  
  @media (max-width: 768px) {
    .ui-task-metric-card,
    .ui-qa-metric-card {
      min-height: 96px;
      margin-bottom: 10px;
    }
  
    .ui-task-metric-value,
    .ui-qa-metric-value {
      font-size: 1.5rem;
    }
  }
  
  .ui-order-table-frame {
    min-height: 500px;
    overflow-x: auto;
    border: 1px solid rgba(17, 24, 39, 0.10);
    border-radius: 12px;
    background: #ffffff;
    box-shadow: var(--ui-shadow-sm);
  }
  
  .ui-order-sidebar {
    position: sticky;
    top: var(--s-2);
  }
  
  /* -------------------------------------------------------------------------- */
  /* App shell / auth shell                                                     */
  /* -------------------------------------------------------------------------- */
  
  body.ui-app-shell {
    min-height: 100vh;
    background:
      radial-gradient(circle at top left, rgba(29, 78, 216, 0.10), transparent 34%),
      radial-gradient(circle at top right, rgba(79, 70, 229, 0.08), transparent 28%),
      linear-gradient(180deg, #f8fbff 0%, #eef3fb 100%);
  }
  
  body.ui-app-shell .ui-topbar {
    position: sticky;
    top: 0;
    z-index: 1030;
    margin: 16px 16px 0;
    padding: 14px 18px;
    border: 1px solid rgba(17, 24, 39, 0.08);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.88) !important;
    backdrop-filter: blur(18px);
    box-shadow: var(--ui-shadow-md);
  }
  
  body.ui-app-shell .ui-page-shell {
    width: min(1440px, calc(100% - 32px));
    margin: 24px auto 40px;
    padding: 0;
  }
  
  body.ui-app-shell .ui-footer {
    margin-top: 24px;
    padding: 18px 0 0;
    color: var(--ui-text-muted);
  }
  
  body.ui-auth-shell {
    min-height: 100vh;
    background:
      radial-gradient(circle at top left, rgba(29, 78, 216, 0.14), transparent 34%),
      radial-gradient(circle at top right, rgba(15, 118, 110, 0.10), transparent 26%),
      linear-gradient(180deg, #f6f8fd 0%, #edf2fb 100%);
  }
  
  body.ui-auth-shell nav.navbar {
    display: none !important;
  }
  
  body.ui-auth-shell .ui-page-shell {
    width: min(760px, calc(100% - 32px));
    margin: 0 auto;
    padding: 48px 0 40px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 20px;
  }
  
  body.ui-auth-shell .ui-footer {
    margin-top: 20px;
  }
  
  body.ui-auth-shell .ui-auth-main {
    width: min(760px, calc(100% - 32px));
  }
  
  /* Make the page body feel more like a dashboard canvas */
  body.ui-app-shell .body-content,
  body.ui-auth-shell .body-content {
    max-width: none;
  }
  
  /* Shell and page surfaces */
  .ui-page-shell > * {
    margin-bottom: 20px;
  }
  
  .ui-page-shell > *:last-child {
    margin-bottom: 0;
  }
  
  /* Cards and panels */
  .card,
  .modal-content,
  .dropdown-menu,
  .ui-auth-card,
  .ui-surface-card {
    border-radius: 20px;
    border: 1px solid rgba(17, 24, 39, 0.10);
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
  }
  
  .card {
    overflow: hidden;
  }
  
  .card-header {
    padding: 20px 20px 0;
    border-bottom: 0;
    background: transparent;
  }
  
  .card-body {
    padding: 20px;
  }
  
  .card-title,
  .modal-title,
  .ui-page-title {
    font-weight: 700;
    letter-spacing: -0.01em;
  }
  
  /* Dashboard blocks */
  .ui-hero-card,
  .ui-panel,
  .ui-auth-card {
    padding: 24px;
  }
  
  .ui-hero-card,
  .ui-panel {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(248, 251, 255, 0.98) 100%);
  }
  
  .ui-panel {
    border-radius: 22px;
    border: 1px solid rgba(17, 24, 39, 0.10);
    box-shadow: var(--ui-shadow-sm);
  }
  
  .ui-stat-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
  }
  
  @media (max-width: 992px) {
    .ui-stat-grid {
      grid-template-columns: 1fr;
    }
  }
  
  /* Tables */
  .table,
  table.table {
    border-collapse: separate;
    border-spacing: 0 12px;
  }
  
  .table thead th,
  table.table thead th {
    border: 0 !important;
    padding: 14px 16px !important;
    color: var(--ui-text-muted) !important;
    font-size: 0.85rem;
    letter-spacing: 0.02em;
    text-transform: uppercase;
  }
  
  .table tbody tr,
  table.table tbody tr {
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.05);
  }
  
  .table tbody td,
  table.table tbody td {
    vertical-align: middle;
    border-top: 0 !important;
    border-bottom: 0 !important;
    padding: 16px !important;
  }
  
  .table-striped tbody tr:nth-of-type(odd) {
    background: rgba(255, 255, 255, 0.98);
  }
  
  .table thead tr,
  table.table thead tr {
    background: transparent;
  }
  
  .table tbody tr:hover,
  table.table tbody tr:hover {
    transform: translateY(-1px);
    box-shadow: 0 16px 30px rgba(15, 23, 42, 0.08);
  }
  
  /* Buttons */
  .btn {
    border-radius: 12px;
    font-weight: 600;
    padding-left: 16px;
    padding-right: 16px;
  }
  
  .btn-primary,
  .btn-info {
    background: linear-gradient(135deg, var(--ui-primary) 0%, #6366f1 100%);
    border-color: transparent;
    box-shadow: 0 14px 26px rgba(29, 78, 216, 0.18);
  }
  
  .btn-outline-primary {
    color: var(--ui-primary);
    border-color: rgba(29, 78, 216, 0.35);
    background: rgba(255, 255, 255, 0.86);
  }
  
  .btn-outline-primary:hover {
    background: var(--ui-primary);
    border-color: var(--ui-primary);
  }
  
  .btn-outline-secondary {
    color: var(--ui-text);
    border-color: rgba(17, 24, 39, 0.16);
    background: rgba(255, 255, 255, 0.86);
  }
  
  /* Navbar + menus */
  .navbar-nav .nav-link,
  .navbar-text,
  .dropdown-item {
    font-weight: 600;
  }
  
  .navbar-light .navbar-nav .nav-link,
  .navbar-light .navbar-text {
    color: var(--ui-text);
  }
  
  .navbar-light .navbar-nav .nav-link:hover,
  .navbar-light .navbar-nav .show > .nav-link,
  .navbar-light .navbar-nav .active > .nav-link {
    color: var(--ui-primary);
  }
  
  .dropdown-menu {
    padding: 10px;
  }
  
  .dropdown-item {
    border-radius: 12px;
    padding: 10px 12px;
  }
  
  .dropdown-item:hover,
  .dropdown-item:focus {
    background: rgba(29, 78, 216, 0.08);
    color: var(--ui-primary);
  }
  
  /* Page typography */
  h1, h2, h3, h4, h5, h6 {
    letter-spacing: -0.01em;
  }
  
  /* Make the old login/register forms feel like the Figma auth design */
  body.ui-auth-shell .container.body-content .row {
    margin-left: 0;
    margin-right: 0;
  }
  
  body.ui-auth-shell .ui-auth-hero {
    text-align: center;
    margin-bottom: 20px;
  }
  
  body.ui-auth-shell .ui-auth-hero h1 {
    font-size: 2.35rem;
    font-weight: 800;
    margin-bottom: 10px;
  }
  
  body.ui-auth-shell .ui-auth-hero p {
    color: var(--ui-text-muted);
    margin-bottom: 0;
  }
  
  body.ui-auth-shell .ui-auth-card {
    width: 100%;
  }
  
  body.ui-auth-shell .ui-auth-card .form-control {
    max-width: none;
  }
  
  body.ui-auth-shell .ui-auth-card .btn {
    min-height: 46px;
  }
  
  /* Minor utilities for the refactored pages */
  .ui-kpi-chip,
  .ui-status-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 999px;
    background: rgba(29, 78, 216, 0.08);
    color: var(--ui-primary);
    font-size: 0.875rem;
    font-weight: 600;
  }
  
  .ui-muted-text {
    color: var(--ui-text-muted);
  }
  
  
  .ui-order-sidebar .card {
    border: 1px solid rgba(17, 24, 39, 0.10);
    box-shadow: var(--ui-shadow-sm);
  }
  
  .ui-order-sidebar .list-group-item {
    border-color: rgba(17, 24, 39, 0.08);
  }
  
  .ui-order-summary-list {
    max-height: calc(100vh - 220px);
    overflow: auto;
  }
  
  .ui-order-grid {
    width: 100%;
    margin-bottom: 0;
  }
  
  .ui-order-grid > tbody > tr:hover {
    background: rgba(79, 70, 229, 0.04);
  }
  
  .ui-order-grid > thead > tr > th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: linear-gradient(180deg, #ffffff 0%, #f6f7fb 100%);
    border-bottom: 1px solid rgba(17, 24, 39, 0.10);
  }
  
  .ui-order-grid > tbody > tr > td,
  .ui-order-grid > thead > tr > th {
    vertical-align: middle;
  }
  
  .ui-order-grid > tbody > tr > td {
    border-top-color: rgba(17, 24, 39, 0.08);
  }
  
  .ui-order-grid a {
    text-underline-offset: 2px;
  }
  
  .ui-order-grid .btn-link {
    text-decoration: none;
  }
  
  .ui-order-grid .btn-link:hover {
    text-decoration: underline;
  }
  
  .ui-order-grid .taskStartDate,
  .ui-order-grid .taskDeadlineDate {
    max-width: 160px;
  }
  
  .ui-order-grid .documentNickName {
    min-width: 180px;
  }
  
  .headContainer {
    margin-bottom: var(--s-2);
  }
  
  .contentheader_header {
    margin-bottom: 0;
  }
  
  .breadcrumb-toolbar {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
  }
  
  .breadcrumb-toolbar-btn .btn {
    min-width: 88px;
  }
  
  .card-header .card-title {
    margin-bottom: 4px;
  }
  
  .card-header .card-subtitle {
    margin-bottom: 0;
  }
  
  .row + .row {
    margin-top: var(--s-2);
  }
  
  .ui-order-toolbar .dropdown-menu {
    border: 1px solid rgba(17, 24, 39, 0.10);
  }
  
  .ui-order-toolbar .dropdown-item.active,
  .ui-order-toolbar .dropdown-item:active {
    background-color: rgba(79, 70, 229, 0.12);
    color: var(--ui-primary-700);
  }
  
  /* Reduce visual noise from legacy gray */
  .menu-select { background-color: rgba(105, 108, 255, 0.10); }
  
  /* Align custom button variants to the new palette */
  .btn-cornflowerblue,
  .btn-chartreuse {
    color: var(--ui-on-primary) !important;
    background-color: var(--ui-primary) !important;
    border-color: var(--ui-primary) !important;
  }
  .btn-cornflowerblue:hover,
  .btn-chartreuse:hover {
    background-color: var(--ui-primary-600) !important;
    border-color: var(--ui-primary-600) !important;
  }
  
  /* Make common "card-like" blocks consistent if used */
  .alert, .breadcrumb, .list-group-item {
    border-radius: var(--ui-radius-sm);
  }
  
  /* Dropdown toggle/button alignment: keep but modernize */
  .dropdown-menu .dropdown-item {
    border-radius: 8px;
    margin: 2px 6px;
    padding: 8px 10px;
  }
  
  /* Prefer flex for navbar content alignment (does not remove bootstrap behavior) */
  .navbar .container-fluid { gap: var(--s-2); }
  
  /* Responsive breakpoints: 1024 / 768 / 480 */
  @media (max-width: 1024px) {
    .container { max-width: 100%; }
  }
  
  @media (max-width: 768px) {
    /* Body text minimum 16px on mobile/tablet sizes */
    body { font-size: 16px; }
  
    /* Hamburger menu usability */
    .navbar-nav { padding-top: var(--s-2); padding-bottom: var(--s-2); }
    .navbar-nav .nav-link,
    .dropdown-menu .dropdown-item {
      min-height: 44px;
      display: flex;
      align-items: center;
      padding-left: 12px;
      padding-right: 12px;
    }
  
    /* Ensure buttons and form controls are tap-friendly */
    .btn,
    .form-control,
    .form-select,
    input,
    select,
    textarea {
      min-height: 44px;
    }
  
    /* Images should never cause horizontal scroll */
    img, svg, canvas {
      max-width: 100%;
      height: auto;
    }
  
    /* Tables: allow horizontal scroll inside table instead of page */
    table,
    .table {
      display: block;
      width: 100%;
      overflow-x: auto;
      -webkit-overflow-scrolling: touch;
    }
  
    .ui-order-sidebar {
      position: static;
      top: auto;
    }
  
    .ui-order-toolbar .navbar {
      justify-content: flex-start !important;
    }
  
    .ui-order-toolbar-actions {
      justify-content: flex-start;
    }
  
    .ui-order-table-frame {
      border-radius: 10px;
    }
  }
  
  @media (max-width: 480px) {
    /* Slightly tighter padding on very small screens */
    .container.body-content { padding-left: var(--s-2); padding-right: var(--s-2); }
    h1, .h1 { font-size: 1.75rem; }
    h2, .h2 { font-size: 1.375rem; }
    h3, .h3 { font-size: 1.125rem; }
  }
  
  /* Manage Documents: strong visual refresh */
  .ui-docs-page {
    position: relative;
    padding-top: 10px;
  }
  
  .ui-docs-page::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: 110px;
    border-radius: 14px;
    background:
      radial-gradient(1200px 120px at 15% 0%, rgba(37, 99, 235, 0.20), transparent 65%),
      radial-gradient(900px 130px at 85% 0%, rgba(234, 88, 12, 0.16), transparent 62%),
      linear-gradient(180deg, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.15) 100%);
    z-index: 0;
    pointer-events: none;
  }
  
  .ui-docs-page > .row,
  .ui-docs-page > input,
  .ui-docs-page > div {
    position: relative;
    z-index: 1;
  }
  
  .ui-docs-title {
    font-size: 1.95rem;
    font-weight: 800;
    letter-spacing: -0.015em;
    margin-bottom: 14px;
    color: #0f172a;
  }
  
  .ui-docs-hero-row {
    margin-bottom: 14px;
  }
  
  /* Home/Index (Admin Home) alignment */
  .ui-admin-home-page {
    position: relative;
  }
  
  .ui-admin-home-hero-row {
    margin-bottom: 12px;
  }
  
  .ui-admin-home-hero {
    border: 1px solid rgba(17, 24, 39, 0.10);
    border-radius: 22px;
    padding: 24px;
    background:
      radial-gradient(900px 180px at 0% 0%, rgba(37, 99, 235, 0.16), transparent 68%),
      linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(243, 247, 255, 0.98) 100%);
    box-shadow: 0 16px 34px rgba(15, 23, 42, 0.08);
  }
  
  .ui-admin-home-title {
    margin: 0;
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: #0f172a;
  }
  
  .ui-admin-home-subtitle {
    margin: 10px 0 0;
    color: var(--ui-text-muted);
    max-width: 760px;
  }
  
  .ui-admin-home-panel {
    border-radius: 20px;
  }
  
  /* AIS Quality Assurance list page alignment */
  .ui-competition-page {
    position: relative;
  }
  
  .ui-competition-hero-row {
    margin-bottom: 8px;
  }
  
  .ui-competition-subtitle {
    margin: 10px 0 0;
    color: var(--ui-text-muted);
  }
  
  .ui-competition-toolbar {
    border: 1px solid rgba(17, 24, 39, 0.10);
    border-radius: 16px;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.86);
  }
  
  .ui-ops-shell {
    border: 1px solid rgba(17, 24, 39, 0.10);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 14px 26px rgba(15, 23, 42, 0.06);
    padding: 14px;
  }
  
  @media (max-width: 768px) {
    .ui-admin-home-title {
      font-size: 1.65rem;
    }
  
    .ui-competition-toolbar {
      justify-content: flex-start !important;
    }
  }
  
  /* School Task Summary alignment with Task List draft */
  .ui-task-list-page {
    position: relative;
  }
  
  .ui-task-list-page .ui-ops-title {
    margin-bottom: 10px;
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: -0.015em;
  }
  
  .ui-task-list-toolbar {
    border: 1px solid rgba(17, 24, 39, 0.10);
    border-radius: 16px;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.88);
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.05);
    margin-bottom: 2px;
  }
  
  .ui-task-list-page .ui-order-table-frame {
    border-radius: 16px;
    padding: 12px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(246, 249, 255, 0.96) 100%);
  }
  
  .ui-task-list-page .ui-order-grid > thead > tr > th,
  .ui-task-list-grid > thead > tr > th {
    text-transform: none !important;
    letter-spacing: 0 !important;
    font-size: 0.82rem;
  }
  
  .ui-task-list-page .ui-order-grid tbody tr:hover {
    transform: translateY(-1px);
    box-shadow: 0 14px 26px rgba(15, 23, 42, 0.08);
  }
  
  .ui-task-list-page .ui-order-grid {
    border-spacing: 0 10px;
  }
  
  .ui-task-list-page .ui-order-grid > thead > tr > th,
  .ui-task-list-page .ui-order-grid > tbody > tr > td,
  .ui-task-list-grid > thead > tr > th,
  .ui-task-list-grid > tbody > tr > td {
    padding-left: 14px !important;
    padding-right: 14px !important;
  }
  
  .ui-task-list-page .ui-order-grid > thead > tr > th:first-child,
  .ui-task-list-page .ui-order-grid > tbody > tr > td:first-child,
  .ui-task-list-grid > thead > tr > th:first-child,
  .ui-task-list-grid > tbody > tr > td:first-child {
    padding-left: 18px !important;
  }
  
  .ui-task-list-page .ui-order-grid > thead > tr > th:last-child,
  .ui-task-list-page .ui-order-grid > tbody > tr > td:last-child,
  .ui-task-list-grid > thead > tr > th:last-child,
  .ui-task-list-grid > tbody > tr > td:last-child {
    padding-right: 18px !important;
  }
  
  .ui-task-list-page .ui-order-grid > tbody > tr,
  .ui-task-list-grid > tbody > tr {
    border-radius: 14px;
    overflow: hidden;
  }
  
  @media (max-width: 768px) {
    .ui-task-list-page .ui-ops-title {
      font-size: 1.6rem;
    }
  
    .ui-task-list-toolbar {
      justify-content: flex-start !important;
    }
  
    .ui-task-list-page {
      max-width: 100%;
    }
  }
  
  .ui-docs-hero {
    display: flex;
    gap: 14px;
    align-items: stretch;
    justify-content: space-between;
    padding: 16px 18px;
    border-radius: 14px;
    border: 1px solid rgba(30, 41, 59, 0.12);
    background:
      radial-gradient(760px 140px at -8% -20%, rgba(2, 132, 199, 0.18), transparent 72%),
      radial-gradient(620px 120px at 110% -30%, rgba(249, 115, 22, 0.18), transparent 66%),
      linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    box-shadow: 0 14px 30px rgba(15, 23, 42, 0.09), 0 2px 8px rgba(15, 23, 42, 0.05);
  }
  
  .ui-docs-hero-main h3 {
    margin: 0;
    font-size: 1.28rem;
    line-height: 1.2;
    font-weight: 800;
    color: #0f172a;
  }
  
  .ui-docs-hero-main p {
    margin: 8px 0 0;
    color: #334155;
    max-width: 620px;
  }
  
  .ui-docs-hero-metrics {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-end;
  }
  
  .ui-docs-metric-chip {
    min-width: 122px;
    padding: 10px 12px;
    border-radius: 12px;
    border: 1px solid rgba(30, 41, 59, 0.10);
    background: rgba(255, 255, 255, 0.88);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
  }
  
  .ui-docs-metric-label {
    display: block;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #64748b;
  }
  
  .ui-docs-metric-value {
    display: block;
    margin-top: 2px;
    font-size: 1.15rem;
    font-weight: 800;
    color: #0f172a;
  }
  
  .ui-docs-toolbar {
    gap: 10px;
    align-items: center;
    padding: 10px 12px;
    border: 1px solid rgba(15, 23, 42, 0.10);
    border-radius: 12px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    box-shadow: var(--ui-shadow-sm);
  }
  
  .ui-docs-toolbar > li {
    display: flex;
    align-items: center;
  }
  
  .ui-docs-toolbar .btn {
    border-radius: 999px;
    padding-left: 14px;
    padding-right: 14px;
  }
  
  .ui-docs-cta {
    position: relative;
    overflow: hidden;
    border: 0 !important;
    color: #ffffff !important;
    background: linear-gradient(92deg, var(--ui-cta-grad-start) 0%, var(--ui-cta-grad-end) 100%) !important;
    box-shadow: 0 10px 20px var(--ui-cta-shadow);
  }
  
  .ui-docs-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 14px 24px rgba(22, 163, 74, 0.36);
    filter: saturate(1.1);
  }
  
  .ui-docs-cta::after {
    content: "";
    position: absolute;
    top: 0;
    left: -140%;
    width: 120%;
    height: 100%;
    background: linear-gradient(120deg, transparent 0%, rgba(255, 255, 255, 0.35) 45%, transparent 100%);
    transition: left 420ms ease;
  }
  
  .ui-docs-cta:hover::after {
    left: 120%;
  }
  
  .ui-docs-shell {
    align-items: stretch;
  }
  
  .ui-docs-sidebar {
    border-radius: 14px;
    border: 1px solid rgba(15, 23, 42, 0.10);
    background: linear-gradient(180deg, #ffffff 0%, #f4f7ff 100%) !important;
    box-shadow: var(--ui-shadow-sm);
  }
  
  .ui-docs-sidebar .siderbar-item {
    border-radius: 10px;
    margin: 3px 0;
    font-weight: 600;
  }
  
  .ui-docs-sidebar .siderbar-item.active,
  .ui-docs-sidebar .siderbar-item:hover {
    color: #0f172a !important;
    background: linear-gradient(90deg, rgba(59, 130, 246, 0.18), rgba(14, 165, 233, 0.10));
  }
  
  .ui-docs-table-frame {
    border-radius: 14px;
    border: 1px solid rgba(15, 23, 42, 0.10);
    background: #ffffff;
    box-shadow: 0 14px 28px rgba(15, 23, 42, 0.08), 0 2px 8px rgba(15, 23, 42, 0.06);
    max-height: calc(100vh - 280px);
    overflow-y: auto;
  }
  
  .ui-docs-grid > thead > tr > th {
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.045em;
    color: #475569 !important;
    background: linear-gradient(180deg, #f8fafc 0%, #eef2ff 100%);
    position: sticky;
    top: 0;
    z-index: 2;
  }
  
  .ui-docs-grid > tbody > tr > td {
    padding-top: 14px;
    padding-bottom: 14px;
  }
  
  .ui-docs-grid > tbody > tr {
    transition: transform 180ms ease, box-shadow 180ms ease, background-color 180ms ease;
  }
  
  .ui-docs-grid > tbody > tr:hover {
    background-color: rgba(37, 99, 235, 0.05) !important;
    box-shadow: inset 3px 0 0 rgba(37, 99, 235, 0.55);
  }
  
  .ui-docs-edit-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 32px;
    min-width: 44px;
    padding: 4px 12px;
    border-radius: 999px;
    border: 1px solid rgba(37, 99, 235, 0.35);
    color: #1d4ed8 !important;
    font-weight: 700;
    font-size: 0.95rem;
    line-height: 1;
    text-decoration: none;
    white-space: nowrap;
  }
  
  .ui-docs-edit-link:hover {
    background: rgba(37, 99, 235, 0.10);
  }
  
  .ui-docs-add-link {
    display: inline-flex;
    align-items: center;
    padding: 10px 20px !important;
    margin: 6px 0;
    border-radius: 999px;
    border: 1px dashed rgba(37, 99, 235, 0.45);
    color: #1d4ed8 !important;
    font-weight: 700;
    text-decoration: none;
    white-space: normal;
    box-sizing: border-box;
  }
  
  .ui-docs-add-link:hover {
    background: rgba(37, 99, 235, 0.08);
  }
  
  .ui-docs-add-cell {
    position: static;
    background: #ffffff;
    padding-left: 14px !important;
    text-align: left;
  }
  
  .ui-docs-delete-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 8px;
    background: rgba(239, 68, 68, 0.10);
  }
  
  .ui-docs-delete-link:hover {
    background: rgba(239, 68, 68, 0.18);
  }
  
  @media (max-width: 768px) {
    .ui-docs-title {
      font-size: 1.5rem;
    }
  
    .ui-docs-hero {
      flex-direction: column;
      padding: 14px;
    }
  
    .ui-docs-hero-metrics {
      justify-content: flex-start;
    }
  
    .ui-docs-toolbar {
      justify-content: flex-start !important;
      padding: 10px;
    }
  }
  
  /* Reusable style system for other Order pages */
  .ui-ops-page {
    position: relative;
    padding-top: 8px;
  }
  
  .ui-ops-page::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: 96px;
    border-radius: 14px;
    background:
      radial-gradient(860px 120px at 8% -8%, rgba(37, 99, 235, 0.14), transparent 68%),
      radial-gradient(700px 120px at 92% -20%, rgba(249, 115, 22, 0.12), transparent 64%),
      linear-gradient(180deg, rgba(255, 255, 255, 0.92) 0%, rgba(255, 255, 255, 0.10) 100%);
    pointer-events: none;
    z-index: 0;
  }
  
  .ui-ops-page > .row,
  .ui-ops-page > div,
  .ui-ops-page > input {
    position: relative;
    z-index: 1;
  }
  
  .ui-ops-title {
    font-size: 1.72rem;
    font-weight: 800;
    letter-spacing: -0.012em;
    color: #0f172a;
  }
  
  .ui-ops-toolbar {
    gap: 10px;
    align-items: center;
    padding: 10px 12px;
    border: 1px solid rgba(15, 23, 42, 0.10);
    border-radius: 12px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    box-shadow: var(--ui-shadow-sm);
  }
  
  .ui-ops-toolbar > li {
    display: flex;
    align-items: center;
  }
  
  .ui-ops-shell {
    align-items: stretch;
  }
  
  .ui-ops-sidebar {
    border-radius: 14px;
    border: 1px solid rgba(15, 23, 42, 0.10);
    background: linear-gradient(180deg, #ffffff 0%, #f4f7ff 100%) !important;
    box-shadow: var(--ui-shadow-sm);
  }
  
  .ui-ops-sidebar .siderbar-item {
    border-radius: 10px;
    margin: 3px 0;
    font-weight: 600;
  }
  
  .ui-ops-sidebar .siderbar-item.active,
  .ui-ops-sidebar .siderbar-item:hover {
    color: #0f172a !important;
    background: linear-gradient(90deg, rgba(59, 130, 246, 0.18), rgba(14, 165, 233, 0.10));
  }
  
  .ui-ops-table-frame {
    border-radius: 14px;
    border: 1px solid rgba(15, 23, 42, 0.10);
    background: #ffffff;
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.08), 0 2px 8px rgba(15, 23, 42, 0.06);
  }
  
  .ui-ops-grid > thead > tr > th {
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.045em;
    color: #475569 !important;
    background: linear-gradient(180deg, #f8fafc 0%, #eef2ff 100%);
  }
  
  .ui-ops-grid > tbody > tr > td {
    padding-top: 13px;
    padding-bottom: 13px;
  }
  
  .ui-ops-grid > tbody > tr:hover {
    background-color: rgba(37, 99, 235, 0.04) !important;
  }
  
  @media (max-width: 768px) {
    .ui-ops-title {
      font-size: 1.42rem;
    }
  
    .ui-ops-toolbar {
      justify-content: flex-start !important;
      padding: 10px;
    }
  }
  
  /* Assign Documents To Task: page-specific polish */
  .ui-assign-docs-page {
    padding-top: 12px;
  }
  
  .ui-assign-docs-hero {
    padding: 14px 16px;
    border: 1px solid rgba(15, 23, 42, 0.10);
    border-radius: 14px;
    background:
      radial-gradient(740px 120px at 12% -30%, rgba(37, 99, 235, 0.12), transparent 70%),
      radial-gradient(680px 120px at 88% -35%, rgba(14, 165, 233, 0.10), transparent 66%),
      linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08), 0 2px 8px rgba(15, 23, 42, 0.05);
  }
  
  .ui-assign-docs-stepper {
    margin-bottom: 0;
    padding: 8px 10px;
    border: 1px solid rgba(148, 163, 184, 0.28);
    border-radius: 12px;
    background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
  }
  
  .ui-assign-docs-stepper .breadcrumb-item,
  .ui-assign-docs-stepper .breadcrumb-item span {
    font-size: 0.9rem;
    color: #64748b;
  }
  
  .ui-assign-docs-stepper .breadcrumb-item.active span,
  .ui-assign-docs-stepper .breadcrumb-item.active i {
    color: #1d4ed8;
    font-weight: 700;
  }
  
  .ui-assign-docs-actions #goPreviousBtn {
    border-radius: 10px;
    border: 1px solid rgba(100, 116, 139, 0.25);
    background: #ffffff;
  }
  
  .ui-assign-docs-actions #goNextBtn {
    border-radius: 10px;
    border: 0;
    background: linear-gradient(92deg, var(--ui-cta-grad-start) 0%, var(--ui-cta-grad-end) 100%);
    color: #ffffff;
    box-shadow: 0 10px 18px var(--ui-cta-shadow);
  }
  
  .ui-assign-docs-actions #goNextBtn:hover {
    transform: translateY(-1px);
    box-shadow: 0 14px 22px rgba(22, 163, 74, 0.34);
  }
  
  /* Reuse the same Figma gradient on other wizard Next/Assign buttons */
  .breadcrumb-toolbar-btn .btn.btn-success {
    border: 0;
    color: #ffffff;
    background: linear-gradient(92deg, var(--ui-cta-grad-start) 0%, var(--ui-cta-grad-end) 100%);
    box-shadow: 0 10px 18px var(--ui-cta-shadow);
  }
  
  .breadcrumb-toolbar-btn .btn.btn-success:hover,
  .breadcrumb-toolbar-btn .btn.btn-success:focus {
    color: #ffffff;
    transform: translateY(-1px);
    box-shadow: 0 14px 22px rgba(22, 163, 74, 0.34);
  }
  
  .ui-assign-docs-step2 .ui-assign-docs-tipbar {
    margin-bottom: 12px;
    padding: 10px 12px;
    border: 1px solid rgba(148, 163, 184, 0.24);
    border-radius: 12px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  }
  
  .ui-assign-docs-step2 .ui-assign-docs-tip-text {
    font-weight: 600;
    color: #334155;
    display: flex;
    align-items: center;
  }
  
  .ui-assign-docs-step2 .ui-ops-toolbar {
    padding: 6px 8px;
  }
  
  .ui-assign-docs-step2 #searchKeyword_input {
    min-width: 180px;
  }
  
  .ui-assign-docs-table-frame {
    border-radius: 14px 0 0 14px;
  }
  
  .ui-assign-docs-step2 .ui-ops-grid > thead > tr > th {
    font-size: 0.78rem;
    letter-spacing: 0.04em;
  }
  
  .ui-assign-docs-step2 .ui-ops-grid > tbody > tr > td {
    padding-top: 10px;
    padding-bottom: 10px;
  }
  
  .ui-assign-docs-step2 .ui-ops-grid .documentNickName {
    min-width: 230px;
    max-width: 290px;
  }
  
  .ui-assign-docs-step2 .ui-ops-grid > tbody > tr:hover {
    background-color: rgba(29, 78, 216, 0.055) !important;
    box-shadow: inset 3px 0 0 rgba(29, 78, 216, 0.55);
  }
  
  .ui-assign-docs-cart {
    padding-left: 0;
  }
  
  .ui-assign-docs-cart .card {
    border-radius: 0 14px 14px 0;
    border-left: 0;
    background:
      linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.08), 0 2px 8px rgba(15, 23, 42, 0.06);
  }
  
  .ui-assign-docs-cart .card-header {
    border-bottom: 1px solid rgba(148, 163, 184, 0.22);
  }
  
  .ui-assign-docs-cart .card-title {
    color: #0f172a;
    font-weight: 800;
  }
  
  .ui-assign-docs-cart .card-subtitle {
    color: #64748b !important;
    line-height: 1.2;
  }
  
  .ui-assign-docs-cart .list-group-item {
    font-size: 0.92rem;
    color: #1e293b;
  }
  
  @media (max-width: 992px) {
    .ui-assign-docs-table-frame {
      border-radius: 14px;
    }
  
    .ui-assign-docs-cart {
      margin-top: 12px;
      padding-left: 15px;
    }
  
    .ui-assign-docs-cart .card {
      border-radius: 14px;
      border-left: 1px solid rgba(15, 23, 42, 0.10);
    }
  }
  
  /* SchoolInfo: richer hero layout based on the new design direction */
  .ui-school-info-page {
    padding-top: 12px;
  }
  
  .ui-school-info-hero-row {
    margin-top: 8px;
    margin-bottom: 12px;
  }
  
  .ui-school-info-hero {
    display: flex;
    gap: 14px;
    align-items: center;
    justify-content: space-between;
    padding: 16px 18px;
    border: 1px solid rgba(15, 23, 42, 0.10);
    border-radius: 14px;
    background:
      radial-gradient(900px 130px at 10% -28%, rgba(37, 99, 235, 0.12), transparent 72%),
      radial-gradient(780px 120px at 90% -35%, rgba(22, 163, 74, 0.12), transparent 66%),
      linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.08), 0 2px 8px rgba(15, 23, 42, 0.05);
  }
  
  .ui-school-info-hero-main {
    min-width: 0;
  }
  
  .ui-school-info-hero-subtitle {
    margin: 6px 0 0;
    color: #475569;
    font-size: 0.96rem;
  }
  
  .ui-school-info-metrics {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-end;
  }
  
  .ui-school-info-chip {
    min-width: 116px;
    padding: 9px 12px;
    border-radius: 12px;
    border: 1px solid rgba(15, 23, 42, 0.10);
    background: rgba(255, 255, 255, 0.90);
  }
  
  .ui-school-info-chip-label {
    display: block;
    font-size: 0.74rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #64748b;
  }
  
  .ui-school-info-chip-value {
    display: block;
    margin-top: 2px;
    font-size: 1.12rem;
    font-weight: 800;
    color: #0f172a;
  }
  
  .ui-school-info-actions-col {
    display: flex;
    align-items: center;
    justify-content: flex-end;
  }
  
  .ui-school-info-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 20px;
  }
  
  @media (max-width: 992px) {
    .ui-school-info-hero {
      flex-direction: column;
      align-items: flex-start;
      padding: 14px;
    }
  
    .ui-school-info-metrics {
      justify-content: flex-start;
    }
  }
  
  