@font-face {
  font-family: Caladea;
  src: url('fonts/caladea-latin-400-normal.woff2') format('woff2');
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: Caladea;
  src: url('fonts/caladea-latin-700-normal.woff2') format('woff2');
  font-weight: 700 800;
  font-display: swap;
}

:root {
  --brand: #d9480f;
  --brand-dark: #b8350a;
  --brand-deep: #7c2d12;
  --brand-bright: #f97316;
  --tint: #fff7ed;
  --tint-strong: #ffedd5;
  --cream: #fffaf5;
  --ink: #1c1917;
  --body: #57534e;
  --line: #e7e5e4;
  --radius: 18px;
  --shadow: 0 1px 2px rgb(28 25 23 / 5%), 0 8px 24px rgb(28 25 23 / 5%);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 84px;
}

body {
  margin: 0;
  background: #fff;
  color: var(--ink);
  font-family: Cambria, Caladea, Georgia, 'Times New Roman', serif;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

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

h1,
h2,
h3,
p,
ul,
ol {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 3px;
  border-radius: 6px;
}

.wrap {
  width: min(1120px, 100% - 40px);
  margin-inline: auto;
}

/* Navigation */
.nav {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgb(255 255 255 / 88%);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 66px;
  gap: 16px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--ink);
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 0;
  text-decoration: none;
}

.logo img {
  width: 34px;
  height: 34px;
}

.logo span {
  color: var(--brand);
}

.logo b {
  font-weight: inherit;
}

.nav-links {
  display: flex;
  gap: 24px;
}

.nav-links a {
  color: var(--ink);
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--brand);
}

.nav-toggle {
  display: none;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}

/* Hero */
.hero {
  position: relative;
  overflow: hidden;
  padding: 72px 0 0;
  background:
    radial-gradient(46rem 30rem at 92% -6%, #fb923c 0%, transparent 68%),
    radial-gradient(36rem 26rem at -4% 88%, #fdba74 0%, transparent 70%),
    linear-gradient(160deg, #ffedd5 0%, #fed7aa 100%);
}

.hero .wrap {
  position: relative;
  z-index: 1;
}

.hero h1 {
  font-size: clamp(36px, 6vw, 68px);
  font-weight: 800;
  line-height: 1.06;
  letter-spacing: -0.01em;
}

.hero h1 span {
  color: var(--brand-dark);
}

.hero-text {
  max-width: 640px;
  margin-top: 18px;
  color: #44403c;
  font-size: 20px;
}

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

.button {
  display: inline-flex;
  align-items: center;
  min-height: 48px;
  padding: 10px 24px;
  border: 1.5px solid transparent;
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
  transition: transform 150ms ease;
}

.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  background: var(--brand);
  color: #fff;
  box-shadow: 0 8px 20px rgb(217 72 15 / 25%);
}

.button-ghost {
  border-color: var(--line);
  background: #fff;
  color: var(--ink);
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 38px;
}

.hero-stat {
  padding: 16px 20px;
  border: 1px solid var(--tint-strong);
  border-radius: var(--radius);
  background: #fff;
  color: var(--body);
  box-shadow: var(--shadow);
}

.hero-stat strong {
  display: block;
  color: var(--brand);
  font-size: 28px;
  font-weight: 800;
  line-height: 1.2;
}

.hero-visual {
  position: relative;
  margin-top: 40px;
  margin-bottom: -6px;
}

.hero-desktop {
  width: 88%;
  border: 1px solid var(--line);
  border-bottom: 0;
  border-radius: 16px 16px 0 0;
  box-shadow: 0 -8px 40px rgb(124 45 18 / 12%);
}

.hero-phone {
  position: absolute;
  right: 0;
  bottom: 24px;
  width: 23%;
  border: 6px solid #1c1917;
  border-radius: 28px;
  box-shadow: 0 20px 44px rgb(124 45 18 / 28%);
}

/* Sections */
section {
  padding: 80px 0;
}

.tinted {
  background: var(--cream);
  border-block: 1px solid var(--tint-strong);
}

.eyebrow {
  color: var(--brand);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h2 {
  margin-top: 6px;
  font-size: clamp(30px, 4.5vw, 42px);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.005em;
}

.section-text {
  max-width: 760px;
  margin-top: 12px;
  color: var(--body);
  font-size: 19px;
}

.grid {
  display: grid;
  gap: 18px;
  margin-top: 36px;
}

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

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

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

.card {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow);
}

.card h3 {
  font-size: 19px;
  font-weight: 800;
  line-height: 1.3;
}

.card p {
  margin-top: 6px;
  color: var(--body);
  font-size: 16px;
}

.card .big {
  color: var(--brand);
  font-size: 34px;
  font-weight: 800;
  line-height: 1.15;
}

.icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  margin-bottom: 14px;
  border-radius: 12px;
  background: var(--tint-strong);
  font-size: 22px;
}

.points {
  margin-top: 12px;
}

.points li {
  position: relative;
  padding-left: 22px;
  color: var(--body);
  font-size: 16px;
}

.points li + li {
  margin-top: 6px;
}

.points li::before {
  position: absolute;
  top: 0.62em;
  left: 4px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--brand-bright);
  content: '';
}

