/* PL: Panel klienta w stylu synlogia.com (rozkaz Szymona 28.10.2026): jasne tło w kratkę, ostre rogi,
   nagłówki Nasalization wielkimi literami, granat i magenta Global Synlogia, przyciski jak na stronie.
   EN: The client panel in the synlogia.com style: a light grid background, sharp corners, Nasalization
   upper-case headings, the Global Synlogia navy and magenta, the site's buttons. */

@font-face {
  font-family: Nasalization;
  src: url("fonts/nasalization.663c62572f93.otf") format("opentype");
  font-display: swap;
}

:root {
  --blue: #124f9e;
  --magenta: #e31b54;
  --ink: #0a0a0a;
  --muted: #4b5263;
  --line: #0000001a;
  --grid: #0000000d;
  --card: #fff;
  --done: #15803d;
  --done-bg: #ecfdf5;
}

* {
  box-sizing: border-box;
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  margin: 0;
  background-color: #f8f9fa;
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 48px 48px;
  color: var(--ink);
  font-family: ui-sans-serif, system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.5;
}

.top {
  border-bottom: 1px solid var(--line);
  background: var(--card);
}

.top__bar {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  min-height: 64px;
  padding: 0 20px;
}

.top__logo {
  width: auto;
  height: 34px;
}

.top__account {
  display: flex;
  gap: 16px;
  align-items: center;
}

.top__profile {
  display: flex;
  gap: 10px;
  align-items: center;
}

.top__avatar {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--magenta);
  color: #fff;
  font-weight: 600;
}

.top__who {
  display: grid;
  min-width: 0;
  max-width: 240px;
  line-height: 1.2;
}

.top__name {
  overflow: hidden;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.top__login {
  overflow: hidden;
  font-size: 12px;
  color: var(--muted);
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 520px) {
  .top__who {
    display: none;
  }
}

.page,
.foot {
  width: 100%;
  padding: 0 24px;
}

.link {
  padding: 0;
  border: 0;
  background: none;
  color: var(--ink);
  font: inherit;
  text-decoration: none;
  cursor: pointer;
}

.link:hover {
  color: var(--magenta);
}

.frame {
  display: flex;
  flex: 1;
}

.body {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-width: 0;
}

/* PL: Boczne menu czarne jak w Synlogia Hub; na telefonie pasek pod górnym.
   EN: The black side menu as in Synlogia Hub; a bar below the top one on a phone. */
.side {
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  gap: 4px;
  width: 220px;
  padding: 16px 12px;
  background: #0f1928;
}

.side a {
  padding: 10px 14px;
  color: #c3c6ca;
  text-decoration: none;
}

.side a:hover {
  background: #3f4753;
  color: #fff;
}

.side a[aria-current="page"] {
  background: var(--blue);
  color: #fff;
}

@media (width <= 860px) {
  .frame {
    flex-direction: column;
  }

  .side {
    flex-flow: row wrap;
    width: auto;
    padding: 8px 12px;
  }

  .side a {
    padding: 8px 12px;
  }

  .top__bar {
    padding: 0 16px;
  }

  .top__logo {
    height: 28px;
  }
}

.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 20px;
  border-bottom: 1px solid var(--line);
}

.tabs a {
  margin-bottom: -1px;
  padding: 6px 0;
  border-bottom: 2px solid transparent;
  color: var(--muted);
  text-decoration: none;
}

.tabs a:hover {
  color: var(--magenta);
}

.tabs a[aria-current="page"] {
  border-bottom-color: var(--magenta);
  color: var(--ink);
  font-weight: 600;
}

.facts {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 10px 20px;
  margin: 0;
}

.facts dt {
  color: var(--muted);
}

.facts dd {
  margin: 0;
  overflow-wrap: anywhere;
}

.page {
  flex: 1;
  padding-top: 40px;
  padding-bottom: 40px;
}

