/* ===== Roboto (локальные шрифты) ===== */
/* Fallback с метриками Roboto для снижения CLS при font-display: swap */
@font-face {
  font-family: 'Roboto-fallback';
  src: local('Arial');
  ascent-override: 92.77%;
  descent-override: 24.41%;
  line-gap-override: 0%;
}

@font-face {
  font-family: 'Roboto';
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url(/fonts/Roboto-Light.ttf) format('truetype');
}

@font-face {
  font-family: 'Roboto';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/fonts/Roboto-Regular.ttf) format('truetype');
}

@font-face {
  font-family: 'Roboto';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(/fonts/Roboto-Medium.ttf) format('truetype');
}

@font-face {
  font-family: 'Roboto';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(/fonts/Roboto-Bold.ttf) format('truetype');
}

/* ===== Logo (корпоративный цвет #0048d6 — чуть темнее #005bff) ===== */
.logo-corporate {
  filter: brightness(0) saturate(100%) invert(24%) sepia(98%) saturate(4800%) hue-rotate(212deg) brightness(92%) contrast(105%);
}

/* ===== Base (Tailwind handles most; these supplement) ===== */
html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
  scrollbar-gutter: stable;
  background-color: white;
  height: 100%;
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  min-height: 100dvh;
  background-color: #f5f5f7;
  background-image: url(/images/bg-slash-pattern.png);
  background-repeat: repeat;
  background-size: 240px auto;
  color: #111111;
  font-family: 'Roboto', 'Roboto-fallback', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  line-height: 1.5;
  overflow-x: hidden;
}

body > main {
  flex: 1 0 auto;
}

body > footer {
  flex-shrink: 0;
  margin-top: auto;
}

/* CTA — белая полупрозрачная полоса на всю ширину */
.cta-block__panel {
  background-color: rgba(255, 255, 255, 0.45);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-sizing: border-box;
}

.cta-block__title {
  color: #111111;
}

.bg_2 .cta-block__title {
  color: #fff;
}

/* bg_1 — светлый паттерн (как у body) */
.bg_1 {
  background-color: #f5f5f7;
  background-image: url(/images/bg-slash-pattern.png);
  background-repeat: repeat;
  background-size: 240px auto;
}

/* bg_2 — средний паттерн (темнее bg_1, светлее bg_3) */
.bg_2 {
  background-color: #6a6b74;
  background-image: url(/images/bg-slash-pattern-mid.png);
  background-repeat: repeat;
  background-size: 240px auto;
  color: #e8e8ec;
}

/* bg_3 — средний серый паттерн */
.bg_3 {
  background-color: #bebebe;
  background-image: url(/images/bg-slash-pattern-dark.png);
  background-repeat: repeat;
  background-size: 240px auto;
  color: #111111;
}

.bg_2 .text-\[\#111\] {
  color: #fff;
}

.bg_2 .text-\[\#404040\] {
  color: #c8c8ce;
}

.bg_2 .text-\[\#666\] {
  color: #a1a1aa;
}

.bg_3 .text-\[\#111\] {
  color: #111111;
}

.bg_3 .text-\[\#404040\] {
  color: #404040;
}

.bg_3 .text-\[\#666\] {
  color: #666666;
}

