/* =========================
   PHI BRAND THEME VARIABLES
   ========================= */
:root {
  --phi-blue: #0093d2;
  --phi-navy: #19395b;
  --phi-grey: #87898b;
  --phi-white: #ffffff;
  --phi-accent: #ffa02f;
  --phi-gold:#ffa02f;
  --phi-border:#d9e1ea;

  /* optional accent */
}

/* =========================
   GLOBAL TYPOGRAPHY
   ========================= */

/* Global font to match guidelines (Arial) */
body {
  font-family: Arial, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  padding-top: 0 !important;
  background-color: #f5f7fa;
  color: var(--phi-navy);
}

/* Headings (per brand guide) */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: Arial, sans-serif;
  font-weight: 700;
  color: var(--phi-navy);
}

/* H1: 36pt / uppercase */
h1 {
  font-size: 27px !important;
  text-transform: uppercase;
}

/* H2: 28pt / semi-bold */
h2 {
  font-size: 23px !important;
  font-weight: 600 !important;
}

/* H3: slightly smaller */
h3 {
  font-size: 18px !important;
  font-weight: 600 !important;
}

/* Hide default portal header */
.navbar.navbar-inverse,
.navbar.navbar-default,
.navbar.navbar-static-top,
div[role="banner"].navbar {
  display: none !important;
}

/* =========================
   SHELL LAYOUT
   ========================= */

.pp-shell {
  display: flex;
  min-height: 100vh;
}

/* ========= Sidebar ========= */
.pp-sidebar {
  width: 240px;
  background: var(--phi-navy);
  color: var(--phi-white);
  padding: 16px 12px;
  display: flex;
  flex-direction: column;
}

.pp-sidebar-logo {
  margin-bottom: 32px;
  text-align: center;
}

.pp-sidebar-logo img {
  max-width: 160px;
}

/* Sidebar navigation links */
.pp-sidebar-nav {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.pp-sidebar-nav .nav-link {
  display: block;
  padding: 10px 16px;
  color: var(--phi-grey);
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
  letter-spacing: 0.02em;
}

.pp-sidebar-nav .nav-link:hover {
  color: var(--phi-white);
  background-color: #204769;
  /* lighter navy */
}

.pp-sidebar-nav .nav-link.active {
  color: var(--phi-white);
  background-color: var(--phi-blue);
}

/* ========= Main Content ========= */
.pp-main {
  flex: 1;
  background: #f3f4f6;
}

.pp-content {
  padding: 24px;
}

/* ========= Top Bar ========= */
.pp-topbar {
  padding: 12px 24px;
  background: transparent;
}

/* White card for user info */
.pp-topbar-card {
  background: var(--phi-white);
  border-radius: 8px;
  padding: 10px 16px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.12);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Text in top bar */
.pp-topbar-text span {
  font-size: 14px;
  color: #374151;
}

.pp-topbar-name {
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  /* matches logo style */
}

.pp-topbar-divider {
  margin: 0 8px;
  color: var(--phi-grey);
}

.pp-topbar-account,
.pp-topbar-role {
  font-weight: 600;
}

/* ========= User Avatar & Menu ========= */
.pp-topbar-user {
  position: relative;
  display: flex;
  align-items: center;
}

.pp-topbar-avatar-card {
  background: #ffffff;
  border-radius: 10px;
  padding: 6px;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.18);
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 52px;
  min-height: 52px;
}

.pp-topbar-avatar {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  background: var(--phi-blue, #0093d2);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
}

/* dropdown */
.pp-user-menu {
  position: absolute;
  top: 110%;
  right: 0;
  background: var(--phi-white);
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.18);
  padding: 8px 0;
  min-width: 220px;
  z-index: 1000;
  display: none;
}

.pp-user-menu.open {
  display: block;
}

.pp-user-menu-header {
  padding: 8px 16px 6px;
  border-bottom: 1px solid #e5e7eb;
  margin-bottom: 4px;
}

.pp-user-menu-name {
  font-size: 14px;
  font-weight: 700;
  color: #111827;
}

.pp-user-menu-email {
  font-size: 12px;
  color: #6b7280;
}

.pp-user-menu-link {
  display: block;
  padding: 8px 16px;
  font-size: 14px;
  color: #374151;
  text-decoration: none;
}

.pp-user-menu-link:hover {
  background: #f3f4f6;
  color: #111827;
}

/* =========================
   HOME PAGE – CASE HISTORY
   ========================= */

