:root {
  --page: #f4f1e8;
  --paper: #fffdf8;
  --ink: #17211c;
  --muted: #667169;
  --muted-light: #89938c;
  --line: #d9ded9;
  --line-strong: #c8cec9;
  --sheet-header: #eef1ed;
  --green: #1f6a4a;
  --green-dark: #145238;
  --green-soft: #dff2e7;
  --lime: #dff39e;
  --yellow: #f2c45d;
  --coral: #f18468;
  --blue: #64a8d8;
  --violet: #a884d8;
  --danger: #b43d35;
  --shadow: 0 24px 70px rgba(39, 50, 43, 0.11), 0 3px 12px rgba(39, 50, 43, 0.06);
  --confetti-1: #dff39e;
  --confetti-2: #f2c45d;
  --confetti-3: #f18468;
  --confetti-4: #64a8d8;
  --confetti-5: #a884d8;
  --confetti-6: #ffffff;
  color-scheme: light;
  font-family: "Segoe UI", Aptos, system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--page);
}

body {
  margin: 0;
  color: var(--ink);
  background-color: var(--page);
  background-image:
    linear-gradient(rgba(31, 106, 74, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(31, 106, 74, 0.035) 1px, transparent 1px);
  background-size: 32px 32px;
}

body.dialog-open {
  overflow: hidden;
}

button,
input {
  font: inherit;
}

button {
  color: inherit;
}

button:focus-visible,
input:focus-visible,
a:focus-visible {
  outline: 3px solid rgba(31, 106, 74, 0.33);
  outline-offset: 3px;
}

[hidden] {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.page-shell {
  width: min(1080px, calc(100% - 40px));
  min-height: 100vh;
  margin: 0 auto;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 28px 0;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: inherit;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  grid-template-columns: repeat(2, 9px);
  grid-template-rows: repeat(2, 9px);
  gap: 3px;
  padding: 7px;
  border: 1px solid rgba(23, 33, 28, 0.16);
  border-radius: 9px;
  background: var(--paper);
  box-shadow: 0 3px 8px rgba(39, 50, 43, 0.08);
}

.brand-mark span {
  border-radius: 2px;
  background: var(--green);
}

.brand-mark span:nth-child(2),
.brand-mark span:nth-child(3) {
  background: var(--lime);
}

.brand-name {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}

.brand-name strong {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.brand-name > span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.tools-menu {
  position: relative;
  flex: 0 0 auto;
}

.tools-menu-button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 36px;
  padding: 7px 10px;
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  color: var(--green-dark);
  background: rgba(255, 253, 248, 0.88);
  box-shadow: 0 2px 7px rgba(39, 50, 43, 0.05);
  font-size: 12px;
  font-weight: 750;
  line-height: 1;
  cursor: pointer;
}

.tools-menu-button:hover,
.tools-menu-button[aria-expanded="true"] {
  border-color: rgba(31, 106, 74, 0.4);
  background: var(--paper);
}

.tools-menu-button svg {
  width: 15px;
  height: 15px;
  flex: 0 0 auto;
}

.tools-menu-grid {
  fill: currentColor;
}

.tools-menu-chevron {
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
  transition: transform 160ms ease;
}

.tools-menu-button[aria-expanded="true"] .tools-menu-chevron {
  transform: rotate(180deg);
}

.tools-menu-popover {
  position: absolute;
  top: calc(100% + 9px);
  left: 0;
  z-index: 30;
  width: 232px;
  max-width: calc(100vw - 24px);
  max-height: calc(100vh - 100px);
  overflow-y: auto;
  padding: 6px;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: var(--paper);
  box-shadow: 0 18px 42px rgba(39, 50, 43, 0.16), 0 3px 10px rgba(39, 50, 43, 0.08);
}

.tools-menu-popover a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 40px;
  padding: 9px 10px;
  border-radius: 8px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 650;
  text-decoration: none;
}

.tools-menu-popover a:hover {
  background: var(--sheet-header);
}

.tools-menu-popover a[aria-current="page"] {
  color: var(--green-dark);
  background: var(--green-soft);
}

.tools-menu-popover a[aria-current="page"]::after {
  content: "";
  width: 7px;
  height: 7px;
  flex: 0 0 auto;
  margin-left: 14px;
  border-radius: 50%;
  background: var(--green);
}

.device-note {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
}

.device-note svg,
.trust-row svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.hero {
  max-width: 760px;
  margin: 72px auto 46px;
  text-align: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 16px;
  color: var(--green-dark);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.eyebrow::before {
  width: 22px;
  height: 2px;
  content: "";
  background: var(--green);
}

.hero h1 {
  max-width: 720px;
  margin: 0 auto;
  font-size: clamp(42px, 7vw, 72px);
  font-weight: 750;
  letter-spacing: -0.055em;
  line-height: 0.98;
  text-wrap: balance;
}

.hero-copy {
  max-width: 630px;
  margin: 24px auto 0;
  color: var(--muted);
  font-size: clamp(16px, 2vw, 19px);
  line-height: 1.6;
  text-wrap: balance;
}

.tool-card {
  overflow: hidden;
  border: 1px solid rgba(23, 33, 28, 0.13);
  border-radius: 20px;
  background: var(--paper);
  box-shadow: var(--shadow);
}

.sheet-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 22px 26px;
  border-bottom: 1px solid var(--line);
}

.sheet-title-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

.status-light {
  width: 10px;
  height: 10px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: #35a36f;
  box-shadow: 0 0 0 5px rgba(53, 163, 111, 0.12);
}

.sheet-toolbar h2 {
  margin: 0;
  font-size: 16px;
  font-weight: 750;
  letter-spacing: -0.02em;
}

.sheet-toolbar p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.sheet-toolbar .entry-summary {
  flex: 0 0 auto;
  margin: 0;
  padding: 7px 11px;
  border-radius: 999px;
  color: var(--green-dark);
  background: var(--green-soft);
  font-weight: 700;
}

.tool-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 26px 0;
}

