/*
 * This is a manifest file that'll be compiled into application.css, which will include all the files
 * listed below.
 *
 * Any CSS (and SCSS, if configured) file within this directory, lib/assets/stylesheets, or any plugin's
 * vendor/assets/stylesheets directory can be referenced here using a relative path.
 *
 * You're free to add application-wide styles to this file and they'll appear at the bottom of the
 * compiled file so the styles you add here take precedence over styles defined in any other CSS
 * files in this directory. Styles in this file should be added after the last require_* statement.
 * It is generally better to create a new file per style scope.
 *
 *= require_tree .
 *= require_self
 */

:root {
  --primary-color: #000;
  --focus-shadow: rgba(0, 0, 0, 0.15);
  --navbar-bg: #214E34;
  --border-radius: 12px;
}

* {
  font-family: "Inter", sans-serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
  font-variation-settings:
    "wdth" 100,
    "YTLC" 500;
}

/******************** Navigation ****************************/
.custom-topnav {
  background-color: var(--navbar-bg) !important;
}

.custom-links {
  color: black !important;
  text-decoration: none !important;
}

.custom-links:hover {
  color: black !important;
}

/******************** Bootstrap Dashboard ****************************/
body {
  font-size: .875rem;
}

.btn {
  border-radius: 0 !important;
}

.bi {
  display: inline-block;
  width: 1rem;
  height: 1rem;
}

.feather {
  width: 16px;
  height: 16px;
}

/*
 * Sidebar
 */
.sidebar {
  position: fixed;
  top: 0;
  /* rtl:raw:
  right: 0;
  */
  bottom: 0;
  /* rtl:remove */
  left: 0;
  z-index: 100; /* Behind the navbar */
  padding: 48px 0 0; /* Height of navbar */
  box-shadow: inset -1px 0 0 rgba(0, 0, 0, .1);
}

@media (max-width: 767.98px) {
  .sidebar {
    top: 5rem;
  }
}

.sidebar-sticky {
  height: calc(100vh - 48px);
  overflow-x: hidden;
  overflow-y: auto; /* Scrollable contents if viewport is shorter than content. */
}

.sidebar .nav-link {
  font-weight: 500;
  color: #333;
}

.sidebar .nav-link .feather {
  margin-right: 4px;
  color: #727272;
}

.sidebar .nav-link.active {
  color: #2470dc;
}

.sidebar .nav-link:hover .feather,
.sidebar .nav-link.active .feather {
  color: inherit;
}

.sidebar-heading {
  font-size: .75rem;
}

