:root {
  --bg-black: #000000;
  --accent-red: #ff2a2a;
  --accent-red-deep: #8f1f1f;
  --text-main: #f5f1f1;
  --text-muted: #bfb3b3;
  --line-soft: rgba(255, 255, 255, 0.1);
  --panel-strong: rgba(12, 12, 12, 0.74);
  --panel-soft: rgba(28, 20, 20, 0.58);
  --glow-red: rgba(255, 42, 42, 0.32);
  --radius-lg: 22px;
  --radius-md: 16px;
  --shadow-lg: 0 20px 44px rgba(0, 0, 0, 0.42);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Sora", "Manrope", sans-serif;
  background: linear-gradient(135deg, #181515 0%, #281d1d 42%, #160c0c 100%);
  color: var(--text-main);
  line-height: 1.7;
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
}

body::before,
body::after {
  content: "";
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: -2;
}

body::before {
  background:
    radial-gradient(circle at 20% 20%, rgba(255, 42, 42, 0.18), transparent 35%),
    radial-gradient(circle at 78% 12%, rgba(255, 42, 42, 0.12), transparent 26%),
    radial-gradient(circle at 62% 78%, rgba(255, 42, 42, 0.1), transparent 34%);
  animation: pulse-bg 16s ease-in-out infinite alternate;
}

body::after {
  z-index: -1;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.5), transparent 90%);
}

@keyframes pulse-bg {
  0% {
    transform: scale(1);
    filter: saturate(0.95);
  }
  100% {
    transform: scale(1.08);
    filter: saturate(1.15);
  }
}

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

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

.container {
  width: min(1160px, 92vw);
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 99;
  border-bottom: 1px solid var(--line-soft);
  background: rgba(0, 0, 0, 0.74);
  backdrop-filter: blur(14px);
}

.header-inner {
  min-height: 84px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 1.2rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
  font-size: 0.95rem;
}

.brand img {
  width: 44px;
  height: 44px;
  padding: 4px;
  object-fit: contain;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.24), rgba(255, 255, 255, 0.1));
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 10px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.35);
  filter: none;
}

.main-nav ul {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 1.15rem;
}

.main-nav {
  margin-left: auto;
}

.main-nav a {
  color: var(--text-muted);
  text-transform: uppercase;
  font-size: 0.79rem;
  letter-spacing: 0.1em;
  padding: 0.35rem 0.1rem;
  position: relative;
  transition: color 0.24s ease;
}

.main-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.16rem;
  width: 100%;
  height: 1px;
  transform-origin: left;
  transform: scaleX(0);
  transition: transform 0.24s ease;
  background: linear-gradient(90deg, var(--accent-red), transparent);
}

.main-nav a:hover,
.main-nav a.active {
  color: var(--text-main);
}

.main-nav a:hover::after,
.main-nav a.active::after {
  transform: scaleX(1);
}

.build-btn,
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 0.74rem;
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}

.build-btn {
  margin-left: 0.7rem;
  padding: 0.9rem 1.52rem;
  min-height: 50px;
  white-space: nowrap;
  line-height: 1;
  flex-shrink: 0;
  background: linear-gradient(130deg, #ff2a2a, #bc1f1f);
  color: #fff;
  box-shadow: 0 0 18px rgba(255, 42, 42, 0.34);
}

.build-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 24px rgba(255, 42, 42, 0.48);
}

.menu-toggle {
  display: none;
  margin-left: auto;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line-soft);
  background: rgba(0, 0, 0, 0.75);
  color: var(--text-main);
  border-radius: 10px;
  align-items: center;
  justify-content: center;
}

.hero {
  position: relative;
  min-height: calc(100vh - 84px);
  display: flex;
  align-items: center;
  padding: 8rem 0 6rem;
}

.hero-content {
  max-width: 760px;
}

.eyebrow {
  color: #f2c6c6;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.76rem;
  margin-bottom: 1.1rem;
}

h1,
.hero h1 {
  font-size: clamp(2.35rem, 5.2vw, 4.45rem);
  line-height: 1.08;
  letter-spacing: -0.03em;
  margin-bottom: 1.28rem;
}

.hero p {
  max-width: 700px;
  color: var(--text-muted);
  font-size: 1.05rem;
}

.button-row {
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
}

.btn {
  padding: 0.86rem 1.45rem;
}

.btn-primary {
  background: linear-gradient(130deg, #ff2a2a, #a51a1a);
  border-color: rgba(255, 42, 42, 0.9);
  color: #fff;
  box-shadow: 0 0 20px rgba(255, 42, 42, 0.3);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.03);
  border-color: rgba(255, 255, 255, 0.2);
  color: var(--text-main);
}

