:root {
  --bg: #f7f8fa;
  --surface: #ffffff;
  --surface-2: #eef3f0;
  --ink: #111827;
  --muted: #4b5563;
  --soft: #6b7280;
  --line: #e5e7eb;
  --primary: #0f766e;
  --primary-dark: #115e59;
  --accent: #f59e0b;
  --shadow: 0 16px 44px rgba(17, 24, 39, 0.06);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 16px 0;
  background: rgba(247, 248, 250, 0.9);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(229, 231, 235, 0.8);
  transform: translateY(0);
  transition: transform 220ms ease, opacity 220ms ease;
  will-change: transform;
}

body.header-hidden .site-header {
  opacity: 0;
  pointer-events: none;
  transform: translateY(calc(-100% - 16px));
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  /* font-weight: 650; */
  letter-spacing: 0;
}

.brand img {
  width: 36px;
  height: 36px;
  border-radius: 8px;
}

.nav {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 500;
}

.nav a {
  padding: 10px 12px;
  border-radius: 8px;
}

.nav a:hover {
  background: var(--surface-2);
  color: var(--ink);
}

.section {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 76px 0;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(360px, 0.8fr);
  align-items: center;
  gap: 56px;
  min-height: auto;
  padding-top: 72px;
  padding-bottom: 76px;
}

.eyebrow,
.tag {
  margin: 0 0 14px;
  color: var(--primary);
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  max-width: 560px;
  margin-bottom: 18px;
  font-size: clamp(34px, 4.4vw, 52px);
  font-weight: 500;
  line-height: 1.12;
  letter-spacing: 0;
  white-space: nowrap;
}

h2 {
  max-width: 760px;
  margin-bottom: 18px;
  font-size: clamp(28px, 3.4vw, 42px);
  font-weight: 500;
  line-height: 1.12;
  letter-spacing: 0;
}

.card-title {
  max-width: none;
  margin-bottom: 10px;
  font-size: 20px;
  font-weight: 500;
  line-height: 1.25;
}

.hero-text,
.section-heading + .split p,
.contact p,
.project-card p,
.update-card p {
  color: var(--muted);
  font-size: 16px;
  line-height: 1.7;
}

.hero-text {
  max-width: 560px;
  font-size: 16px;
}

.hero-points {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.hero-points span {
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.68);
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
}

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

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
}

.button.primary {
  border-color: var(--primary);
  background: var(--primary);
  color: #fff;
}

.button.primary:hover {
  background: var(--primary-dark);
}

.button.secondary {
  background: #fff;
}

.button.secondary:hover {
  border-color: #cbd5e1;
  background: var(--surface-2);
}

.product-preview {
  display: flex;
  justify-content: center;
}

.phone-shell,
.update-card,
.project-card,
.principles div,
.flow div,
.contribute-grid div {
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.phone-shell {
  --state-color: #2e7d4f;
  --state-soft: rgba(46, 125, 79, 0.12);
  --state-border: rgba(46, 125, 79, 0.42);
  width: min(100%, 350px);
  padding: 10px;
  border: 1px solid #17251b;
  border-radius: 38px;
  background: #07110b;
  color: #e8f0eb;
  box-shadow: 0 26px 70px rgba(13, 27, 18, 0.22);
}

.phone-shell.is-unlocked {
  --state-color: #ef5350;
  --state-soft: rgba(239, 83, 80, 0.12);
  --state-border: rgba(239, 83, 80, 0.38);
}

.phone-bezel {
  overflow: hidden;
  border: 1px solid #26392c;
  border-radius: 30px;
  background: #0d1b12;
}

.phone-statusbar {
  display: flex;
  justify-content: space-between;
  padding: 12px 20px 6px;
  color: #a3b8ab;
  font-size: 11px;
}

.app-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 18px 14px;
  background: #0d1b12;
}

.app-title {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-weight: 600;
}

.app-title img {
  width: 28px;
  height: 28px;
  border-radius: 7px;
}

.app-menu {
  color: #a3b8ab;
  font-size: 22px;
  line-height: 1;
}

.phone-content {
  padding: 14px 18px 18px;
}

.device-switcher {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
  padding: 12px 14px;
  border: 1px solid #1f3628;
  border-radius: 12px;
  background: #142a1b;
}

