:root {
  color-scheme: light;
  --bg: #f6f7f4;
  --surface: #ffffff;
  --ink: #15211d;
  --muted: #66706d;
  --soft: #e6eae5;
  --line: #d6ddd7;
  --dark: #18231f;
  --green: #0e7c66;
  --blue: #315f93;
  --coral: #d86d4a;
  --gold: #b78b33;
  --shadow: 0 24px 70px rgb(29 45 39 / 14%);
  --page-bg:
    radial-gradient(circle at top left, rgb(49 95 147 / 12%), transparent 30%),
    linear-gradient(180deg, #fbfcfa 0%, var(--bg) 46%, #eef2ef 100%);
  --glass-bg: rgb(255 255 255 / 58%);
  --button-bg: var(--ink);
  --button-fg: #ffffff;
  --feature-primary-bg: var(--dark);
  --feature-primary-fg: #ffffff;
  --feature-primary-muted: #adc5bc;
  --feature-primary-body: #d7e4df;
  --feature-primary-link: #7de2c6;
  --mockup-bg:
    linear-gradient(135deg, rgb(255 255 255 / 82%), rgb(255 255 255 / 42%)),
    radial-gradient(circle at 78% 18%, rgb(216 109 74 / 18%), transparent 28%),
    #edf1ed;
  --device-bg: #ffffff;
  --device-bar-bg: #f7f8f5;
  --screen-bg:
    linear-gradient(135deg, rgb(14 124 102 / 8%), transparent 42%),
    linear-gradient(180deg, #ffffff, #f3f6f2);
  --paper-bg: #fffdf7;
  --paper-ink: #15211d;
  --paper-line: #dfe3dc;
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0b1110;
  --surface: #121a17;
  --ink: #eef7f3;
  --muted: #a6b2ad;
  --soft: #25312d;
  --line: #2d3934;
  --dark: #eef7f3;
  --green: #7ddcc3;
  --blue: #9abce8;
  --coral: #ff9f79;
  --gold: #e1bf70;
  --shadow: 0 24px 70px rgb(0 0 0 / 32%);
  --page-bg:
    radial-gradient(circle at top left, rgb(125 220 195 / 13%), transparent 30%),
    linear-gradient(180deg, #0e1513 0%, #0b1110 52%, #101714 100%);
  --glass-bg: rgb(18 26 23 / 72%);
  --button-bg: #eef7f3;
  --button-fg: #101714;
  --feature-primary-bg: #dcebe4;
  --feature-primary-fg: #101714;
  --feature-primary-muted: #4f625c;
  --feature-primary-body: #263a33;
  --feature-primary-link: #0b6855;
  --mockup-bg:
    linear-gradient(135deg, rgb(21 31 27 / 92%), rgb(18 26 23 / 72%)),
    radial-gradient(circle at 78% 18%, rgb(255 159 121 / 15%), transparent 30%),
    #111916;
  --device-bg: #15201c;
  --device-bar-bg: #111916;
  --screen-bg:
    linear-gradient(135deg, rgb(125 220 195 / 12%), transparent 42%),
    linear-gradient(180deg, #16221e, #101714);
  --paper-bg: #f4f0e8;
  --paper-ink: #16211d;
  --paper-line: #cfd7cf;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

a {
  color: inherit;
}

.site-header,
main,
footer {
  width: min(100% - 40px, 1120px);
  margin: 0 auto;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 28px 0;
}

.brand {
  font-size: 1.08rem;
  font-weight: 800;
  letter-spacing: 0;
  text-decoration: none;
}

nav {
  display: flex;
  gap: 20px;
  margin-left: auto;
  color: var(--muted);
  font-size: 0.95rem;
}

nav a,
.text-link,
.back-link,
.feature-card a,
.archive-row {
  text-decoration: none;
}

nav a:hover,
.text-link:hover,
.back-link:hover,
.feature-card a:hover {
  color: var(--green);
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid rgb(21 33 29 / 10%);
  border-radius: 999px;
  background: var(--glass-bg);
  color: var(--ink);
  font: inherit;
  font-size: 0.9rem;
  font-weight: 760;
  cursor: pointer;
}

:root[data-theme="dark"] .theme-toggle {
  border-color: rgb(238 247 243 / 14%);
}

.theme-toggle:hover {
  color: var(--green);
}

.theme-toggle-icon {
  position: relative;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: var(--ink);
}

.theme-toggle-icon::after {
  content: "";
  position: absolute;
  top: 2px;
  right: 2px;
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: var(--bg);
  transform: scale(0);
  transform-origin: center;
  transition: transform 160ms ease;
}

:root[data-theme="dark"] .theme-toggle-icon::after {
  transform: scale(1);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 0.96fr) minmax(420px, 1.04fr);
  gap: 54px;
  align-items: center;
  min-height: calc(100vh - 94px);
  padding: 34px 0 70px;
}

.hero-copy h1 {
  max-width: 720px;
  margin: 0 0 22px;
  font-size: clamp(4rem, 11vw, 8.8rem);
  line-height: 0.86;
  letter-spacing: 0;
}

.hero-copy p {
  max-width: 600px;
  margin: 0;
  color: var(--muted);
  font-size: 1.18rem;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 34px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  border-radius: 6px;
  background: var(--button-bg);
  color: var(--button-fg);
  font-weight: 800;
  text-decoration: none;
}

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

.text-link {
  color: var(--muted);
  font-weight: 760;
}

.mockup-board {
  position: relative;
  min-height: 560px;
  margin: 0;
  border-radius: 28px;
  background: var(--mockup-bg);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.mockup-board::before {
  content: "";
  position: absolute;
  inset: 34px;
  border: 1px solid rgb(21 33 29 / 8%);
  border-radius: 22px;
}

.device {
  position: absolute;
  background: var(--device-bg);
  box-shadow: 0 18px 50px rgb(20 32 28 / 18%);
}

.laptop {
  left: 44px;
  right: 44px;
  top: 72px;
  height: 270px;
  border-radius: 18px;
  overflow: hidden;
}

.device-bar {
  display: flex;
  gap: 7px;
  height: 38px;
  align-items: center;
  padding: 0 16px;
  border-bottom: 1px solid var(--soft);
  background: var(--device-bar-bg);
}

.device-bar span {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--line);
}

.device-bar span:nth-child(1) {
  background: var(--coral);
}

.device-bar span:nth-child(2) {
  background: var(--gold);
}

.device-bar span:nth-child(3) {
  background: var(--green);
}

.screen {
  height: calc(100% - 38px);
  padding: 34px;
  background:
    var(--screen-bg);
}

.screen-kicker {
  margin: 0 0 12px;
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.screen h2 {
  max-width: 410px;
  margin: 0 0 12px;
  font-size: 2.14rem;
  line-height: 1.02;
}

.screen p:not(.screen-kicker) {
  display: none;
}

.phone {
  right: 44px;
  bottom: 44px;
  width: 176px;
  min-height: 244px;
  padding: 44px 20px 22px;
  border: 8px solid #111917;
  border-radius: 34px;
}

.phone-notch {
  position: absolute;
  top: 16px;
  left: 50%;
  width: 56px;
  height: 6px;
  border-radius: 999px;
  background: #111917;
  transform: translateX(-50%);
}

.phone p {
  margin: 0 0 18px;
  color: var(--coral);
  font-size: 0.78rem;
  font-weight: 850;
  text-transform: uppercase;
}

.phone strong {
  display: block;
  margin-bottom: 16px;
  font-size: 1.4rem;
  line-height: 1.08;
}

.phone span {
  color: var(--muted);
}

.paper-card {
  position: absolute;
  left: 70px;
  bottom: 58px;
  width: 250px;
  padding: 24px;
  border: 1px solid rgb(21 33 29 / 10%);
  border-radius: 16px;
  background: var(--paper-bg);
  color: var(--paper-ink);
  box-shadow: 0 14px 40px rgb(20 32 28 / 12%);
  transform: rotate(-3deg);
}

.paper-card span {
  display: block;
  margin-bottom: 14px;
  color: var(--blue);
  font-size: 0.78rem;
  font-weight: 850;
  text-transform: uppercase;
}

.paper-card strong {
  display: block;
  padding: 9px 0;
  border-top: 1px solid var(--paper-line);
}

.feature-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.9fr 0.9fr;
  gap: 18px;
  padding: 54px 0;
}

.feature-card {
  min-height: 310px;
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: color-mix(in srgb, var(--surface) 82%, transparent);
}

.feature-card-primary {
  background: var(--feature-primary-bg);
  color: var(--feature-primary-fg);
}

.feature-card .meta {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 760;
}

.feature-card-primary .meta {
  color: var(--feature-primary-muted);
}

.feature-card h2 {
  margin: 0 0 14px;
  font-size: 1.75rem;
  line-height: 1.08;
}

.feature-card p:not(.meta) {
  margin: 0 0 24px;
  color: var(--muted);
}

.feature-card-primary p:not(.meta) {
  color: var(--feature-primary-body);
}

.feature-card a {
  color: var(--green);
  font-weight: 850;
}

.feature-card-primary a {
  color: var(--feature-primary-link);
}

.archive {
  padding: 54px 0 92px;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 28px;
}

.section-heading h2 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 4.5rem);
  line-height: 0.96;
}

.section-heading p {
  max-width: 390px;
  margin: 0;
  color: var(--muted);
}

.archive-list {
  border-top: 1px solid var(--line);
}

.archive-row {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr) 130px;
  gap: 24px;
  align-items: center;
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
}

.archive-row span,
.archive-row em {
  color: var(--muted);
  font-size: 0.9rem;
  font-style: normal;
}

.archive-row strong {
  font-size: 1.18rem;
}

.archive-row:hover strong {
  color: var(--green);
}

.post {
  display: grid;
  grid-template-columns: minmax(180px, 0.32fr) minmax(0, 0.68fr);
  gap: 56px;
  padding: 76px 0 96px;
}

.post-sidebar {
  color: var(--muted);
  font-size: 0.92rem;
}

.back-link {
  display: inline-block;
  margin-bottom: 36px;
  color: var(--muted);
}

.post-tag {
  display: inline-block;
  margin-bottom: 14px;
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.post-body {
  max-width: 720px;
}

.post-body h1 {
  margin: 0 0 16px;
  font-size: clamp(2.65rem, 7vw, 5.6rem);
  line-height: 0.94;
  letter-spacing: 0;
}

.post-meta {
  margin: 0 0 38px;
  color: var(--muted);
}

.post-body p,
.post-body li {
  font-size: 1.1rem;
}

.post-body h2 {
  margin: 42px 0 12px;
  font-size: 1.75rem;
  line-height: 1.18;
}

.post-body blockquote {
  margin: 34px 0;
  padding: 20px 24px;
  border-left: 4px solid var(--green);
  background: rgb(255 255 255 / 70%);
  color: var(--ink);
  font-size: 1.12rem;
}

.post-body ul {
  padding-left: 22px;
}

footer {
  padding: 30px 0 42px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.92rem;
}

footer p {
  margin: 0;
}

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

  .hero {
    min-height: auto;
  }

  .mockup-board {
    min-height: 500px;
  }

  .section-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .archive-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }
}