.home-request-wrapper {
  margin-top: 20px;
}

/* Create Case button row */
.home-request-actions {
  display: flex;
  justify-content: flex-start;
  margin-bottom: 16px;
}

.home-create-btn {
  font-weight: 600;
  padding: 10px 20px;
  border-radius: 6px;
  border: 2px solid var(--phi-navy);
  color: var(--phi-navy);
  background: transparent;
}

.home-create-btn:hover {
  background: var(--phi-navy);
  color: var(--phi-white);
}

/* Case History heading */
.home-request-title {
  font-weight: 700;
  margin-bottom: 20px;
}

/* Stat cards row */
.home-stats-row {
  margin-bottom: 30px;
}

/* Individual stat card */
.home-stat-card {
  background: #ffffff;
  border-radius: 10px;
  padding: 25px;
  text-align: center;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.12);
}

/* Stat values (numbers) */
.home-stat-value {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 4px;
}

/* Colors per status – PHI palette */
.home-stat-total {
  color: var(--phi-blue);
  /* primary blue */
}

.home-stat-cancelled {
  color: var(--phi-grey);
  /* grey */
}

.home-stat-active {
  color: #0A6A9B;
  /* dark blue */
}

.home-stat-resolved {
  color: #296C87;
  /* deep teal */
}

/* Labels under numbers */
.home-stat-label {
  margin: 0;
  font-weight: 600;
  font-size: 14px;
}

/* List wrapper spacing */
.home-list-wrapper {
  margin-bottom: 40px;
}

/* =========================
   CREATE CASE PAGE
   ========================= */

.create-request-wrapper {
  margin-top: 20px;
}

/* Main title: "Create Case" */
.cr-title {
  font-weight: 700;
  margin-bottom: 16px;
  text-transform: uppercase;
  color: var(--phi-navy);
}

/* Section titles: "Case Details", "Information" */
.cr-section-title {
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--phi-navy);
}

.cr-page-subtitle {
  margin-bottom: 20px;
  color: #6b7280;
  font-size: 14px;
}

/* Layout row */
.cr-form-row {
  margin-top: 10px;
}

/* Right info card (Account / Contact) */
.cr-info-card {
  background: #ffffff;
  border-radius: 8px;
  padding: 16px 18px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.12);
  border-top: 3px solid var(--phi-blue);
  /* subtle PHI accent */
}

/* Info lines inside card */
.cr-info-line {
  margin-bottom: 12px;
}

/* "Account", "Contact" labels */
.cr-info-label {
  display: inline-block;
  font-weight: 600;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--phi-grey);
}

/* Values under labels */
.cr-info-value {
  color: #111827;
  font-weight: 600;
  font-size: 14px;
}

/* =========================
   FOOTER
   ========================= */

.footer {
  background: #f3f4f6;
  margin-top: 0;
}

.footer-bottom {
  border-top: 1px solid #e5e7eb;
  padding-top: 12px;
  padding-bottom: 16px;
}

.footer-bottom .container {
  max-width: 1200px;
  /* keep it aligned with main content */
}