.device-switcher span,
.device-switcher small,
.lock-card strong,
.lock-card span,
.lock-card small {
  display: block;
}

.device-switcher span {
  margin-top: 3px;
  font-size: 15px;
  font-weight: 500;
}

.device-switcher small,
.lock-card span,
.lock-card small {
  color: #a3b8ab;
}

.connection-pill {
  padding: 7px 10px;
  border: 1px solid rgba(76, 175, 80, 0.35);
  border-radius: 999px;
  background: rgba(76, 175, 80, 0.12);
  color: #74d382;
  font-size: 12px;
}

.lock-card {
  display: grid;
  justify-items: center;
  padding: 24px 16px;
  border: 1px solid var(--state-border);
  border-radius: 24px;
  background: linear-gradient(145deg, var(--state-soft), rgba(26, 51, 36, 0.82));
  transition: border-color 180ms ease, background 180ms ease;
}

.lock-ring {
  position: relative;
  display: grid;
  place-items: center;
  width: 124px;
  height: 124px;
  margin-bottom: 20px;
  border: 2px solid color-mix(in srgb, var(--state-color) 35%, transparent);
  border-radius: 999px;
  background: var(--state-soft);
  transition: border-color 180ms ease, background 180ms ease;
}

.pulse-ring {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  border: 2px solid var(--state-color);
  opacity: 0;
}

.phone-shell.is-unlocked .pulse-ring {
  animation: pulse-ring 1.7s ease-out infinite;
}

.lock-icon {
  position: absolute;
  width: 76px;
  height: 76px;
  opacity: 0;
  transform: scale(0.86);
  transition: opacity 180ms ease, transform 180ms ease;
}

.lock-body-fill,
.lock-shackle {
  fill: var(--state-color);
}

.lock-key {
  fill: none;
  stroke: #0d1b12;
  stroke-linecap: round;
  stroke-width: 5;
}

.lock-icon-locked {
  opacity: 1;
  transform: scale(1);
}

.phone-shell.is-unlocked .lock-icon-locked {
  opacity: 0;
  transform: scale(0.86) rotate(-8deg);
}

.phone-shell.is-unlocked .lock-icon-unlocked {
  opacity: 1;
  transform: scale(1) rotate(0deg);
}

.lock-card strong {
  color: var(--state-color);
  font-size: 28px;
  font-weight: 600;
  letter-spacing: 0;
  transition: color 180ms ease;
}

.lock-card span {
  margin-top: 6px;
  font-size: 16px;
}

.lock-card small {
  margin-top: 12px;
  font-size: 12px;
}

.auto-lock {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  width: min(100%, 210px);
  margin-top: 16px;
  padding: 10px 14px;
  border: 1px solid rgba(245, 166, 35, 0.25);
  border-radius: 12px;
  background: rgba(245, 166, 35, 0.08);
  color: #f5a623;
}