.foot {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: space-between;
  padding-top: 16px;
  padding-bottom: 24px;
  color: var(--muted);
  font-size: 14px;
}

.foot a {
  color: var(--muted);
}

.card {
  display: grid;
  gap: 18px;
  width: 100%;
  padding: 24px;
  border: 1px solid var(--line);
  background: var(--card);
}

.card--narrow {
  width: min(420px, 100%);
  margin: 0 auto;
}

.title {
  margin: 0;
  font-family: Nasalization, sans-serif;
  font-size: 26px;
  font-weight: 400;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.note {
  margin: 0;
  color: var(--muted);
}

.alert {
  margin: 0;
  padding: 10px 12px;
  border-left: 3px solid var(--magenta);
  background: #fff1f4;
  color: #9f1239;
}

.done {
  margin: 0;
  padding: 10px 12px;
  border-left: 3px solid var(--done);
  background: var(--done-bg);
  color: var(--done);
}

.field {
  display: grid;
  gap: 6px;
}

.field__label {
  color: var(--ink);
  font-size: 14px;
  font-weight: 600;
}

.field input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #d4d4d8;
  border-radius: 0;
  background: var(--card);
  color: var(--ink);
  font: inherit;
}

.field input:focus-visible,
.choice input:focus-visible,
.button:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}

.field__error {
  color: #9f1239;
  font-size: 14px;
}

.button {
  justify-self: start;
  padding: 11px 22px;
  border: 1px solid var(--magenta);
  border-radius: 0;
  background: var(--magenta);
  color: #fff;
  font: inherit;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
}

.button:hover {
  background: #c8143f;
}

.button--outline {
  border-color: #d4d4d8;
  background: var(--card);
  color: var(--ink);
}

.button--outline:hover {
  border-color: var(--ink);
  background: var(--card);
}

.facts {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 6px 14px;
  margin: 0;
}

.facts dt {
  color: var(--muted);
}

.facts dd {
  margin: 0;
  overflow-wrap: anywhere;
}

.step {
  display: grid;
  gap: 14px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.choices {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  margin: 0;
  padding: 0;
  border: 0;
}

.choices legend {
  margin-bottom: 8px;
  padding: 0;
}

.choice {
  display: flex;
  gap: 10px;
  align-items: center;
}

.choice--check {
  align-items: flex-start;
}

.choice input {
  display: inline-grid;
  flex-shrink: 0;
  place-content: center;
  width: 18px;
  height: 18px;
  margin: 2px 0 0;
  border: 1.5px solid #a1a1aa;
  background: var(--card);
  appearance: none;
}

.choice input[type="radio"] {
  border-radius: 50%;
}

.choice input::before {
  width: 8px;
  height: 8px;
  background: #fff;
  transform: scale(0);
  content: "";
}

.choice input[type="radio"]::before {
  border-radius: 50%;
}

.choice input:checked {
  border-color: var(--magenta);
  background: var(--magenta);
}

.choice input:checked::before {
  transform: scale(1);
}

.rows {
  display: grid;
  margin: 0;
  padding: 0;
  list-style: none;
}

.rows__row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  align-items: center;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}

.rows__main {
  display: grid;
  flex: 1 1 260px;
  min-width: 0;
}

.tag {
  padding: 2px 8px;
  border: 1px solid #d4d4d8;
  font-family: ui-monospace, monospace;
  font-size: 13px;
  text-transform: uppercase;
}

.tag--done {
  border-color: var(--done);
  color: var(--done);
}