.footer-bottom p {
  margin: 0;
  font-size: 12px;
  color: var(--phi-grey);
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

/* ===== PHI Footer with Logo ===== */

.phi-footer-inner {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* logo size in footer */
.phi-footer-logo-img {
  height: 26px;
  width: auto;
  display: block;
}

/* make footer text match brand styling */
.phi-footer-copy span {
  display: block;
  font-size: 12px;
  color: var(--phi-white);
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

/* mobile: center logo + text */
@media (max-width: 768px) {
  .phi-footer-inner {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
}

/* Small screens: center text */
@media (max-width: 768px) {
  .footer-bottom .text-start {
    text-align: center !important;
  }
}

/* ===== Entity List font override ===== */
.entitylist,
.entitylist table,
.entitylist th,
.entitylist td {
  font-family: Arial, sans-serif !important;
  font-size: 14px;
  color: var(--phi-navy, #19395b);
}

/* Page size selector styling */
.phi-page-size {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 8px;
  font-size: 13px;
  color: var(--phi-navy, #19395b);
}

.phi-page-size-select {
  padding: 2px 6px;
  border-radius: 4px;
  border: 1px solid #d1d5db;
  font-size: 13px;
}

/* =========================
   PHI Onboarding Modal – Enhanced Styling
   ========================= */

.phi-onboarding-modal .modal-dialog {
  max-width: 960px;
}

/* Shell */
.phi-onboarding-modal .modal-content {
  border-radius: 18px;
  border-top: 4px solid var(--phi-blue);
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.35);
  background: #ffffff;
}

/* Header */
.phi-onboarding-modal .modal-header {
  padding: 18px 20px 8px;
}

/* "Getting started" pill injected via ::before */
.phi-onboarding-modal .modal-header > div:first-child::before {
  content: "Getting started";
  display: inline-block;
  margin-bottom: 4px;
  padding: 2px 10px;
  border-radius: 999px;
  background: rgba(0, 147, 210, 0.08);
  color: var(--phi-blue);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.phi-onboarding-modal .modal-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--phi-navy);
}

.phi-onboarding-modal .modal-header p.small {
  color: #6b7280;
}

/* Close button */
.phi-onboarding-modal .btn-close {
  opacity: 0.7;
}

.phi-onboarding-modal .btn-close:hover {
  opacity: 1;
}

/* Body */
.phi-onboarding-modal .modal-body {
  padding: 12px 20px 18px;
}

/* Video card */
.phi-onboarding-modal .ratio {
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.18);
  background: #000;
}

.phi-onboarding-modal .ratio iframe {
  border: 0;
}

/* Right panel */
.phi-onboarding-modal .phi-onboarding-panel {
  background: #f9fafb;
  border-radius: 12px;
  padding: 14px 16px;
  border: 1px solid #e5e7eb;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.08);
}

.phi-onboarding-modal .phi-onboarding-panel .btn-outline-primary {
  border-radius: 999px;
  border-color: var(--phi-blue);
  color: var(--phi-blue);
  font-weight: 600;
}

.phi-onboarding-modal .phi-onboarding-panel .btn-outline-primary:hover {
  background: rgba(0, 147, 210, 0.08);
  color: var(--phi-navy);
  border-color: var(--phi-blue);
}

/* Steps – hover and layout */
.phi-onboarding-modal .phi-step-card {
  background: #ffffff;
  border-radius: 12px;
  padding: 12px 14px;
  border: 1px solid #e5e7eb;
  display: flex;
  flex-direction: column;
  gap: 4px;
  height: 100%;
  transition:
    transform 0.16s ease,
    box-shadow 0.16s ease,
    border-color 0.16s ease;
}

.phi-onboarding-modal .phi-step-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.18);
  border-color: var(--phi-blue);
}

.phi-onboarding-modal .phi-step-number {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: rgba(0, 147, 210, 0.08);
  color: var(--phi-blue);
  font-weight: 700;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 4px;
}

/* Footer + button */
.phi-onboarding-modal .modal-footer {
  padding: 8px 20px 18px;
  display: flex;
  justify-content: flex-end;
}

.phi-onboarding-modal .modal-footer .btn {
  border-radius: 999px;
  padding: 6px 16px;
  font-weight: 600;
}

/* Make the existing secondary button look like a PHI primary CTA */
.phi-onboarding-modal .modal-footer .btn-secondary {
  background-color: var(--phi-blue);
  border-color: var(--phi-blue);
  color: #ffffff;
}

.phi-onboarding-modal .modal-footer .btn-secondary:hover {
  background-color: #0079ac;
  border-color: #0079ac;
}

/* Checkbox tweaks */
.phi-onboarding-modal #phiOnboardingCheckboxWrapper {
  margin-top: 16px;
}

.phi-onboarding-modal .form-check-input:focus {
  box-shadow: 0 0 0 2px rgba(0, 147, 210, 0.4);
  border-color: var(--phi-blue);
}

/* Small tweak for very small screens */
@media (max-width: 576px) {
  .phi-onboarding-modal .modal-dialog {
    margin: 0.75rem;
  }

  .phi-onboarding-modal .modal-body {
    padding: 10px 14px 16px;
  }

  .phi-onboarding-modal .modal-footer {
    flex-direction: column-reverse;
    align-items: stretch;
    gap: 6px;
  }
}

/* ===== Entity List Pagination (PHI Brand) ===== */

.jquery-bootstrap-pagination {
  margin-top: 12px;
}

/* Wrapper UL */
.jquery-bootstrap-pagination .pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin: 0;
}

/* Individual page items */
.jquery-bootstrap-pagination .page-item {
  display: inline-block;
}