.visibility-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.visibility-button {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 11px;
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  color: var(--muted);
  background: #ffffff;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: color 150ms ease, background 150ms ease, border-color 150ms ease;
}

.visibility-button:hover {
  color: var(--green-dark);
  border-color: rgba(31, 106, 74, 0.4);
  background: var(--green-soft);
}

.visibility-button[data-hidden="true"] {
  color: #ffffff;
  border-color: var(--green-dark);
  background: var(--green-dark);
}

.visibility-button svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.visibility-button[data-hidden="false"] .visibility-slash {
  display: none;
}

.reveal-time-control {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 3px 5px 3px 11px;
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  color: var(--muted);
  background: var(--sheet-header);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.reveal-time-control input {
  width: 58px;
  height: 28px;
  padding: 0 5px;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  color: var(--ink);
  background: #ffffff;
  font-weight: 750;
  text-align: center;
}

.reveal-time-control input[aria-invalid="true"] {
  border-color: var(--danger);
  color: var(--danger);
  background: rgba(180, 61, 53, 0.055);
}

.spreadsheet {
  margin: 16px 26px 0;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: #ffffff;
}

.sheet-grid {
  display: grid;
  grid-template-columns: 44px minmax(180px, 1fr) 120px 110px 48px;
}

.spreadsheet.is-tickets-hidden .tickets-column,
.spreadsheet.is-tickets-hidden .tickets-cell,
.spreadsheet.is-odds-hidden .odds-column,
.spreadsheet.is-odds-hidden .odds-cell {
  display: none;
}

.spreadsheet.is-tickets-hidden .sheet-grid {
  grid-template-columns: 44px minmax(180px, 1fr) 110px 48px;
}

.spreadsheet.is-odds-hidden .sheet-grid {
  grid-template-columns: 44px minmax(180px, 1fr) 120px 48px;
}

.spreadsheet.is-tickets-hidden.is-odds-hidden .sheet-grid {
  grid-template-columns: 44px minmax(180px, 1fr) 48px;
}

.column-letters {
  height: 28px;
  color: var(--muted);
  background: var(--sheet-header);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-align: center;
}

.column-letters span {
  display: grid;
  place-items: center;
  border-right: 1px solid var(--line);
}

.column-letters span:last-child {
  border-right: 0;
}

.corner-cell {
  background:
    linear-gradient(135deg, transparent 48%, rgba(23, 33, 28, 0.12) 49%, rgba(23, 33, 28, 0.12) 52%, transparent 53%);
}

.sheet-heading {
  min-height: 40px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line-strong);
  color: #3d4941;
  background: #f7f8f6;
  font-size: 12px;
  font-weight: 750;
  letter-spacing: 0.03em;
}

.sheet-heading > span {
  display: flex;
  align-items: center;
  padding: 0 12px;
  border-right: 1px solid var(--line);
}

.sheet-heading > span:last-child {
  border-right: 0;
}

.sheet-heading .row-number {
  justify-content: center;
  padding: 0;
  color: var(--muted-light);
}