.btn:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 42, 42, 0.7);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.32), 0 0 16px rgba(255, 42, 42, 0.25);
}

.hero-shapes {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.hero-shape {
  position: absolute;
  border: 1px solid rgba(255, 42, 42, 0.36);
  background: linear-gradient(120deg, rgba(255, 42, 42, 0.14), rgba(255, 42, 42, 0.02));
  clip-path: polygon(10% 0%, 100% 10%, 84% 100%, 0% 88%);
  animation: float-shape 10s ease-in-out infinite;
}

.hero-shape:nth-child(1) {
  width: 220px;
  height: 240px;
  top: 18%;
  right: 11%;
}

.hero-shape:nth-child(2) {
  width: 150px;
  height: 170px;
  right: 28%;
  top: 58%;
  animation-duration: 13s;
}

.hero-shape:nth-child(3) {
  width: 120px;
  height: 130px;
  right: 6%;
  top: 70%;
  animation-duration: 8.8s;
}

@keyframes float-shape {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-14px) rotate(4deg);
  }
}

.section {
  padding: 5.7rem 0;
  border-top: 1px solid var(--line-soft);
  position: relative;
}

.section-ornament {
  width: 150px;
  height: 150px;
  border: 1px solid rgba(255, 42, 42, 0.28);
  clip-path: polygon(7% 0%, 100% 15%, 90% 100%, 0% 84%);
  position: absolute;
  right: 6%;
  top: 1.6rem;
  opacity: 0.3;
}

.section-title {
  font-size: clamp(1.8rem, 3.8vw, 3rem);
  line-height: 1.15;
  margin-bottom: 1.2rem;
  letter-spacing: -0.02em;
}

.section-intro {
  max-width: 820px;
  color: var(--text-muted);
  margin-bottom: 1.8rem;
}

p + p {
  margin-top: 1rem;
}

.card-grid {
  display: grid;
  gap: 1.1rem;
}

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

.grid-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.grid-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.card {
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.045), rgba(255, 42, 42, 0.045));
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-lg);
  padding: 1.42rem;
  backdrop-filter: blur(12px);
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
  transition: transform 0.32s ease, border-color 0.32s ease, box-shadow 0.32s ease;
}

.card::before {
  content: "";
  position: absolute;
  left: -14%;
  top: -26%;
  width: 54%;
  height: 64%;
  background: linear-gradient(145deg, rgba(255, 42, 42, 0.36), transparent 70%);
  transform: rotate(10deg);
  pointer-events: none;
}

.card:hover {
  transform: translateY(-6px);
  border-color: rgba(255, 42, 42, 0.54);
  box-shadow: 0 24px 44px rgba(0, 0, 0, 0.44), 0 0 24px rgba(255, 42, 42, 0.18);
}

.card h3 {
  font-size: 1.08rem;
  line-height: 1.35;
  margin-bottom: 0.65rem;
}

.card p {
  color: var(--text-muted);
  font-size: 0.96rem;
}

.split-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 1.65rem;
  align-items: start;
}

.feature-list {
  margin-top: 1.2rem;
  list-style: none;
  display: grid;
  gap: 0.72rem;
}

.feature-list li {
  position: relative;
  padding-left: 1.28rem;
  color: var(--text-muted);
}

.feature-list li::before {
  content: "";
  position: absolute;
  width: 0.55rem;
  height: 0.55rem;
  background: linear-gradient(135deg, var(--accent-red), var(--accent-red-deep));
  transform: rotate(45deg);
  left: 0;
  top: 0.62rem;
}

.kpi-strip {
  margin-top: 2rem;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.9rem;
}

.kpi {
  padding: 1rem;
  border-radius: 14px;
  background: var(--panel-soft);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.kpi strong {
  display: block;
  font-size: 1.5rem;
  letter-spacing: -0.02em;
  margin-bottom: 0.3rem;
}

.kpi span {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.tech-diagram {
  margin-top: 1.7rem;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.72rem;
}

.diagram-node {
  min-height: 134px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 42, 42, 0.35);
  background: rgba(8, 8, 8, 0.88);
  padding: 1rem;
  position: relative;
}

.diagram-node h4 {
  font-size: 0.95rem;
  margin-bottom: 0.5rem;
}

.diagram-node p {
  color: var(--text-muted);
  font-size: 0.85rem;
  line-height: 1.55;
}

.diagram-node::after {
  content: "";
  position: absolute;
  right: -0.72rem;
  top: 50%;
  width: 0.72rem;
  height: 1px;
  background: rgba(255, 42, 42, 0.56);
}

.diagram-node:last-child::after {
  display: none;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border: 1px solid rgba(255, 42, 42, 0.45);
  border-radius: 999px;
  padding: 0.35rem 0.7rem;
  color: #ffd7d7;
  font-size: 0.73rem;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  margin-bottom: 0.95rem;
}

.code-block {
  margin-top: 1.2rem;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 42, 42, 0.42);
  background: #0a0909;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.03);
  overflow-x: auto;
  padding: 1rem;
  color: #f4d1d1;
  font-size: 0.84rem;
  font-family: "IBM Plex Mono", "Fira Code", monospace;
  line-height: 1.6;
}