@media (max-width: 640px) {
  .site-header,
  main,
  footer {
    width: min(100% - 28px, 1120px);
  }

  .site-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 14px;
    padding: 20px 0 14px;
  }

  nav {
    width: 100%;
    margin-left: 0;
    gap: 6px;
    padding: 5px;
    border: 1px solid color-mix(in srgb, var(--ink) 10%, transparent);
    border-radius: 999px;
    background: var(--glass-bg);
    box-shadow: 0 10px 28px rgb(29 45 39 / 7%);
    font-size: 0.92rem;
  }

  nav a {
    flex: 1 1 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 36px;
    padding: 0 12px;
    border-radius: 999px;
    color: var(--ink);
    font-weight: 760;
  }

  nav a:hover {
    background: rgb(14 124 102 / 8%);
  }

  .site-header {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
  }

  .brand {
    grid-column: 1;
  }

  .theme-toggle {
    grid-column: 2;
    grid-row: 1;
    min-height: 36px;
    padding: 0 10px;
    font-size: 0.86rem;
  }

  nav {
    grid-column: 1 / -1;
  }

  .hero {
    gap: 30px;
    padding: 16px 0 38px;
  }

  .hero-copy h1 {
    margin-bottom: 16px;
    font-size: clamp(3rem, 18vw, 4.45rem);
    line-height: 0.9;
  }

  .hero-copy p {
    font-size: 1.02rem;
    line-height: 1.48;
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
    gap: 14px;
    margin-top: 26px;
  }

  .button {
    width: 100%;
    min-height: 48px;
  }

  .mockup-board {
    min-height: 380px;
    border-radius: 18px;
    box-shadow: 0 18px 45px rgb(29 45 39 / 12%);
  }

  .mockup-board::before {
    inset: 16px;
    border-radius: 16px;
  }

  .laptop {
    left: 18px;
    right: 18px;
    top: 34px;
    height: 216px;
    border-radius: 15px;
  }

  .device-bar {
    height: 34px;
  }

  .screen {
    height: calc(100% - 34px);
    padding: 24px;
  }

  .screen-kicker {
    margin-bottom: 10px;
    font-size: 0.7rem;
  }

  .screen h2 {
    max-width: 260px;
    font-size: 1.65rem;
    line-height: 1.04;
  }

  .paper-card {
    left: 26px;
    bottom: 24px;
    width: min(228px, calc(100% - 52px));
    padding: 18px;
    border-radius: 14px;
    transform: rotate(-2deg);
  }

  .paper-card span {
    margin-bottom: 8px;
    font-size: 0.68rem;
  }

  .paper-card strong {
    padding: 7px 0;
    font-size: 0.95rem;
  }

  .phone {
    display: none;
  }

  .feature-grid {
    gap: 14px;
    padding: 34px 0;
  }

  .feature-card {
    min-height: auto;
    padding: 22px;
    border-radius: 14px;
  }

  .feature-card h2 {
    font-size: 1.48rem;
  }

  .archive {
    padding: 38px 0 64px;
  }

  .section-heading {
    gap: 14px;
    margin-bottom: 20px;
  }

  .section-heading h2 {
    font-size: 2.28rem;
  }

  .archive-row {
    padding: 18px 0;
  }

  .archive-row strong {
    font-size: 1.05rem;
    line-height: 1.3;
  }

  .post {
    gap: 24px;
    padding: 28px 0 68px;
  }

  .post-sidebar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 10px;
    align-items: center;
    padding-bottom: 4px;
  }

  .back-link {
    width: 100%;
    margin-bottom: 8px;
    color: var(--ink);
    font-weight: 760;
  }

  .post-sidebar p {
    margin: 0;
    padding: 5px 10px;
    border: 1px solid color-mix(in srgb, var(--ink) 10%, transparent);
    border-radius: 999px;
    background: var(--glass-bg);
    color: var(--muted);
    font-size: 0.84rem;
  }

  .post-body h1 {
    font-size: clamp(2.25rem, 12vw, 3.1rem);
    line-height: 0.98;
  }

  .post-body p,
  .post-body li {
    font-size: 1.02rem;
  }

  .post-body blockquote {
    margin: 26px 0;
    padding: 18px;
  }
}