.entry-row {
  min-height: 49px;
  border-bottom: 1px solid var(--line);
  background: #ffffff;
}

.entry-row:last-child {
  border-bottom: 0;
}

.entry-row > * {
  min-width: 0;
  border-right: 1px solid var(--line);
}

.entry-row > *:last-child {
  border-right: 0;
}

.row-number {
  display: grid;
  place-items: center;
  color: var(--muted-light);
  background: var(--sheet-header);
  font-size: 11px;
  font-weight: 700;
}

.sheet-input {
  width: 100%;
  min-height: 48px;
  padding: 0 12px;
  border: 0;
  border-radius: 0;
  color: var(--ink);
  background: transparent;
  font-size: 15px;
  outline: 0;
}

.sheet-input::placeholder {
  color: #adb5af;
}

.sheet-input:focus {
  box-shadow: inset 0 0 0 2px var(--green);
}

.sheet-input[aria-invalid="true"] {
  color: var(--danger);
  background: rgba(180, 61, 53, 0.055);
  box-shadow: inset 0 0 0 2px rgba(180, 61, 53, 0.55);
}

.tickets-input {
  font-variant-numeric: tabular-nums;
}

.odds-cell {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding: 0 12px;
  color: var(--muted);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

.remove-cell {
  display: grid;
  place-items: center;
}

.remove-row-button {
  display: grid;
  width: 30px;
  height: 30px;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 6px;
  color: var(--muted-light);
  background: transparent;
  cursor: pointer;
  transition: color 150ms ease, background 150ms ease;
}

.remove-row-button:hover {
  color: var(--danger);
  background: rgba(180, 61, 53, 0.08);
}

.remove-row-button svg,
.add-row-button svg,
.draw-button svg,
.dialog-close-button svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.sheet-footer {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 44px;
  padding: 0 12px;
  border-top: 1px solid var(--line-strong);
  background: var(--sheet-header);
}

.add-row-button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 9px;
  border: 0;
  border-radius: 7px;
  color: var(--green-dark);
  background: transparent;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.add-row-button:hover {
  background: rgba(31, 106, 74, 0.08);
}

.sheet-tab {
  align-self: stretch;
  display: flex;
  align-items: center;
  padding: 0 18px;
  border-bottom: 3px solid var(--green);
  color: var(--green-dark);
  background: rgba(255, 255, 255, 0.7);
  font-size: 12px;
  font-weight: 750;
}

.form-message {
  min-height: 20px;
  margin: 12px 26px 0;
  color: var(--muted);
  font-size: 13px;
}

.form-message.is-error {
  color: var(--danger);
  font-weight: 650;
}

.form-message.is-ready {
  color: var(--green-dark);
  font-weight: 650;
}

.draw-area {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  margin-top: 18px;
  padding: 22px 26px;
  border-top: 1px solid var(--line);
  background: #faf9f5;
}

.draw-label {
  margin: 0;
  font-size: 14px;
  font-weight: 750;
}

.draw-note {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.draw-button {
  display: inline-flex;
  min-width: 190px;
  min-height: 54px;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 0 22px;
  border: 0;
  border-radius: 12px;
  color: #ffffff;
  background: var(--green);
  box-shadow: 0 8px 20px rgba(31, 106, 74, 0.22);
  font-size: 15px;
  font-weight: 750;
  cursor: pointer;
  transition: transform 150ms ease, background 150ms ease, box-shadow 150ms ease;
}

.draw-button:hover:not(:disabled) {
  transform: translateY(-1px);
  background: var(--green-dark);
  box-shadow: 0 11px 24px rgba(31, 106, 74, 0.28);
}

.draw-button:active:not(:disabled) {
  transform: translateY(1px);
}

.draw-button:disabled {
  color: #a7aea9;
  background: #e4e7e3;
  box-shadow: none;
  cursor: not-allowed;
}

.trust-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin: 22px 0 0;
}

.trust-row p {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 0;
  padding: 13px 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
}

.trust-row svg {
  color: var(--green);
}

.site-footer {
  padding: 76px 0 30px;
  color: var(--muted-light);
  font-size: 12px;
  text-align: center;
}

.home-page .page-shell {
  display: flex;
  flex-direction: column;
}

.home-main {
  flex: 1;
}

.home-hero {
  margin-bottom: 38px;
}

.tool-directory {
  width: min(960px, 100%);
  margin: 0 auto;
}

.directory-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 18px;
}

