/* Trial page. Shares the site tokens; only this route loads it. */
html { color-scheme: light; }
.trial ::selection { background: #d7edb4; color: var(--ink); }

.trial { padding: 48px 0 72px; }
.trial .wrap { width: min(520px, calc(100% - 48px)); }
.trial h1 {
  font-size: clamp(32px, 4vw, 40px);
  font-weight: 720;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin-top: 12px;
}
.trial .intro { max-width: 36em; }
.trial h2 {
  font-size: clamp(22px, 2.5vw, 26px);
  font-weight: 700;
  line-height: 1.45;
  letter-spacing: 0;
  margin: 0;
}
.trial h2 b { font-weight: 750; overflow-wrap: anywhere; }

.stack { display: grid; gap: 14px; margin-top: 28px; }
.trial-card {
  position: relative;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: var(--sh1);
  padding: 26px 26px 24px;
  display: grid;
  gap: 14px;
  align-content: start;
}
.wait-msg { margin: 0; color: var(--muted); font-size: 15px; }
.closed-msg { margin: 0; color: var(--ink); font-size: 17px; font-weight: 650; line-height: 1.6; }

.field { display: grid; gap: 8px; min-width: 0; }
.field label { font-size: 14px; font-weight: 650; color: var(--ink); }
.hint { margin: 0; font-size: 13px; color: var(--muted); line-height: 1.6; }
.trial .note { margin-top: 0; }

.trial input {
  width: 100%;
  height: 48px;
  border-radius: 12px;
  border: 1px solid var(--line2);
  background: var(--paper);
  color: var(--ink);
  padding: 0 14px;
  font: inherit;
  font-size: 16px;
  caret-color: var(--leafink);
}
.trial input::placeholder { color: var(--muted); }
.trial input:focus-visible {
  border-color: #b7d592;
  background-color: #fff;
}
.trial input[aria-invalid="true"] {
  border-color: #e0b48a;
  background-color: #fffdfb;
}
.trial input:-webkit-autofill {
  -webkit-text-fill-color: var(--ink);
  box-shadow: 0 0 0 1000px var(--paper) inset;
  caret-color: var(--leafink);
}

.cap-line { display: flex; gap: 8px; align-items: center; min-width: 0; }
.cap-line input { flex: 1; min-width: 0; }
.cap {
  width: 132px;
  height: 48px;
  flex: none;
  padding: 0;
  border-radius: 12px;
  border: 1px solid var(--line2);
  background: var(--paper);
  color: var(--muted);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
  overflow: hidden;
}
.cap img { display: block; width: 132px; height: 48px; object-fit: contain; background: var(--paper); }
.cap:hover { border-color: #b7d592; background: #fff; }
.cap:disabled { cursor: wait; opacity: 0.7; }

.trial .b.block { width: 100%; height: 48px; }
.trial .b:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}
.trial .code-btn { font-variant-numeric: tabular-nums; }

.status:empty { margin: 0; }
.status:not(:empty) { margin: 0; font-size: 14px; line-height: 1.6; color: var(--leafink); }

.live:not(.on) {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}
.live.on {
  position: static;
  width: auto;
  height: auto;
  margin: 0;
  padding: 12px 14px;
  overflow: visible;
  clip: auto;
  clip-path: none;
  white-space: normal;
  border-radius: 12px;
  background: var(--warnsoft);
  color: var(--warn);
  font-size: 14px;
  line-height: 1.65;
}
.live.on a { color: var(--warn); font-weight: 650; text-underline-offset: 3px; white-space: nowrap; }
.trial input[aria-invalid="true"]:focus-visible { outline-color: rgba(154, 79, 13, .55); }

.resend-launch { margin: 2px 0 0; }
.linkbtn {
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  font-size: 14px;
  font-weight: 650;
  color: var(--leafink);
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: var(--line2);
}
.linkbtn:hover { text-decoration-color: var(--leafink); }

body:has(main.trial) { min-height: 100vh; display: flex; flex-direction: column; }
main.trial { flex: 1 0 auto; }
footer .wrap.trial-foot { display: block; }
.trial-foot > p { color: var(--ink2); font-weight: 650; margin: 0 0 8px; }
.trial-foot .fbot {
  margin-top: 0;
  border: 0;
  padding: 0;
  color: var(--muted);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.trial-foot .fbot a { color: var(--leafink); }

@media (max-width: 640px) {
  .trial { padding: 32px 0 56px; }
  .trial .wrap { width: calc(100% - 36px); }
  .trial-card { padding: 18px 16px 16px; border-radius: 18px; }
  .cap-line { flex-wrap: wrap; }
  .cap, .cap img { width: 100%; }
  .cap { height: 56px; }
  .cap img { height: 56px; }
}
@media (prefers-reduced-motion: reduce) {
  .trial .b, .cap, .linkbtn { transition: none; }
}
