@font-face {
  font-family: "Archivo";
  src: url("/public/fonts/Archivo-VariableFont_wdth,wght.ttf") format("truetype");
  font-style: normal;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}

@font-face {
  font-family: "Archivo";
  src: url("/public/fonts/Archivo-Italic-VariableFont_wdth,wght.ttf") format("truetype");
  font-style: italic;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}

@font-face {
  font-family: "NDOT";
  src: url("/public/fonts/ndot.otf") format("opentype");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

:root {
  color-scheme: light;
  --ink: #252525;
  --ink-muted: rgba(37, 37, 37, 0.52);
  --ink-soft: rgba(37, 37, 37, 0.4);
  --ink-faint: rgba(37, 37, 37, 0.28);
  --paper: #fbfaf7;
  --paper-2: #faf9f6;
  --cream: #f4f2ec;
  --white: #fff;
  --sand: #e9e7e0;
  --sand-strong: rgba(37, 37, 37, 0.18);
  --lavender: #c0b5fd;
  --lavender-soft: #f0ecff;
  --peach: #ffbd9a;
  --peach-soft: #fff1e8;
  --mint: #a4ff9a;
  --mint-soft: #ecfbe9;
  --blue: #8e9aff;
  --radius-control: 12px;
  --radius-card: 17px;
  --radius-composer: 23px;
  --shadow-floating: 0 0 0 1px rgba(0, 0, 0, 0.05), 0 1px 1px -0.5px rgba(0, 0, 0, 0.05), 0 3px 3px -1.5px rgba(0, 0, 0, 0.05), 0 12px 24px -12px rgba(0, 0, 0, 0.09);
  font-family: "Archivo", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  margin: 0;
  color: var(--ink);
  background: var(--paper);
}

button,
input,
select {
  font: inherit;
}

button,
a,
summary,
select {
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

button:focus-visible,
a:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
}

input:focus-visible,
select:focus-visible {
  outline: 2px solid var(--lavender);
  outline-offset: -2px;
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 1000;
  padding: 10px 14px;
  border-radius: var(--radius-control);
  background: var(--ink);
  color: var(--paper);
  transform: translateY(-160%);
}

.skip-link:focus {
  transform: translateY(0);
}

.preview-bar {
  display: flex;
  min-height: 30px;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 6px 20px;
  background: var(--cream);
  color: var(--ink-muted);
  font-size: 12px;
  line-height: 18px;
}

.status-dot {
  width: 7px;
  height: 7px;
  flex: 0 0 auto;
  border-radius: 999px;
  background: #55d66b;
  box-shadow: 0 0 0 3px rgba(85, 214, 107, 0.13);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  border-top: 1px solid rgba(255, 255, 255, 0.8);
  background: rgba(251, 250, 247, 0.82);
  backdrop-filter: blur(20px) saturate(160%);
}

.header-shell {
  display: flex;
  width: min(1160px, calc(100% - 40px));
  min-height: 68px;
  align-items: center;
  margin: 0 auto;
}

.header-gutter {
  display: flex;
  min-width: 0;
  flex: 1;
  align-items: center;
}

.brand {
  display: inline-flex;
  min-width: 0;
  align-items: center;
  gap: 9px;
  font-size: 18px;
  letter-spacing: -0.7px;
}

.brand img {
  width: 28px;
  height: 28px;
  flex: 0 0 auto;
}

.brand-suffix {
  color: var(--ink-soft);
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border-radius: 13px;
  background: rgba(233, 231, 224, 0.48);
}

.desktop-nav a {
  padding: 7px 11px;
  border-radius: 10px;
  color: var(--ink-muted);
  font-size: 13px;
  white-space: nowrap;
}

.desktop-nav a:hover,
.desktop-nav a.active {
  background: var(--white);
  color: var(--ink);
}

.header-actions {
  justify-content: flex-end;
}

.header-bid-button,
.mobile-menu-button {
  color: var(--ink-muted);
  font-size: 13px;
}

.header-bid-button {
  min-height: 36px;
  border: 1px solid rgba(37, 37, 37, 0.1);
  border-radius: 11px;
  padding: 7px 11px;
  background: var(--white);
}

.mobile-menu-button {
  border: 0;
  background: transparent;
}

.header-bid-button:hover,
.mobile-menu-button:hover {
  color: var(--ink);
}

.mobile-menu-button,
.mobile-bid-button,
.mobile-nav {
  display: none;
}

.page-shell {
  isolation: isolate;
  width: min(1000px, calc(100% - 40px));
  margin: 0 auto;
}

.hero {
  position: relative;
  isolation: isolate;
  display: flex;
  overflow: hidden;
  flex-direction: column;
  align-items: flex-start;
  gap: 30px;
  padding: 66px 0 50px;
  text-align: left;
}

.hero > :not(.hero-creative-field) {
  position: relative;
  z-index: 2;
}

.hero-creative-field {
  position: absolute;
  z-index: 0;
  top: 48px;
  right: 0;
  width: 61%;
  pointer-events: none;
  opacity: 0.72;
  -webkit-mask-image: linear-gradient(to right, transparent 0%, rgba(0, 0, 0, 0.1) 16%, #000 48%);
  mask-image: linear-gradient(to right, transparent 0%, rgba(0, 0, 0, 0.1) 16%, #000 48%);
}

.hero-creative-grid {
  display: grid;
  aspect-ratio: 3 / 2;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.hero-creative-tile {
  position: relative;
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(37, 37, 37, 0.06);
  border-radius: 10px;
  background-image: url("/public/creative-concepts-contact-sheet.jpg");
  background-repeat: no-repeat;
  background-size: 400% 300%;
  opacity: 0.24;
  transform: scale(0.96);
  transition:
    opacity 600ms cubic-bezier(0.22, 1, 0.36, 1),
    transform 760ms cubic-bezier(0.22, 1, 0.36, 1);
}

.hero-creative-tile::after {
  position: absolute;
  content: "";
  inset: 0;
  border: 2px solid rgba(255, 255, 255, 0.92);
  border-radius: inherit;
  opacity: 0;
  transition: opacity 600ms cubic-bezier(0.22, 1, 0.36, 1);
}

.hero-creative-tile.is-active {
  z-index: 1;
  opacity: 0.94;
  transform: scale(1.045);
}

.hero-creative-tile.is-active::after {
  opacity: 1;
}

.hero-creative-tile:nth-child(1) { background-position: 0% 0%; }
.hero-creative-tile:nth-child(2) { background-position: 33.333% 0%; }
.hero-creative-tile:nth-child(3) { background-position: 66.667% 0%; }
.hero-creative-tile:nth-child(4) { background-position: 100% 0%; }
.hero-creative-tile:nth-child(5) { background-position: 0% 50%; }
.hero-creative-tile:nth-child(6) { background-position: 33.333% 50%; }
.hero-creative-tile:nth-child(7) { background-position: 66.667% 50%; }
.hero-creative-tile:nth-child(8) { background-position: 100% 50%; }
.hero-creative-tile:nth-child(9) { background-position: 0% 100%; }
.hero-creative-tile:nth-child(10) { background-position: 33.333% 100%; }
.hero-creative-tile:nth-child(11) { background-position: 66.667% 100%; }
.hero-creative-tile:nth-child(12) { background-position: 100% 100%; }

.hero-creative-caption {
  display: flex;
  justify-content: flex-end;
  gap: 9px;
  margin: 9px 0 0;
  color: var(--ink-soft);
  font-size: 10px;
  line-height: 14px;
  text-align: right;
}

.hero-creative-caption span:first-child {
  font-family: "NDOT", "Archivo", sans-serif;
  letter-spacing: 0.25px;
  text-transform: uppercase;
}

.live-chip,
.soft-badge,
.preview-data-label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  width: fit-content;
  border-radius: 999px;
  font-size: 12px;
}

.live-chip {
  padding: 7px 11px 7px 8px;
  background: var(--cream);
  color: var(--ink-muted);
}

.hero-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
}

.hero-display-accent {
  margin: 0;
  font-family: "NDOT", "Archivo", sans-serif;
  color: var(--ink-soft);
  font-size: 13px;
  letter-spacing: 0.4px;
  text-transform: uppercase;
}

.hero h1 {
  max-width: 16ch;
  margin: 0;
  font-family: "Archivo", sans-serif;
  font-size: clamp(48px, 7vw, 78px);
  font-weight: 500;
  line-height: 0.96;
  letter-spacing: -4.3px;
  text-wrap: balance;
}

.hero-copy > p {
  max-width: 62ch;
  margin: 0;
  color: var(--ink-muted);
  font-size: 18px;
  line-height: 1.58;
  letter-spacing: -0.25px;
  text-wrap: pretty;
}

.hero-action-group {
  display: flex;
  align-items: center;
  gap: 16px;
}

.hero-action-group p {
  max-width: 31ch;
  margin: 0;
  color: var(--ink-soft);
  font-size: 12px;
  line-height: 17px;
}

.hero-bid-button {
  min-height: 48px;
  padding: 12px 14px;
}

.market-stats {
  display: grid;
  width: 100%;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 0;
  padding: 22px 0 0;
  border-top: 1px solid rgba(37, 37, 37, 0.09);
}

.market-stats > div {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 4px;
  padding: 4px 22px;
  border-left: 1px solid rgba(37, 37, 37, 0.09);
}

.market-stats > div:first-child {
  border-left: 0;
}

.market-stats dt {
  color: var(--ink-soft);
  font-size: 12px;
  line-height: 16px;
}

.market-stats dd {
  overflow: hidden;
  margin: 0;
  font-size: 16px;
  font-weight: 500;
  line-height: 20px;
  letter-spacing: -0.2px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.bid-composer {
  display: flex;
  width: min(680px, 100%);
  flex-direction: column;
  gap: 18px;
  padding: 22px;
  border-radius: var(--radius-composer);
  background: var(--white);
  box-shadow: var(--shadow-floating);
  text-align: left;
}

.modal-bid-form {
  width: 100%;
  padding: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.composer-topline,
.composer-footer,
.label-row,
.section-heading-row,
.preview-topline,
.dialog-header,
.dialog-actions,
.footer-shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.composer-kicker,
.composer-note,
.field-help,
.composer-footer p,
.section-label,
.section-intro,
.creative-copy > p,
.process-list p,
.rules-list p,
.site-footer p,
.dialog-note p {
  margin: 0;
}

.composer-kicker {
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.2px;
}

.composer-note {
  padding-top: 3px;
  color: var(--ink-soft);
  font-size: 12px;
}

.soft-badge {
  flex: 0 0 auto;
  padding: 6px 10px;
  background: var(--lavender-soft);
  color: rgba(37, 37, 37, 0.66);
}

.field,
.field-wide {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 7px;
}

.field label,
.label-row > span {
  font-size: 12px;
  line-height: 17px;
}

.field label {
  color: rgba(37, 37, 37, 0.72);
  font-weight: 500;
}

.label-row > span {
  color: var(--ink-soft);
}

.field input,
.field select {
  width: 100%;
  min-width: 0;
  height: 48px;
  border: 1px solid rgba(37, 37, 37, 0.1);
  border-radius: var(--radius-control);
  background: var(--paper);
  color: var(--ink);
  font-size: 16px;
}

.field input {
  padding: 0 14px;
}

.field input:hover,
.field select:hover {
  border-color: var(--sand-strong);
}

.field input::placeholder {
  color: var(--ink-faint);
}

.composer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 14px;
}

.select-wrap {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 38px;
}

.select-wrap select {
  grid-column: 1 / -1;
  grid-row: 1;
  appearance: none;
  padding: 0 38px 0 14px;
}

.select-wrap > span {
  z-index: 1;
  grid-column: 2;
  grid-row: 1;
  place-self: center;
  color: var(--ink-soft);
  pointer-events: none;
}

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

.amount-control .currency {
  position: absolute;
  left: 14px;
  z-index: 1;
  color: var(--ink-soft);
  font-size: 15px;
}

.amount-control input {
  padding-right: 91px;
  padding-left: 30px;
  font-variant-numeric: tabular-nums;
}

.stepper {
  position: absolute;
  right: 6px;
  display: flex;
  gap: 3px;
}

.stepper button {
  position: relative;
  display: inline-flex;
  width: 34px;
  height: 34px;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 9px;
  background: var(--cream);
  color: var(--ink-muted);
  font-size: 17px;
}

.stepper button:hover {
  background: var(--sand);
  color: var(--ink);
}

.field-help {
  color: var(--ink-soft);
  font-size: 11px;
  line-height: 15px;
}

.field-error {
  min-height: 0;
  margin: 0;
  color: #aa3c24;
  font-size: 11px;
  line-height: 15px;
}

.field-error:not(:empty) {
  min-height: 15px;
}

.field.invalid input,
.field.invalid select,
.field-wide.invalid input {
  border-color: rgba(170, 60, 36, 0.52);
  background: #fff8f5;
}

.composer-footer {
  align-items: flex-start;
  padding-top: 2px;
}

.composer-footer-copy {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  gap: 4px;
}

.composer-footer-copy > p:first-child {
  color: var(--ink-soft);
  font-size: 12px;
  line-height: 18px;
}

.composer-footer .primary-button {
  flex: 0 0 auto;
}

.bid-outcome-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 0;
  padding: 13px 0;
  border-top: 1px solid rgba(37, 37, 37, 0.09);
  border-bottom: 1px solid rgba(37, 37, 37, 0.09);
}

.bid-outcome-strip > div {
  min-width: 0;
  padding: 0 13px;
  border-left: 1px solid rgba(37, 37, 37, 0.09);
}

.bid-outcome-strip > div:first-child {
  padding-left: 0;
  border-left: 0;
}

.bid-outcome-strip > div:last-child {
  padding-right: 0;
}

.bid-outcome-strip dt {
  color: var(--ink-soft);
  font-size: 10px;
  line-height: 15px;
}

.bid-outcome-strip dd {
  overflow: hidden;
  margin: 3px 0 0;
  font-size: 13px;
  font-weight: 500;
  line-height: 18px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.primary-button,
.secondary-button,
.close-button {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 14px;
  font-weight: 500;
}

.primary-button {
  border: 1px solid var(--ink);
  background: var(--ink);
  color: var(--paper);
}

.primary-button:hover {
  background: #393939;
}

.primary-button:disabled {
  cursor: wait;
  opacity: 0.62;
}

.primary-button:active,
.secondary-button:active {
  transform: scale(0.985);
}

.secondary-button,
.close-button {
  border: 1px solid rgba(37, 37, 37, 0.1);
  background: var(--white);
  color: var(--ink-muted);
}

.secondary-button:hover,
.close-button:hover {
  border-color: var(--sand-strong);
  color: var(--ink);
}

.market-section,
.creative-section,
.process-section,
.rules-section {
  padding: 72px 0;
  border-top: 1px solid rgba(37, 37, 37, 0.08);
}

.market-section {
  padding-top: 54px;
}

.section-heading-row {
  align-items: flex-end;
}

.section-label {
  font-family: "NDOT", "Archivo", sans-serif;
  color: var(--ink-soft);
  font-size: 11px;
  line-height: 16px;
  letter-spacing: -0.35px;
  text-transform: uppercase;
}

.section-heading-row h2,
.creative-copy h2,
.rules-copy h2,
.dialog-header h2 {
  margin: 7px 0 0;
  font-size: clamp(28px, 4vw, 43px);
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: -1.8px;
  text-wrap: balance;
}

.preview-data-label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 9px;
  background: var(--peach-soft);
  color: rgba(37, 37, 37, 0.57);
}

.market-heading-side {
  display: flex;
  max-width: 32ch;
  flex-direction: column;
  align-items: flex-end;
  gap: 7px;
  color: var(--ink-soft);
  font-size: 11px;
  line-height: 15px;
  text-align: right;
}

.market-heading-side p {
  margin: 0;
}

.filter-scroll {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 25px 0 15px;
  scrollbar-width: none;
}

.filter-scroll::-webkit-scrollbar {
  display: none;
}

.filter-chip {
  flex: 0 0 auto;
  border: 0;
  border-radius: 10px;
  padding: 8px 11px;
  background: transparent;
  color: var(--ink-soft);
  font-size: 13px;
}

.filter-chip:hover {
  color: var(--ink);
}

.filter-chip.active {
  background: var(--sand);
  color: var(--ink);
}

.leaderboard {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.bid-row {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr) auto;
  gap: 15px;
  align-items: center;
  min-height: 104px;
  padding: 16px;
  border: 1px solid rgba(37, 37, 37, 0.06);
  border-radius: var(--radius-card);
  background: var(--paper);
}

.bid-row:first-child {
  border-color: rgba(117, 99, 212, 0.22);
  background: var(--lavender-soft);
}

.rank-badge {
  display: inline-flex;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  background: var(--cream);
  color: var(--ink-muted);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

.bid-row:first-child .rank-badge {
  background: var(--lavender);
  color: var(--ink);
}

.bid-content {
  min-width: 0;
}

.bid-title-row,
.bid-meta,
.bid-status {
  display: flex;
  align-items: center;
  gap: 8px;
}

.bid-title-row h3 {
  overflow: hidden;
  margin: 0;
  font-size: 15px;
  font-weight: 500;
  line-height: 21px;
  letter-spacing: -0.25px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.company-site-link {
  display: inline-flex;
  max-width: 100%;
  align-items: center;
  gap: 5px;
}

.company-site-link span {
  color: var(--ink-soft);
  font-size: 11px;
}

@media (hover: hover) and (pointer: fine) {
  .company-site-link:hover {
    text-decoration: underline;
    text-underline-offset: 3px;
  }
}

.category-badge {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 4px 7px;
  background: var(--cream);
  color: var(--ink-soft);
  font-size: 10px;
  line-height: 14px;
}

.bid-row:first-child .category-badge {
  background: rgba(255, 255, 255, 0.58);
}

.bid-description {
  overflow: hidden;
  margin: 3px 0 6px;
  color: var(--ink-muted);
  font-size: 13px;
  line-height: 18px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.bid-meta {
  flex-wrap: wrap;
  color: var(--ink-soft);
  font-size: 11px;
  line-height: 15px;
}

.delivery-state {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.delivery-state::before {
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: var(--peach);
  content: "";
}

.delivery-state.delivered::before {
  background: #5ad46d;
}

.bid-price {
  display: flex;
  align-self: stretch;
  flex-direction: column;
  align-items: flex-end;
  justify-content: space-between;
  gap: 10px;
  padding-left: 18px;
  border-left: 1px solid rgba(37, 37, 37, 0.08);
}

.bid-price strong {
  font-size: 18px;
  font-weight: 500;
  letter-spacing: -0.6px;
  font-variant-numeric: tabular-nums;
}

.bid-price button,
.bid-price .library-action {
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--ink-soft);
  font-size: 11px;
}

.bid-price button:hover,
.bid-price .library-action:hover {
  color: var(--ink);
}

.delivery-timing {
  display: flex;
  align-items: flex-end;
  flex-direction: column;
  gap: 2px;
  color: var(--ink-muted);
  font-size: 11px;
  line-height: 15px;
  text-align: right;
}

.delivery-timing small {
  color: var(--ink-soft);
  font-size: 10px;
}

.empty-market {
  padding: 34px;
  border: 1px dashed rgba(37, 37, 37, 0.14);
  border-radius: var(--radius-card);
  color: var(--ink-muted);
  text-align: center;
}

.empty-market.error-state {
  border-color: rgba(201, 86, 52, 0.24);
  background: var(--peach-soft);
  color: #8e3d29;
}

.creative-section {
  display: grid;
  grid-template-columns: minmax(0, 0.83fr) minmax(0, 1.17fr);
  gap: 64px;
  align-items: center;
}

.creative-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 18px;
}

.creative-copy h2 {
  max-width: 15ch;
  margin-top: 0;
}

.creative-copy > p:not(.section-label) {
  max-width: 48ch;
  color: var(--ink-muted);
  font-size: 16px;
  line-height: 1.6;
  letter-spacing: -0.2px;
  text-wrap: pretty;
}

.library-company-tabs {
  display: flex;
  max-width: 100%;
  flex-wrap: wrap;
  gap: 6px;
}

.library-company-tabs button {
  border: 0;
  border-radius: 10px;
  padding: 8px 10px;
  background: var(--cream);
  color: var(--ink-muted);
  font-size: 12px;
}

.library-company-tabs button.active {
  background: var(--ink);
  color: var(--paper);
}

.library-empty-panel {
  display: flex;
  min-height: 300px;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-end;
  gap: 8px;
  padding: 26px;
  border: 1px solid rgba(37, 37, 37, 0.07);
  border-radius: var(--radius-card);
  background: var(--cream);
}

.library-empty-panel > span {
  color: var(--ink-soft);
  font-family: "NDOT", "Archivo", sans-serif;
  font-size: 10px;
  text-transform: uppercase;
}

.library-empty-panel strong {
  font-size: clamp(25px, 4vw, 38px);
  font-weight: 500;
  line-height: 1.04;
  letter-spacing: -1.4px;
}

.library-empty-panel p {
  margin: 0;
  color: var(--ink-muted);
  font-size: 13px;
}

.library-empty-panel a {
  margin-top: 16px;
  color: var(--ink-muted);
  font-size: 12px;
}

.library-empty-panel a:hover {
  color: var(--ink);
}

.creative-preview {
  display: flex;
  width: 100%;
  flex-direction: column;
  gap: 12px;
  padding: 18px;
  border-radius: var(--radius-card);
  background: var(--cream);
}

.preview-topline {
  color: var(--ink-soft);
  font-family: "NDOT", "Archivo", sans-serif;
  font-size: 9px;
  line-height: 14px;
  letter-spacing: -0.2px;
  text-transform: uppercase;
}

.creative-preview h3 {
  margin: 0;
  font-size: 18px;
  font-weight: 500;
  line-height: 24px;
  letter-spacing: -0.5px;
}

.creative-preview > p {
  margin: 0;
  color: var(--ink-muted);
  font-size: 13px;
  line-height: 19px;
}

.preview-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.preview-tags span {
  padding: 5px 8px;
  border-radius: 999px;
  background: var(--white);
  color: var(--ink-muted);
  font-size: 10px;
}

.creative-grid-wrap {
  position: relative;
  padding: 29px 0 0 29px;
}

.creative-grid {
  display: grid;
  grid-template-columns: repeat(10, minmax(0, 1fr));
  gap: 5px;
  padding: 10px;
  border: 1px solid rgba(37, 37, 37, 0.06);
  border-radius: var(--radius-card);
  background: var(--white);
  box-shadow: var(--shadow-floating);
}

.creative-cell {
  aspect-ratio: 1;
  border: 0;
  border-radius: 7px;
  background: var(--cream);
  opacity: 0.74;
}

.creative-cell:nth-child(4n + 1) {
  background: var(--lavender);
}

.creative-cell:nth-child(4n + 2) {
  background: var(--peach);
}

.creative-cell:nth-child(4n + 3) {
  background: var(--mint);
}

.creative-cell:hover,
.creative-cell.active {
  opacity: 1;
  transform: scale(1.12);
}

.creative-cell.active {
  box-shadow: 0 0 0 2px var(--ink);
}

.creative-axis {
  position: absolute;
  color: var(--ink-soft);
  font-family: "NDOT", "Archivo", sans-serif;
  font-size: 8px;
  letter-spacing: 0;
  text-transform: uppercase;
}

.creative-axis-top {
  top: 6px;
  right: 10px;
}

.creative-axis-side {
  bottom: 10px;
  left: 6px;
  transform: rotate(-90deg);
  transform-origin: left bottom;
}

.section-intro {
  max-width: 48ch;
  color: var(--ink-muted);
  font-size: 15px;
  line-height: 1.55;
  text-align: right;
  text-wrap: pretty;
}

.process-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 46px 0 0;
  padding: 0;
  list-style: none;
}

.process-list li {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 13px;
  padding: 0 28px;
  border-left: 1px solid rgba(37, 37, 37, 0.09);
}

.process-list li:first-child {
  padding-left: 0;
  border-left: 0;
}

.process-list li:last-child {
  padding-right: 0;
}

.process-number {
  color: var(--ink-soft);
  font-family: "NDOT", "Archivo", sans-serif;
  font-size: 10px;
}

.process-list h3 {
  margin: 0;
  font-size: 17px;
  font-weight: 500;
  letter-spacing: -0.4px;
}

.process-list p {
  color: var(--ink-muted);
  font-size: 15px;
  line-height: 1.55;
  text-wrap: pretty;
}

.rules-section {
  display: grid;
  grid-template-columns: minmax(0, 0.7fr) minmax(0, 1.3fr);
  gap: 64px;
}

.rules-copy h2 {
  max-width: 11ch;
}

.rules-list {
  border-top: 1px solid rgba(37, 37, 37, 0.09);
}

.rules-list details {
  border-bottom: 1px solid rgba(37, 37, 37, 0.09);
}

.rules-list summary {
  position: relative;
  padding: 20px 36px 20px 0;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -0.2px;
  list-style: none;
}

.rules-list summary::-webkit-details-marker {
  display: none;
}

.rules-list summary::after {
  position: absolute;
  top: 20px;
  right: 4px;
  color: var(--ink-soft);
  content: "+";
}

.rules-list details[open] summary::after {
  content: "−";
}

.rules-list p {
  padding: 0 36px 20px 0;
  color: var(--ink-muted);
  font-size: 15px;
  line-height: 1.55;
}

.site-footer {
  margin-top: 42px;
  border-top: 1px solid rgba(37, 37, 37, 0.08);
}

.footer-shell {
  width: min(1160px, calc(100% - 40px));
  min-height: 96px;
  margin: 0 auto;
}

.footer-brand {
  font-size: 15px;
}

.footer-brand img {
  width: 24px;
  height: 24px;
}

.site-footer p,
.footer-links {
  color: var(--ink-soft);
  font-size: 12px;
}

.footer-links {
  display: flex;
  gap: 18px;
}

.footer-links a:hover {
  color: var(--ink);
}

.bid-dialog {
  width: min(620px, calc(100% - 30px));
  max-width: none;
  padding: 0;
  border: 0;
  border-radius: var(--radius-composer);
  background: transparent;
  color: var(--ink);
  box-shadow: var(--shadow-floating);
}

.bid-dialog::backdrop {
  background: rgba(37, 37, 37, 0.26);
  backdrop-filter: blur(3px);
}

.dialog-card {
  display: flex;
  flex-direction: column;
  gap: 22px;
  max-height: calc(100dvh - 30px);
  overflow-y: auto;
  padding: 24px;
  border-radius: var(--radius-composer);
  background: rgba(255, 255, 255, 0.96);
}

.dialog-header {
  align-items: flex-start;
}

.dialog-header h2 {
  max-width: 16ch;
  font-size: 29px;
}

.close-button {
  min-height: 34px;
  padding: 6px 9px;
  font-size: 12px;
}

.bid-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 0;
  border-top: 1px solid rgba(37, 37, 37, 0.09);
  border-left: 1px solid rgba(37, 37, 37, 0.09);
}

.bid-summary > div {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 5px;
  padding: 14px;
  border-right: 1px solid rgba(37, 37, 37, 0.09);
  border-bottom: 1px solid rgba(37, 37, 37, 0.09);
}

.bid-summary dt {
  color: var(--ink-soft);
  font-size: 10px;
}

.bid-summary dd {
  overflow: hidden;
  margin: 0;
  font-size: 14px;
  font-weight: 500;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dialog-note {
  padding: 14px;
  border-radius: var(--radius-control);
  background: var(--peach-soft);
}

.dialog-note p {
  color: var(--ink-muted);
  font-size: 13px;
  line-height: 1.5;
}

.dialog-note .field-error:not(:empty) {
  margin-top: 9px;
  color: #b74c31;
}

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

.checkout-assurance > div {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  padding: 13px;
  border: 1px solid rgba(37, 37, 37, 0.07);
  border-radius: var(--radius-control);
  background: var(--cream);
}

.assurance-icon {
  display: inline-flex;
  width: 19px;
  height: 19px;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--mint);
  font-size: 11px;
}

.checkout-assurance p {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 2px;
  margin: 0;
  font-size: 12px;
  line-height: 16px;
}

.checkout-assurance strong {
  font-weight: 500;
}

.checkout-assurance p span {
  color: var(--ink-soft);
}

.button-spinner {
  display: none;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(251, 250, 247, 0.4);
  border-top-color: var(--paper);
  border-radius: 999px;
  animation: button-spin 700ms linear infinite;
}

.primary-button.is-loading .button-spinner {
  display: inline-block;
}

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

.dialog-actions {
  justify-content: flex-end;
}

.success-dialog {
  width: min(540px, calc(100% - 30px));
}

.success-card {
  position: relative;
  overflow: hidden;
  gap: 20px;
}

.success-topline,
.success-actions {
  position: relative;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.success-topline p,
.success-copy p,
.success-note {
  margin: 0;
}

.success-mark {
  position: relative;
  z-index: 1;
  display: inline-flex;
  width: 58px;
  height: 58px;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--mint);
  font-size: 25px;
  opacity: 0;
  transform: translateY(8px) rotate(-8deg) scale(0.8);
}

.success-dialog.is-celebrating .success-mark {
  animation: success-mark-in 480ms cubic-bezier(0.22, 1, 0.36, 1) 80ms forwards;
}

.success-copy {
  position: relative;
  z-index: 1;
}

.success-copy h2 {
  max-width: 14ch;
  margin: 0;
  font-size: clamp(34px, 7vw, 48px);
  font-weight: 500;
  line-height: 0.98;
  letter-spacing: -2.2px;
  text-wrap: balance;
}

.success-copy h2:focus {
  outline: none;
}

.success-copy p {
  max-width: 48ch;
  padding-top: 12px;
  color: var(--ink-muted);
  font-size: 14px;
  line-height: 1.55;
}

.success-copy strong {
  color: var(--ink);
  font-weight: 500;
}

.success-stats {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 0;
  padding: 15px 0;
  border-top: 1px solid rgba(37, 37, 37, 0.09);
  border-bottom: 1px solid rgba(37, 37, 37, 0.09);
}

.success-stats > div {
  min-width: 0;
  padding: 0 14px;
  border-left: 1px solid rgba(37, 37, 37, 0.09);
}

.success-stats > div:first-child {
  padding-left: 0;
  border-left: 0;
}

.success-stats > div:last-child {
  padding-right: 0;
}

.success-stats dt {
  color: var(--ink-soft);
  font-size: 10px;
  line-height: 14px;
}

.success-stats dd {
  overflow: hidden;
  margin: 4px 0 0;
  font-size: 16px;
  font-weight: 500;
  line-height: 20px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.success-note {
  position: relative;
  z-index: 1;
  color: var(--ink-soft);
  font-size: 12px;
  line-height: 18px;
}

.success-actions {
  justify-content: flex-end;
}

.success-actions .secondary-button {
  text-decoration: none;
}

.confetti-layer {
  position: absolute;
  z-index: 2;
  inset: 0;
  overflow: hidden;
  border-radius: inherit;
  pointer-events: none;
}

.confetti-piece {
  position: absolute;
  top: 31%;
  left: 50%;
  width: 7px;
  height: 12px;
  border-radius: 2px;
  background: var(--confetti-color);
  opacity: 0;
  transform: translate(0, 0) rotate(0);
  animation: confetti-burst var(--confetti-duration) cubic-bezier(0.22, 1, 0.36, 1) var(--confetti-delay) forwards;
}

@keyframes success-mark-in {
  to {
    opacity: 1;
    transform: translateY(0) rotate(0) scale(1);
  }
}

@keyframes confetti-burst {
  0% {
    opacity: 0;
    transform: translate(0, 0) rotate(0) scale(0.7);
  }
  12% {
    opacity: 1;
  }
  55% {
    opacity: 1;
    transform: translate(var(--confetti-x-mid), var(--confetti-y-mid)) rotate(var(--confetti-rotation-mid)) scale(1);
  }
  100% {
    opacity: 0;
    transform: translate(var(--confetti-x-end), var(--confetti-y-end)) rotate(var(--confetti-rotation)) scale(0.9);
  }
}

.toast {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 46px;
  padding: 10px 14px;
  border-radius: 14px;
  background: var(--ink);
  color: var(--paper);
  box-shadow: var(--shadow-floating);
  font-size: 13px;
}

.toast[hidden] {
  display: none;
}

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

@media (max-width: 760px) {
  .header-shell,
  .page-shell,
  .footer-shell {
    width: min(100% - 28px, 1000px);
  }

  .desktop-nav,
  .header-bid-button {
    display: none;
  }

  .mobile-menu-button {
    display: inline-flex;
    min-height: 42px;
    align-items: center;
    border-radius: 10px;
    padding: 8px 4px 8px 10px;
  }

  .mobile-nav {
    width: min(100% - 28px, 1000px);
    flex-direction: column;
    gap: 3px;
    margin: 0 auto;
    padding: 0 0 12px;
  }

  .mobile-nav:not([hidden]) {
    display: flex;
  }

  .mobile-nav a {
    padding: 11px 12px;
    border-radius: 10px;
    color: var(--ink-muted);
    font-size: 15px;
  }

  .mobile-nav a:hover {
    background: var(--cream);
    color: var(--ink);
  }

  .mobile-bid-button {
    display: inline-flex;
    min-height: 48px;
    align-items: center;
    justify-content: center;
    margin-top: 5px;
    border: 1px solid var(--ink);
    border-radius: 12px;
    background: var(--ink);
    color: var(--paper);
    font-size: 15px;
  }

  .hero {
    gap: 26px;
    padding: 46px 0 38px;
  }

  .hero-creative-field {
    top: 68px;
    right: -28%;
    width: 108%;
    opacity: 0.44;
    -webkit-mask-image: linear-gradient(to right, transparent 0%, rgba(0, 0, 0, 0.08) 30%, #000 74%);
    mask-image: linear-gradient(to right, transparent 0%, rgba(0, 0, 0, 0.08) 30%, #000 74%);
  }

  .hero-creative-grid {
    gap: 6px;
  }

  .hero-creative-caption {
    display: none;
  }

  .hero h1 {
    max-width: 13ch;
    font-size: clamp(43px, 13vw, 58px);
    letter-spacing: -2.8px;
  }

  .hero-copy > p {
    font-size: 16px;
    line-height: 1.6;
  }

  .hero-action-group {
    width: 100%;
    align-items: flex-start;
    flex-direction: column;
  }

  .hero-bid-button {
    width: 100%;
  }

  .market-stats {
    grid-template-columns: 1fr;
    gap: 0;
    border-bottom: 1px solid rgba(37, 37, 37, 0.08);
  }

  .market-stats > div {
    flex-direction: row;
    justify-content: space-between;
    padding: 12px 0;
    border-top: 1px solid rgba(37, 37, 37, 0.08);
    border-left: 0;
  }

  .market-stats > div:first-child {
    border-top: 0;
  }

  .bid-composer {
    gap: 17px;
    padding: 17px;
  }

  .modal-bid-form {
    padding: 0;
  }

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

  .composer-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .primary-button,
  .secondary-button {
    min-height: 48px;
  }

  .composer-footer .primary-button {
    width: 100%;
  }

  .market-section,
  .creative-section,
  .process-section,
  .rules-section {
    padding: 56px 0;
  }

  .section-heading-row {
    align-items: flex-start;
  }

  .market-heading-side {
    align-items: flex-start;
    text-align: left;
  }

  .market-section .section-heading-row {
    flex-direction: column;
    gap: 16px;
  }

  .bid-row {
    grid-template-columns: 46px minmax(0, 1fr);
    gap: 11px;
    padding: 14px;
  }

  .rank-badge {
    width: 38px;
    height: 38px;
    border-radius: 12px;
  }

  .bid-title-row {
    align-items: flex-start;
    flex-direction: column;
    gap: 5px;
  }

  .bid-description {
    display: -webkit-box;
    overflow: hidden;
    white-space: normal;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  .bid-price {
    grid-column: 2;
    align-self: auto;
    align-items: center;
    flex-direction: row;
    padding: 11px 0 0;
    border-top: 1px solid rgba(37, 37, 37, 0.08);
    border-left: 0;
  }

  .delivery-timing {
    align-items: flex-end;
  }

  .creative-section,
  .rules-section {
    grid-template-columns: 1fr;
    gap: 42px;
  }

  .creative-copy h2,
  .rules-copy h2 {
    max-width: 18ch;
  }

  .creative-grid-wrap {
    padding-left: 22px;
  }

  .creative-grid {
    gap: 3px;
    padding: 7px;
  }

  .creative-cell {
    border-radius: 4px;
  }

  .process-section .section-heading-row {
    flex-direction: column;
    gap: 16px;
  }

  .section-intro {
    font-size: 16px;
    text-align: left;
  }

  .process-list {
    grid-template-columns: 1fr;
    margin-top: 34px;
  }

  .process-list li,
  .process-list li:first-child,
  .process-list li:last-child {
    padding: 22px 0;
    border-top: 1px solid rgba(37, 37, 37, 0.09);
    border-left: 0;
  }

  .footer-shell {
    align-items: flex-start;
    flex-direction: column;
    padding: 26px 0;
  }

  .bid-outcome-strip {
    grid-template-columns: 1fr 1fr;
    row-gap: 12px;
  }

  .bid-outcome-strip > div:nth-child(3) {
    padding: 12px 0 0;
    border-top: 1px solid rgba(37, 37, 37, 0.09);
    border-left: 0;
  }

  .bid-outcome-strip > div:nth-child(4) {
    padding-top: 12px;
    border-top: 1px solid rgba(37, 37, 37, 0.09);
  }

  .success-stats {
    grid-template-columns: 1fr 1fr;
    row-gap: 13px;
  }

  .success-stats > div:nth-child(3) {
    grid-column: 1 / -1;
    padding: 13px 0 0;
    border-top: 1px solid rgba(37, 37, 37, 0.09);
    border-left: 0;
  }

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

  .success-actions > * {
    width: 100%;
  }

  .toast {
    right: 14px;
    bottom: 14px;
    left: 14px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }

  .confetti-piece {
    display: none;
  }

  .hero-creative-tile {
    opacity: 0.22;
    transform: none;
  }

  .hero-creative-tile.is-active {
    opacity: 0.58;
    transform: none;
  }

  .success-mark {
    opacity: 1;
    transform: none;
  }
}

@media (prefers-reduced-transparency: reduce) {
  .site-header {
    background: var(--paper);
    backdrop-filter: none;
  }

  .bid-dialog::backdrop,
  .success-dialog::backdrop {
    backdrop-filter: none;
  }
}

@media (prefers-contrast: more) {
  .site-header,
  .dialog-card {
    background: var(--white);
  }

  .bid-row,
  .bid-composer,
  .creative-grid {
    border-color: rgba(37, 37, 37, 0.3);
  }
}
