/* ===========================================================================
   Rentallia — the landing page.

   Its own stylesheet, in public/ rather than in src/, for one reason: this
   page loads no JavaScript and must not depend on the application bundle to
   look like itself. The tokens below are copied from src/styles.css rather
   than imported, which is a real duplication and a deliberate one — a
   marketing page that cannot render until a React app builds is a marketing
   page that breaks at the worst time.

   Everything interactive here is HTML: links, <details>, and a pair of radios
   driving the pricing switch through a sibling selector.
   ========================================================================= */

:root {
  --paper:      #f6f7f4;
  --card:       #ffffff;
  --rule:       #e1e5dd;
  --rule-firm:  #c6ccc2;
  --ink:        #14181a;
  --ink-soft:   #5c645f;
  --ink-faint:  #8d948f;

  --debit:      #b4331f;
  --debit-wash: #f9ece9;
  --credit:     #1f5b4e;
  --credit-wash:#e9f2ef;
  --flag-wash:  #fdf6e2;
  --stamp:      #2c3e8f;

  --edge-navy:  #16324f;
  --edge-teal:  #1a5a63;

  --display: "Archivo", system-ui, sans-serif;
  --body:    "Public Sans", system-ui, sans-serif;
  --mono:    "IBM Plex Mono", ui-monospace, monospace;

  --radius: 3px;
  --shadow: 0 1px 2px rgba(20, 24, 26, 0.05),
            0 4px 16px -6px rgba(20, 24, 26, 0.09);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.55;
  font-variant-numeric: tabular-nums;
}

h1, h2, h3 {
  font-family: var(--display);
  font-weight: 700;
  font-stretch: 112%;
  letter-spacing: -0.015em;
  margin: 0;
}

a { color: var(--stamp); }

.eyebrow {
  font-family: var(--display);
  font-size: 0.6875rem;
  font-weight: 600;
  font-stretch: 118%;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin: 0 0 0.625rem;
}

/* --- The patterned margins, as on the app ------------------------------- */

.page-edges { position: fixed; inset: 0; pointer-events: none; z-index: 0; }

