:root {
  --ink: #18212b;
  --muted: #64717f;
  --line: #dce3ea;
  --paper: #f4f7fa;
  --white: #ffffff;
  --red: #d9292f;
  --redDark: #a8171c;
  --teal: #0d7a75;
  --blue: #1d3557;
  --dark: #101923;
  --shadow: 0 18px 45px rgba(16, 25, 35, 0.14);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
}

img {
  display: block;
  max-width: 100%;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  min-height: 72px;
  padding: 12px clamp(18px, 4vw, 56px);
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

.brand,
.sideBrand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
}

.brand span,
.sideBrand span,
.brandMark {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 8px;
  color: var(--white);
  background: var(--red);
  font-weight: 900;
}

.nav {
  display: flex;
  gap: 18px;
  color: var(--muted);
  font-weight: 700;
}

.nav a:hover {
  color: var(--red);
}

.call,
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 16px;
  border: 0;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 800;
}

.call,
.btn.primary {
  color: var(--white);
  background: var(--red);
}

.btn.primary:hover {
  background: var(--redDark);
}

.btn.light {
  color: var(--ink);
  background: var(--white);
  border: 1px solid var(--line);
}

.btn.dark {
  color: var(--white);
  background: var(--dark);
}

.btn.small {
  min-height: 36px;
  padding: 0 12px;
  font-size: 13px;
}

.hero {
  position: relative;
  min-height: calc(100vh - 72px);
  overflow: hidden;
}

.hero img,
.heroShade {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero img {
  object-fit: cover;
}

.heroShade {
  background: linear-gradient(90deg, rgba(10, 16, 22, 0.88), rgba(10, 16, 22, 0.58), rgba(10, 16, 22, 0.12));
}

.heroInner {
  position: relative;
  z-index: 1;
  display: grid;
  align-content: center;
  width: min(780px, 100%);
  min-height: calc(100vh - 72px);
  padding: 78px clamp(20px, 6vw, 72px) 110px;
  color: var(--white);
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--red);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: #ffb9bc;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 18px;
  font-size: clamp(42px, 7vw, 76px);
  line-height: 0.98;
}

h2 {
  margin-bottom: 14px;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.05;
}

h3 {
  margin-bottom: 8px;
}

.hero p {
  max-width: 650px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 19px;
  line-height: 1.6;
}

.actions,
.workActions,
.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.strip {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  margin-top: -52px;
  padding: 0 clamp(18px, 4vw, 56px);
}

.strip article {
  min-height: 104px;
  padding: 24px;
  background: var(--white);
  box-shadow: var(--shadow);
}

.strip strong,
.strip span {
  display: block;
}

.strip strong {
  font-size: 26px;
}

.strip span {
  color: var(--muted);
}

.section,
.tools {
  padding: 88px clamp(18px, 4vw, 56px);
}

.heading {
  max-width: 780px;
  margin-bottom: 30px;
}

.grid {
  display: grid;
  gap: 16px;
}

.grid.four {
  grid-template-columns: repeat(4, 1fr);
}

.card,
.panel,
.report,
.box {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  box-shadow: 0 8px 28px rgba(16, 25, 35, 0.07);
}

.card {
  padding: 24px;
}

.card p,
.split p,
.report li,
.empty {
  color: var(--muted);
  line-height: 1.6;
}

.num {
  display: inline-flex;
  margin-bottom: 26px;
  color: var(--red);
  font-weight: 900;
}

.tools {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  background: var(--white);
}

.panel {
  padding: clamp(22px, 4vw, 34px);
}

.panel.accent {
  background: #eaf7f6;
  border-color: #b7d9d6;
}

.form {
  display: grid;
  gap: 14px;
}

.row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

label {
  display: grid;
  gap: 7px;
  color: #354453;
  font-size: 14px;
  font-weight: 800;
}

input,
select,
textarea {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: var(--white);
}

textarea {
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  outline: 3px solid rgba(217, 41, 47, 0.16);
  border-color: var(--red);
}

.notice {
  display: block;
  padding: 14px;
  border-radius: 8px;
  color: var(--white);
  background: var(--dark);
  line-height: 1.5;
}

.notice.white {
  color: var(--ink);
  background: var(--white);
  border: 1px solid #b7d9d6;
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(320px, 1.1fr);
  gap: 36px;
  align-items: center;
}

.inline {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: end;
  margin-top: 24px;
}

.report {
  padding: clamp(22px, 4vw, 34px);
}

.report span {
  color: var(--muted);
  font-weight: 700;
}

.bar {
  height: 12px;
  overflow: hidden;
  margin: 18px 0;
  border-radius: 999px;
  background: #e4eaf0;
}

.bar i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--teal);
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 28px clamp(18px, 4vw, 56px);
  color: var(--white);
  background: var(--dark);
}

