/* ==========================================================================
   Kubera Software — shared stylesheet
   Design: "greenbar" accounting paper. Ledger banding, hairline rules,
   all figures set in mono.
   ========================================================================== */

:root {
  --ink:        #17231c;
  --ink-soft:   #4a5a50;
  --paper:      #f6f7f3;
  --band:       #dbe5d3;
  --band-soft:  #e9eee4;
  --rule:       #9fb097;
  --rule-faint: rgba(23, 35, 28, 0.12);
  --brass:      #8a6220;

  --display: "Fraunces", Georgia, "Times New Roman", serif;
  --body:    "Karla", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --mono:    "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --measure: 68ch;
  --shell:   1140px;
  --gutter:  clamp(1.25rem, 4vw, 3rem);
  --rhythm:  28px;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background-color: var(--paper);
  /* Ruled paper: horizontal rules on a 28px rhythm, kept faint enough to
     read as texture rather than decoration. */
  background-image: repeating-linear-gradient(
    to bottom,
    transparent 0,
    transparent calc(var(--rhythm) - 1px),
    rgba(23, 35, 28, 0.045) calc(var(--rhythm) - 1px),
    rgba(23, 35, 28, 0.045) var(--rhythm)
  );
  color: var(--ink);
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.65;
  font-weight: 400;
}

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

a { color: var(--brass); text-decoration: none; border-bottom: 1px solid rgba(138, 98, 32, 0.35); }
a:hover { border-bottom-color: var(--brass); }

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

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--ink);
  color: var(--paper);
  padding: 0.75rem 1rem;
  z-index: 100;
  border: 0;
}
.skip:focus { left: 0; }

/* --------------------------------------------------------------- layout -- */

.shell {
  width: 100%;
  max-width: var(--shell);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* The ledger margin rule: a single vertical hairline down the left of the
   content column, as on ruled accounting stock. */
.ruled { position: relative; }
.ruled::before {
  content: "";
  position: absolute;
  inset-block: 0;
  left: calc(var(--gutter) - 0.75rem);
  width: 1px;
  background: var(--rule);
  opacity: 0.5;
}

.band-block { background-color: var(--band-soft); border-block: 1px solid var(--rule); }

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

.masthead {
  position: sticky;
  top: 0;
  z-index: 40;
  background-color: var(--paper);
  border-bottom: 1px solid var(--ink);
}

.masthead__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 1.5rem;
  padding-block: 0.875rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6875rem;
  border: 0;
  color: var(--ink);
}
/* A single struck diamond — a coin's edge, for a studio named after a god of
   wealth. The one ornamental mark on the site. */
.brand__glyph {
  width: 0.5rem;
  height: 0.5rem;
  background-color: var(--brass);
  transform: rotate(45deg);
  flex: none;
  transition: transform 0.3s cubic-bezier(0.22, 0.61, 0.36, 1);
}
.brand:hover .brand__glyph { transform: rotate(135deg); }

.brand__logotype {
  display: inline-flex;
  align-items: baseline;
  gap: 0.5rem;
  font-family: var(--display);
  font-variation-settings: "SOFT" 0, "WONK" 0;
  font-size: 1.1875rem;
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1;
}
.brand__logotype em {
  font-family: var(--mono);
  font-size: 0.625rem;
  font-style: normal;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.footer__mark {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  margin: 0 0 2.5rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--rule-faint);
}
.footer__mark .brand__glyph { width: 0.625rem; height: 0.625rem; }
.footer__mark .brand__logotype { font-size: 1.625rem; }
.footer__mark .brand__logotype em { font-size: 0.6875rem; }

.nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.25rem 1.5rem;
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.nav a { color: var(--ink-soft); border-bottom: 0; padding-block: 0.25rem; }
.nav a:hover { color: var(--ink); }
.nav a[aria-current="page"] {
  color: var(--ink);
  border-bottom: 2px solid var(--brass);
}

/* ----------------------------------------------------------------- type -- */

.eyebrow {
  font-family: var(--mono);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin: 0 0 1.25rem;
}

h1, h2, h3 {
  font-family: var(--display);
  font-variation-settings: "SOFT" 0, "WONK" 0;
  font-weight: 550;
  line-height: 1.06;
  letter-spacing: -0.015em;
  margin: 0;
  text-wrap: balance;
}

h1 { font-size: clamp(2.5rem, 6.5vw, 4.75rem); }
h2 { font-size: clamp(1.75rem, 3.4vw, 2.5rem); }
h3 { font-size: clamp(1.1875rem, 2vw, 1.4375rem); font-weight: 600; line-height: 1.2; }

.lede {
  font-size: clamp(1.125rem, 1.9vw, 1.375rem);
  line-height: 1.5;
  max-width: 56ch;
  color: var(--ink);
}

p, ul, ol, dl { max-width: var(--measure); }
p { margin-block: 0 1.1em; }