.points strong {
  color: var(--ink);
}

/* App tour */
.tour-title {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 48px;
  font-size: 24px;
  font-weight: 800;
}

.tour-title .tag {
  padding: 3px 12px;
  border-radius: 999px;
  background: var(--tint-strong);
  color: var(--brand-dark);
  font-size: 13px;
  font-weight: 800;
}

.step {
  display: grid;
  grid-template-columns: 330px 1fr;
  align-items: center;
  gap: 36px;
  margin-top: 28px;
}

.step-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  margin-bottom: 10px;
  border-radius: 50%;
  background: var(--brand);
  color: #fff;
  font-size: 15px;
  font-weight: 800;
}

.step h3 {
  font-size: 22px;
  font-weight: 800;
  line-height: 1.25;
}

.zoom {
  display: block;
  width: 100%;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  box-shadow: var(--shadow);
  cursor: zoom-in;
  transition: transform 150ms ease;
}

.zoom:hover {
  transform: translateY(-3px);
}

.phones {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
  margin-top: 28px;
}

.phone-step h3 {
  margin-top: 12px;
  font-size: 16px;
  font-weight: 800;
  line-height: 1.3;
}

.phone-step p {
  margin-top: 3px;
  color: var(--body);
  font-size: 14px;
  line-height: 1.45;
}

.phone-step .zoom {
  border: 4px solid var(--ink);
  border-radius: 22px;
}

.phone-step .number {
  color: var(--brand);
  font-weight: 800;
}

/* Ticket life cycle */
.lifecycle {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 28px;
}

.state {
  padding: 8px 18px;
  border-radius: 999px;
  background: var(--tint-strong);
  color: var(--brand-dark);
  font-weight: 800;
}

.state.end {
  background: #d1fae5;
  color: #065f46;
}

.state.out {
  background: #e7e5e4;
  color: #44403c;
}

.arrow {
  color: var(--brand);
  font-size: 20px;
  font-weight: 800;
}

.small-note {
  margin-top: 12px;
  color: var(--body);
  font-size: 15px;
}

/* Architecture */
.arch-stage {
  margin-top: 32px;
}

.arch-svg {
  display: block;
  width: 100%;
  height: auto;
  font-family: inherit;
}

.arch-tall {
  display: none;
  max-width: 420px;
  margin-inline: auto;
}

.arch-svg .stage {
  fill: var(--cream);
  stroke: var(--tint-strong);
}

.arch-svg text {
  text-anchor: middle;
}

.arch-svg .zone rect {
  fill: #fff;
  stroke: #fed7aa;
  stroke-width: 1.5;
}

.arch-svg .zt {
  fill: var(--ink);
  font-size: 18px;
  font-weight: 800;
}

.arch-svg .zh {
  fill: var(--brand);
  font-size: 12.5px;
  font-weight: 700;
}

.arch-svg .node rect {
  fill: var(--tint);
  stroke: var(--tint-strong);
}

.arch-svg .node.hot rect {
  fill: var(--brand);
  stroke: var(--brand);
}

.arch-svg .t {
  fill: var(--ink);
  font-size: 14px;
  font-weight: 800;
}

.arch-svg .s {
  fill: var(--body);
  font-size: 11.5px;
  font-weight: 500;
}

.arch-svg .node.hot .t,
.arch-svg .node.hot .s,
.arch-svg .t.light,
.arch-svg .s.light {
  fill: #fff;
}

.arch-svg .frame {
  fill: var(--ink);
}

.arch-svg .screen {
  fill: #fff7ed;
}

.arch-svg .dt {
  fill: var(--brand);
  font-size: 19px;
  font-weight: 800;
}

.arch-svg .ds {
  fill: var(--ink);
  font-size: 9.5px;
  font-weight: 700;
}

.arch-svg .who {
  fill: var(--ink);
  font-size: 15px;
  font-weight: 800;
}

.arch-svg .db path,
.arch-svg .db ellipse {
  fill: var(--brand);
  stroke: #fff;
  stroke-width: 2;
}

.arch-svg .db ellipse {
  fill: var(--brand-bright);
}