/* Ministry navigation follows the national dashboard's deep green identity. */
.ministry-sidebar {
  background: radial-gradient(ellipse at top left, #124f40, transparent 65%), #042f28;
  color: #fff;
}
.ministry-sidebar .ministry-identity { border-bottom: 1px solid #ffffff26; padding-top: 1rem; }
.ministry-sidebar .ministry-identity-flag { font-size: 2.4rem; margin-bottom: .8rem; }
.ministry-sidebar .ministry-identity-country { color: #fff; font-size: .85rem; letter-spacing: .18em; font-weight: 600; }
.ministry-sidebar .ministry-identity-org { color: #d9ece6; font-size: .85rem; margin-top: .5rem; line-height: 1.5; }
.ministry-sidebar .sidebar-heading, .ministry-sidebar .nav-item { color: #b6d5cb !important; }
.ministry-sidebar .nav-link.custom-links { color: #f4faf7 !important; border-radius: 8px; margin: .2rem .65rem; padding: .85rem .8rem; font-weight: 400; }
.ministry-sidebar .nav-link.custom-links i { width: 1.5rem; color: #e0f0e9; text-align: center; margin-right: .4rem; }
.ministry-sidebar .nav-link.custom-links:hover { background: #ffffff12; }
.ministry-sidebar .nav-link.custom-links.active { background: #69b39740; color: #fff !important; }
.ministry-sidebar .nav-link.custom-links:focus-visible { outline: 2px solid #bce0ce; outline-offset: 2px; }

/* Ministry Portal stat-tile icon badge (app/views/ministry/shared/_stat_tile.html.erb) */
.stat-tile-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

/* Center the icon glyph itself, without its inline text baseline. */
.stat-tile-icon > .bi { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; line-height: 1; }
.stat-tile-icon > .bi::before { display: block; line-height: 1; vertical-align: 0; }

/* Ministry Portal masthead (app/views/ministry/shared/_page_header.html.erb) */
.ministry-masthead {
  border-bottom: 1px solid #e1e0d9;
}

.ministry-masthead-eyebrow {
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .08em;
  color: #898781;
}

.ministry-masthead-identity {
  white-space: nowrap;
}

.ministry-masthead-flag {
  font-size: 1.75rem;
  line-height: 1;
}

.ministry-masthead-org {
  font-weight: 600;
  color: var(--navbar-bg);
  font-size: .9rem;
}

/* Ministry Portal choropleth in-map value labels (app/views/ministry/shared/_choropleth_map.html.erb) */
.region-label-tooltip {
  background: transparent;
  border: none;
  box-shadow: none;
  font-weight: 700;
  font-size: .8rem;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, .55);
}

.region-label-tooltip::before {
  display: none;
}

/*
 * Navbar
 */
.navbar-brand {
  padding-top: .75rem;
  padding-bottom: .75rem;
  background-color: rgba(0, 0, 0, .25);
  box-shadow: inset -1px 0 0 rgba(0, 0, 0, .25);
}

.navbar .navbar-toggler {
  top: .25rem;
  right: 1rem;
}

.navbar .form-control {
  padding: .75rem 1rem;
}



/******************** Buttons ****************************/
  .btn-dark {
    background-color: #000;
    border-color: #000;
  }

  .btn-dark:hover {
    background-color: #333;
    border-color: #333;
  }

/******************** Tables ****************************/

  .table thead th {
    background: #f8f9fa !important;
    color: #000 !important;
    border: none !important;
    font-weight: 600 !important;
  }

.table th {
  border-bottom: 2px solid var(--primary-color);
  font-weight: 600;
  white-space: nowrap;
}

.table td {
  vertical-align: middle;
}

/* Hover effect */
.table-hover tbody tr:hover {
  background-color: #f8f9fa;
  transition: background-color 0.2s ease;
}



/******************** Forms ****************************/
.form-control-dark {
  color: #fff;
  background-color: rgba(255, 255, 255, .1);
  border-color: rgba(255, 255, 255, .1);
}

.form-control-dark:focus {
  border-color: transparent;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, .25);
}

/* Form Focus States */
.form-control:focus,
.form-select:focus {
  border-color: var(--primary-color) !important;
  box-shadow: 0 0 0 0.2rem var(--focus-shadow) !important;
}

/* Placeholders */
  .form-control::placeholder {
    color: #ced4da !important;
    opacity: 1 !important;
  }

/* Checkboxes */
.form-check-input:focus {
  border-color: var(--primary-color) !important;
  box-shadow: 0 0 0 0.2rem var(--focus-shadow) !important;
}

  .form-check-input:checked {
    background-color: #000 !important;
    border-color: #000 !important;
  }




/* Additional specificity for search inputs */
.search-box .form-control:focus {
  border-color: var(--primary-color) !important;
  box-shadow: 0 0 0 0.2rem var(--focus-shadow) !important;
}



/******************** Cards ****************************/

/* Dashboard */



/* General cards */

  .card {
    border: none !important;
    border-radius: 12px !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06) !important;
  }
  
  .card-header {
    background: white !important;
    color: #000 !important;
    font-weight: 600 !important;
    border-radius: 12px 12px 0 0 !important;
    border-bottom: 2px solid #000 !important;
  }

/* Stats cards */
.stats-card {
  border-radius: var(--border-radius);
  border: none;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.patient-card {
  transition: all 0.2s;
  cursor: pointer;
}

.patient-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}



/******************** Search Box ****************************/
.search-box {
  border-radius: var(--border-radius);
}



/******************** Pagination ****************************/
/* Pagination styling */
.pagination {
  margin-top: 1.5rem;
}

.pagination .page-item .page-link {
  color: var(--primary-color);
  border-color: #dee2e6;
}

.pagination .page-item.active .page-link {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
  color: #fff;
}

.pagination .page-item .page-link:hover {
  background-color: #f8f9fa;
  border-color: var(--primary-color);
  color: var(--primary-color);
}

.pagination .page-item.disabled .page-link {
  color: #6c757d;
}



/******************** Badges ****************************/
.badge-custom {
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-size: 0.875rem;
}

  .status-badge {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
  }
/******************** Nav Pills ****************************/



/******************** Icons & Status ****************************/
/* General Icon Styles */
.icon {
  font-size: 16px;
  margin-right: 5px;
}

/* Status-specific Icon Styles */
.pending_approval_icon {
  color: lightgray;
}

.approved_icon {
  color: green;
}

.to_review_icon {
  color: yellow;
}

.paused_icon {
  color: blue;
}

.disabled_icon {
  color: gray;
}

.blocked_icon {
  color: red;
}

.system_owned_icon {
  color: black;
}

.pending_adoption_icon {
  color: lightgray;
}

.adopted_icon {
  color: green;
}

.restricted_offer_icon {
  color: purple;
}

.private_offer_icon {
  color: black;
}

.public_offer_icon {
  color: green;
}

.deal_icon {
  color: teal;
}

.free_icon {
  color: magenta;
}

.paid_icon {
  color: gold;
}

.live_icon {
  color: green;
}

.expired_icon {
  color: darkred;
}

.admin_icon {
  color: red;
}

.new_user_icon {
  color: lightgray;
}

.standard_icon {
  color: blue;
}

.business_icon {
  color: black;
}

.microservice_icon {
  color: darkorchid;
}

.error_icon {
  color: darkred;
}

/******************** Images ****************************/
.index-list-image {
  /*  height: 56px !important;*/
  width: 56px !important;
  margin: auto;
}


/******************** Info ****************************/



  .info-label {
    font-size: 0.85rem;
    color: #6c757d;
    font-weight: 500;
    margin-bottom: 0.25rem;
  }
  
  .info-value {
    font-weight: 600;
    color: #212529;
    margin-bottom: 1rem;
  }

/******************** Progress Steps ****************************/

  .progress-steps {
    display: flex;
    justify-content: space-between;
    margin-bottom: 2rem;
    padding: 0;
    list-style: none;
  }

  .progress-step {
    flex: 1;
    text-align: center;
    position: relative;
    padding-top: 3rem;
  }

  .progress-step::before {
    content: attr(data-step);
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    background: #e9ecef;
    border: 3px solid #e9ecef;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: #6c757d;
    z-index: 1;
  }

  .progress-step::after {
    content: '';
    position: absolute;
    top: 1.25rem;
    left: -50%;
    width: 100%;
    height: 3px;
    background: #e9ecef;
    z-index: 0;
  }

  .progress-step:first-child::after {
    display: none;
  }

  .progress-step.completed::before {
    background: #28a745;
    border-color: #28a745;
    color: white;
    font-family: 'bootstrap-icons' !important;
    content: '\F633'; 
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .progress-step.completed::after {
    background: #28a745;
  }

  .progress-step.completed::after {
    background: #28a745;
  }

  .progress-step.active::before {
    background: #000;
    border-color: #000;
    color: white;
  }

  .progress-step-label {
    display: block;
    margin-top: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
  }

  .progress-step.active .progress-step-label {
    color: #000;
    font-weight: 600;
  }

  .progress-step.completed .progress-step-label {
    color: #28a745;
  }




/* Executive dashboard — restrained surfaces and a fluid metric grid. */
.ministry-portal { background: #f3f6f8; color: #172b3a; }
.ministry-portal main { min-width: 0; }
.ministry-portal main > br { display: none; }
.ministry-sidebar { background: linear-gradient(160deg, #104c3d, #052f28 65%); box-shadow: none; }
.ministry-sidebar .ministry-identity { padding-top: .35rem; padding-bottom: .75rem !important; }
.ministry-sidebar .ministry-identity-flag { font-size: 1.8rem; margin-bottom: .4rem; }
.ministry-sidebar .ministry-identity-country { font-size: .75rem; }
.ministry-sidebar .ministry-identity-org { font-size: .8rem; }
.ministry-sidebar .nav-link.custom-links { margin: .15rem .4rem; padding: .6rem .65rem; font-size: .85rem; }
.ministry-executive-dashboard { padding: 1.75rem .5rem 2rem !important; max-width: 1800px; margin-inline: auto; font-size: .875rem; line-height: 1.55; }
.ministry-executive-dashboard .ministry-masthead { border: 0; padding-bottom: 0 !important; margin-bottom: 1.5rem !important; align-items: flex-start !important; }
.ministry-executive-dashboard .ministry-masthead > div:first-child { flex: 1 1 420px; min-width: 0; }
.ministry-executive-dashboard .ministry-masthead h1 { font-size: clamp(1.65rem, 2vw, 2.2rem); font-weight: 700; letter-spacing: -.04em; color: #102331; line-height: 1.2; }
.ministry-executive-dashboard .ministry-masthead-eyebrow { color: #526c78; font-size: .65rem; letter-spacing: .2em; margin-bottom: .5rem !important; }
.ministry-executive-dashboard .ministry-masthead .text-muted { font-size: .9rem; }
.ministry-executive-dashboard .ministry-masthead-identity { flex: 0 0 auto; white-space: nowrap; max-width: none; margin-left: auto; padding: .35rem 0 0; border: 0; gap: 1.4rem !important; }
.ministry-masthead-right { display: flex; flex-direction: column; align-items: flex-end; gap: .85rem; margin-left: auto; flex: 0 0 auto; }
.ministry-period-control { position: relative; width: 204px; }
.ministry-period-control > .bi { position: absolute; left: .8rem; top: 50%; transform: translateY(-50%); line-height: 1; color: #174d40; pointer-events: none; }
.ministry-period-control .form-select { width: 100%; padding: .45rem 2rem .45rem 2.45rem; font-size: .75rem; color: #294a61; background-color: #fff; border: 1px solid #cfdde6; border-radius: 6px; box-shadow: none; cursor: pointer; }
.ministry-period-control .form-select:focus { border-color: #44896c; box-shadow: 0 0 0 3px #44896c1f; }
.ministry-masthead-flat-flag { display: block; width: 64px; height: 48px; aspect-ratio: 4 / 3; object-fit: contain; flex: 0 0 auto; }
.ministry-masthead-ministry { display: flex; align-items: center; gap: .9rem; padding-left: 1.4rem; border-left: 1px solid #adbdc9; color: #073b30; }
.ministry-masthead-emblem { display: block; width: 44px; height: 48px; flex: 0 0 auto; }
.ministry-executive-dashboard .ministry-masthead-ministry .ministry-masthead-org { font-size: .95rem; font-weight: 650; letter-spacing: .055em; line-height: 1.3; }
.ministry-executive-dashboard .ministry-masthead-flag { font-size: 2rem; }
.ministry-executive-dashboard .ministry-masthead-org { color: #174d40; font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; line-height: 1.5; }
.ministry-executive-dashboard .card { background: #fff; border: 1px solid #e1e8ec !important; border-radius: 12px; box-shadow: 0 2px 6px #153a4c03 !important; overflow: hidden; }
.ministry-executive-dashboard .card-body { padding: 1.1rem !important; }
.ministry-executive-dashboard h2 { font-weight: 650; font-size: .95rem; letter-spacing: -.02em; color: #183443; line-height: 1.4; }
.ministry-executive-dashboard .text-muted { color: #6c818e !important; }
.ministry-executive-dashboard h2 + p { font-size: .73rem !important; margin-bottom: 1.1rem !important; }
.ministry-executive-dashboard .ministry-stat-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: .85rem; margin: 0 0 1.1rem !important; }
.ministry-executive-dashboard .ministry-stat-column { grid-column: span 3; width: auto; padding: 0; margin: 0; min-width: 0; }
.ministry-executive-dashboard .ministry-stat-card .card-body { position: relative; display: grid; grid-template-columns: 48px minmax(0, 1fr); gap: .25rem .8rem; align-content: start; min-height: 132px; padding: .9rem !important; }
.ministry-executive-dashboard .stat-tile-icon { grid-column: 1; grid-row: 1 / 4; width: 48px; height: 48px; margin: 0 !important; font-size: 1.4rem; background: linear-gradient(145deg, #26765b, #0b4837) !important; color: #fff !important; border-radius: 50%; }
.ministry-executive-dashboard .ministry-stat-card p { grid-column: 2; overflow-wrap: normal; word-break: normal; }
.ministry-executive-dashboard .ministry-stat-card p:first-of-type { grid-column: 2; color: #193044 !important; font-size: .72rem; font-weight: 600; line-height: 1.35; margin: 0 !important; min-height: 1.9rem; }
.ministry-executive-dashboard .ministry-stat-card .fs-4 { color: #122f3e; font-size: 1.65rem !important; font-weight: 700 !important; letter-spacing: -.035em; line-height: 1.2; margin: 0 !important; }
.ministry-executive-dashboard .ministry-stat-card .ministry-stat-change { display: flex; flex-wrap: wrap; align-items: baseline; gap: .15rem .4rem; font-size: .63rem; line-height: 1.4; margin-top: .15rem !important; }
.ministry-executive-dashboard .ministry-stat-delta { white-space: nowrap; font-weight: 650; font-size: .72rem; }
.ministry-executive-dashboard .ministry-stat-change-context { color: #82939c; }
.ministry-executive-dashboard .text-danger { color: #be4c50 !important; }
.ministry-executive-dashboard .text-success { color: #287354 !important; }
.ministry-overview-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(250px, 1fr); gap: 1rem; margin-bottom: 1rem; }
.ministry-overview-grid > *, .ministry-distribution-grid > * { min-width: 0; }
.ministry-regional-content { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1.25rem; align-items: center; }
.ministry-regional-content-with-map { grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); }
.ministry-regional-content > * { min-width: 0; }
.ministry-executive-dashboard .ministry-regional-card { margin-bottom: 0 !important; }
.ministry-executive-dashboard #ministry-region-map { height: clamp(360px, 28vw, 460px) !important; background: #fafcfb !important; }
.ministry-executive-dashboard .ministry-trend-card figure > svg { height: 250px; }
.ministry-executive-dashboard figure > .d-flex { gap: 1rem !important; }
.ministry-executive-dashboard figure svg { max-width: 100%; }
.ministry-executive-dashboard details { margin-top: .8rem !important; border-top: 1px solid #eef2f4; padding-top: .65rem; }
.ministry-executive-dashboard details summary { font-size: .67rem !important; color: #718895 !important; }
.ministry-executive-dashboard details[open] { overflow-x: auto; }
.ministry-executive-dashboard .ministry-key-points { font-size: .77rem; line-height: 1.65; }
.ministry-executive-dashboard .ministry-key-points li { padding: .85rem 0; border-bottom: 1px solid #edf2f4; margin: 0 !important; gap: .75rem !important; }
.ministry-executive-dashboard .ministry-key-points li:last-child { border: 0; padding-bottom: 0; }
.ministry-executive-dashboard .ministry-key-points li > .bi {
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: .1rem;
  border: 1px solid #dcebe3;
  border-radius: 50%;
  background: #edf6f2;
  color: #287354;
  font-size: 1.1rem;
  line-height: 1;
}
.ministry-executive-dashboard .ministry-key-points li > .bi::before { display: block; line-height: 1; vertical-align: 0; }
.ministry-executive-dashboard .ministry-key-points li > .bi.text-warning { color: #a86b13 !important; background: #fff6e7; border-color: #f2e3c7; }
.ministry-executive-dashboard .ministry-key-points li > .bi.text-danger { background: #fcf0f0; border-color: #f0dddd; }
.ministry-executive-dashboard .ministry-key-points li > div { flex: 1; min-width: 0; }
.ministry-executive-dashboard .ministry-key-points .text-primary { color: #287354 !important; }
.ministry-executive-dashboard .ministry-distribution-grid { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, 1fr); gap: 1rem; margin-bottom: 1rem; }
.ministry-executive-dashboard .ministry-stat-column:nth-child(n + 5) { grid-column: span 4; }
@media (min-width: 2200px) {
  .ministry-executive-dashboard .ministry-stat-grid { grid-template-columns: repeat(7, minmax(0, 1fr)); }
  .ministry-executive-dashboard .ministry-stat-column { grid-column: auto; }
  .ministry-executive-dashboard .ministry-stat-column:nth-child(n + 5) { grid-column: auto; }
}
@media (max-width: 1199.98px) {
  .ministry-executive-dashboard .ministry-stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ministry-executive-dashboard .ministry-stat-column, .ministry-executive-dashboard .ministry-stat-column:nth-child(n + 5) { grid-column: auto; }
  .ministry-overview-grid { grid-template-columns: minmax(0, 1fr); }
  .ministry-executive-dashboard .ministry-distribution-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ministry-trend-card { grid-column: 1 / -1; }
  .ministry-key-points-card { grid-column: 1 / -1; }
  .ministry-executive-dashboard .ministry-key-points { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 1.5rem; }
}
@media (max-width: 767.98px) {
  .ministry-executive-dashboard { padding: 1.25rem 0 !important; }
  .ministry-executive-dashboard .ministry-stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .65rem; }
  .ministry-executive-dashboard .ministry-stat-card .card-body { grid-template-columns: minmax(0, 1fr); padding: .85rem !important; }
  .ministry-executive-dashboard .stat-tile-icon { grid-column: 1; grid-row: auto; }
  .ministry-executive-dashboard .ministry-stat-card p { grid-column: 1; }
  .ministry-executive-dashboard .ministry-stat-card p:first-of-type { grid-column: 1; min-height: 0; }
  .ministry-executive-dashboard .ministry-stat-card .fs-4 { font-size: 1.5rem !important; }
  .ministry-overview-grid { grid-template-columns: minmax(0, 1fr); }
  .ministry-executive-dashboard .ministry-key-points { display: block; }
  .ministry-regional-content-with-map { grid-template-columns: minmax(0, 1fr); }
  .ministry-executive-dashboard .ministry-distribution-grid { grid-template-columns: minmax(0, 1fr); }
  .ministry-executive-dashboard .ministry-masthead-identity { margin-left: 0; }
  .ministry-masthead-right { margin-left: 0; align-items: flex-start; }
}

/* Regional rankings retain readable labels at the card's actual width. */
.ministry-horizontal-bars { display: grid; grid-template-columns: minmax(90px, 1.2fr) minmax(70px, 1.8fr) max-content; align-items: start; gap: .75rem; }
.ministry-horizontal-bar-labels, .ministry-horizontal-bar-values { display: flex; flex-direction: column; min-width: 0; }
.ministry-horizontal-bar-labels span, .ministry-horizontal-bar-values span { display: flex; align-items: center; height: 32px; font-size: .72rem; }
.ministry-horizontal-bar-labels span { display: block; line-height: 32px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #536d79; }
.ministry-horizontal-bar-values span { justify-content: flex-end; font-weight: 600; color: #193044; font-variant-numeric: tabular-nums; }

/* Ministry portals use the full-height sidebar instead of the shared top bar. */
.ministry-portal .ministry-sidebar { top: 0; padding-top: 0; container-type: inline-size; }
.ministry-portal .ministry-sidebar .sidebar-sticky { height: 100vh; height: 100dvh; padding-top: .5rem !important; }
.ministry-sidebar .px-3 { padding-left: .75rem !important; padding-right: .75rem !important; }
.ministry-sidebar-brand { display: flex; align-items: center; gap: .5rem; padding-block: .6rem .9rem; color: #fff; text-transform: uppercase; }
.ministry-sidebar-globe { display: block; flex: 0 0 auto; width: clamp(56px, 30cqw, 80px); height: auto; aspect-ratio: 1; object-fit: contain; }
.ministry-sidebar-wordmark { border-left: 1px solid #ffffff70; padding-left: .5rem; font-size: clamp(.75rem, 5.4cqw, 1rem); font-weight: 400; letter-spacing: .12em; line-height: 1.35; }
.ministry-mobile-menu { position: fixed; top: .75rem; right: .75rem; z-index: 110; display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; border: 1px solid #d7e3de; border-radius: 8px; background: #fff; color: #174d40; box-shadow: 0 2px 8px #153a4c12; }
.ministry-mobile-menu > .bi { display: flex; font-size: 1.4rem; line-height: 1; }
.ministry-mobile-menu:focus-visible { outline: 2px solid #44896c; outline-offset: 3px; }
@media (max-width: 767.98px) {
  .ministry-portal main { padding-top: 3.5rem; }
  .ministry-portal .ministry-sidebar { right: 0; }
  .ministry-sidebar-brand { padding-right: 4rem !important; }
}

/* National identity sits below ministry navigation, as in the reference. */
.ministry-national-identity { flex: 0 0 auto; padding: 1rem 1rem .5rem; color: #f4faf7; }
.ministry-national-map { display: block; width: clamp(120px, 75cqw, 180px); height: auto; margin: 0 auto .55rem; }
.ministry-national-country { margin: 0 0 .4rem; font-size: 1.35rem; font-weight: 600; letter-spacing: .22em; line-height: 1.3; text-transform: uppercase; }
.ministry-national-system { margin: 0; font-size: .73rem; font-weight: 400; letter-spacing: .055em; line-height: 1.6; text-transform: uppercase; }

/* One account row replaces the repeated ministry role and profile labels. */
.ministry-sidebar-account { display: grid; grid-template-columns: 28px minmax(0, 1fr) 32px; align-items: center; gap: .5rem; flex: 0 0 auto; margin: .75rem .75rem 0; padding: .75rem 0; border-top: 1px solid #ffffff26; color: #e4f0eb; }
.ministry-account-avatar { display: flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 50%; background: #ffffff12; }
.ministry-account-avatar > .bi, .ministry-account-signout > .bi { display: flex; line-height: 1; font-size: 1rem; }
.ministry-account-name { color: inherit; text-decoration: none; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .75rem; line-height: 1.4; }
.ministry-account-signout-form { margin: 0; }
.ministry-account-signout { display: flex; align-items: center; justify-content: center; width: 32px; height: 32px; padding: 0; border: 0; border-radius: 6px; background: transparent; color: #d2e7de; cursor: pointer; }
.ministry-account-signout:hover { background: #ffffff12; color: #fff; }
.ministry-account-signout:focus-visible { outline: 2px solid #bce0ce; outline-offset: 2px; }

.ministry-account-name:hover { color: #fff; text-decoration: underline; text-underline-offset: .2em; }
.ministry-account-name:focus-visible { outline: 2px solid #bce0ce; outline-offset: 3px; border-radius: 2px; }

/* Regular form submission makes sign-out independent of Turbo navigation. */
.sidebar-signout-button { border: 0; background: transparent; text-align: left; }
