/* ================= Design Tokens ================= */
:root {
  --bg: #0e1b33;
  --bg-2: #101b30;
  --primary: #d72626;
  --text: #0e1320;
  --muted: #5d667b;
  --surface: #ffffff;
  --surface-2: #f4f6fb;
  --radius: 16px;
  --shadow-light: 0 8px 24px rgba(14, 27, 51, 0.08);
  --shadow-heavy: 0 12px 28px rgba(215, 38, 38, 0.25);
}
/* ================= Reset & Base ================= */
* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  scroll-behavior: smooth;
}

body {
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Ubuntu,
    "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  color: var(--text);
  background: var(--surface);
  line-height: 1.5;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

.container {
  width: min(1100px, 92%);
  margin-inline: auto;
}

/* ================= Header ================= */
.header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--bg);
  color: #fff;
  box-shadow: 0 2px 0 rgba(0, 0, 0, 0.06);
  transition: background 0.2s ease, box-shadow 0.2s ease;
}

.header.scrolled {
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
  background: #0b1630;
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: #fff;
  text-decoration: none;
}

.brand__logo {
  width: 38px;
  height: 72px;
  object-fit: cover;
}

.brand__name {
  font-weight: 800;
  letter-spacing: 0.3px;
}

.nav {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.nav__link {
  color: #c7d0e8;
  text-decoration: none;
  font-weight: 600;
  padding: 0.5rem 0.25rem;
}

.nav__link:hover {
  color: #fff;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.7rem 1.1rem;
  border: none;
  border-radius: 999px;
  cursor: pointer;
  text-decoration: none;
  font-weight: 700;
  transition: transform 0.08s ease, box-shadow 0.2s ease, background 0.2s ease,
    filter 0.2s ease;
}

.btn--primary {
  background: linear-gradient(180deg, #e03a3a, var(--primary));
  color: #fff;
  box-shadow: 0 6px 14px rgba(215, 38, 38, 0.25);
}

.btn--primary:hover {
  transform: translateY(-1px);
  filter: brightness(1.03);
}

.btn--xl {
  font-size: 1.05rem;
  padding: 1rem 1.4rem;
}

.btn--block {
  width: 100%;
}

/* ================= Burger ================= */
.burger {
  display: none;
  width: 44px;
  height: 44px;
  background: transparent;
  border: none;
  cursor: pointer;
}

.burger span {
  display: block;
  width: 24px;
  height: 2px;
  background: #fff;
  margin: 6px auto;
  transition: transform 0.2s, opacity 0.2s;
}

.burger.is-open span:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}

.burger.is-open span:nth-child(2) {
  opacity: 0;
}

.burger.is-open span:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

@media (max-width: 900px) {
  .burger {
    display: block;
  }

  .nav {
    position: fixed;
    inset: 0px 0 auto;
    background: var(--bg);
    flex-direction: column;
    padding: 1rem;
    gap: 0.75rem;
    transform: translateY(-100%);
    transition: transform 0.25s ease;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  }

  .nav.open {
    transform: translateY(0);
  }
}

/* ================= Hero ================= */
.hero {
  position: relative;
  isolation: isolate;
  min-height: 68vh;
  display: flex;
  align-items: center;
  color: #fff;
}

.hero__bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg,
      rgba(14, 27, 51, 0.85) 0%,
      rgba(14, 27, 51, 0.35) 55%,
      rgba(14, 27, 51, 0) 100%),
    url("images/hero.png");
  background-size: cover;
  background-position: center;
  will-change: background-position;
}

.hero__content {
  padding: 6rem 0;
}

.hero__slogan {
  font-size: 1.2rem;
  font-weight: 500;
  margin-bottom: 1.5rem;
  color: #f4f6fb;
}

.hero__title {
  color: #fff;
  font-weight: 900;
  font-size: clamp(2.4rem, 6vw, 4.2rem);
  line-height: 1.05;
  margin: 0 0 1.5rem 0;
}

/* ================= Sections ================= */
.section {
  padding: 64px 0;
  background: var(--surface);
}

.section:nth-of-type(even) {
  background: var(--surface-2);
}

.section__title {
  font-size: clamp(1.6rem, 3.5vw, 2.2rem);
  margin: 0 0 1rem 0;
}

.section__text {
  color: var(--muted);
  max-width: 65ch;
}

/* ================= À propos ================= */
#apropos {
  background: var(--surface-2);
  padding: 64px 0;
}

#apropos .container {
  max-width: 900px;
  margin-inline: auto;
  text-align: center;
}