.arch-svg .tbl {
  fill: var(--brand-deep);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 11.5px;
  font-weight: 600;
}

.arch-svg .lab {
  fill: var(--brand-dark);
  font-size: 12.5px;
  font-weight: 800;
}

.arch-svg .lab.small {
  font-size: 11px;
}

.arch-svg .wire {
  fill: none;
  stroke: #fb923c;
  stroke-width: 2.5;
  stroke-dasharray: 8 7;
  animation: flow 1s linear infinite;
}

.arch-svg .wire.push {
  stroke: var(--brand);
  stroke-width: 3;
}

.arch-svg .wire.ci-line {
  stroke: #a8a29e;
  stroke-width: 2;
  animation: none;
}

.arch-svg .ah {
  fill: #fb923c;
}

.arch-svg .ahh {
  fill: var(--brand);
}

.arch-svg .ci rect {
  fill: #fff;
  stroke: #d6d3d1;
  stroke-dasharray: 6 5;
}

@keyframes flow {
  to {
    stroke-dashoffset: -15;
  }
}

.ci-note {
  display: none;
  padding: 12px 16px;
  margin-top: 14px;
  border: 1.5px dashed #d6d3d1;
  border-radius: 14px;
  background: #fff;
  font-size: 14px;
  font-weight: 600;
  text-align: center;
}

/* Data flow */
.flow h3 {
  margin-bottom: 14px;
}

.flow ol {
  counter-reset: flow;
}

.flow li {
  position: relative;
  padding-left: 38px;
  color: var(--body);
  font-size: 15.5px;
  counter-increment: flow;
}

.flow li + li {
  margin-top: 12px;
}

.flow li::before {
  position: absolute;
  top: 1px;
  left: 0;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--tint-strong);
  color: var(--brand-dark);
  content: counter(flow);
  font-size: 13px;
  font-weight: 800;
  line-height: 26px;
  text-align: center;
}

.flow strong,
td strong {
  color: var(--ink);
}

code {
  padding: 1px 6px;
  border-radius: 6px;
  background: var(--tint-strong);
  color: var(--brand-deep);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.86em;
  overflow-wrap: anywhere;
}

/* Tables */
.table-wrap {
  margin-top: 32px;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 16px;
}

th,
td {
  padding: 13px 18px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  background: var(--tint);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

td {
  color: var(--body);
}

tr:last-child td {
  border-bottom: 0;
}

.tech-group {
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--brand);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 10px;
}

.chips span {
  padding: 3px 11px;
  border-radius: 999px;
  background: var(--tint-strong);
  color: var(--brand-deep);
  font-size: 14px;
  font-weight: 700;
}

/* Footer */
footer {
  padding: 44px 0;
  background: var(--ink);
  color: #d6d3d1;
}

.foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

footer .logo {
  color: #fff;
}

footer .logo span {
  color: #fdba74;
}

footer a {
  color: #fdba74;
  font-weight: 700;
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgb(28 25 23 / 88%);
}

.lightbox.open {
  display: flex;
}

.lightbox img {
  max-width: 100%;
  max-height: 100%;
  border-radius: 12px;
}

.lightbox button {
  position: absolute;
  top: 14px;
  right: 16px;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 50%;
  background: #fff;
  color: var(--ink);
  font-size: 22px;
  font-weight: 800;
  cursor: pointer;
}

@media (max-width: 980px) {
  .nav-toggle {
    display: block;
  }

  .nav-links {
    position: absolute;
    top: 100%;
    right: 0;
    left: 0;
    display: none;
    flex-direction: column;
    gap: 0;
    padding: 8px 20px 14px;
    border-bottom: 1px solid var(--line);
    background: #fff;
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    padding: 10px 0;
  }

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

  .cols-3 {
    grid-template-columns: 1fr;
  }

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

}

@media (max-width: 680px) {
  body {
    font-size: 16px;
  }

  section {
    padding: 56px 0;
  }

  .hero {
    padding-top: 48px;
  }

  .hero-text {
    font-size: 18px;
  }

  .arch-wide {
    display: none;
  }

  .arch-tall,
  .ci-note {
    display: block;
  }

  .hero-stats,
  .cols-2,
  .cols-4 {
    grid-template-columns: 1fr;
  }

  .step {
    grid-template-columns: 1fr;
    gap: 14px;
  }

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

  .hero-desktop {
    width: 100%;
  }

  .hero-phone {
    display: none;
  }

  th,
  td {
    padding: 11px 13px;
  }
}

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

  .button,
  .zoom {
    transition: none;
  }

  .arch-svg .wire {
    animation: none;
  }
}
