/* HR-management presentation layer. Business controls remain owned by plugins. */
:root {
  --hrm-surface: #fff;
  --hrm-border: #d7e2e5;
  --hrm-subtle: #eff5f3;
  --hrm-muted: #526774;
  --hrm-green: #076859;
  --hrm-shadow: 0 10px 32px rgb(17 40 63 / 4%);
}

.hrm-portal {
  padding-block: 44px 76px;
  overflow-wrap: anywhere;
}

.hrm-portal-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin-block-end: 30px;
}

.hrm-portal-heading h1 {
  margin-block: 10px 12px;
  font-size: clamp(2rem, 3.4vw, 3rem);
  letter-spacing: -.04em;
  line-height: 1.15;
}

.hrm-portal-heading p {
  max-width: 720px;
  color: var(--hrm-muted);
  font-size: .95rem;
  margin: 0;
}

.hrm-role,
.hrm-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 12px;
  border: 1px solid #c5ded6;
  border-radius: 999px;
  background: #e8f5ef;
  color: var(--hrm-green);
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .015em;
  line-height: 1.6;
}

.hrm-role { margin-block-start: 12px; }

.hrm-portal-layout {
  display: grid;
  grid-template-columns: 246px minmax(0, 1fr);
  gap: 28px;
  align-items: start;
}

.hrm-sidebar {
  position: sticky;
  inset-block-start: 116px;
  padding: 12px;
  background: var(--hrm-surface);
  border: 1px solid var(--hrm-border);
  border-radius: 18px;
  box-shadow: var(--hrm-shadow);
}