.pager {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.pager a {
  min-width: 36px;
  padding: 6px 10px;
  border: 1px solid #d4d4d8;
  color: var(--ink);
  text-align: center;
  text-decoration: none;
}

.pager a[aria-current="page"] {
  border-color: var(--magenta);
  background: var(--magenta);
  color: #fff;
}

.side__off {
  padding: 10px 14px;
  color: #777b80;
  cursor: not-allowed;
}

.cases {
  display: grid;
  gap: 14px;
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
}

.case {
  padding: 12px 14px;
  border: 1px solid #d9dcdf;
}

.case__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.case__dates {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 14px;
  margin: 8px 0;
  font-size: 13px;
}

.rows__main {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.case__sub {
  font-size: 13px;
  color: var(--muted);
}

.case__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.case__amount {
  font-size: 16px;
  font-weight: 700;
  white-space: nowrap;
}

.case__foot {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
}

.case__foot .case__dates {
  margin: 0;
}

.tag--due {
  border-color: #d97706;
  color: #b45309;
  background: #fff7ed;
}

.button--sm {
  padding: 7px 14px;
  font-size: 13px;
}

.files {
  display: grid;
  gap: 8px;
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
}

.files__row {
  display: grid;
  gap: 2px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  background: #fafafa;
  overflow-wrap: anywhere;
}

.files__row a {
  width: fit-content;
  color: var(--ink);
  font-weight: 600;
  text-decoration: none;
}

.files__row a:hover {
  color: var(--magenta);
  text-decoration: underline;
}

.files__row small {
  color: var(--muted);
}

.signed-form {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: 6px;
}

.signed-form__file {
  max-width: 100%;
  font-size: 13px;
}

.sub-state {
  width: fit-content;
  margin-top: 6px;
  padding: 2px 8px;
  border: 1px solid #d4d4d8;
  font-size: 12px;
}

.sub-state--pending {
  border-color: #d97706;
  color: #b45309;
}

.sub-state--approved {
  border-color: var(--done);
  color: var(--done);
}

.sub-state--rework {
  border-color: var(--magenta);
  color: var(--magenta);
}

.cf-turnstile {
  margin: 12px 0;
}

/* PL: Pomoc: własne lewe menu (wyszukiwarka, sekcje, filmy wybranej sekcji) i treść po prawej.
   EN: Help: its own left menu (the search, sections, the chosen section's films) and the content. */
.help {
  display: grid;
  grid-template-columns: minmax(260px, 340px) minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.help__menu {
  display: grid;
  position: sticky;
  top: 16px;
  gap: 14px;
  max-height: calc(100vh - 32px);
  padding: 18px;
  overflow-y: auto;
  border: 1px solid var(--line);
  background: var(--card);
}

.help__main {
  width: 100%;
  margin: 0;
}

.help__back,
.help__project,
.help__crumb {
  margin: 0;
}

.help__project {
  font-weight: 600;
}

.help__crumb {
  color: var(--muted);
}

.help__sections {
  display: grid;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.help__section {
  display: block;
  padding: 8px 10px;
  color: var(--ink);
  text-decoration: none;
}

.help__section:hover {
  background: var(--grid);
}

.help__section[aria-current="page"] {
  background: var(--blue);
  color: #fff;
}

.help__sections .help__list {
  margin: 4px 0 8px 10px;
}

.help__sections .pager {
  margin: 0 0 8px 10px;
}

@media (width <= 860px) {
  .help {
    grid-template-columns: minmax(0, 1fr);
  }

  .help__menu {
    position: static;
    max-height: none;
  }
}

.help__search {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.help__search input {
  flex: 1 1 160px;
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid var(--line);
  font: inherit;
}

.help__player {
  display: grid;
  gap: 10px;
}

.help__player video {
  width: 100%;
  max-height: 70vh;
  background: var(--ink);
}

.help__text,
.help__body {
  margin: 0;
  overflow-wrap: anywhere;
}

.help__list {
  display: grid;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.help__item {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  align-items: center;
  padding: 7px 8px;
  border-top: 1px solid var(--line);
  color: var(--ink);
  text-decoration: none;
}

.help__item:hover,
.help__item[aria-current="true"] {
  background: var(--grid);
  color: var(--blue);
}

.help__item .tag {
  margin-left: auto;
}

.help__number {
  min-width: 2.5em;
  color: var(--muted);
}