#apropos .section__title {
  font-size: clamp(1.8rem, 3vw, 2.2rem);
  font-weight: 900;
  color: var(--bg-2);
  margin-bottom: 1.5rem;
  position: relative;
}

#apropos .section__title::after {
  content: "";
  display: block;
  width: 60px;
  height: 3px;
  background: var(--primary);
  margin: 0.5rem auto 0;
  border-radius: 2px;
}

#apropos p {
  color: var(--text);
  font-size: 1.05rem;
  font-style: italic;
  line-height: 1.8;
  background: var(--surface);
  padding: 1.5rem 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow-light);
  transition: transform 0.3s ease, box-shadow 0.3s ease, opacity 0.6s ease;
  opacity: 0;
  transform: translateY(24px);
}

#apropos p.show {
  opacity: 1;
  transform: translateY(0);
}

#apropos p:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-heavy);
}

@media (max-width: 900px) {
  #apropos p {
    padding: 1.25rem 1.5rem;
    font-size: 1rem;
  }
}

/* ================= Cards / Services ================= */
.cards {
  margin-top: 1.25rem;
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 980px) {
  .cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 680px) {
  .cards {
    grid-template-columns: 1fr;
  }
}

.card {
  background: var(--surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow-light);
  padding: 1.25rem 1.1rem;
  transition: transform 0.12s ease, box-shadow 0.2s ease;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-heavy);
  transition: transform 0.12s ease, box-shadow 0.2s ease;
  cursor: pointer;
}

.card__icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: var(--bg);
  display: grid;
  place-items: center;
  margin-bottom: 0.9rem;
}

.card__icon svg {
  width: 28px;
  height: 28px;
  fill: #fff;
}

.card__title {
  margin: 0.2rem 0 0.4rem;
  font-size: 1.05rem;
}

.card__text {
  color: var(--muted);
}

/* ================= Contact ================= */
.contact__grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: start;
}

.contact__info {
  margin-bottom: 1.5rem;
  color: var(--text);
  font-weight: 500;
}

.contact__info a {
  color: var(--primary);
  text-decoration: none;
}

.contact__info a:hover {
  text-decoration: underline;
}

@media (max-width: 900px) {
  .contact__grid {
    grid-template-columns: 1fr;
  }

  .hero__content {
    text-align: center;
  }
}

.form {
  background: var(--surface);
  padding: 1.25rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow-light);
  display: grid;
  gap: 0.9rem;
}

.form__field {
  display: grid;
  gap: 0.35rem;
}

.form__field span {
  font-weight: 600;
}

.form input,
.form textarea {
  width: 100%;
  padding: 0.85rem 1rem;
  border: 1px solid #e5e8f0;
  border-radius: 12px;
  outline: none;
  font: inherit;
  background: #fff;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form input:focus,
.form textarea:focus {
  border-color: #b5bed8;
  box-shadow: 0 0 0 3px rgba(42, 76, 180, 0.12);
}

.error {
  color: #c0392b;
  font-size: 0.85rem;
  min-height: 1em;
}

.is-invalid {
  border-color: #c0392b !important;
  box-shadow: 0 0 0 3px rgba(192, 57, 43, 0.12) !important;
}

.is-disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

/* ================= Footer ================= */
.footer {
  background: var(--bg-2);
  color: #c7d0e8;
  padding-block: 28px;
}

.footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

@media (max-width: 680px) {
  .footer__inner {
    flex-direction: column;
    align-items: center;
    gap: 1rem;
  }
}

.footer__nav {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.footer__nav a {
  color: #c7d0e8;
  text-decoration: none;
}

.footer__nav a:hover {
  color: #fff;
}

.social-icons {
  display: flex;
  gap: 16px;
}

.social-icons a {
  display: flex;
  width: 30px;
  height: 30px;
  background: var(--primary);
  border-radius: 50%;
  color: #fff;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  transition: background-color 0.3s ease;
}

.social-icons a:hover {
  background: #a2251e;
}

.footer__copy {
  text-align: center;
  font-size: 0.9rem;
  color: #95a4c7;
  padding: 16px 0 22px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  margin-top: 18px;
}

.footer__up {
  margin-left: 0.5rem;
  color: #fff;
  text-decoration: none;
}

/* ================= Toast ================= */
.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(100%);
  background: var(--primary);
  color: #fff;
  padding: 1rem 1.5rem;
  border-radius: 12px;
  box-shadow: var(--shadow-heavy);
  font-weight: 700;
  opacity: 0;
  pointer-events: none;
  transition: transform 0.4s ease, opacity 0.4s ease;
  z-index: 999;
}

.toast.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

/* ================= Sticky CTA ================= */
.cta-fab {
  position: fixed;
  bottom: 16px;
  right: 16px;
  z-index: 60;
  background: var(--primary);
  border-radius: 50%;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-heavy);
  cursor: pointer;
  transition: transform 0.2s ease, opacity 0.2s ease;
  opacity: 0;
  pointer-events: none;
}