.auto-lock > span:first-child {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.auto-lock span,
.auto-lock strong {
  color: #f5a623;
  font-weight: 600;
}

.auto-lock > span:first-child {
  font-size: 13px;
  line-height: 1;
}

.timer-dot {
  width: 14px;
  height: 14px;
  border: 2px solid #f5a623;
  border-radius: 999px;
}

.auto-lock-track {
  display: block;
  height: 4px;
  width: 100%;
  overflow: hidden;
  border-radius: 999px;
  background: #1f3628;
}

.auto-lock-track span {
  display: block;
  width: var(--countdown-progress, 100%);
  height: 100%;
  background: #f5a623;
  transition: width 180ms linear;
}

.slide-preview {
  --slide-x: 0px;
  --slide-progress: 50px;
  position: relative;
  display: grid;
  place-items: center;
  height: 54px;
  margin-top: 18px;
  border: 1px solid #1f3628;
  border-radius: 999px;
  background: #142a1b;
  color: #a3b8ab;
  font-size: 14px;
  font-weight: 500;
  cursor: grab;
  overflow: hidden;
  touch-action: pan-y;
  user-select: none;
}

.slide-preview:active {
  cursor: grabbing;
}

.slide-preview.is-animating .slide-thumb,
.slide-preview.is-animating .slide-fill {
  transition: transform 180ms ease, width 180ms ease;
}

.slide-fill {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: var(--slide-progress);
  border-radius: inherit;
  background: color-mix(in srgb, var(--state-color) 18%, transparent);
}

.slide-thumb {
  position: absolute;
  left: 4px;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 999px;
  background: var(--state-color);
  color: #fff;
  font-size: 20px;
  transform: translateX(var(--slide-x));
  z-index: 1;
  transition: background 180ms ease;
}

.slide-preview > span:last-child {
  position: relative;
  z-index: 1;
}

.refresh-preview {
  width: 100%;
  min-height: 48px;
  margin-top: 14px;
  border: 1px solid #2d4a36;
  border-radius: 8px;
  background: transparent;
  color: #e8f0eb;
  font: inherit;
  font-size: 14px;
  font-weight: 500;
}

.phone-nav {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  padding: 8px 12px 10px;
  border-top: 1px solid #1f3628;
  background: #142a1b;
}

.phone-nav span {
  display: grid;
  justify-items: center;
  gap: 4px;
  padding: 6px 4px;
  border-radius: 12px;
  color: #6b7f72;
  font-size: 11px;
  font-weight: 500;
  text-align: center;
}

.phone-nav svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.phone-nav .is-active {
  color: #2e7d4f;
}

.phone-nav .is-active svg {
  padding: 3px 12px;
  width: 46px;
  height: 24px;
  border-radius: 999px;
  background: rgba(46, 125, 79, 0.25);
}

@keyframes pulse-ring {
  0% {
    opacity: 0.38;
    transform: scale(0.94);
  }

  100% {
    opacity: 0;
    transform: scale(1.28);
  }
}

.section-heading {
  margin-bottom: 32px;
}

.updates,
.system,
.contribute {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.update-grid,
.project-list,
.contribute-grid {
  display: grid;
  gap: 16px;
}

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

.update-card,
.project-card,
.principles div,
.flow div,
.contribute-grid div {
  border-radius: 8px;
  padding: 24px;
}

.update-card .tag,
.project-card .tag {
  color: var(--accent);
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(320px, 1fr);
  gap: 44px;
}

.principles {
  display: grid;
  gap: 14px;
}

.principles strong,
.principles span,
.contribute-grid strong,
.contribute-grid span {
  display: block;
}

.principles strong,
.contribute-grid strong {
  margin-bottom: 8px;
  font-size: 17px;
  font-weight: 600;
}

.principles span,
.contribute-grid span {
  color: var(--muted);
  line-height: 1.6;
}

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

.flow span {
  display: inline-flex;
  margin-bottom: 26px;
  color: var(--primary);
  font-size: 13px;
  font-weight: 650;
}

.flow strong,
.flow small {
  display: block;
}

.flow strong {
  font-weight: 600;
}

.flow small {
  margin-top: 10px;
  color: var(--muted);
  line-height: 1.5;
}

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

.project-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(210px, 0.72fr);
  gap: 24px;
  min-height: 230px;
}

.project-card dl {
  display: grid;
  gap: 12px;
  align-content: start;
  margin: 0;
}

.project-card dt {
  color: var(--soft);
  font-size: 12px;
  font-weight: 650;
  text-transform: uppercase;
}

.project-card dd {
  margin: 4px 0 0;
  color: var(--ink);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.45;
}

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

.contact {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 32px;
}

.contact p {
  max-width: 720px;
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 36px;
  border-top: 1px solid var(--line);
  color: var(--soft);
  font-size: 14px;
}

@media (max-width: 940px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .nav {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .hero,
  .split,
  .contact {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
  }

  .update-grid,
  .project-list,
  .flow,
  .contribute-grid {
    grid-template-columns: 1fr;
  }

  .project-card {
    grid-template-columns: 1fr;
  }

  .contact {
    display: grid;
    align-items: start;
  }
}

@media (max-width: 560px) {
  .section {
    width: min(100% - 24px, 1180px);
    padding: 58px 0;
  }

  .site-header {
    width: min(100% - 24px, 1180px);
  }

  h1 {
    font-size: 32px;
    line-height: 1.14;
    white-space: normal;
  }

  h2 {
    font-size: 30px;
  }

  .phone-shell {
    width: min(100%, 330px);
  }

  .phone-content {
    padding: 12px 14px 16px;
  }

  .footer {
    flex-direction: column;
    width: min(100% - 24px, 1180px);
  }
}