/* Page links */
.jquery-bootstrap-pagination .page-link {
  border-radius: 6px;
  border: 1px solid #d1d5db;
  padding: 4px 10px;
  min-width: 32px;
  text-align: center;
  font-size: 13px;
  font-weight: 600;
  color: var(--phi-navy, #19395b);
  background-color: #ffffff;
  text-decoration: none;
}

/* Hover state */
.jquery-bootstrap-pagination .page-link:hover {
  background-color: #CBE7F4;
  /* light PHI blue */
  border-color: var(--phi-blue, #0093d2);
  color: var(--phi-navy, #19395b);
}

/* Active page */
.jquery-bootstrap-pagination .page-item.active .page-link {
  background-color: var(--phi-blue, #0093d2);
  border-color: var(--phi-blue, #0093d2);
  color: #ffffff;
}

/* Disabled (e.g. prev on page 1) */
.jquery-bootstrap-pagination .page-item.disabled .page-link {
  background-color: #f3f4f6;
  border-color: #e5e7eb;
  color: #9ca3af;
  cursor: default;
}

/* Remove default focus outline, but keep subtle focus for accessibility */
.jquery-bootstrap-pagination .page-link:focus {
  box-shadow: 0 0 0 2px rgba(0, 147, 210, 0.25);
  outline: none;
}


/* =========================================
   PHI Onboarding – Blue Cards & Equal Steps
   ========================================= */

/* Make the three step columns equal height */
.phi-onboarding-modal .row.g-3.mt-4 > [class*='col-'] {
  display: flex;
}

.phi-onboarding-modal .row.g-3.mt-4 > [class*='col-'] .phi-step-card {
  flex: 1;
}

/* Step cards: PHI blue background + white text */
.phi-onboarding-modal .phi-step-card {
  background: linear-gradient(135deg, var(--phi-blue), #0A6A9B);
  border-radius: 12px;
  border: none;
  color: var(--phi-white);
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.18);
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px;
  transition:
    transform 0.16s ease,
    box-shadow 0.16s ease;
}

.phi-onboarding-modal .phi-step-card h4,
.phi-onboarding-modal .phi-step-card p {
  color: var(--phi-white);
}

/* Step number chip on blue background */
.phi-onboarding-modal .phi-step-number {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.15);
  color: var(--phi-white);
  font-weight: 700;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 4px;
  border: 1px solid rgba(255, 255, 255, 0.45);
}

/* Hover: slightly lift the cards */
.phi-onboarding-modal .phi-step-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.25);
}

/* "Prefer a PDF walkthrough?" panel: PHI blue + white text */
.phi-onboarding-modal .phi-onboarding-panel {
  background: linear-gradient(135deg, var(--phi-blue), #0A6A9B);
  border-radius: 12px;
  border: none;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.2);
  color: var(--phi-white);
}

.phi-onboarding-modal .phi-onboarding-panel p,
.phi-onboarding-modal .phi-onboarding-panel li {
  color: var(--phi-white);
}

/* Button inside the PDF panel: white pill CTA */
.phi-onboarding-modal .phi-onboarding-panel .btn-outline-primary {
  border-radius: 999px;
  border-color: var(--phi-white);
  background-color: var(--phi-white);
  color: var(--phi-blue);
  font-weight: 600;
}

.phi-onboarding-modal .phi-onboarding-panel .btn-outline-primary:hover {
  background-color: #f3f4f6;
  border-color: #f3f4f6;
  color: #0A6A9B;
}

.phi-onboarding-modal .form-check-input {
  width: 1rem;
  height: 1rem;
}

/* Make the checked state clearly visible */
.phi-onboarding-modal .form-check-input:checked {
  background-color: var(--phi-blue);
  border-color: var(--phi-blue);
}

/* Banner card */
.phi-terms-banner{
  border: 1px solid var(--phi-border);
  border-left: 6px solid var(--phi-blue);
  border-radius: 14px;
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.06);
  background: #ffffff;
}

/* Small icon */
.phi-terms-icon{
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: rgba(0,147,210,0.12);
  color: var(--phi-blue);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
}

/* Pill with count */
.phi-terms-pill{
  display: inline-flex;
  align-items: baseline;
  gap: 10px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(0,147,210,0.25);
  background: rgba(0,147,210,0.08);
  color: var(--phi-navy);
  font-weight: 800;
  white-space: nowrap;
}
.phi-terms-pill-label{
  font-size: 12px;
  opacity: 0.75;
  font-weight: 800;
}
.phi-terms-pill-value{
  font-size: 18px;
  font-weight: 900;
  line-height: 1;
}