.directory-kicker {
  margin: 0 0 6px;
  color: var(--green-dark);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.directory-heading h2 {
  margin: 0;
  font-size: clamp(27px, 4vw, 38px);
  letter-spacing: -0.035em;
}

.directory-heading > div > p:last-child {
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 14px;
}

.tool-count {
  flex: 0 0 auto;
  padding: 7px 11px;
  border-radius: 999px;
  color: var(--green-dark);
  background: var(--green-soft);
  font-size: 12px;
  font-weight: 750;
}

.tool-search-panel {
  margin: 22px 0 18px;
  padding: 20px;
  border: 1px solid var(--line-strong);
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.62);
  box-shadow: 0 12px 34px rgba(39, 50, 43, 0.055);
}

.tool-search-panel > label {
  display: block;
  margin-bottom: 8px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
}

.tool-search-control {
  position: relative;
  display: flex;
  align-items: center;
}

.tool-search-control > svg {
  position: absolute;
  left: 16px;
  width: 20px;
  height: 20px;
  fill: none;
  stroke: var(--green-dark);
  stroke-linecap: round;
  stroke-width: 1.8;
  pointer-events: none;
}

.tool-search-control input {
  width: 100%;
  min-height: 52px;
  padding: 0 82px 0 48px;
  border: 1px solid var(--line-strong);
  border-radius: 11px;
  color: var(--ink);
  background: #ffffff;
  font: inherit;
  font-size: 16px;
}

.tool-search-control input:focus {
  border-color: rgba(31, 106, 74, 0.72);
  outline: 3px solid rgba(31, 106, 74, 0.16);
  outline-offset: 1px;
}

.tool-search-control button {
  position: absolute;
  right: 7px;
  min-height: 38px;
  padding: 0 12px;
  border: 0;
  border-radius: 8px;
  color: var(--green-dark);
  background: var(--green-soft);
  font: inherit;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.tool-search-panel > p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.tool-categories {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 24px;
}

.tool-category {
  min-width: 0;
  min-height: 86px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line-strong);
  border-radius: 13px;
  color: var(--ink);
  background: var(--paper);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: border-color 150ms ease, background 150ms ease, transform 150ms ease;
}

.tool-category:hover {
  border-color: rgba(31, 106, 74, 0.42);
  transform: translateY(-1px);
}

.tool-category.is-active {
  border-color: rgba(31, 106, 74, 0.55);
  background: var(--green-soft);
  box-shadow: inset 0 0 0 1px rgba(31, 106, 74, 0.08);
}

.tool-category-icon {
  width: 36px;
  height: 36px;
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 10px;
  color: var(--green-dark);
  background: rgba(255, 255, 255, 0.72);
  font-size: 12px;
  font-weight: 850;
}

.tool-category strong,
.tool-category small {
  display: block;
}

.tool-category strong {
  font-size: 13px;
  line-height: 1.2;
}

.tool-category small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.3;
}

.directory-results-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 18px;
  margin: 0 0 14px;
}

.directory-results-heading h3 {
  margin: 0;
  font-size: 20px;
  letter-spacing: -0.02em;
}

.directory-results-heading p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  text-align: right;
}

.tool-search-empty {
  margin: 0;
  padding: 34px 22px;
  border: 1px dashed var(--line-strong);
  border-radius: 14px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.5);
  font-size: 14px;
  line-height: 1.55;
  text-align: center;
}

.tool-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.tool-link-card {
  min-height: 286px;
  display: flex;
  flex-direction: column;
  padding: 28px;
  border: 1px solid var(--line-strong);
  border-radius: 18px;
  color: inherit;
  background: var(--paper);
  box-shadow: 0 16px 42px rgba(39, 50, 43, 0.08);
  text-decoration: none;
  transition: transform 170ms ease, border-color 170ms ease, box-shadow 170ms ease;
}

.tool-link-card:hover {
  border-color: rgba(31, 106, 74, 0.42);
  box-shadow: 0 22px 52px rgba(39, 50, 43, 0.13);
  transform: translateY(-3px);
}

.tool-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.tool-card-icon {
  display: grid;
  width: 52px;
  height: 52px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 14px;
  color: var(--green-dark);
  background: var(--green-soft);
}

.equal-tool-card .tool-card-icon {
  background: rgba(223, 243, 158, 0.58);
}

.tool-card-icon svg {
  width: 27px;
  height: 27px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.65;
}

.tool-card-kicker {
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-align: right;
  text-transform: uppercase;
}

.tool-link-card h3 {
  margin: 26px 0 10px;
  font-size: clamp(24px, 3vw, 31px);
  letter-spacing: -0.035em;
  line-height: 1.08;
}