.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.4rem;
}

.contact-panel,
.contact-form {
  border-radius: var(--radius-lg);
  padding: 1.3rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: var(--panel-soft);
  backdrop-filter: blur(10px);
}

.contact-form {
  display: grid;
  gap: 0.9rem;
}

.form-row {
  display: grid;
  gap: 0.4rem;
}

label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: #d7c7c7;
}

input,
select,
textarea {
  width: 100%;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(0, 0, 0, 0.42);
  color: var(--text-main);
  font: inherit;
  padding: 0.73rem 0.84rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: rgba(255, 42, 42, 0.72);
  box-shadow: 0 0 0 3px rgba(255, 42, 42, 0.18);
}

textarea {
  min-height: 120px;
  resize: vertical;
}

.form-status {
  color: #ffd0d0;
  font-size: 0.86rem;
  min-height: 1.2rem;
}

.site-footer {
  margin-top: 4rem;
  border-top: 1px solid var(--line-soft);
  background: rgba(0, 0, 0, 0.84);
  backdrop-filter: blur(10px);
  padding: 2.5rem 0 1.8rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.35fr 1fr 1fr;
  gap: 1.4rem;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.footer-brand .brand {
  font-size: 0.86rem;
}

.footer-brand p,
.footer-links a,
.footer-social a {
  color: var(--text-muted);
  font-size: 0.92rem;
}

.footer-links,
.footer-social {
  display: grid;
  gap: 0.54rem;
  align-content: start;
}

.x-link {
  width: fit-content;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.48rem 0.78rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.02);
  transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
}

.x-link svg {
  width: 0.88rem;
  height: 0.88rem;
  display: block;
  fill: currentColor;
}

.x-link span {
  font-size: 0.84rem;
  letter-spacing: 0.04em;
}

.footer-links a:hover,
.footer-social a:hover {
  color: #ffdede;
}

.x-link:hover {
  border-color: rgba(255, 42, 42, 0.62);
  box-shadow: 0 0 16px rgba(255, 42, 42, 0.18);
  transform: translateY(-1px);
}

.footer-bottom {
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: #a69696;
  font-size: 0.82rem;
}

.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 1140px) {
  .grid-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .grid-3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .kpi-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .tech-diagram {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .diagram-node:nth-child(2)::after,
  .diagram-node:nth-child(4)::after {
    display: none;
  }
}

@media (max-width: 900px) {
  .menu-toggle {
    display: inline-flex;
  }

  .main-nav {
    position: fixed;
    right: -100%;
    top: 84px;
    width: min(320px, 82vw);
    height: calc(100vh - 84px);
    border-left: 1px solid var(--line-soft);
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(10px);
    transition: right 0.28s ease;
    padding: 2rem 1.2rem;
  }

  body.nav-open .main-nav {
    right: 0;
  }

  .main-nav ul {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.8rem;
  }

  .main-nav a {
    font-size: 0.84rem;
  }

  .build-btn {
    display: none;
  }

  .hero {
    min-height: auto;
    padding-top: 6.2rem;
  }

  .split-grid,
  .contact-layout,
  .footer-grid,
  .grid-2 {
    grid-template-columns: 1fr;
  }

  .hero-shape:nth-child(1) {
    width: 160px;
    height: 180px;
    right: 6%;
  }

  .hero-shape:nth-child(2),
  .hero-shape:nth-child(3) {
    display: none;
  }
}

@media (max-width: 640px) {
  .section {
    padding: 4.6rem 0;
  }

  .grid-4,
  .grid-3,
  .kpi-strip,
  .tech-diagram {
    grid-template-columns: 1fr;
  }

  .diagram-node::after,
  .section-ornament {
    display: none;
  }

  h1,
  .hero h1 {
    font-size: clamp(2rem, 9vw, 3.1rem);
  }
}