.admin-bar .hrm-sidebar { inset-block-start: 148px; }
.hrm-sidebar nav { margin: 0; }
.hrm-nav-list,
.hrm-nav-list ul { margin: 0; padding: 0; list-style: none; }
.hrm-nav-list li { margin-block: 3px; }
.hrm-nav-list a {
  min-height: 46px;
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 10px 13px;
  border: 1px solid transparent;
  border-radius: 10px;
  color: #334e60;
  text-decoration: none;
  font-size: .875rem;
  font-weight: 600;
  line-height: 1.5;
}
.hrm-nav-list a svg { width: 19px; height: 19px; flex-shrink: 0; }
.hrm-nav-list a:hover { background: #f1f6f5; color: var(--wv-navy); }
.hrm-nav-list a.is-current,
.hrm-nav-list .is-current > a,
.hrm-nav-list a[aria-current="page"] {
  background: #e8f4f0;
  border-color: #d0e5dc;
  color: #085d50;
  font-weight: 750;
}
.hrm-sidebar-note {
  margin: 16px 8px 4px;
  padding-block-start: 16px;
  border-block-start: 1px solid var(--hrm-border);
  color: var(--hrm-muted);
  font-size: .75rem;
  line-height: 1.65;
}
.hrm-sidebar-note p { margin-block-end: 8px; }

.hrm-portal-main,
.hrm-panel,
.hrm-module-output { min-width: 0; max-width: 100%; }
.hrm-portal-breadcrumb {
  margin-block-end: 16px;
  color: var(--hrm-muted);
  font-size: .8125rem;
}
.hrm-portal-breadcrumb a { text-underline-offset: 3px; }
.hrm-panel {
  padding: clamp(20px, 3vw, 36px);
  border: 1px solid var(--hrm-border);
  border-radius: 20px;
  background: var(--hrm-surface);
  box-shadow: var(--hrm-shadow);
}
.hrm-panel > h2,
.hrm-intro-card h2 {
  font-size: clamp(1.5rem, 2.4vw, 2rem);
  line-height: 1.2;
  margin-block-end: 12px;
}
.hrm-panel > p { color: var(--hrm-muted); }

.hrm-intro-card {
  padding: clamp(24px, 3vw, 36px);
  margin-block-end: 24px;
  border-radius: 20px;
  background: var(--wv-navy);
  color: #fff;
  border: 1px solid var(--wv-navy);
}
.hrm-intro-card p { max-width: 690px; color: #d0e1e9; font-size: .9375rem; }
.hrm-intro-card .wv-kicker { color: #89e3d4; margin-block-end: 14px; }
.hrm-intro-card a:not(.wv-btn) { color: #a4eee1; text-underline-offset: 4px; }
.hrm-intro-card p:last-child { margin-block-end: 0; }

.hrm-module-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.hrm-module-card {
  min-width: 0;
  padding: 26px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  border: 1px solid var(--hrm-border);
  border-radius: 16px;
  background: var(--hrm-surface);
  box-shadow: var(--hrm-shadow);
}
.hrm-module-icon {
  width: 44px;
  height: 44px;
  display: inline-grid;
  place-items: center;
  margin-block-end: 20px;
  border-radius: 12px;
  background: #eaf5f0;
  color: var(--hrm-green);
}
.hrm-module-icon svg { width: 23px; height: 23px; }
.hrm-module-card h2,
.hrm-module-card h3 {
  margin-block: 0 10px;
  font-size: 1.2rem;
  letter-spacing: -.025em;
  line-height: 1.3;
}
.hrm-module-card p { color: var(--hrm-muted); font-size: .875rem; margin-block-end: 18px; }
.hrm-module-card .hrm-status { margin-block-end: 14px; }
.hrm-card-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  margin-block-start: auto;
  padding-block: 10px;
  color: #076557;
  font-size: .875rem;
  font-weight: 750;
  text-decoration-thickness: 1px;
  text-underline-offset: 5px;
}
.hrm-card-link svg { width: 17px; height: 17px; }
.hrm-empty-state {
  padding: clamp(24px, 4vw, 48px);
  border: 1px dashed #bfced4;
  border-radius: 16px;
  background: #f7faf9;
  text-align: start;
}
.hrm-empty-state h2 { font-size: 1.6rem; line-height: 1.2; }
.hrm-empty-state p { color: var(--hrm-muted); max-width: 650px; }
.hrm-account-actions { display: flex; flex-wrap: wrap; gap: 10px 18px; margin-block-start: 24px; }
.hrm-account-actions a { min-height: 44px; display: inline-flex; align-items: center; text-underline-offset: 4px; }
.hrm-account-actions .wv-btn { padding-inline: 20px; }

/* Only the theme's language controls are styled here, not plugin-owned inputs. */
.hrm-language-tools { max-width: 100%; }
.hrm-language-form {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 8px;
  margin: 0;
}
.hrm-language-form label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  color: #334e60;
  font-size: .75rem;
  font-weight: 650;
}
.hrm-language-form select {
  min-height: 44px;
  width: 100%;
  max-width: 200px;
  padding-block: 8px;
  padding-inline: 10px 28px;
  border: 1px solid #a9bcc5;
  border-radius: 8px;
  background-color: #fff;
  color: var(--wv-navy);
  font-size: .8125rem;
}
.hrm-language-form button {
  min-height: 44px;
  padding: 8px 13px;
  border: 1px solid #a9bcc5;
  border-radius: 8px;
  background: #f1f6f4;
  color: var(--wv-navy);
  font-size: .8125rem;
  font-weight: 700;
}
.hrm-language-form button:hover { background: #e1eee8; }
.hrm-portal :is(a, button, input, select, textarea, summary):focus-visible,
.hrm-language-tools :is(a, button, select):focus-visible {
  outline: 3px solid var(--wv-navy);
  outline-offset: 3px;
  box-shadow: 0 0 0 5px #fff;
}
.hrm-intro-card a:focus-visible { outline-color: #8ee8d5; box-shadow: none; }
.hrm-module-output { overflow-wrap: anywhere; }
.hrm-module-output > :first-child { margin-block-start: 0; }
.hrm-module-output pre { max-width: 100%; overflow-x: auto; }
.hrm-module-output img { height: auto; }
.hrm-module-output [class$="table-wrap"],
.hrm-module-output [class$="table-scroll"] { overflow-x: auto; max-width: 100%; }

/* Header remains usable when the language selector is enabled. */
.wv-header-inner > * { min-width: 0; }
.wv-header .wv-menu-toggle { min-height: 44px; min-width: 44px; }
.wv-header .wv-portal-link { min-height: 44px; }
.wv-header .hrm-language-form select { max-width: 142px; }
.wv-header .hrm-language-form label { font-size: .6875rem; }

@media (min-width: 961px) and (max-width: 1220px) {
  .wv-header-inner { flex-wrap: wrap; padding-block: 14px; gap: 14px 20px; }
  .wv-header #wv-navigation { order: 3; width: 100%; }
  .wv-header .hrm-language-tools { margin-inline-start: auto; }
}
@media (max-width: 960px) {
  .hrm-portal { padding-block: 32px 56px; }
  .hrm-portal-layout { grid-template-columns: minmax(0, 1fr); gap: 22px; }
  .hrm-sidebar,
  .admin-bar .hrm-sidebar { position: static; }
  .hrm-nav-list { display: flex; flex-wrap: wrap; gap: 4px; }
  .hrm-nav-list li { margin: 0; }
  .hrm-nav-list a { padding-inline: 12px; }
  .hrm-sidebar-note { margin-block-start: 10px; padding-block-start: 10px; }
  .hrm-sidebar-note p:last-child { margin-block-end: 0; }
  .wv-header .hrm-language-tools { order: 5; flex-basis: 100%; }
  .wv-header .hrm-language-form { justify-content: flex-start; align-items: center; }
  .wv-header .hrm-language-form label { flex-direction: row; align-items: center; gap: 8px; }
}
@media (max-width: 600px) {
  .hrm-portal { padding-block-start: 26px; }
  .hrm-portal-heading { flex-direction: column; gap: 12px; margin-block-end: 22px; }
  .hrm-portal-heading h1 { font-size: 2rem; }
  .hrm-portal-heading p { font-size: .875rem; }
  .hrm-role { margin: 0; }
  .hrm-module-grid { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .hrm-module-card { padding: 22px; }
  .hrm-panel { padding: 20px 16px; border-radius: 16px; }
  .hrm-intro-card { padding: 25px 22px; border-radius: 16px; }
  .hrm-nav-list { gap: 3px; }
  .hrm-nav-list li { flex: 1 1 calc(50% - 3px); }
  .hrm-nav-list a { height: 100%; min-height: 46px; font-size: .8125rem; }
  .hrm-account-actions { flex-direction: column; align-items: flex-start; gap: 5px; }
  .hrm-account-actions .wv-btn { width: 100%; }
  .wv-header .hrm-language-form { gap: 6px; }
  .wv-header .hrm-language-form label { font-size: .75rem; }
  .wv-header .hrm-language-form select { max-width: 140px; }
}
@media (prefers-reduced-motion: reduce) {
  .hrm-portal *, .hrm-language-tools * { scroll-behavior: auto; transition: none; animation: none; }
}
@media print {
  .hrm-sidebar, .hrm-account-actions, .hrm-language-tools { display: none; }
  .hrm-portal { padding: 0; }
  .hrm-portal-layout { display: block; }
  .hrm-panel, .hrm-module-card, .hrm-intro-card { box-shadow: none; border-color: #777; background: #fff; color: #000; }
  .hrm-intro-card p, .hrm-intro-card .wv-kicker { color: #000; }
  .hrm-module-card { break-inside: avoid; }
}

/* Compact language controls keep the main navigation on one row. */
.wv-header .hrm-language-form label { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }
.wv-header .hrm-language-form { flex-wrap:nowrap; }
.wv-header .hrm-language-form select { width:auto; min-width:110px; }
.hrm-language-tools ul { display:flex; flex-wrap:wrap; list-style:none; gap:10px; padding:0; margin:0; }
.hrm-language-tools li a { display:inline-flex; min-height:44px; align-items:center; }
.wv-feature-grid h2 { font-size:23px; line-height:1.25; margin-block:24px 16px; }
.hrm-search-form { display:flex; flex-wrap:wrap; gap:12px; align-items:center; margin-block:24px; }
.hrm-search-form label { flex-basis:100%; }
.hrm-search-form input { min-width:0; min-height:48px; padding:10px 14px; border:1px solid #a9bcc5; border-radius:8px; flex:1 1 180px; }
.wv-header :is(a,button,select):focus-visible, .wv-content :is(a,button,input):focus-visible { outline:3px solid #08796f; outline-offset:3px; box-shadow:0 0 0 5px #fff; }
@media(max-width:960px) { .wv-header { position:relative; top:auto; } .admin-bar .wv-header { top:auto; } html { scroll-padding-top:24px; } .hrm-sidebar { position:static; } }

/* Keep long translated labels and contacts within the existing mobile layout. */
.wv-header .wv-portal-link { max-width:100%; white-space:normal; overflow-wrap:anywhere; text-align:center; }
.wv-header #wv-navigation ul ul { inset-inline-start:0; inset-inline-end:auto; }
.wv-contact-links { min-width:0; max-width:100%; overflow-wrap:anywhere; }
.wv-footer-top > div,
.wv-footer-bottom > * { min-width:0; overflow-wrap:anywhere; }
.wv-footer-bottom { flex-wrap:wrap; }
@media (max-width:600px) {
  .wv-header .wv-portal-link { font-size:.75rem; }
  .wv-contact-links { flex-shrink:1; }
}