.footer strong,
.footer span {
  display: block;
}

.footer span {
  color: rgba(255, 255, 255, 0.68);
}

.login {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  color: var(--white);
  background:
    linear-gradient(135deg, rgba(16, 25, 35, 0.94), rgba(16, 25, 35, 0.72)),
    url("assets/garage-hero.png") center / cover;
}

.loginCard {
  width: min(460px, 100%);
  display: grid;
  gap: 15px;
  padding: 30px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.loginCard h1,
.loginCard p,
.loginCard label {
  color: var(--white);
}

.loginCard p {
  color: rgba(255, 255, 255, 0.72);
  line-height: 1.55;
}

.error,
.errorText {
  color: #fff5f5;
  background: rgba(217, 41, 47, 0.35);
  padding: 10px 12px;
  border-radius: 8px;
}

.manager {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  background: #edf2f6;
}

.side {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 18px 12px;
  color: var(--white);
  background: var(--dark);
}

.sideBrand {
  margin: 0 8px 18px;
}

.sideLink {
  min-height: 42px;
  padding: 0 12px;
  border: 0;
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.68);
  background: transparent;
  text-align: left;
  cursor: pointer;
  font-weight: 800;
}

.sideLink:hover,
.sideLink.active {
  color: var(--white);
  background: var(--red);
}

.sideLink.muted {
  margin-top: auto;
  color: rgba(255, 255, 255, 0.48);
}

.work {
  min-width: 0;
  padding: 24px;
}

.workTop {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 18px;
  margin-bottom: 22px;
}

.workTop h1 {
  margin: 0;
  font-size: 36px;
  line-height: 1.08;
}

.kpis {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 18px;
}

.kpis article {
  padding: 20px;
  border-left: 4px solid var(--red);
  border-radius: 8px;
  background: var(--white);
  box-shadow: 0 8px 28px rgba(16, 25, 35, 0.07);
}

.kpis span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.kpis strong {
  display: block;
  margin-top: 8px;
  font-size: 30px;
}

.adminGrid {
  display: grid;
  grid-template-columns: minmax(320px, 0.9fr) minmax(0, 1.1fr);
  gap: 18px;
}

.box {
  padding: 20px;
}

.box.narrow {
  max-width: 560px;
}

.boxHead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.boxHead h2 {
  margin: 0;
  font-size: 24px;
}

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

.list article {
  display: grid;
  gap: 4px;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f9fbfd;
}

.list p,
.list small {
  margin: 0;
  color: var(--muted);
}

.kanban {
  display: grid;
  grid-template-columns: repeat(4, minmax(230px, 1fr));
  gap: 12px;
  align-items: start;
}

.column {
  min-height: 180px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #e8eef4;
}

.column header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
  padding: 5px;
}

.column header span {
  display: grid;
  place-items: center;
  min-width: 24px;
  height: 24px;
  border-radius: 999px;
  color: var(--white);
  background: var(--dark);
  font-size: 12px;
  font-weight: 900;
}

.jobCard {
  display: grid;
  gap: 8px;
  margin-bottom: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  box-shadow: 0 6px 20px rgba(16, 25, 35, 0.06);
}

.jobCard div {
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

.jobCard h3,
.jobCard p {
  margin: 0;
}

.jobCard p,
.jobCard small {
  color: var(--muted);
}

.pill {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: 999px;
  color: #065f46;
  background: #dff7ed;
  font-size: 11px;
  font-weight: 900;
}

.pill.danger {
  color: #991b1b;
  background: #ffe0e2;
}

.empty {
  margin: 0;
}

.empty.mini {
  padding: 12px;
  font-size: 13px;
}

.modalLayer {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(0, 0, 0, 0.48);
}

.modalBox {
  position: relative;
  width: min(780px, 100%);
  max-height: 92vh;
  overflow: auto;
  padding: 26px;
  border-radius: 8px;
  background: var(--white);
  box-shadow: var(--shadow);
}

.modalClose {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 8px;
  background: var(--paper);
  cursor: pointer;
  font-size: 22px;
}

.modalForm {
  padding-top: 26px;
}

@media (max-width: 1120px) {
  .grid.four,
  .kpis,
  .kanban {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 820px) {
  .nav {
    display: none;
  }

  .hero,
  .heroInner {
    min-height: 680px;
  }

  .strip,
  .tools,
  .split,
  .grid.four,
  .adminGrid,
  .kpis,
  .kanban,
  .row {
    grid-template-columns: 1fr;
  }

  .strip {
    margin-top: 0;
    padding: 0;
  }

  .manager {
    grid-template-columns: 1fr;
  }

  .side {
    position: static;
    height: auto;
  }

  .workTop,
  .footer {
    flex-direction: column;
    align-items: stretch;
  }
}
