/* ============================================================
   Office map — ported from the internal HR-landing reference
   (self-contained interactive world map of TMRW offices).
   OS design tokens are re-declared here (unique names, no clash
   with tokens.css --color-*) and mapped to the tmrw.com palette.
   ============================================================ */
:root {
  --paper: #fbf9f0;
  --ink: #1f1f1f;
  --card: #ffffff;
  --blue: #1832ba;
  --blue-hover: #0f1f8c;
  --muted: #6b6b6b;
  --faint: #717171;
  --border: rgba(31, 31, 31, 0.11);
  --border-strong: rgba(31, 31, 31, 0.22);
  --secondary: rgba(0, 0, 0, 0.03);
  --hover: rgba(0, 0, 0, 0.04);
  --r-sm: 4px;
  --r-md: 5px;
  --r-lg: 8px;
  --sans: var(--font-sans, "Söhne Buch", "Helvetica Neue", Arial, system-ui, sans-serif);
  --m-land: #e6e4e0;
  --m-land-border: #d4d2cd;
  --m-office: #dde2f1;
  --m-office-hover: #c8d0ed;
  --m-office-border: #92a1db;
  --m-planned-ring: #a76b1a;
  --m-planned-text: #855210;
}

.hrx-map { display: flex; flex-direction: column; gap: 16px; margin-top: 32px; }
@media (min-width: 1024px) {
  .hrx-map { flex-direction: row; }
}
.hrx-map-card { position: relative; flex: 1; min-height: 300px; overflow: hidden; border: 1px solid var(--border); background: var(--card); border-radius: var(--r-lg); }
#wf-map { display: block; width: 100%; height: 100%; cursor: grab; touch-action: none; user-select: none; }
#wf-map:active { cursor: grabbing; }
#wf-map .wf-office { cursor: pointer; transition: fill 150ms ease; }
#wf-map .wf-marker { cursor: pointer; }
#wf-map .wf-label { pointer-events: none; transition: opacity 150ms ease; }
.hrx-map-zoom { position: absolute; top: 14px; right: 14px; display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--border); background: var(--card); border-radius: var(--r-md); }
.hrx-map-zoom button { width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; border: none; border-bottom: 1px solid var(--border); background: var(--card); color: var(--muted); cursor: pointer; }
.hrx-map-zoom button:last-child { border-bottom: none; }
.hrx-map-zoom button:hover { background: var(--hover); color: var(--ink); }
.hrx-map-zoom svg { width: 18px; height: 18px; }
.hrx-map-legend { position: absolute; left: 14px; bottom: 14px; display: flex; flex-direction: column; gap: 6px; border: 1px solid var(--border); background: rgba(255, 255, 255, 0.94); border-radius: var(--r-md); padding: 10px 12px; }
.hrx-legend-row { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); }
.hrx-dot { width: 11px; height: 11px; border-radius: 999px; flex: none; }
.hrx-dot--active { background: var(--blue); border: 1.5px solid #fff; box-shadow: 0 0 0 1px var(--border); }
.hrx-dot--soon { background: #fff; border: 1.5px dashed var(--m-planned-ring); }
.hrx-map-panel { display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--border); background: var(--card); border-radius: var(--r-lg); flex: none; }
@media (min-width: 1024px) {
  .hrx-map-panel { width: 344px; }
}
.hrx-map-stats { display: flex; border-bottom: 1px solid var(--border); margin: 0; }
.hrx-map-stats > div { flex: 1; padding: 18px 20px; }
.hrx-map-stats > div:first-child { border-right: 1px solid var(--border); }
.hrx-map-stats dd { margin: 0; font-size: 36px; font-weight: 500; line-height: 1; letter-spacing: -0.01em; }
.hrx-map-stats dt { margin-top: 8px; font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--faint); }
.hrx-map-list { flex: 1; min-height: 0; overflow-y: auto; padding: 14px; max-height: 420px; }
.hrx-list-row { display: block; width: 100%; text-align: left; background: none; border: none; font: inherit; cursor: pointer; padding: 12px; border-radius: var(--r-md); margin-bottom: 2px; transition: background 150ms ease; }
.hrx-list-row:hover, .hrx-list-row.is-hover { background: var(--hover); }
.hrx-list-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.hrx-list-left { display: flex; align-items: center; gap: 10px; min-width: 0; }
.hrx-list-entity { font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hrx-dot-sm { width: 10px; height: 10px; border-radius: 999px; flex: none; }
.hrx-list-count { flex: none; font-size: 12px; color: var(--faint); }
.hrx-list-offices { margin-top: 4px; padding-left: 22px; display: flex; flex-direction: column; gap: 4px; }
.hrx-list-office { display: flex; align-items: baseline; gap: 8px; }
.hrx-list-office .city { font-size: 13px; }
.hrx-list-office .div { font-size: 13px; color: var(--muted); }
.hrx-map-foot { flex: none; border-top: 1px solid var(--border); padding: 14px 20px; font-size: 13px; line-height: 1.4; color: var(--muted); }
.wf-drawer { margin: 0; margin-left: auto; height: 100%; max-height: 100%; width: 480px; max-width: 100%; padding: 0; border: none; border-left: 1px solid var(--border); background: var(--card); color: var(--ink); box-shadow: 0 12px 32px rgba(0, 0, 0, 0.14); }
.wf-drawer:not([open]) { display: none; }
.wf-drawer[open] { display: flex; flex-direction: column; animation: wfDrawerIn 0.45s cubic-bezier(0.2, 0, 0.2, 1); }
.wf-drawer::backdrop { background: rgba(17, 17, 16, 0.4); }
.wf-drawer[open]::backdrop { animation: wfScrimIn 0.3s ease; }
.wf-drawer-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; border-bottom: 1px solid var(--border); padding: 24px 24px 18px; }
.wf-drawer-country { font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--faint); margin-bottom: 8px; }
.wf-drawer-entity { font-size: 24px; line-height: 1.2; letter-spacing: -0.01em; }
.wf-drawer-close { width: 36px; height: 36px; flex: none; display: flex; align-items: center; justify-content: center; border: 1px solid var(--border); background: var(--card); border-radius: var(--r-md); color: var(--muted); cursor: pointer; }
.wf-drawer-close:hover { border-color: var(--border-strong); background: var(--hover); color: var(--ink); }
.wf-drawer-body { flex: 1; min-height: 0; overflow-y: auto; padding: 8px 24px 28px; }
.wf-office { padding: 20px 0; border-bottom: 1px solid var(--border); }
.wf-office:last-child { border-bottom: none; }
.wf-office-div { font-size: 12px; font-weight: 500; letter-spacing: 0.06em; text-transform: uppercase; }
.wf-office-city { font-size: 22px; line-height: 1.2; letter-spacing: -0.01em; margin: 6px 0 14px; }
.wf-office-addr { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 12px; font-size: 15px; line-height: 1.45; color: var(--muted); white-space: pre-line; }
.wf-office-addr svg { width: 18px; height: 18px; flex: none; margin-top: 2px; color: var(--faint); }
.wf-office-desc { font-size: 15px; line-height: 1.5; }
/* --- Fixes: drawer focus ring + close-icon sizing --- */
.wf-drawer:focus, .wf-drawer:focus-visible { outline: none; }
.wf-drawer-close svg { width: 18px; height: 18px; display: block; }
.wf-drawer-close:focus { outline: none; }
.wf-drawer-close:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }

/* --- Drawer entrance: slide from right + scrim fade --- */
@keyframes wfDrawerIn {
  from { transform: translateX(100%); }
  to { transform: translateX(0); }
}
@keyframes wfScrimIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .wf-drawer[open], .wf-drawer[open]::backdrop { animation: none; }
}
