:root {
  color-scheme: light;
  --bg: #f6f9fc;
  --bg-contrast: #e9f4ff;
  --card: #ffffff;
  --accent: #09e3b0;
  --accent-secondary: #f576be;
  --text: #0f172a;
  --text-muted: #4b5563;
  --border: #e4e8f0;
  --shadow: 0 16px 40px rgba(15, 23, 42, 0.12);
  --shadow-soft: 0 8px 24px rgba(15, 23, 42, 0.08);
  --panel-gradient: linear-gradient(135deg, rgba(9, 227, 176, 0.08), rgba(245, 118, 190, 0.08));
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background: radial-gradient(circle at 10% 20%, rgba(245, 118, 190, 0.08), transparent 25%),
    radial-gradient(circle at 90% 10%, rgba(9, 227, 176, 0.12), transparent 26%),
    linear-gradient(180deg, #ffffff 0%, var(--bg) 48%, var(--bg-contrast) 100%);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
}

a {
  color: inherit;
}

.page {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
  padding: 28px 0 32px;
}

.top-nav {
  position: sticky;
  top: 16px;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(12px);
}

.brand {
  margin: 0;
  font-size: 1.2rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  line-height: 1;
}

.brand-cube {
  color: var(--accent);
}

.brand-delta {
  color: var(--accent-secondary);
}

.login-link,
.contact-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 18px;
  overflow: hidden;
  border: 1px solid transparent;
  border-radius: 999px;
  background: linear-gradient(120deg, var(--accent), var(--accent-secondary));
  box-shadow: var(--shadow-soft);
  color: #0b1320;
  font-weight: 720;
  scroll-margin-top: 120px;
  text-align: center;
  text-decoration: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
  white-space: nowrap;
}

.login-link:hover,
.contact-link:hover {
  box-shadow: var(--shadow);
  filter: brightness(1.02);
  transform: translateY(-1px);
}

.login-link:target {
  animation: portal-target-pulse 1.8s ease-in-out infinite;
  outline: 3px solid rgba(9, 227, 176, 0.34);
  outline-offset: 4px;
}

.login-link:target::after {
  position: absolute;
  inset: -35% -70%;
  background: linear-gradient(110deg, transparent 35%, rgba(255, 255, 255, 0.72) 50%, transparent 65%);
  content: "";
  pointer-events: none;
  transform: translateX(-55%);
  animation: portal-target-shine 1.6s ease-in-out infinite;
}

@keyframes portal-target-shine {
  from {
    transform: translateX(-55%);
  }
  to {
    transform: translateX(55%);
  }
}

@keyframes portal-target-pulse {
  0%,
  100% {
    box-shadow: var(--shadow-soft);
  }
  50% {
    box-shadow: 0 0 0 8px rgba(245, 118, 190, 0.12), var(--shadow);
  }
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(300px, 0.95fr);
  gap: 36px;
  align-items: center;
  padding: 54px 0 34px;
}

.hero h1 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(2.35rem, 4.8vw, 4.9rem);
  font-weight: 820;
  line-height: 0.98;
}

.hero p {
  max-width: 620px;
  margin: 22px 0 0;
  color: var(--text-muted);
  font-size: 1.04rem;
  line-height: 1.65;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.signal {
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--panel-gradient), var(--card);
  box-shadow: var(--shadow);
}

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

.metric {
  min-height: 130px;
  padding: 22px 20px;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.36);
}

.metric:nth-child(2n) {
  border-right: 0;
}

.metric:nth-last-child(-n + 2) {
  border-bottom: 0;
}

.metric strong {
  display: block;
  color: var(--text);
  font-size: 2rem;
  line-height: 1;
}

.metric span {
  display: block;
  margin-top: 10px;
  color: var(--text-muted);
  line-height: 1.45;
}

.section {
  padding: 30px 0;
}

.section h2 {
  margin: 0 0 18px;
  font-size: 1.45rem;
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.service {
  min-height: 250px;
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: linear-gradient(180deg, #ffffff 0%, #f9fbff 100%);
  box-shadow: var(--shadow-soft);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.service:hover {
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}

.service h3 {
  margin: 0;
  font-size: 1.04rem;
}

.service p {
  min-height: 48px;
  margin: 12px 0 16px;
  color: var(--text-muted);
  line-height: 1.5;
}

.service ul {
  margin: 0;
  padding-left: 18px;
  color: var(--text-muted);
  line-height: 1.55;
}

.contact-band {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--panel-gradient), var(--card);
  box-shadow: var(--shadow-soft);
}

.contact-band p {
  margin: 6px 0 0;
  color: var(--text-muted);
  line-height: 1.55;
}

footer {
  padding-top: 26px;
  color: var(--text-muted);
  font-size: 0.9rem;
}

@media (max-width: 920px) {
  .hero {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 620px) {
  .page {
    width: min(100% - 28px, 1120px);
    padding-top: 18px;
    text-align: center;
  }

  .top-nav,
  .contact-band {
    align-items: center;
    flex-direction: column;
    text-align: center;
  }

  .brand {
    width: 100%;
    font-size: 2.4rem;
    text-align: center;
  }

  .top-nav .login-link {
    display: none;
  }

  .service ul {
    padding-left: 0;
    list-style-position: inside;
  }

  .hero {
    padding-top: 28px;
  }

  .hero-actions {
    justify-content: center;
  }

  .signal-grid,
  .service-grid {
    grid-template-columns: 1fr;
  }

  .metric,
  .metric:nth-child(2n),
  .metric:nth-last-child(-n + 2) {
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }

  .metric:last-child {
    border-bottom: 0;
  }

  .login-link,
  .contact-link {
    width: min(320px, calc(100% - 32px));
    min-height: 44px;
    margin-right: auto;
    margin-left: auto;
    padding-right: 16px;
    padding-left: 16px;
    white-space: normal;
  }
}
