:root {
  --nav-height: 72px;

  --font-body: "IBM Plex Sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-heading: "Space Grotesk", "IBM Plex Sans", system-ui, sans-serif;

  --bg: #f3f6f8;
  --surface: #ffffff;
  --surface-muted: #eaf0f5;
  --surface-strong: #dfe8ef;

  --text: #122131;
  --text-muted: #3f4d5c;

  --brand: #0e4e81;
  --brand-strong: #0a3d66;
  --accent: #c33325;
  --accent-strong: #9f261d;

  --border: #d2dbe4;
  --shadow-soft: 0 10px 32px rgba(12, 30, 52, 0.08);

  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 18px;

  --space-xs: 0.5rem;
  --space-sm: 0.875rem;
  --space-md: 1.25rem;
  --space-lg: 1.75rem;
  --space-xl: 2.5rem;
}

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

body {
  font-family: var(--font-body);
  line-height: 1.6;
  color: var(--text);
  background: linear-gradient(180deg, #f8fafc 0%, var(--bg) 36%, #edf2f6 100%);
  padding-top: var(--nav-height);
}

body.updates-view {
  padding-top: 0;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  letter-spacing: -0.015em;
  line-height: 1.15;
  color: #091727;
}

a {
  color: var(--brand);
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid rgba(14, 78, 129, 0.35);
  outline-offset: 2px;
}

section[id],
footer[id] {
  scroll-margin-top: calc(var(--nav-height) + 18px);
}

.top-nav {
  border-bottom: 1px solid var(--border);
  background-color: rgba(248, 251, 253, 0.95);
  backdrop-filter: blur(9px);
}

.top-nav .nav-link {
  color: #24303d;
  font-weight: 500;
}

.top-nav .nav-link:hover,
.top-nav .nav-link:focus-visible {
  color: var(--brand-strong);
}

.top-nav .nav-link.active {
  color: var(--brand);
  font-weight: 700;
}

.brand-logo {
  height: 28px;
  width: auto;
}

.section-shell {
  padding: clamp(3rem, 5vw, 4.5rem) 0;
}

.section-alt {
  background-color: var(--surface-muted);
  border-top: 1px solid rgba(255, 255, 255, 0.7);
  border-bottom: 1px solid rgba(210, 219, 228, 0.65);
}

.better-way-shell {
  background: linear-gradient(180deg, #e8f0f7 0%, #edf4fa 100%);
  border-top: 1px solid rgba(210, 219, 228, 0.8);
  border-bottom: 1px solid rgba(210, 219, 228, 0.8);
}

.section-title {
  margin-bottom: 1rem;
  text-align: center;
}

.section-intro {
  max-width: 760px;
  margin: 0 auto 2rem;
  text-align: center;
  color: var(--text-muted);
}

.surface-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
}

.hero-section {
  padding-top: 1.5rem;
}

.hero-panel {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  border: 1px solid #bfcddb;
  padding: clamp(1.5rem, 4vw, 2.8rem);
  background-image: linear-gradient(120deg, rgba(7, 22, 37, 0.74), rgba(16, 61, 99, 0.68)), url("../background.jpg");
  background-size: cover;
  background-position: center;
  box-shadow: 0 18px 42px rgba(7, 22, 37, 0.28);
}

.hero-grid {
  display: grid;
  gap: clamp(1.5rem, 4vw, 2.5rem);
  align-items: center;
}

.hero-copy {
  color: #f0f6fb;
}

.hero-copy h1 {
  color: #ffffff;
  font-size: clamp(2rem, 4vw, 3rem);
  margin-top: 1.2rem;
  margin-bottom: 1rem;
}

.hero-copy p {
  max-width: 60ch;
  color: rgba(241, 247, 252, 0.95);
}

.hero-logo {
  width: min(300px, 85%);
  height: auto;
}

.logo-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 12px;
  padding: 0.45rem 0.75rem;
}

.demo-card {
  background: rgba(14, 78, 129, 0.94);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-md);
  padding: 1.25rem;
}

.demo-card h5 {
  color: #ffffff;
  margin-bottom: 0.65rem;
}

.demo-card p {
  color: rgba(255, 255, 255, 0.95);
  margin-bottom: 1rem;
}

.btn-cta {
  border-radius: 999px;
  padding-inline: 1.2rem;
  font-weight: 600;
}

.btn-primary.btn-cta {
  background-color: var(--accent);
  border-color: var(--accent);
}

.btn-primary.btn-cta:hover,
.btn-primary.btn-cta:focus-visible {
  background-color: var(--accent-strong);
  border-color: var(--accent-strong);
}

.text-block {
  max-width: 860px;
  margin-inline: auto;
}

.better-way-panel {
  padding: clamp(1.2rem, 3vw, 2rem);
  border-color: #b7c9d9;
  background:
    linear-gradient(135deg, rgba(14, 78, 129, 0.08) 0%, rgba(255, 255, 255, 0.9) 45%),
    var(--surface);
}

.better-way-kicker {
  display: inline-block;
  margin: 0 0 0.6rem;
  padding: 0.16rem 0.65rem;
  border-radius: 999px;
  border: 1px solid rgba(14, 78, 129, 0.3);
  background: rgba(14, 78, 129, 0.08);
  color: var(--brand-strong);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.better-way-panel .section-title {
  text-align: left;
  margin-bottom: 0.8rem;
}

.better-way-lead {
  margin-bottom: 1.1rem;
  color: var(--text-muted);
  max-width: 72ch;
}

.better-way-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.8rem;
}