.tool-link-card > p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.55;
}

.tool-card-action {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: auto;
  padding-top: 24px;
  color: var(--green-dark);
  font-size: 13px;
  font-weight: 800;
}

.tool-card-action svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
  transition: transform 170ms ease;
}

.tool-link-card:hover .tool-card-action svg {
  transform: translateX(3px);
}

.home-trust {
  width: min(960px, 100%);
  margin: 24px auto 0;
}

.ad-placement {
  width: min(960px, calc(100% - 32px));
  min-height: 124px;
  margin: 54px auto 44px;
  padding: 16px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  text-align: center;
}

.ad-label {
  display: block;
  margin-bottom: 8px;
  color: var(--muted-light);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.ad-placement .adsbygoogle {
  width: 100%;
  min-height: 90px;
}

.tool-guide {
  width: min(960px, 100%);
  margin: 48px auto 0;
  padding: clamp(26px, 5vw, 48px);
  border: 1px solid var(--line-strong);
  border-radius: 18px;
  background: var(--paper);
  box-shadow: 0 18px 48px rgba(39, 50, 43, 0.08);
}

.guide-intro {
  max-width: 760px;
}

.guide-kicker {
  margin: 0 0 8px;
  color: var(--green-dark);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.guide-intro h2,
.fairness-note h2,
.faq-section h2 {
  margin: 0;
  letter-spacing: -0.035em;
}

.guide-intro h2 {
  font-size: clamp(29px, 4.5vw, 43px);
  line-height: 1.08;
}

.guide-intro > p:last-child,
.fairness-note p,
.faq-section details p,
.related-tool {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.65;
}

.guide-intro > p:last-child {
  max-width: 720px;
  margin: 16px 0 0;
}

.guide-steps {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 28px;
  margin: 36px 0;
  padding: 0;
  list-style: none;
}

.guide-steps li {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  gap: 12px;
  padding: 20px 0;
  border-top: 1px solid var(--line);
}

.guide-steps li > span {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 50%;
  color: var(--green-dark);
  background: var(--green-soft);
  font-size: 11px;
  font-weight: 800;
}

.guide-steps h3 {
  margin: 3px 0 7px;
  font-size: 16px;
}

.guide-steps p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.fairness-note {
  padding: 24px;
  border-left: 4px solid var(--green);
  border-radius: 0 12px 12px 0;
  background: var(--green-soft);
}

.fairness-note h2 {
  font-size: clamp(22px, 3vw, 29px);
}

.fairness-note p {
  margin: 11px 0 0;
  color: #405046;
}

.faq-section {
  margin-top: 42px;
}

.faq-section h2 {
  margin-bottom: 18px;
  font-size: clamp(25px, 3.5vw, 34px);
}

.faq-section details {
  border-top: 1px solid var(--line);
}

.faq-section details:last-of-type {
  border-bottom: 1px solid var(--line);
}

.faq-section summary {
  padding: 17px 28px 17px 0;
  font-size: 15px;
  font-weight: 750;
  cursor: pointer;
}

.faq-section details p {
  margin: -4px 0 18px;
}

.related-tool {
  margin: 28px 0 0;
}

.related-tool a,
.legal-content a,
.site-footer a,
.back-to-tools-link {
  color: var(--green-dark);
  font-weight: 750;
}

.site-footer nav {
  display: flex;
  justify-content: center;
  gap: 18px;
  margin-top: 10px;
}

.site-footer a {
  text-underline-offset: 3px;
}

.back-to-tools-link {
  font-size: 13px;
  text-decoration: none;
}

.back-to-tools-link:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.legal-content {
  width: min(760px, 100%);
  margin: 64px auto 0;
  padding: clamp(26px, 5vw, 48px);
  border: 1px solid var(--line-strong);
  border-radius: 18px;
  background: var(--paper);
  box-shadow: 0 18px 48px rgba(39, 50, 43, 0.08);
}

.legal-content h1 {
  margin: 0;
  font-size: clamp(44px, 8vw, 68px);
  letter-spacing: -0.055em;
}

.legal-updated {
  margin: 12px 0 34px;
  color: var(--muted-light);
  font-size: 12px;
  font-weight: 700;
}

.legal-content section {
  padding: 24px 0;
  border-top: 1px solid var(--line);
}

.legal-content section h2 {
  margin: 0;
  font-size: 23px;
  letter-spacing: -0.025em;
}

.legal-content section p {
  margin: 11px 0 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.7;
}

.draw-dialog {
  position: fixed;
  z-index: 1000;
  inset: 0;
  display: grid;
  align-items: start;
  justify-items: center;
  overflow-y: auto;
  padding: 24px;
}

.dialog-scrim {
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at 50% 40%, rgba(65, 105, 82, 0.3), transparent 38%),
    rgba(13, 22, 17, 0.92);
  backdrop-filter: blur(10px);
}

#confetti-canvas {
  position: absolute;
  z-index: 3;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.draw-stage {
  position: relative;
  z-index: 2;
  width: min(1080px, 100%);
  min-height: min(520px, calc(100dvh - 48px));
  display: grid;
  margin: auto 0;
  padding: 62px 0 40px;
  place-items: center;
  color: #ffffff;
  text-align: center;
}

.dialog-close-button {
  position: absolute;
  z-index: 4;
  top: 0;
  right: 0;
  display: grid;
  width: 44px;
  height: 44px;
  padding: 0;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 50%;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.07);
  cursor: pointer;
}

