/* KINH Tech — shared styles.
   Plain CSS, no build step. Palette mirrors the app: teal shell, calculator
   green display, stone dark theme. */

:root {
  --shell: #0f766e;
  --shell-deep: #134e4a;
  --display: #9c9f86;
  --ink: #1c1917;
  --ink-soft: #44403c;
  --panel: #ffffff;
  --edge: #1c1917;
  --link: #0f766e;
  --muted: #57534e;
}

@media (prefers-color-scheme: dark) {
  :root {
    --shell: #292524;
    --shell-deep: #1c1917;
    --display: #164e63;
    --ink: #e7e5e4;
    --ink-soft: #d6d3d1;
    --panel: #292524;
    --edge: #0c0a09;
    --link: #5eead4;
    --muted: #a8a29e;
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: linear-gradient(to top right, var(--shell-deep), var(--shell));
  background-attachment: fixed;
  color: var(--ink);
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas,
    "Liberation Mono", monospace;
  line-height: 1.65;
  min-height: 100vh;
}

.wrap {
  max-width: 46rem;
  margin: 0 auto;
  padding: 2rem 1.25rem 4rem;
}

/* --- masthead ------------------------------------------------------- */

header.masthead {
  text-align: center;
  padding: 2.5rem 0 1.5rem;
  color: #f5f5f4;
}

@media (prefers-color-scheme: dark) {
  header.masthead {
    color: var(--ink);
  }
}

header.masthead .brand {
  font-size: clamp(2.5rem, 12vw, 4rem);
  font-weight: 700;
  letter-spacing: 0.1em;
  text-decoration: underline;
  text-underline-offset: 0.15em;
  margin: 0;
  text-shadow: rgba(0, 0, 0, 0.25) -2px 2px;
}

header.masthead .tagline {
  margin: 0.35rem 0 0;
  font-size: 0.8rem;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  opacity: 0.75;
}

/* --- panels --------------------------------------------------------- */

.panel {
  background: var(--panel);
  border: 4px solid var(--edge);
  border-radius: 2px;
  padding: 1.75rem;
  margin: 1.5rem 0;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.22);
}

.panel.display {
  background: var(--display);
  color: var(--ink);
  text-align: center;
}

@media (prefers-color-scheme: dark) {
  .panel.display {
    color: #e7e5e4;
  }
}

.panel.display p {
  margin: 0 0 1.25rem;
}

h1,
h2,
h3 {
  line-height: 1.25;
  margin: 2rem 0 0.75rem;
}

h1 {
  margin-top: 0;
  font-size: 1.6rem;
}

h2 {
  font-size: 1.15rem;
  border-bottom: 2px solid currentColor;
  padding-bottom: 0.3rem;
  display: inline-block;
}

p,
li {
  color: var(--ink-soft);
}

.panel.display p {
  color: inherit;
}

a {
  color: var(--link);
  text-underline-offset: 0.2em;
}

/* --- download button ------------------------------------------------ */

.cta {
  display: inline-block;
  background: #292524;
  color: #f5f5f4;
  text-decoration: none;
  padding: 0.85rem 1.75rem;
  border-radius: 999px;
  font-size: 1rem;
  box-shadow: 0 4px 0 rgba(0, 0, 0, 0.35);
  transition: transform 0.05s ease, box-shadow 0.05s ease;
}

.cta:hover {
  background: #1c1917;
}

.cta:active {
  transform: translateY(3px);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.35);
}

.cta-note {
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: 0.85rem;
}

/* --- feature list --------------------------------------------------- */

ul.features {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.5rem;
}

ul.features li::before {
  content: "▸ ";
  opacity: 0.6;
}

/* --- fill-me-in markers --------------------------------------------- */

.todo {
  background: #fef08a;
  color: #713f12;
  padding: 0.1em 0.35em;
  border-radius: 2px;
  font-weight: 700;
}

/* --- footer --------------------------------------------------------- */

footer {
  text-align: center;
  padding-top: 2rem;
  font-size: 0.85rem;
  color: rgba(245, 245, 244, 0.85);
}

@media (prefers-color-scheme: dark) {
  footer {
    color: var(--muted);
  }
}

footer a {
  color: inherit;
}

.legal-meta {
  font-size: 0.85rem;
  color: var(--muted);
  border-left: 3px solid currentColor;
  padding-left: 0.85rem;
  margin-bottom: 1.75rem;
}

.back {
  display: inline-block;
  margin-bottom: 1rem;
  font-size: 0.85rem;
  color: #f5f5f4;
}

@media (prefers-color-scheme: dark) {
  .back {
    color: var(--muted);
  }
}