.better-way-item {
  background: rgba(255, 255, 255, 0.86);
  border: 1px solid rgba(183, 201, 217, 0.95);
  border-left: 4px solid var(--accent);
  border-radius: var(--radius-md);
  padding: 0.9rem 1rem;
}

.better-way-item h3 {
  margin-bottom: 0.45rem;
}

.better-way-item p {
  margin: 0;
  color: var(--text-muted);
}

.text-block ul {
  padding-left: 1.2rem;
}

.text-block li + li {
  margin-top: 0.55rem;
}

.feature-grid,
.ops-grid,
.adopter-grid,
.updates-grid,
.archive-grid {
  display: grid;
  gap: 1rem;
}

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

.feature-card,
.ops-card,
.adopter-card,
.update-featured,
.update-card,
.footer-panel {
  padding: 1.1rem 1.2rem;
}

.feature-card {
  display: flex;
  gap: 0.9rem;
  height: 100%;
}

.feature-card p,
.ops-card p,
.update-featured p,
.update-card p {
  color: var(--text-muted);
  margin-bottom: 0;
}

.icon-chip {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  display: inline-grid;
  place-items: center;
  background: #e4eef7;
  color: var(--brand);
  flex-shrink: 0;
}

.icon-chip i {
  font-size: 1.3rem;
}

.ops-card {
  height: 100%;
  text-align: center;
}

.adopter-card {
  height: 100%;
}

.adopter-card h3 {
  margin-bottom: 0.55rem;
}

.adopter-card p {
  color: var(--text-muted);
  margin-bottom: 0;
}

.ops-icons {
  min-height: 52px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.35rem;
  color: var(--brand);
  margin-bottom: 0.5rem;
}

.ops-icons i {
  font-size: 1.25rem;
}

.updates-shell {
  background: linear-gradient(180deg, #f5f8fb 0%, #eef3f8 100%);
  border-top: 1px solid rgba(210, 219, 228, 0.7);
  border-bottom: 1px solid rgba(210, 219, 228, 0.7);
}

.update-kicker {
  display: inline-block;
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--brand-strong);
  margin-bottom: 0.5rem;
}

.update-meta {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin-bottom: 0.5rem;
}

.update-date {
  font-size: 0.92rem;
  color: var(--text-muted);
}

.update-type {
  display: inline-block;
  border: 1px solid rgba(14, 78, 129, 0.3);
  border-radius: 999px;
  padding: 0.14rem 0.65rem;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--brand-strong);
  background: rgba(14, 78, 129, 0.08);
}

.update-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.8rem;
  font-weight: 600;
  text-decoration: none;
}

.update-link:hover,
.update-link:focus-visible {
  text-decoration: underline;
}

.updates-actions {
  margin-top: 1.5rem;
  text-align: center;
}

.updates-empty {
  margin: 0;
  color: var(--text-muted);
}

.update-post-shell {
  padding-top: 2.25rem;
}

.update-post-shell .container {
  max-width: 940px;
}

.update-post-card {
  width: min(100%, 860px);
  max-width: 860px;
  margin-inline: auto;
  padding: clamp(1.2rem, 3vw, 2rem);
}

.update-post-card h1 {
  margin-bottom: 0.8rem;
}

.update-post-summary {
  margin-bottom: 1.15rem;
  color: var(--text-muted);
  max-width: 70ch;
}

.update-post-content p {
  margin-bottom: 0.95rem;
}

.update-post-content p:last-child {
  margin-bottom: 0;
}

.update-post-lead {
  font-size: 1.08rem;
}

.update-post-nav {
  margin-top: 1.4rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  display: flex;
  gap: 0.6rem;
  justify-content: space-between;
  flex-wrap: wrap;
}

.update-post-nav-error {
  margin-top: 0.9rem;
  margin-bottom: 0;
  color: var(--text-muted);
}

.site-footer {
  padding: 2.5rem 0 3rem;
}

.footer-panel {
  display: grid;
  gap: 1.25rem;
}

.footer-lead {
  color: var(--text-muted);
  margin: 0;
}

.footer-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.footer-brand {
  width: 152px;
  height: 75px;
  border-radius: 10px;
  border: 2px solid #c33325;
}

.footer-meta {
  margin-top: 0.9rem;
  font-size: 0.95rem;
  color: var(--text-muted);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  column-gap: 0.9rem;
  row-gap: 0.6rem;
}

#back-to-top {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 1030;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
}

#back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.archive-hero {
  padding: 2.5rem 0 1.5rem;
}

.archive-hero h1 {
  margin-bottom: 0.9rem;
}

.archive-hero p {
  max-width: 68ch;
  color: var(--text-muted);
  margin-bottom: 0;
}

.archive-grid .update-card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.45rem;
}

@media (min-width: 992px) {
  .hero-grid {
    grid-template-columns: 1.2fr minmax(280px, 420px);
  }

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

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

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

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

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

  .footer-panel {
    grid-template-columns: 1.5fr auto;
    align-items: center;
  }

  .footer-actions {
    justify-content: flex-end;
  }
}

@media (min-width: 768px) and (max-width: 991.98px) {
  .better-way-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 768px) and (max-width: 991.98px) {
  .adopter-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 991.98px) {
  .section-shell {
    padding: 2.4rem 0;
  }

  .hero-panel {
    border-radius: 18px;
  }

  .better-way-panel .section-title {
    text-align: center;
  }

  .feature-grid,
  .ops-grid,
  .updates-grid,
  .archive-grid {
    grid-template-columns: 1fr;
  }

  .update-post-nav {
    justify-content: flex-start;
  }
}