.dialog-close-button:hover {
  background: rgba(255, 255, 255, 0.14);
}

.dialog-close-button:focus-visible,
.winner-primary-button:focus-visible,
.winner-secondary-button:focus-visible {
  outline-color: rgba(223, 243, 158, 0.72);
}

.drawing-content,
.winner-content {
  width: min(680px, 100%);
}

.overview-content {
  width: 100%;
  text-align: left;
}

.overview-heading {
  max-width: 720px;
  margin: 0 auto;
  text-align: center;
}

.overview-heading .dialog-kicker {
  margin-bottom: 16px;
}

.overview-heading h2 {
  margin: 0;
  color: #ffffff;
  font-size: clamp(42px, 7vw, 72px);
  font-weight: 800;
  letter-spacing: -0.055em;
  line-height: 0.98;
  text-wrap: balance;
}

.overview-heading > p:last-child {
  max-width: 560px;
  margin: 20px auto 0;
  color: rgba(255, 255, 255, 0.66);
  font-size: 16px;
  line-height: 1.5;
}

.overview-summary {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 9px;
  margin: 30px 0 24px;
}

.overview-summary span {
  padding: 7px 11px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.82);
  background: rgba(255, 255, 255, 0.07);
  font-size: 12px;
  font-weight: 700;
}

.overview-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  overflow: hidden;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
  border-left: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.035);
}

.overview-entry {
  min-width: 0;
  min-height: 62px;
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 11px 14px;
  border-right: 1px solid rgba(255, 255, 255, 0.16);
  border-bottom: 1px solid rgba(255, 255, 255, 0.16);
}

.overview-entry-number {
  color: rgba(255, 255, 255, 0.38);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
}

.overview-entry-name {
  min-width: 0;
  color: #ffffff;
  font-size: 16px;
  font-weight: 750;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.overview-entry-meta {
  color: rgba(255, 255, 255, 0.55);
  font-size: 11px;
  font-weight: 650;
  text-align: right;
  white-space: nowrap;
}

.overview-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-top: 26px;
}

.overview-footer > p {
  margin: 0;
  color: rgba(255, 255, 255, 0.55);
  font-size: 12px;
}

.overview-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.overview-draw-button {
  min-width: 190px;
}

.dialog-kicker,
.winner-kicker {
  margin: 0 0 24px;
  color: var(--lime);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.spinner-stage {
  position: relative;
  width: min(340px, 74vw);
  aspect-ratio: 1;
  display: grid;
  margin: 0 auto;
  place-items: center;
}

.orbit {
  position: absolute;
  border-radius: 50%;
}

.orbit-one {
  inset: 0;
  border: 2px solid rgba(255, 255, 255, 0.13);
  border-top-color: var(--lime);
  border-right-color: var(--yellow);
  animation: orbit-spin 1.05s linear infinite;
}

.orbit-two {
  inset: 24px;
  border: 1px dashed rgba(255, 255, 255, 0.32);
  animation: orbit-spin-reverse 2.6s linear infinite;
}

.name-window {
  position: relative;
  z-index: 1;
  width: calc(100% - 82px);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  padding: 22px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 0 40px rgba(255, 255, 255, 0.04), 0 0 80px rgba(134, 203, 162, 0.13);
}

#spinning-name {
  display: block;
  max-width: 100%;
  overflow: hidden;
  font-size: clamp(28px, 6vw, 48px);
  font-weight: 750;
  letter-spacing: -0.045em;
  line-height: 1.05;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#spinning-name.is-changing {
  animation: name-flick 180ms ease;
}

