/* ─── Design Tokens ──────────────────────────────────────────── */
:root {
  /* Colors */
  --ink:     #221d18;
  --ink-2:   #4a4138;
  --paper:   #f4efe6;
  --paper-2: #ebe4d7;
  --muted:   #9a8f80;
  --line:    #2a241e;
  --accent:  #c2410c;

  /* Fonts */
  --sans: "Zen Kaku Gothic New", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", monospace;

  /* Spacing — 8px grid */
  --sp-1:  8px;
  --sp-2: 16px;
  --sp-3: 24px;
  --sp-4: 32px;
  --sp-5: 40px;
  --sp-6: 48px;
  --sp-7: 56px;
  --sp-8: 64px;
  --sp-9: 72px;
}

/* ─── Reset ──────────────────────────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.7;
  color: var(--ink);
  background-color: var(--paper);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a:hover {
  color: var(--accent);
  text-decoration: underline;
}

ul {
  list-style: none;
}

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

/* ─── Layout ─────────────────────────────────────────────────── */
.container {
  max-width: 720px;
  margin-inline: auto;
  padding-inline: var(--sp-3);
}

/* ─── Header ─────────────────────────────────────────────────── */
.site-header {
  padding-block: var(--sp-3);
  border-bottom: 1px solid rgba(42, 36, 30, 0.1);
}

.site-header__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.monogram {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.1em;
  color: var(--ink);
  text-decoration: none;
}

.monogram:hover {
  color: var(--ink);
  text-decoration: none;
}

.site-nav {
  display: flex;
  gap: var(--sp-3);
}

.site-nav a {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-2);
  text-decoration: none;
  letter-spacing: 0.05em;
}

.site-nav a:hover {
  color: var(--accent);
  text-decoration: underline;
}

/* ─── Hero ───────────────────────────────────────────────────── */
.hero {
  padding-block: var(--sp-9) var(--sp-7);
  text-align: center;
}

.hero__name {
  font-family: var(--sans);
  font-weight: 700;
  font-size: clamp(40px, 6vw, 52px);
  line-height: 1.2;
  color: var(--ink);
  letter-spacing: 0.02em;
}

.hero__subtitle {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--muted);
  margin-top: var(--sp-2);
  letter-spacing: 0.06em;
}

.hero__bio {
  font-size: 14px;
  color: var(--ink-2);
  max-width: 460px;
  margin-inline: auto;
  margin-top: var(--sp-3);
  line-height: 1.8;
}

/* ─── Section ────────────────────────────────────────────────── */
.section {
  padding-block: var(--sp-7);
}

.section-header {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: var(--sp-2);
  margin-bottom: var(--sp-4);
}

.section-header--simple {
  grid-template-columns: auto 1fr;
}

.section-label {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink);
}

.section-rule {
  height: 1px;
  background: rgba(42, 36, 30, 0.15);
}

.section-count {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.05em;
}

/* ─── App Cards ──────────────────────────────────────────────── */
.apps {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-3);
}

.app-card {
  display: flex;
  align-items: flex-start;
  gap: var(--sp-2);
  padding: var(--sp-2);
  border: 1.6px solid rgba(42, 36, 30, 0.18);
  border-radius: 6px;
  background: var(--paper-2);
  max-width: 440px;
  color: inherit;
  text-decoration: none;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.app-card:hover {
  color: inherit;
  text-decoration: none;
  border-color: rgba(42, 36, 30, 0.4);
  background: var(--paper);
}

.app-card__icon {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  flex-shrink: 0;
  object-fit: cover;
}

.app-card__body {
  flex: 1;
  min-width: 0;
}

.app-card__name {
  font-family: var(--sans);
  font-size: 17px;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.3;
}

.app-card__desc {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-2);
  margin-top: 6px;
  line-height: 1.5;
}

.app-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: var(--sp-1);
}

/* ─── Tags ───────────────────────────────────────────────────── */
.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  display: inline-block;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-2);
  border: 1.4px dashed rgba(42, 36, 30, 0.4);
  border-radius: 999px;
  padding: 4px 12px;
  line-height: 1.4;
}

/* ─── Footer ─────────────────────────────────────────────────── */
.site-footer {
  padding-block: var(--sp-5) var(--sp-6);
  margin-top: var(--sp-3);
  border-top: 1px solid rgba(42, 36, 30, 0.1);
}

.site-footer__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--sp-2);
}

.footer-copy {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted);
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
}

.footer-nav a {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted);
  text-decoration: none;
}

.footer-nav a:hover {
  color: var(--accent);
  text-decoration: underline;
}

/* ─── Legal Pages ────────────────────────────────────────────── */
.page-legal main {
  padding-block: var(--sp-6) var(--sp-9);
}

.breadcrumb {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-bottom: var(--sp-4);
}

.breadcrumb a {
  color: var(--muted);
  text-decoration: none;
}

.breadcrumb a:hover {
  color: var(--accent);
  text-decoration: underline;
}

.breadcrumb__sep {
  color: rgba(42, 36, 30, 0.3);
}

.page-title {
  font-family: var(--sans);
  font-size: 32px;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.2;
  margin-bottom: var(--sp-1);
}

.page-meta {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted);
  margin-bottom: var(--sp-4);
}

.page-divider {
  height: 1px;
  background: rgba(42, 36, 30, 0.15);
  margin-bottom: var(--sp-6);
}

.legal-content {
  display: flex;
  flex-direction: column;
  gap: var(--sp-5);
}

.legal-section h2 {
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: var(--sp-2);
}

.legal-section p,
.legal-section li {
  font-family: var(--sans);
  font-size: 13px;
  color: var(--ink-2);
  line-height: 1.8;
}

.legal-section p + p {
  margin-top: var(--sp-2);
}

.legal-section ul {
  padding-left: var(--sp-3);
  list-style: disc;
  margin-top: var(--sp-1);
}

.legal-section ul li {
  margin-bottom: 4px;
}

.legal-section a {
  color: var(--ink-2);
  text-decoration: underline;
}

.legal-section a:hover {
  color: var(--accent);
}

/* ─── Responsive ─────────────────────────────────────────────── */
@media (max-width: 640px) {
  .hero {
    padding-block: var(--sp-7) var(--sp-6);
  }

  .hero__name {
    font-size: 34px;
  }

  .site-footer__inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .page-title {
    font-size: 26px;
  }

  .app-card {
    max-width: 100%;
  }
}