.figure { font-family: var(--mono); font-feature-settings: "tnum" 1; }

.section { padding-block: clamp(3.5rem, 8vw, 6rem); }
.section--tight { padding-block: clamp(2.5rem, 5vw, 3.75rem); }
.section + .section { border-top: 1px solid var(--rule-faint); }

.section__head { margin-bottom: 2.5rem; }

/* ----------------------------------------------------------------- hero -- */

.hero { padding-block: clamp(3.5rem, 10vw, 7rem) clamp(3rem, 7vw, 5rem); }
.hero h1 { margin-bottom: 1.5rem; }
.hero .lede { margin-bottom: 2.25rem; }

.rise { animation: rise 0.7s cubic-bezier(0.22, 0.61, 0.36, 1) backwards; }
.rise--1 { animation-delay: 0.05s; }
.rise--2 { animation-delay: 0.16s; }
.rise--3 { animation-delay: 0.27s; }

@keyframes rise {
  from { opacity: 0; transform: translateY(0.75rem); }
  to   { opacity: 1; transform: none; }
}

/* -------------------------------------------------------------- buttons -- */

.actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }

.btn {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.8125rem 1.375rem;
  border: 1px solid var(--ink);
  border-radius: 0;
  transition: background-color 0.18s ease, color 0.18s ease;
}
.btn--solid { background-color: var(--ink); color: var(--paper); }
.btn--solid:hover { background-color: var(--brass); border-color: var(--brass); color: var(--paper); }
.btn--ghost { background-color: transparent; color: var(--ink); }
.btn--ghost:hover { background-color: var(--ink); color: var(--paper); }

/* ------------------------------------------------- ledger: product rows -- */

.ledger { border-top: 1px solid var(--ink); }

.entry {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.5rem 2.5rem;
  padding-block: 2.25rem;
  border-bottom: 1px solid var(--rule);
  transition: background-color 0.2s ease;
}
/* Greenbar banding: alternating pale bands, as on accounting stock. */
.entry:nth-child(odd) { background-color: var(--band); }
.entry:hover { background-color: #d2ddc8; }

.entry__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.5rem 2.5rem;
  padding-inline: clamp(1rem, 3vw, 2rem);
}

.entry__title { margin-bottom: 0.5rem; }
.entry__title a { color: var(--ink); border-bottom: 2px solid rgba(138, 98, 32, 0.4); }
.entry__title a:hover { border-bottom-color: var(--brass); }
.entry__mark { height: 30px; width: auto; margin-bottom: 1rem; }
.entry__body p:last-child { margin-bottom: 0; }

.cells {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr));
  gap: 1.25rem 1.5rem;
  margin: 1.5rem 0 0;
  padding: 0;
}
.cells > div { min-width: 0; }
.cells dt {
  font-family: var(--mono);
  font-size: 0.625rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 0.375rem;
}
.cells dd {
  margin: 0;
  font-family: var(--mono);
  font-size: 0.9375rem;
  line-height: 1.4;
  font-feature-settings: "tnum" 1;
}

.status { display: inline-flex; align-items: baseline; gap: 0.5rem; }
.status::before {
  content: "";
  width: 0.5rem;
  height: 0.5rem;
  background-color: var(--brass);
  transform: translateY(-0.1rem);
  flex: none;
}

/* ----------------------------------------------------------- step-lists -- */
/* Numbered because these genuinely are sequences. */

.steps { list-style: none; margin: 0; padding: 0; max-width: none; counter-reset: step; }
.steps li {
  counter-increment: step;
  display: grid;
  grid-template-columns: 3rem minmax(0, 1fr);
  gap: 0 1.25rem;
  padding-block: 1.5rem;
  border-top: 1px solid var(--rule-faint);
}
.steps li::before {
  content: counter(step, decimal-leading-zero);
  font-family: var(--mono);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--brass);
  padding-top: 0.2rem;
}
.steps h3 { margin-bottom: 0.375rem; }
.steps p { margin-bottom: 0; }

/* --------------------------------------------------------- feature grid -- */

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr));
  gap: 1px;
  background-color: var(--rule);
  border: 1px solid var(--rule);
}
.grid > article { background-color: var(--paper); padding: clamp(1.25rem, 2.5vw, 1.75rem); }
.grid h3 { margin-bottom: 0.5rem; }
.grid p { margin-bottom: 0; max-width: 40ch; }

/* ---------------------------------------------------------- price table -- */

.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }

.prices {
  width: 100%;
  min-width: 44rem;
  border-collapse: collapse;
  font-family: var(--mono);
  font-feature-settings: "tnum" 1;
  text-align: left;
}
.prices caption {
  text-align: left;
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-soft);
  padding-bottom: 0.875rem;
}
.prices th, .prices td {
  padding: 0.9375rem 1.125rem;
  border-bottom: 1px solid var(--rule);
  vertical-align: baseline;
}
.prices thead th {
  font-size: 0.625rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  border-bottom: 1px solid var(--ink);
  border-top: 1px solid var(--ink);
  white-space: nowrap;
}
.prices tbody tr:nth-child(odd) { background-color: var(--band); }
.prices tbody th {
  font-family: var(--body);
  font-size: 1.0625rem;
  font-weight: 700;
  white-space: nowrap;
}
.prices .amount { font-size: 1.25rem; font-weight: 500; white-space: nowrap; }
.prices .per { font-size: 0.75rem; color: var(--ink-soft); }
.prices td a { white-space: nowrap; }

/* -------------------------------------------------------------- content -- */

.prose h2 { margin-top: 2.75rem; margin-bottom: 1rem; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { margin-top: 2rem; margin-bottom: 0.625rem; }
.prose ul, .prose ol { padding-left: 1.25rem; margin-block: 0 1.1em; }
.prose li { margin-bottom: 0.5rem; }
.prose li::marker { color: var(--rule); }

.checks { list-style: none; padding: 0; }
.checks li {
  padding-left: 1.5rem;
  position: relative;
  margin-bottom: 0.6875rem;
}
.checks li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.6em;
  width: 0.5rem;
  height: 0.5rem;
  border: 1px solid var(--brass);
}

.callout {
  border-left: 3px solid var(--brass);
  padding: 0.25rem 0 0.25rem 1.25rem;
  margin-block: 1.75rem;
  max-width: var(--measure);
}
.callout p { margin-bottom: 0; }

.quote { margin: 0; max-width: 48ch; }
.quote blockquote {
  margin: 0 0 0.875rem;
  font-family: var(--display);
  font-size: clamp(1.25rem, 2.4vw, 1.625rem);
  line-height: 1.32;
}
.quote figcaption {
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  color: var(--ink-soft);
}

.contact-line {
  font-family: var(--mono);
  font-size: clamp(1rem, 2.6vw, 1.5rem);
  word-break: break-word;
}

.meta {
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  color: var(--ink-soft);
}

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

.footer {
  border-top: 1px solid var(--ink);
  background-color: var(--paper);
  padding-block: 3rem 2.25rem;
  margin-top: clamp(3rem, 7vw, 5rem);
}
.footer__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 13rem), 1fr));
  gap: 2.25rem;
  margin-bottom: 2.75rem;
}
.footer h2 {
  font-family: var(--mono);
  font-size: 0.625rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 0.875rem;
}
.footer ul { list-style: none; margin: 0; padding: 0; }
.footer li { margin-bottom: 0.5rem; }
.footer a { color: var(--ink); border-bottom-color: var(--rule); font-size: 0.9375rem; }
.footer a:hover { color: var(--brass); border-bottom-color: var(--brass); }

.footer__legal {
  border-top: 1px solid var(--rule-faint);
  padding-top: 1.5rem;
  font-size: 0.8125rem;
  line-height: 1.6;
  color: var(--ink-soft);
  max-width: 90ch;
}
.footer__legal p { margin-bottom: 0.5rem; max-width: none; }
.footer__legal a { font-size: inherit; color: var(--ink-soft); }

/* ------------------------------------------------------------ responsive -- */

@media (min-width: 48rem) {
  .entry__inner { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: start; }
  .cells { margin-top: 0; }
  .hero--split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 0.75fr); gap: 3rem; align-items: end; }
}

@media (max-width: 30rem) {
  .steps li { grid-template-columns: minmax(0, 1fr); gap: 0.5rem; }
  .steps li::before { padding-top: 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .rise { animation: none; }
  *, *::before, *::after { transition-duration: 0.01ms !important; }
}

@media print {
  body { background-image: none; }
  .masthead, .nav { position: static; }
  a { color: var(--ink); }
}

/* Scrollable table region: give it a visible focus ring, since it is now
   keyboard-reachable for people who scroll it without a mouse. */
.table-scroll:focus-visible { outline: 2px solid var(--brass); outline-offset: 4px; }

/* ------------------------------------------------------------ screenshots -- */

.shots {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 19rem), 1fr));
  gap: 1.75rem;
  margin-top: 2.5rem;
}

.shot { margin: 0; }
.shot img {
  width: 100%;
  height: auto;
  border: 1px solid var(--rule);
  background-color: #fff;
}
.shot figcaption {
  font-family: var(--mono);
  font-size: 0.75rem;
  line-height: 1.5;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
  margin-top: 0.75rem;
  padding-left: 0.875rem;
  border-left: 2px solid var(--brass);
}

/* A single wide screenshot, used on its own rather than in the grid. */
.shot--wide { max-width: 46rem; margin-top: 2rem; }

/* Four-column plan table: narrower, so it only scrolls on genuinely small screens. */
.prices--compact { min-width: 33rem; }