.draw-progress {
  width: min(360px, 78vw);
  height: 5px;
  margin: 30px auto 14px;
  overflow: hidden;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.14);
}

.draw-progress span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--lime), var(--yellow));
}

.draw-progress span.is-running {
  animation: draw-progress var(--draw-duration, 10s) linear forwards;
}

.draw-countdown {
  margin: 0;
  color: rgba(255, 255, 255, 0.86);
  font-size: 14px;
  font-weight: 650;
}

.winner-content {
  animation: winner-pop 540ms cubic-bezier(0.2, 0.85, 0.25, 1.15);
}

.winner-burst {
  width: 76px;
  height: 76px;
  display: grid;
  margin: 0 auto 28px;
  place-items: center;
  border-radius: 50%;
  color: var(--green-dark);
  background: var(--lime);
  box-shadow: 0 0 0 14px rgba(223, 243, 158, 0.1), 0 0 70px rgba(223, 243, 158, 0.25);
  font-size: 30px;
}

.winner-content h2 {
  max-width: 620px;
  margin: 0 auto;
  overflow-wrap: anywhere;
  font-size: clamp(54px, 11vw, 104px);
  font-weight: 800;
  letter-spacing: -0.065em;
  line-height: 0.92;
  text-wrap: balance;
}

.winner-kicker {
  margin-bottom: 18px;
}

.winner-details {
  margin: 24px 0 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: 15px;
}

.winner-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 38px;
}

.winner-primary-button,
.winner-secondary-button {
  min-height: 48px;
  padding: 0 20px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 750;
  cursor: pointer;
}

.winner-primary-button {
  border: 0;
  color: var(--green-dark);
  background: var(--lime);
}

.winner-primary-button:hover {
  background: #ebfac0;
}

.winner-secondary-button {
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
}

.winner-secondary-button:hover {
  background: rgba(255, 255, 255, 0.14);
}

@keyframes orbit-spin {
  to { transform: rotate(360deg); }
}

@keyframes orbit-spin-reverse {
  to { transform: rotate(-360deg); }
}