.page-edge {
  position: absolute;
  top: 0;
  bottom: 0;
  width: min(12vw, calc((100vw - 1210px) / 2));
  -webkit-mask-image:
    repeating-radial-gradient(circle at 50% 50%, #000 0 1.2px, transparent 1.2px 4.5px);
  mask-image:
    repeating-radial-gradient(circle at 50% 50%, #000 0 1.2px, transparent 1.2px 4.5px);
  -webkit-mask-size: 24px 24px;
  mask-size: 24px 24px;
  opacity: 0.42;
}
.page-edge--left {
  left: 0;
  background: linear-gradient(100deg, var(--edge-navy) 0%, var(--edge-navy) 26%,
    var(--edge-teal) 58%, var(--credit) 78%, transparent 100%);
}
.page-edge--right {
  right: 0;
  background: linear-gradient(260deg, var(--edge-navy) 0%, var(--edge-navy) 26%,
    var(--edge-teal) 58%, var(--credit) 78%, transparent 100%);
}

/* --- The mark ----------------------------------------------------------- */

.wordmark {
  display: inline-flex; align-items: center; gap: 0.45em;
  text-decoration: none; color: var(--ink);
  font-family: var(--display); font-weight: 700; font-stretch: 118%;
  font-size: 1.375rem; letter-spacing: -0.01em;
}
.wordmark-rail { width: 0.86em; height: 0.86em; flex: 0 0 auto; overflow: visible; }
.wordmark-spine { fill: var(--rule-firm); }
.wordmark-bar { animation: strike-out 380ms cubic-bezier(0.2, 0.75, 0.3, 1) backwards; }
.wordmark-bar--debit-1 { fill: var(--debit);  transform-origin: 8px 3.65px;  animation-delay: 80ms; }
.wordmark-bar--credit  { fill: var(--credit); transform-origin: 8px 8px;     animation-delay: 190ms; }
.wordmark-bar--debit-2 { fill: var(--debit);  transform-origin: 8px 12.35px; animation-delay: 300ms; }
@keyframes strike-out { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@media (prefers-reduced-motion: reduce) { .wordmark-bar { animation: none; } }

/* --- Shell -------------------------------------------------------------- */

.top, main, .foot {
  position: relative; z-index: 1;
  max-width: 1080px; margin: 0 auto; padding-inline: 1.25rem;
}

.top {
  display: flex; align-items: center; gap: 1rem;
  padding-top: 1.5rem; padding-bottom: 1.25rem;
}
.top-nav { margin-left: auto; display: flex; align-items: center; gap: 1.25rem; }
.top-nav a { color: var(--ink-soft); text-decoration: none; font-size: 0.9375rem; }
.top-nav a:hover { color: var(--ink); }
@media (max-width: 560px) {
  .top-nav a:not(.button) { display: none; }
}

/* --- Buttons ------------------------------------------------------------ */

.button {
  display: inline-block;
  font-family: var(--body); font-size: 0.9375rem; font-weight: 600;
  padding: 0.625rem 1.125rem; border-radius: var(--radius);
  border: 1px solid var(--ink); text-decoration: none;
  white-space: nowrap;
}
.button--primary { background: var(--ink); color: var(--paper); }
.button--primary:hover { background: #000; }
.button--ghost {
  background: transparent; color: var(--ink); border-color: var(--rule-firm);
}
.button--ghost:hover { background: var(--card); border-color: var(--ink); }
.top-nav .button { padding: 0.4375rem 0.875rem; font-size: 0.875rem; }

/* --- Hero --------------------------------------------------------------- */

.hero { padding: 2.5rem 0 3rem; border-top: 2px solid var(--ink); box-shadow: 0 3px 0 -1px var(--rule-firm); }
.hero h1 {
  font-size: clamp(2rem, 5.5vw, 3.25rem);
  line-height: 1.06;
  font-stretch: 118%;
  max-width: 18ch;
}
.lede {
  font-size: clamp(1rem, 2vw, 1.1875rem);
  color: var(--ink-soft);
  max-width: 56ch;
  margin: 1rem 0 0;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 1.75rem; }
.hero-note { font-size: 0.8125rem; color: var(--ink-faint); margin: 0.75rem 0 0; }

/* --- The specimen ------------------------------------------------------- */

.specimen {
  margin: 2.5rem 0 0;
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.specimen-head {
  display: flex; justify-content: space-between; align-items: baseline; gap: 1rem;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--rule-firm);
  font-family: var(--display); font-weight: 700; font-size: 0.875rem;
}
.specimen-as-of { font-family: var(--mono); font-size: 0.6875rem; color: var(--ink-faint); font-weight: 400; }

.specimen-table { width: 100%; border-collapse: collapse; font-size: 0.8125rem; }
.specimen-table td { padding: 0.5rem 1rem; border-bottom: 1px solid var(--rule); vertical-align: middle; }
.specimen-table tr:last-child td { border-bottom: 0; }
.specimen-table .d { font-family: var(--mono); font-size: 0.75rem; color: var(--ink-faint); white-space: nowrap; width: 1%; }
.specimen-table .detail { color: var(--ink-soft); }
.specimen-table .amt {
  font-family: var(--mono); text-align: right; white-space: nowrap;
  width: 1%; font-weight: 500;
}
.amt--debit { color: var(--debit); }
.amt--credit { color: var(--credit); }

.kind {
  font-family: var(--display); font-size: 0.5625rem; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase; white-space: nowrap;
  padding: 0.125rem 0.375rem; border-radius: 2px;
}
.kind--charge  { background: var(--debit-wash);  color: var(--debit); }
.kind--payment { background: var(--credit);      color: #fff; }
.kind--fee     { background: var(--debit);       color: #fff; }

.specimen figcaption {
  padding: 0.75rem 1rem;
  border-top: 1px solid var(--rule);
  background: var(--paper);
  font-size: 0.8125rem;
  color: var(--ink-soft);
}

/* The statutory stamp, as in the app. */
.stamp {
  display: inline-block; margin-left: 0.5rem;
  padding: 0.125rem 0.375rem;
  font-family: var(--mono); font-size: 0.625rem;
  letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--stamp); border: 1px solid var(--stamp); border-radius: 2px;
  transform: rotate(-0.9deg); opacity: 0.85;
}

/* --- Bands -------------------------------------------------------------- */

.band { padding: 3rem 0; border-top: 1px solid var(--rule-firm); }
.band h2 { font-size: clamp(1.375rem, 3.2vw, 2rem); max-width: 22ch; }
.section-lede { color: var(--ink-soft); max-width: 60ch; margin: 0.75rem 0 0; }

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1px;
  margin-top: 2rem;
  background: var(--rule);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  overflow: hidden;
}
.feature { background: var(--card); padding: 1.25rem; }
.feature h3 { font-size: 0.9375rem; margin-bottom: 0.5rem; }
.feature p { margin: 0; font-size: 0.875rem; color: var(--ink-soft); }

/* --- Pricing ------------------------------------------------------------ */

/*
 * The monthly/annual switch, without JavaScript.
 *
 * Two radios sit off-screen (not display:none, which would take them out of
 * the tab order and make the switch unreachable from a keyboard). The labels
 * are the visible control, and :checked on the radio selects which of the two
 * price spans is shown further down the tree.
 */
.interval input[type="radio"] {
  position: absolute; width: 1px; height: 1px; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}

.interval-switch {
  display: inline-flex; margin-top: 1.5rem;
  border: 1px solid var(--rule-firm); border-radius: var(--radius);
  background: var(--card); overflow: hidden;
}
.interval-switch label {
  padding: 0.4375rem 0.875rem;
  font-size: 0.875rem; font-weight: 600; color: var(--ink-soft);
  cursor: pointer;
}
.interval-switch label + label { border-left: 1px solid var(--rule); }
#monthly:checked ~ .interval-switch label[for="monthly"],
#annual:checked  ~ .interval-switch label[for="annual"] {
  background: var(--ink); color: var(--paper);
}
#monthly:checked ~ .interval-switch label[for="monthly"] .save,
#annual:checked  ~ .interval-switch label[for="annual"] .save { color: var(--flag-wash); }

.save {
  font-family: var(--mono); font-size: 0.625rem; letter-spacing: 0.04em;
  color: var(--credit); margin-left: 0.375rem;
}

.interval input[type="radio"]:focus-visible ~ .interval-switch {
  outline: 2px solid var(--stamp); outline-offset: 2px;
}

.price .a { display: none; }
#annual:checked ~ .tiers .price .m { display: none; }
#annual:checked ~ .tiers .price .a { display: inline; }

.tiers {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1rem;
  margin-top: 1.25rem;
  align-items: start;
}

.tier {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow);
  display: flex; flex-direction: column; height: 100%;
}
.tier--featured { border-color: var(--ink); border-width: 2px; }
.tier-flag {
  font-family: var(--display); font-size: 0.5625rem; font-weight: 700;
  letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--debit); margin: 0 0 0.375rem;
}
.tier h3 { font-size: 1.0625rem; }
.tier-blurb { font-size: 0.8125rem; color: var(--ink-faint); margin: 0.25rem 0 0; }

.price { margin: 0.875rem 0 0; font-family: var(--mono); }
.price strong { font-size: 1.75rem; font-weight: 600; letter-spacing: -0.02em; }
.price .per { font-size: 0.8125rem; color: var(--ink-faint); margin-left: 0.25rem; }

.tier ul {
  list-style: none; margin: 1rem 0 1.25rem; padding: 0;
  font-size: 0.875rem; color: var(--ink-soft); flex: 1;
}
.tier li { padding: 0.3125rem 0 0.3125rem 1.125rem; position: relative; border-bottom: 1px dotted var(--rule); }
.tier li:last-child { border-bottom: 0; }
.tier li::before {
  content: "";
  position: absolute; left: 0; top: 0.875rem;
  width: 0.5rem; height: 1px; background: var(--credit);
}
.tier .button { text-align: center; }

.trial-note {
  margin: 1.75rem 0 0;
  padding: 0.875rem 1rem;
  border-left: 3px solid var(--flag-wash);
  background: var(--flag-wash);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-size: 0.875rem;
  max-width: 68ch;
}

/* --- FAQ ---------------------------------------------------------------- */

.faq { margin-top: 1.75rem; border-top: 1px solid var(--rule); }
.faq details { border-bottom: 1px solid var(--rule); }
.faq summary {
  cursor: pointer; padding: 0.875rem 0;
  font-weight: 600; font-size: 0.9375rem;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; float: right;
  font-family: var(--mono); color: var(--ink-faint);
}
.faq details[open] summary::after { content: "\2212"; }
.faq summary:focus-visible { outline: 2px solid var(--stamp); outline-offset: 2px; }
.faq p { margin: 0 0 1rem; font-size: 0.9375rem; color: var(--ink-soft); max-width: 68ch; }

/* --- Closer and footer -------------------------------------------------- */

.closer {
  padding: 3.5rem 0;
  border-top: 2px solid var(--ink);
  box-shadow: 0 3px 0 -1px var(--rule-firm);
  text-align: center;
}
.closer h2 { font-size: clamp(1.5rem, 4vw, 2.25rem); margin-inline: auto; }
.closer p { color: var(--ink-soft); max-width: 46ch; margin: 0.75rem auto 1.75rem; }

.foot { padding: 2rem 1.25rem 4rem; border-top: 1px solid var(--rule); }
.foot-mark {
  display: flex; align-items: center; gap: 0.45em;
  font-family: var(--display); font-weight: 700; font-stretch: 118%;
  font-size: 1rem;
}
.foot-mark .wordmark-rail { width: 0.86em; height: 0.86em; }
.foot-legal { font-size: 0.75rem; color: var(--ink-faint); max-width: 76ch; margin: 0.75rem 0 0; }
.foot-links { font-size: 0.8125rem; margin: 0.875rem 0 0; color: var(--ink-faint); }
.foot-links a { color: var(--ink-soft); }