.cta-fab:hover {
  transform: scale(1.1);
}

.cta-fab svg {
  width: 24px;
  height: 24px;
}

@media (min-width: 900px) {
  .cta-fab {
    display: none;
  }
}

/* ================= Reveal ================= */
.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.reveal.show {
  opacity: 1;
  transform: translateY(0);
}

/* ================= Motion Preferences ================= */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}





.lang-switch {
  display: flex;
  align-items: center;
  gap: 8px;
}

.lang-switch button {
  background: var(--surface-2);
  border: 1px solid var(--primary);
  border-radius: 8px;
  padding: 4px 8px;
  cursor: pointer;
  font-weight: bold;
  color: var(--bg-2);
  transition: all 0.2s ease;
}

.lang-switch button:hover {
  background: var(--primary);
  color: #fff;
}

.lang-switch button.active {
  background: var(--primary);
  color: #fff;
}




@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }

  .reveal,
  #apropos p,
  .toast,
  .cta-fab,
  .burger span,
  .card {
    transition: none !important;
    transform: none !important;
    opacity: 1 !important;
  }

  .burger.is-open span {
    transform: none !important;
  }

  .toast.show,
  .cta-fab {
    opacity: 1 !important;
    pointer-events: auto !important;
    transform: none !important;
  }
}










/* ===== Modal Styles ===== */
.modal {
  position: fixed;
  z-index: 1000;
  inset: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  background: rgba(0,0,0,0); /* прозрачный по умолчанию */
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease, background 0.35s ease;
}

.modal.show {
  opacity: 1;
  pointer-events: auto;
  background: rgba(0,0,0,0.7); /* затемнение фона */
}

.modal__content {
  background: #fff;
  max-width: 600px;
  width: 90%;
  padding: 20px;
  border-radius: 16px;
  text-align: center;
  position: relative;
  transform: scale(0.8);
  box-shadow: 0 12px 28px rgba(0,0,0,0.2);
  transition: transform 0.35s cubic-bezier(0.25, 1, 0.5, 1), box-shadow 0.35s ease;
}

.modal.show .modal__content {
  transform: scale(1);
  box-shadow: 0 16px 36px rgba(0,0,0,0.25);
}

.modal__img {
  max-width: 100%;
  border-radius: 12px;
  margin-bottom: 20px;
  transform: translateY(20px);
  opacity: 0;
  transition: transform 0.35s ease, opacity 0.35s ease;
}

.modal.show .modal__img {
  transform: translateY(0);
  opacity: 1;
}

.modal__title {
  font-size: 1.6rem;
  margin-bottom: 10px;
  transform: translateY(20px);
  opacity: 0;
  transition: transform 0.35s ease 0.05s, opacity 0.35s ease 0.05s;
}

.modal.show .modal__title {
  transform: translateY(0);
  opacity: 1;
}

.modal__desc {
  font-size: 1rem;
  color: #555;
  transform: translateY(20px);
  opacity: 0;
  transition: transform 0.35s ease 0.1s, opacity 0.35s ease 0.1s;
}

.modal.show .modal__desc {
  transform: translateY(0);
  opacity: 1;
}

/* ===== Красивый крестик ===== */
.modal__close {
  position: absolute;
  top: -20px;  /* сдвиг наружу на половину круга */
  right: -20px; /* сдвиг наружу на половину круга */
  width: 40px;  /* размер круга */
  height: 40px; /* размер круга */
  background: var(--primary);
  color: #fff;
  border-radius: 50%;
  font-size: 22px; /* размер крестика */
  display: flex;
  align-items: center;
  justify-content: center; /* идеально по центру */
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0,0,0,0.25);
  transition: transform 0.2s ease, background 0.2s ease;
  z-index: 10;
}

.modal__close:hover {
  transform: rotate(90deg) scale(1.1);
  background: #e03a3a;
}
@media (max-width: 470px) {
  .modal__close {
    top: -15px;
    right: -15px;
    width: 32px;
    height: 32px;
    font-size: 18px;
  }
}