@keyframes name-flick {
  0% { opacity: 0.2; transform: translateY(7px) scale(0.97); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes draw-progress {
  to { width: 100%; }
}

@keyframes winner-pop {
  0% { opacity: 0; transform: scale(0.72); }
  100% { opacity: 1; transform: scale(1); }
}

@media (min-width: 701px) and (max-width: 1020px) {
  .tool-categories {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 700px) {
  .page-shell {
    width: min(100% - 24px, 1080px);
  }

  .site-header {
    padding: 18px 0;
  }

  .device-note {
    max-width: 150px;
    justify-content: flex-end;
    font-size: 11px;
    text-align: right;
  }

  .hero {
    margin: 48px auto 32px;
  }

  .hero h1 {
    font-size: clamp(40px, 12vw, 58px);
  }

  .home-hero {
    margin-bottom: 34px;
  }

  .directory-heading {
    align-items: flex-start;
  }

  .tool-categories {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .tool-grid {
    grid-template-columns: 1fr;
  }

  .tool-link-card {
    min-height: 250px;
  }

  .ad-placement {
    margin-top: 42px;
    margin-bottom: 36px;
  }

  .tool-guide {
    margin-top: 36px;
  }

  .guide-steps {
    grid-template-columns: 1fr;
  }

  .legal-content {
    margin-top: 42px;
  }

  .tool-card {
    border-radius: 14px;
  }

  .sheet-toolbar {
    align-items: flex-start;
    padding: 18px;
  }

  .sheet-toolbar .entry-summary {
    padding: 6px 9px;
    font-size: 11px;
  }

  .sheet-title-group .status-light {
    margin-top: 4px;
  }

  .sheet-toolbar p:not(.entry-summary) {
    max-width: 220px;
  }

  .tool-controls {
    align-items: stretch;
    flex-wrap: wrap;
    padding: 14px 18px 0;
  }

  .reveal-time-control {
    margin-left: auto;
  }

  .spreadsheet {
    margin: 18px 12px 0;
  }

  .sheet-grid {
    grid-template-columns: 36px minmax(100px, 1fr) 76px 68px 42px;
  }

  .spreadsheet.is-tickets-hidden .sheet-grid {
    grid-template-columns: 36px minmax(100px, 1fr) 68px 42px;
  }

  .spreadsheet.is-odds-hidden .sheet-grid {
    grid-template-columns: 36px minmax(100px, 1fr) 76px 42px;
  }

  .spreadsheet.is-tickets-hidden.is-odds-hidden .sheet-grid {
    grid-template-columns: 36px minmax(100px, 1fr) 42px;
  }

  .form-message {
    margin-right: 18px;
    margin-left: 18px;
  }

  .draw-area {
    align-items: stretch;
    flex-direction: column;
    padding: 20px 18px;
  }

  .draw-button {
    width: 100%;
  }

  .trust-row {
    grid-template-columns: 1fr;
    gap: 0;
    margin-top: 15px;
  }

  .trust-row p {
    justify-content: flex-start;
    padding: 9px 12px;
  }

  .draw-dialog {
    padding: 16px;
  }

  .draw-stage {
    min-height: min(500px, calc(100dvh - 32px));
    padding-bottom: 30px;
  }

  .dialog-close-button {
    top: 4px;
    right: 4px;
  }

  .overview-heading h2 {
    font-size: clamp(38px, 11vw, 56px);
  }

  .overview-list {
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  }

  .overview-footer {
    align-items: stretch;
    flex-direction: column;
    gap: 14px;
    text-align: center;
  }

  .overview-actions {
    justify-content: center;
  }

  .winner-actions {
    align-items: stretch;
    flex-direction: column;
    width: min(300px, 100%);
    margin-right: auto;
    margin-left: auto;
  }
}

@media (max-width: 520px) {
  .site-header {
    gap: 12px;
  }

  .header-left {
    gap: 10px;
  }

  .device-note {
    display: none;
  }

  .tools-menu-popover {
    right: 0;
    left: auto;
  }
}

@media (max-width: 420px) {
  .brand-name strong {
    font-size: 14px;
  }

  .brand-name > span {
    font-size: 10px;
  }

  .hero-copy {
    font-size: 15px;
  }

  .directory-heading {
    gap: 12px;
  }

  .directory-heading > div > p:last-child {
    font-size: 13px;
  }

  .tool-search-panel {
    padding: 15px;
  }

  .tool-search-control input {
    padding-right: 76px;
    font-size: 15px;
  }

  .tool-categories {
    grid-template-columns: 1fr;
    gap: 9px;
  }

  .tool-category {
    min-height: 72px;
  }

  .directory-results-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 5px;
  }

  .directory-results-heading p {
    text-align: left;
  }

  .tool-link-card {
    min-height: 238px;
    padding: 22px;
    border-radius: 15px;
  }

  .tool-link-card h3 {
    margin-top: 22px;
  }

  .tool-guide,
  .legal-content {
    padding: 22px;
    border-radius: 15px;
  }

  .fairness-note {
    padding: 20px;
  }

  .faq-section summary {
    padding-right: 18px;
  }

  .sheet-toolbar {
    gap: 12px;
  }

  .sheet-toolbar p:not(.entry-summary) {
    display: none;
  }

  .tool-controls {
    align-items: stretch;
    flex-direction: column;
    gap: 9px;
    padding: 12px 12px 0;
  }

  .visibility-controls {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  body[data-raffle-mode="equal"] .visibility-controls {
    grid-template-columns: 1fr;
  }

  .reveal-time-control {
    justify-content: center;
    margin-left: 0;
  }

  .spreadsheet {
    margin-right: 8px;
    margin-left: 8px;
  }

  .sheet-grid {
    grid-template-columns: 30px minmax(82px, 1fr) 62px 58px 34px;
  }

  .spreadsheet.is-tickets-hidden .sheet-grid {
    grid-template-columns: 30px minmax(82px, 1fr) 58px 34px;
  }

  .spreadsheet.is-odds-hidden .sheet-grid {
    grid-template-columns: 30px minmax(82px, 1fr) 62px 34px;
  }

  .spreadsheet.is-tickets-hidden.is-odds-hidden .sheet-grid {
    grid-template-columns: 30px minmax(82px, 1fr) 34px;
  }

  .sheet-heading > span,
  .sheet-input,
  .odds-cell {
    padding-right: 8px;
    padding-left: 8px;
  }

  .sheet-tab {
    padding: 0 10px;
  }

  .overview-heading h2 {
    font-size: 38px;
  }

  .overview-heading > p:last-child {
    font-size: 14px;
  }

  .overview-summary {
    margin: 24px 0 18px;
  }

  .overview-list {
    grid-template-columns: 1fr;
  }

  .overview-entry {
    grid-template-columns: 26px minmax(0, 1fr) auto;
    padding: 10px;
  }

  .overview-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .overview-draw-button {
    min-width: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .draw-progress span.is-running {
    animation: none !important;
    width: 100%;
  }
}