/* В светлых поверхностях внутри bg_2 оставляем тёмный текст */
.bg_2 :is(.bg-white, .bg-\[\#fafafc\], header, footer) {
  color: #111111;
}

.bg_2 :is(.bg-white, .bg-\[\#fafafc\], header, footer) .text-\[\#111\] {
  color: #111111;
}

.bg_2 :is(.bg-white, .bg-\[\#fafafc\], header, footer) .text-\[\#404040\] {
  color: #404040;
}

.bg_2 :is(.bg-white, .bg-\[\#fafafc\], header, footer) .text-\[\#666\] {
  color: #666666;
}

.container {
  max-width: 1280px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.25rem;
  padding-right: 1.25rem;
}

@media (min-width: 768px) {
  .container {
    padding-left: 2.5rem;
    padding-right: 2.5rem;
  }
}

/* ===== Contacts grid ===== */
.contacts-grid {
  display: grid;
  gap: 3rem;
  grid-template-columns: 1fr;
}

@media (min-width: 768px) {
  .contacts-grid {
    gap: 2rem;
    grid-template-columns: 1fr 2fr;
  }
}

/* ===== Projects grid ===== */
.projects-grid {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: 1fr;
}

@media (min-width: 768px) {
  .projects-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .projects-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Вакансии: после tailwind.css — перекрывает preflight (ul { list-style: none }) */
ul.vacancy-requirements {
  list-style-type: disc;
  list-style-position: outside;
  margin: 0;
  padding-left: 2.5rem;
}

ul.vacancy-requirements li {
  display: list-item;
  margin-bottom: 0;
  padding-left: 0.5rem;
}

ul.vacancy-requirements li:last-child {
  margin-bottom: 0;
}

/* Вход администратора: окно на фоне разметки сайта */
.admin-gate {
  flex: 1 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  min-height: 100dvh;
  padding: 1.5rem 1.25rem;
}

.admin-gate__window {
  box-sizing: border-box;
  width: min(100%, 26rem);
  padding: 2.25rem 2rem 1.75rem;
  border: 2px solid #111111;
  border-radius: 16px;
  background: #ffffff;
}

.admin-gate__logo {
  display: inline-block;
  line-height: 0;
}

.admin-gate__logo img {
  display: block;
  width: auto;
  max-width: 11.5rem;
  height: auto;
}

.admin-gate__mark {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin: 1.35rem 0 1.5rem;
}

.admin-gate__mark span {
  display: block;
  height: 7px;
  border-radius: 1px;
}

.admin-gate__mark span:first-child {
  background: #005bff;
}

.admin-gate__mark span:last-child {
  background: repeating-linear-gradient(
    90deg,
    #005bff 0 1.75rem,
    transparent 1.75rem 2.75rem
  );
}

.admin-gate__title {
  margin: 0;
  color: #111111;
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1.2;
}

.admin-gate__lead {
  margin: 0.4rem 0 0;
  color: #404040;
  font-size: 1rem;
  line-height: 1.45;
}

.admin-gate__form {
  margin-top: 1.5rem;
}

.admin-gate__field {
  margin-bottom: 1rem;
}

.admin-gate__field label,
.admin-gate__remember label {
  display: block;
  margin-bottom: 0.4rem;
  color: #111111;
  font-size: 0.9375rem;
  font-weight: 500;
}

.admin-gate__field input {
  box-sizing: border-box;
  display: block;
  width: 100%;
  margin: 0;
  padding: 0.8rem 0.9rem;
  border: 1px solid #c8c8ce;
  border-radius: 10px;
  background: #ffffff;
  color: #111111;
  font: inherit;
  font-size: 1rem;
  line-height: 1.4;
}

.admin-gate__field input::placeholder {
  color: #8a8a93;
}

.admin-gate__field input:focus {
  border-color: #005bff;
  outline: 2px solid rgba(0, 91, 255, 0.28);
  outline-offset: 1px;
}

.admin-gate__remember {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin: 0.25rem 0 1.25rem;
}

.admin-gate__remember label {
  margin: 0;
  font-weight: 400;
  color: #404040;
}

.admin-gate__remember input {
  width: 1.05rem;
  height: 1.05rem;
  margin: 0;
  accent-color: #005bff;
}

.admin-gate__submit {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0.85rem 1.25rem;
  border: 0;
  border-radius: 999px;
  background: #005bff;
  color: #ffffff;
  font: inherit;
  font-size: 1.0625rem;
  font-weight: 600;
  line-height: 1.2;
  cursor: pointer;
}

.admin-gate__submit:hover {
  background: #0047c2;
}

.admin-gate__submit:focus-visible {
  outline: 2px solid #111111;
  outline-offset: 3px;
}

.admin-gate__foot {
  margin: 1.15rem 0 0;
  text-align: center;
}

.admin-gate__foot a,
.admin-gate__links a {
  color: #005bff;
  font-size: 0.9375rem;
  text-decoration: none;
}

.admin-gate__foot a:hover,
.admin-gate__links a:hover {
  text-decoration: underline;
}

.admin-gate__flash {
  margin: 0 0 1.25rem;
  padding: 0.75rem 0.9rem;
  border-radius: 10px;
  font-size: 0.9375rem;
  line-height: 1.4;
}

.admin-gate__flash--notice {
  border: 1px solid #b7e4c7;
  background: #f0faf3;
  color: #14532d;
}

.admin-gate__flash--alert {
  border: 1px solid #f3c0c0;
  background: #fff5f5;
  color: #7f1d1d;
}

@media (max-width: 420px) {
  .admin-gate__window {
    padding: 1.75rem 1.25rem 1.4rem;
  }
}

/* ===== Print ===== */
@media print {

  header,
  footer,
  .no-print {
    display: none !important;
  }
}
