:root {
  font-family: Geist, Arial, sans-serif;
  color: #0e0e0e;
  background: #111;
  color-scheme: dark;
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
  --paper: #fefffa;
  --surface: #f4f5f0;
  --line: #eaebe6;
  --muted: rgba(0, 0, 0, 0.6);
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --modal-fill: #161616;
  --modal-border: #282828;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  min-height: 100dvh;
}
.app-starting .screen {
  visibility: hidden;
}
html:has(.workspace:not([hidden])) {
  scrollbar-gutter: stable;
}
html:has(dialog[open]),
html:has(dialog[open]) body {
  overflow: hidden;
}
.detail-dialog,
.detail-info,
.board-drawer {
  overscroll-behavior: contain;
}
button,
input,
textarea {
  font: inherit;
}
button,
a {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
}
a {
  color: inherit;
}
button:disabled {
  cursor: wait;
  opacity: 0.6;
}
[hidden] {
  display: none !important;
}
h1,
h2,
p {
  margin: 0;
}
button:focus-visible,
a:focus-visible {
  outline: 2px solid #777;
  outline-offset: 4px;
}
.screen {
  min-height: 100svh;
}
.navigation {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 32px;
  height: 80px;
  position: relative;
  z-index: 2;
}
.navigation > a {
  display: flex;
  border-radius: 50%;
}
.navigation img {
  display: block;
}
nav {
  display: flex;
  align-items: center;
  gap: 6px;
}
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  height: 38px;
  padding: 4px 16px;
  border: 1px solid transparent;
  border-radius: 900px;
  font-size: 14px;
  line-height: normal;
  white-space: nowrap;
  transition:
    transform 140ms var(--ease-out),
    background-color 150ms ease,
    color 150ms ease;
}
.button:active {
  transform: scale(0.97);
}
.primary {
  color: #fefefe;
  background: #262626;
}
.secondary {
  background: var(--surface);
  border-color: var(--line);
  color: #0e0e0e;
}
.x-icon {
  width: 14px;
  height: 14px;
  display: grid;
  place-items: center;
}
.x-icon img {
  display: block;
}
h1 {
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -1.2px;
}
.auth-screen {
  display: grid;
  place-items: center;
  padding: 152px 24px;
  background: #111;
  color: #fefefe;
  font-family: Geist, sans-serif;
}

.auth-card {
  width: min(360px, 100%);
}

.auth-heading {
  display: grid;
  justify-items: center;
  gap: 28px;
  margin-bottom: 39px;
}

.auth-heading img, .auth-button img {
  display: block;
}

.auth-heading h1 {
  max-width: 340px;
  font: 400 24px/1.25 "Geist Serif", Georgia, serif;
  letter-spacing: normal;
  text-align: center;
}

.auth-fields, #auth-form {
  display: grid;
  gap: 24px;
}

.auth-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 34px;
  border: 0;
  border-radius: 12px;
  font: 500 14px Geist, sans-serif;
  letter-spacing: -.14px;
  text-decoration: none;
  transition: background-color 160ms ease, color 160ms ease, transform 160ms var(--ease-out);
}

.auth-button:active {
  transform: scale(.985);
}

.auth-provider {
  background: #1f1f1f;
}

.auth-provider:hover {
  background: #292929;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 14px;
  color: #888;
}

.auth-divider::before, .auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: url("assets/login-rule.svg") repeat-x;
}

.input-field label {
  margin-bottom: 8px;
  color: #b1b0ae;
  font: 400 15px/18px Geist, sans-serif;
  letter-spacing: -.15px;
}

.input-shell {
  position: relative;
}

.input-shell input {
  height: 36px;
  padding: 4px 10px;
  background: #1f1f1f;
  color: #fefefe;
  font: 400 15px/normal Geist, sans-serif;
  letter-spacing: -.225px;
}

.input-shell input::placeholder { color: #6e6e6e; }
.input-shell input:hover { border-color: #909090; }
.input-shell input:focus,
.input-shell input[readonly] { border-color: #fefefe; }
.input-shell input[aria-invalid="true"] { border-color: #ff7300; }

.input-count {
  position: absolute;
  inset: 0 10px 0 auto;
  display: grid;
  align-items: center;
  color: #6e6e6e;
  font: 400 14px/normal Geist, sans-serif;
  letter-spacing: -.14px;
  pointer-events: none;
}
.input-shell:has(.input-count) input { padding-right: 58px; }
.input-shell input[aria-invalid="true"] + .input-count { color: #ff7300; }
#board-name-error {
  margin-top: 6px;
  color: #ff7300;
  font: 400 14px/normal Geist, sans-serif;
  letter-spacing: -.14px;
}

.auth-input img {
  position: absolute;
  inset: 10px 10px auto auto;
  opacity: 0;
  transition: opacity 160ms ease;
  pointer-events: none;
}

.input-shell:not(:has(.input-count)) input[aria-invalid="true"] { padding-right: 36px; }
.auth-input input[aria-invalid="true"] + img {
  opacity: 1;
}

.auth-error {
  display: grid;
  grid-template-rows: 0fr;
  opacity: 0;
  color: #ff7300;
  font-size: 14px;
  letter-spacing: -.14px;
  transition: grid-template-rows 180ms var(--ease-out), opacity 160ms ease;
}

.auth-error span {
  overflow: hidden;
}

.auth-error[data-visible] {
  grid-template-rows: 1fr;
  opacity: 1;
}

.auth-error[data-visible] span {
  padding-top: 6px;
}

.auth-submit {
  background: #fefefe;
  color: #0e0e0e;
}

.auth-submit[data-muted], .auth-submit:disabled {
  background: #b8b8b8;
  color: #555;
  opacity: 1;
}

.auth-loader {
  animation: auth-spin 800ms linear infinite;
}

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

#auth-status {
  color: #b1b0ae;
  font-size: 14px;
}

#auth-status:empty {
  display: none;
}

@media (max-width: 700px) {
  .auth-screen { padding-inline: 16px; }
  .auth-heading h1 { font-size: 26px; }
  .auth-button { height: 40px; }
}

@media (prefers-reduced-motion: reduce) {
  .auth-loader { animation: none; }
}

form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
label {
  font-size: 16px;
  line-height: 1.15;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
input,
textarea {
  width: 100%;
  min-width: 0;
  background: var(--surface);
  border: 1px solid transparent;
  border-radius: 12px;
  padding: 10px 16px;
  font-size: 14px;
  color: #0e0e0e;
  outline: none;
  transition: border-color 150ms ease;
}
input {
  height: 40px;
}
input::placeholder,
textarea::placeholder {
  color: rgba(14, 14, 14, 0.3);
}
input:focus,
textarea:focus {
  border-color: #262626;
}
textarea {
  resize: vertical;
}
.form-status {
  font-size: 12px;
  line-height: 1.5;
  color: #ac392d;
}
.form-status:empty {
  display: none;
}
.workspace {
  background: #111;
  color: #b1b0ae;
  font-family: Geist, sans-serif;
  --workspace-gutter: 32px;
  --workspace-nav-height: 80px;
}

.workspace-nav {
  position: sticky;
  top: 0;
  z-index: 3;
  height: var(--workspace-nav-height);
  padding-inline: var(--workspace-gutter);
  background: #111;
}

.workspace .secondary {
  gap: 6px;
  border: 0;
  border-radius: 12px;
  background: #1f1f1f;
  color: inherit;
  letter-spacing: -.21px;
}

.workspace .secondary:hover {
  background: #292929;
}

#paste-link {
  height: 34px;
  border: 0;
  border-radius: 12px;
  padding: 4px 16px;
  gap: 6px;
  background: #fefefe;
  color: #0e0e0e;
  font-weight: 500;
  letter-spacing: -.21px;
}
#paste-link .x-icon { width: 16px; height: 16px; }
#paste-link .x-icon img { filter: brightness(0); }
@media (hover: hover) and (pointer: fine) {
  #paste-link:hover { background: #eaeaea; }
}

.avatar-button {
  display: flex;
  border: 0;
  background: none;
  border-radius: 12px;
  padding: 0;
  width: 34px;
  height: 34px;
}

.avatar-button img {
  border-radius: inherit;
  object-fit: cover;
}
.account-initial {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  background: #282828;
  color: #fefefe;
  font-size: 15px;
  font-weight: 500;
}

.filters {
  position: sticky;
  top: var(--workspace-nav-height);
  z-index: 2;
  background: #111;
  padding: 12px var(--workspace-gutter);
  min-height: 56px;
  gap: 2px;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scrollbar-width: none;
  isolation: isolate;
}

.filter {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 32px;
  border: 0;
  background: transparent;
  color: inherit;
  padding: 4px 12px;
  border-radius: 12px;
  font-size: 14px;
  letter-spacing: -.21px;
  white-space: nowrap;
  transition: background-color 150ms ease, color 150ms ease;
}

.filter.active {
  background: #1f1f1f;
  color: #fefefe;
}

@media (hover: hover) and (pointer: fine) {
  .filter:not(.active):hover { color: #fefefe; }
}

.filter[data-board=""] {
  min-width: 70px;
}

.filter-count {
  font-size: 13px;
  font-variant-numeric: tabular-nums;
  padding-inline: 4px;
  border-radius: 6px;
  transition: background-color 150ms ease;
}

.filter.active .filter-count {
  background: #292929;
  color: #b1b0ae;
}

.gallery-content {
  padding: 18.5px var(--workspace-gutter) 40px;
  scroll-margin-top: calc(var(--workspace-nav-height) + 56px);
}

.gallery-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 18px;
  margin-bottom: 28px;
  font-size: 16px;
  line-height: 1.15;
  letter-spacing: -.24px;
}

.empty-state {
  text-align: center;
  padding: 181.5px 0 80px;
}

.empty-state h1 {
  color: #fefefe;
  font: 400 24px/1.15 "Geist Serif", Georgia, serif;
  letter-spacing: normal;
}

.empty-state p {
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: -.24px;
  margin: 12px 0 28px;
}

.design-grid {
  position: relative;
  --columns: 4;
  --gap: 12px;
}
.design-card {
  position: absolute;
  top: 0;
  left: 0;
  padding: 0;
  border: 1px solid #1B1B1B;
  background: #edeee9;
  border-radius: 6px;
  overflow: hidden;
  cursor: pointer;
  text-align: left;
  color: #0e0e0e;
  display: block;
  isolation: isolate;
}
.image-slot {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: var(--image-ratio);
  background: #edeee9;
  overflow: hidden;
}
.image-slot img {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 180ms ease;
}
.design-card:has(.extreme-label) .image-slot img { object-fit: contain; }
.design-card.loaded .image-slot img {
  opacity: 1;
}
.design-card.loading .image-slot:after {
  content: "";
  position: absolute;
  inset: 0;
  background: #e3e5de;
  animation: skeleton-pulse 1.4s ease-in-out infinite alternate;
}
.design-card.loaded:has(.creator-badge)::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: min(76px, 100%);
  background: linear-gradient(to top, rgba(0, 0, 0, 0.36), transparent);
  pointer-events: none;
}

.creator-badge {
  position: absolute;
  bottom: 12px;
  left: 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  max-width: calc(100% - 24px);
  padding: 4px 10px 4px 4px;
  height: 36px;
  background: rgba(235, 235, 230, 0.82);
  box-shadow:
    0 8px 15px rgba(0, 0, 0, 0.04),
    inset 0 1px 2px rgba(255, 255, 255, 0.45),
    inset 0 -1px 2px rgba(26, 26, 26, 0.09);
  border-radius: 1000px;
  corner-shape: round;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: -.18px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  z-index: 1;
}

@supports (backdrop-filter: blur(1px)) {
  .creator-badge {
    background: linear-gradient(155deg, rgba(255, 255, 255, 0.72), rgba(225, 225, 225, 0.53));
    backdrop-filter: blur(8px) saturate(1.4);
  }
}

.creator-name {
  overflow: hidden;
  text-overflow: ellipsis;
}

.creator-badge img,
.creator-initial {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  border-radius: 50%;
  object-fit: cover;
}
.creator-initial {
  display: grid;
  place-items: center;
  background: #dedfd6;
  color: #606458;
  font-size: 12px;
}
.extreme-label {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 5px 8px;
  border-radius: 30px;
  background: #fefffadd;
  color: #333;
  font-size: 10px;
}
.image-error {
  display: grid;
  place-items: center;
  position: absolute;
  inset: 0;
  padding: 16px;
  font-size: 12px;
  color: #777;
  text-align: center;
}
.account-menu {
  position: fixed;
  inset: 65px 32px auto auto;
  margin: 0;
  width: 240px;
  max-width: calc(100vw - 32px);
  padding: 0;
  border: 1px solid #282828;
  border-radius: 12px;
  background: #1a1a1a;
  color: #b1b0ae;
  font: 400 14px/18px Geist, sans-serif;
  letter-spacing: -.21px;
  box-shadow: 0 12px 16px -4px #00000014, 0 4px 6px -2px #00000008;
}
.account-options,
.account-footer { padding: 6px; }
.account-footer { border-top: 1px solid #282828; }
.menu-button {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  height: 34px;
  padding: 4px 10px;
  border: 0;
  border-radius: 12px;
  background: none;
  color: inherit;
  font: inherit;
  text-align: left;
  text-decoration: none;
}
.menu-button:hover:not(:disabled) { background: #212121; }
.account-upload { justify-content: space-between; }
.account-upload:disabled { opacity: 1; cursor: default; }
.account-upload > span:first-child { opacity: .4; }
.coming-soon-badge {
  padding: 2px 6px;
  border-radius: 20px;
  background: #ff730024;
  color: #ff7300;
  font-size: 10px;
  line-height: 12px;
  letter-spacing: -.15px;
}
#logout { background: #ff383c24; color: #ff383c; }
#logout:hover { background: #ff383c38; }
#logout > img { flex: none; }
.add-board { width: 32px; padding: 0; font-size: 20px; }
dialog {
  width: min(408px, calc(100% - 32px));
  max-height: calc(100svh - 48px);
  overflow: auto;
  border: 0;
  border-radius: 24px;
  padding: 24px;
  color: #0e0e0e;
  background: var(--paper);
  box-shadow:
    0 0 0 1px #00000003,
    0 16px 60px #0000000a;
  opacity: 0;
  transform: translateY(8px) scale(0.98);
  transition:
    opacity 180ms ease,
    transform 220ms var(--ease-out),
    display 220ms allow-discrete,
    overlay 220ms allow-discrete;
}
dialog[open] {
  opacity: 1;
  transform: translateY(0) scale(1);
}
dialog:focus { outline: none; }
dialog::backdrop {
  background: rgba(0, 0, 0, 0.14);
  backdrop-filter: blur(8px);
  opacity: 0;
  transition:
    opacity 180ms ease,
    display 220ms allow-discrete,
    overlay 220ms allow-discrete;
}
dialog[open]::backdrop {
  opacity: 1;
}
@starting-style {
  dialog[open] {
    opacity: 0;
    transform: translateY(8px) scale(0.98);
  }
  dialog[open]::backdrop {
    opacity: 0;
  }
}
dialog.closing {
  opacity: 0;
  transform: translateY(4px) scale(0.985);
  transition-duration: 140ms;
}
dialog.closing::backdrop {
  opacity: 0;
  transition-duration: 140ms;
}
dialog :is(h2, h3) { color: #fefefe; }
dialog h2 {
  font-size: 24px;
  font-weight: 500;
  letter-spacing: -0.6px;
  line-height: 1.15;
}
.close {
  position: absolute;
  right: 12px;
  top: 10px;
  border: 0;
  background: none;
  color: #818278;
  font-size: 22px;
  width: 24px;
  height: 24px;
  line-height: 1;
  opacity: 0;
}
.close:focus-visible,
dialog:hover > .close {
  opacity: 1;
}
.import-dialog,
.board-dialog,
.delete-dialog {
  width: 400px;
  max-width: calc(100% - 32px);
  padding: 0;
  background: var(--modal-fill);
  border: 1px solid var(--modal-border);
  border-radius: 24px;
  color: #b1b0ae;
  font-family: Geist, sans-serif;
}

.import-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--modal-border);
}

.import-header h2 {
  font: 450 16px/20px Geist, sans-serif;
  letter-spacing: -.24px;
}

.import-header .close {
  position: static;
  display: grid;
  place-items: center;
  opacity: 1;
  margin: -2px 0;
  padding: 0;
}

#import-form {
  padding: 20px;
  gap: 20px;
}

.import-input img {
  position: absolute;
  right: 10px;
  top: 10px;
  pointer-events: none;
}

#import-error, #import-status {
  color: #ff7300;
  font-size: 14px;
}

#import-error {
  margin-top: 6px;
}

.import-actions {
  display: grid;
  gap: 8px;
}

.import-actions .button {
  height: 34px;
  gap: 6px;
  border: 0;
  border-radius: 12px;
  letter-spacing: -.21px;
}

.import-actions .primary {
  background: #fefefe;
  color: #0e0e0e;
  font-weight: 500;
}

.import-actions .primary[data-muted],
.import-actions .primary:disabled {
  opacity: 1;
  background: #b8b8b8;
  color: #555;
}

@media (max-width: 700px) {
  .import-actions .primary { height: 40px; }
}

.detail-layout {
  display: grid;
}
.detail-image-slot {
  position: relative;
  width: min(100%, calc(var(--preview-image-height, 100cqh) * var(--image-ratio)));
  aspect-ratio: var(--image-ratio);
  margin: auto;
  overflow: hidden;
  border-radius: 6px;
  corner-shape: round;
  background: #262626;
}
.detail-image {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 1;
  transition: opacity 180ms ease;
}
.detail-image-slot.loading .detail-image { opacity: 0; }
.detail-image-slot.loading::after {
  content: "";
  position: absolute;
  inset: 0;
  background: #333;
  animation: skeleton-pulse 1.4s ease-in-out infinite alternate;
}
.detail-info h2 {
  font: 400 20px/1.15 "Geist Serif", Georgia, serif;
  letter-spacing: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.detail-stage {
  display: grid;
  container-type: size;
  align-content: center;
  justify-items: center;
  gap: 16px;
}
.detail-toolbar,
.detail-actions,
.detail-author,
.detail-boards,
.detail-navigation {
  display: flex;
  align-items: center;
  gap: 8px;
}
.detail-toolbar { justify-content: space-between; }
.detail-info,
.detail-metadata {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.detail-author,
.detail-notes {
  color: #b1b0ae;
  font-size: 14px;
  overflow-wrap: anywhere;
}
.detail-author > span:last-child { font-size: 15px; }
.detail-author img { border-radius: 50%; object-fit: cover; }
.navigation > a,
.creator-badge img,
.creator-initial,
.detail-author img,
.board-options input {
  corner-shape: round;
}
.detail-boards { flex-wrap: wrap; }
.detail-boards:empty { display: none; }
.detail-boards span {
  border-radius: 12px;
  padding: 8px 12px;
  background: #1f1f1f;
  font-size: 14px;
  overflow-wrap: anywhere;
  max-width: 100%;
}
.detail-actions { align-items: flex-start; }
.preview-control {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 34px;
  padding: 4px 12px;
  border: 0;
  border-radius: 12px;
  background: #1f1f1f;
  color: #b1b0ae;
  font: inherit;
  font-size: 14px;
  cursor: pointer;
  transition: background-color 150ms ease, color 150ms ease;
}
.preview-control:not(:disabled):hover { background: #292929; color: #fefefe; }
.preview-control:disabled { opacity: .4; cursor: default; }
.preview-icon { flex: 0 0 34px; width: 34px; padding: 0; }
.detail-navigation { width: min(240px, 100%); gap: 6px; }
.detail-navigation button { flex: 1; }
.board-picker { flex: 1; min-width: 0; position: relative; }
.board-picker summary {
  display: flex;
  justify-content: space-between;
  padding-inline: 16px;
  list-style: none;
}
.board-picker.unassigned summary {
  background: #fefefe;
  color: #111;
  font-weight: 500;
}
.board-picker.unassigned summary:hover { background: #eaeaea; color: #111; }
.board-picker.unassigned summary img { filter: brightness(0); }
.board-picker summary::-webkit-details-marker { display: none; }
.board-picker-panel {
  position: relative;
  isolation: isolate;
  width: min(242px, 100%);
  margin-top: 6px;
  overflow: hidden;
  border: 1px solid #282828;
  border-radius: 18px;
  background: #1a1a1a;
  color: #fefefe;
  font: 400 14px/18px Geist, sans-serif;
  letter-spacing: -0.21px;
  box-shadow: 0 12px 16px -4px #00000014, 0 4px 6px -2px #00000008;
}
.board-picker-panel h3 {
  margin: 0;
  padding: 12px 16px;
  font: inherit;
  font-weight: 500;
  border-bottom: 1px solid #282828;
}
.board-options {
  max-height: 174px;
  overflow-y: auto;
}
.board-options,
.board-picker-footer {
  padding: 6px;
}
.board-picker-footer { border-top: 1px solid #282828; }
.board-options[hidden] + .board-picker-footer { border-top: 0; }
.board-options label,
.board-create {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  padding: 6px 10px;
  border-radius: 12px;
  cursor: pointer;
  transition: color 150ms ease, background-color 150ms ease;
}
.board-options label {
  flex-direction: row-reverse;
  justify-content: space-between;
  color: #b1b0ae;
  font: 400 14px/normal Geist, sans-serif;
}
.board-options label span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
/* Keep native checkbox semantics; show only the selected Figma checkmark. */
.board-options input {
  appearance: none;
  flex: none;
  width: 16px;
  height: 16px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  cursor: inherit;
}
.board-options label:has(:checked) { color: #fefefe; }
.board-options input:checked {
  background: url("/assets/board-check.svg") center / 16px 16px no-repeat;
}
.board-options label:hover,
.board-options label:focus-within,
.board-create:hover,
.board-create:focus-visible {
  color: #fefefe;
}
.board-options label:has(input:focus-visible) { background: #242424; }
.board-create:focus-visible { background: #212121; }
@media (hover: hover) and (pointer: fine) {
  .board-options label:hover { background: #242424; }
  .board-create:hover { background: #212121; }
}
.board-create {
  width: 100%;
  height: 34px;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  letter-spacing: inherit;
  text-align: left;
}

@media (min-width: 1000px) {
  .detail-dialog {
    inset: 0;
    width: 100%;
    max-width: none;
    height: 100%;
    max-height: none;
    margin: 0;
    padding: 0;
    overflow: hidden;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    color: #fefefe;
    transform: none;
  }
  .detail-dialog[open],
  .detail-dialog.closing { transform: none; }
  .detail-dialog::backdrop {
    background: rgb(0 0 0 / 20%);
    backdrop-filter: blur(15px);
  }
  #detail-content,
  .detail-layout { height: 100%; }
  .detail-layout {
    grid-template-columns: minmax(0, 1fr) 420px;
    gap: 0;
  }
  .detail-stage {
    position: relative;
    grid-template: minmax(0, 1fr) / minmax(0, 1fr);
    align-items: center;
    padding-inline: clamp(48px, 8.333vw, 120px);
  }
  .detail-image-slot {
    --preview-image-height: min(100cqh, max(120px, calc(100dvh - 164px)));
  }
  .detail-navigation {
    position: absolute;
    inset: auto 0 min(40px, 5dvh);
    margin-inline: auto;
  }
  .detail-toolbar {
    position: absolute;
    z-index: 1;
    top: 24px;
    right: 24px;
    width: 372px;
  }
  .detail-info {
    padding: 98px 24px 24px;
    gap: 40px;
    overflow: auto;
    background: #111;
  }
  .board-picker-panel {
    position: absolute;
    right: 0;
    top: 100%;
    transform-origin: top right;
  }
  @media (prefers-reduced-motion: no-preference) {
    .board-picker summary img {
      transition: transform 160ms ease-out;
    }
  }
  .board-picker[data-expanded] > summary img {
    transform: rotate(180deg);
  }
}
.confirm-actions {
  display: flex;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}
.delete-body { padding: 20px; display: grid; gap: 20px; }
#confirm-description {
  font: 400 16px/normal Geist, sans-serif;
  letter-spacing: -.16px;
}
.delete-dialog .confirm-actions { margin: 0; gap: 12px; }
.delete-dialog .button {
  height: 34px;
  padding: 4px 20px;
  border: 0;
  border-radius: 12px;
  font: 400 14px/normal Geist, sans-serif;
}
.delete-dialog .secondary { background: #1f1f1f; color: #b1b0ae; }
.delete-dialog .secondary:hover { background: #292929; }
.delete-dialog .primary { background: #ff383c24; color: #ff383c; font-weight: 500; }
.delete-dialog .primary:hover { background: #ff383c38; }
#toast {
  position: fixed;
  inset: auto max(16px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom)) auto;
  margin: 0;
  border: 0;
  background: #262626;
  color: #fff;
  padding: 13px 20px;
  border-radius: 12px;
  font-size: 13px;
  max-width: calc(100% - 32px);
  width: max-content;
  z-index: 10;
  box-shadow: 0 6px 25px #0001;
  transition:
    opacity 180ms ease,
    transform 220ms var(--ease-out),
    display 220ms allow-discrete;
}
@starting-style {
  #toast {
    opacity: 0;
    transform: translateY(8px);
  }
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
}
@keyframes skeleton-pulse {
  to {
    opacity: 0.45;
  }
}
@media (hover: hover) and (pointer: fine) {
  .primary:hover {
    background: #141414;
  }
  .import-actions .primary:enabled:not([data-muted]):hover {
    background: #EAEAEA;
  }
  .secondary:hover {
    background: #eaebe6;
  }
}
@media (min-width: 1800px) {
  .design-grid {
    --columns: 5;
  }
}
@media (min-width: 701px) and (max-width: 1100px) {
  .design-grid {
    --columns: 3;
  }
}
@media (max-width: 700px) {
  .design-grid {
    --columns: 1;
    --gap: 12px;
  }
  .workspace {
    --workspace-gutter: 16px;
    --workspace-nav-height: 58px;
  }
  .workspace-nav {
    padding-block: 12px;
  }
  .workspace-nav nav {
    height: 34px;
  }
  .workspace-nav #paste-link,
  .workspace-nav .avatar-button,
  .workspace-nav .avatar-button img {
    height: 100%;
  }
  .workspace-nav .avatar-button,
  .workspace-nav .avatar-button img {
    width: 34px;
  }
  .account-menu {
    inset: 60px 16px auto auto;
    max-width: calc(100vw - 32px);
  }
  .extreme-label {
    font-size: 9px;
    max-width: calc(100% - 12px);
    top: 6px;
    right: 6px;
  }
  .close {
    opacity: 1;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition-duration: 0ms !important;
    scroll-behavior: auto !important;
  }
  dialog,
  dialog[open],
  dialog.closing {
    transform: none;
  }
  .button:active,
  .filter:active {
    transform: none;
  }
}
html[data-keyboard] dialog:not(.board-drawer),
html[data-keyboard] dialog:not(.board-drawer)::backdrop {
  transition-duration: 0ms !important;
  transform: none;
}

@media (pointer: coarse), (max-width: 700px) {
  input,
  textarea,
  select,
  .input-shell input {
    font-size: 16px;
  }
}

/* Smooth programmatic navigation alongside the library wheel animation. */
html,
dialog,
.filters {
  scroll-behavior: smooth;
}

#board-form {
  margin: 0;
  padding: 20px;
  gap: 20px;
}
#board-form .primary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 34px;
  min-height: 0;
  border: 0;
  border-radius: 12px;
  background: #fefefe;
  color: #111;
  font: 500 14px/normal Geist, sans-serif;
}
#board-form .primary:hover:not(:disabled) { background: #eaeaea; }
#board-form .primary:disabled { opacity: 1; background: #b8b8b8; color: #555; }

.detail-boards span { min-height: 34px; }
.detail-dialog { font-family: Geist, sans-serif; }

.board-drawer {
  inset: auto 16px max(16px, env(safe-area-inset-bottom));
  margin: 0;
  width: auto;
  max-width: none;
  max-height: 75dvh;
  padding: 0;
  background: var(--modal-fill);
  border: 1px solid var(--modal-border);
  border-radius: 24px;
  transform: translateY(12px);
}
.board-drawer .board-picker-panel {
  width: 100%;
  margin: 0;
  border-radius: 0;
  outline: none;
  border: 0;
  box-shadow: none;
}
@media (prefers-reduced-motion: no-preference) {
  .board-drawer.closing { transform: translateY(6px); }
  @starting-style {
    .board-drawer[open] { transform: translateY(12px); }
  }
}
.board-drawer h3 {
  padding: 16px 56px 16px 16px;
  font-size: 16px;
  font-weight: 450;
  line-height: 21px;
}
.board-drawer .board-options { max-height: min(40dvh, 260px); }
.board-drawer .board-options label {
  min-height: 40px;
  padding-inline: 10px;
  gap: 10px;
  font-size: 16px;
}
.board-drawer .board-options label + label { margin-top: 4px; }
.board-drawer .board-create { height: 40px; }
.board-drawer-close {
  position: absolute;
  top: 18px;
  right: 18px;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  padding: 0;
  border: 0;
  background: transparent;
}
.board-drawer.closing { transform: translateY(16px); }
.account-drawer {
  color: #b1b0ae;
  font: 400 16px/normal Geist, sans-serif;
}
.account-drawer .account-options { display: grid; gap: 4px; }
.account-drawer .menu-button { height: 40px; }
.account-drawer .account-footer { padding: 16px; border: 0; }
.account-drawer #logout { justify-content: center; gap: 6px; font-size: 14px; }
@starting-style {
  .board-drawer[open] { transform: translateY(12px); }
}

@media (max-width: 999px) {
  .detail-dialog {
    inset: 0;
    width: 100%;
    max-width: none;
    height: 100dvh;
    max-height: none;
    margin: 0;
    padding: 0;
    border-radius: 0;
    background: #111;
    color: #fefefe;
  }
  #detail-content { height: 100%; display: flex; }
  .detail-layout {
    display: flex;
    flex: 1;
    flex-direction: column;
    min-width: 0;
    gap: 0;
  }
  .detail-toolbar {
    position: sticky;
    top: 0;
    z-index: 2;
    padding: 16px;
    background: #111;
  }
  .detail-stage {
    flex: 1;
    min-height: 0;
    grid-template: minmax(0, 1fr) / minmax(0, 1fr);
    padding: 16px;
  }
  .detail-image-slot {
    min-height: 0;
    border-radius: 8px;
  }
  .detail-navigation { display: none; }
  .detail-info {
    flex: none;
    padding: 16px;
    padding-bottom: max(16px, env(safe-area-inset-bottom));
    gap: 24px;
  }
  .detail-info .detail-metadata { max-height: 25dvh; overflow: auto; }
  .detail-info h2 { font-size: 18px; }
  .detail-layout .preview-control { height: 40px; }
  .detail-layout .preview-icon { width: 40px; flex-basis: 40px; }
}

@media (max-width: 700px) {
  .account-menu .menu-button { height: 40px; }
  .account-options { display: grid; gap: 4px; }
  #board-form .primary { height: 40px; }
  .delete-dialog .button { flex: 1; height: 40px; }
}

@media (max-width: 700px) {
  .import-dialog,
  .board-dialog,
  .delete-dialog {
    inset: auto 16px max(16px, env(safe-area-inset-bottom));
    margin: 0;
    width: auto;
    max-width: none;
    max-height: calc(100dvh - 32px);
    border-radius: 24px;
    transform: translateY(24px);
  }
  :is(.import-dialog, .board-dialog, .delete-dialog)[open] { transform: none; }
  :is(.import-dialog, .board-dialog, .delete-dialog).closing { transform: translateY(16px); }
  @starting-style {
    :is(.import-dialog, .board-dialog, .delete-dialog)[open] { transform: translateY(24px); }
  }
  .board-drawer .board-picker-footer { border: 0; padding: 8px 16px 16px; }
  .board-drawer .board-create { justify-content: center; gap: 6px; background: #1f1f1f; }
  .account-drawer { font-size: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  :is(.import-dialog, .board-dialog, .delete-dialog),
  :is(.import-dialog, .board-dialog, .delete-dialog)[open],
  :is(.import-dialog, .board-dialog, .delete-dialog).closing {
    transform: none;
  }
}

/* App board flows share the existing modal, field and drawer primitives. */
.workspace-nav > a img { width: 112.877px; height: 34px; }
#item-count span { color: #fefefe; }
#edit-board { display: inline-flex; align-items: center; gap: 6px; padding: 0; border: 0; background: transparent; color: #b1b0ae; font: 400 14px Geist, sans-serif; white-space: nowrap; transition: color 150ms ease; }
#edit-board[hidden] { display: none; }
#edit-board:hover { color: #fefefe; }
#edit-board:hover img { filter: brightness(1.5); }
.filter.active .filter-count { color: #fefefe; }
.import-dialog { overflow: visible; }
#import-board-picker summary { height: 36px; padding: 4px 10px; border: 1px solid transparent; color: #fefefe; font: 400 15px Geist, sans-serif; letter-spacing: -.225px; }
#import-board-picker[open] summary { border-color: #fefefe; }
#import-board-picker .board-picker-panel { position: absolute; top: 100%; right: 0; z-index: 2; }
#import-board-picker summary span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#import-board-error, #edit-board-error { color: #ff7300; margin-top: 6px; font-size: 14px; }
#edit-board-form { padding: 20px; display: grid; gap: 20px; }
.edit-board-actions { display: flex; gap: 12px; }
.edit-board-actions .button { flex: 1; height: 34px; border: 0; border-radius: 12px; }
.edit-board-actions .secondary { background: #1f1f1f; color: #fefefe; }
.edit-board-actions .primary { background: #fefefe; color: #0e0e0e; font-weight: 500; }
.edit-board-actions .primary:disabled { background: #b8b8b8; color: #555; opacity: 1; }
.edit-board-actions .primary:hover:not(:disabled) { background: #eaeaea; }
.board-danger { padding: 20px; border-top: 1px solid #282828; display: grid; gap: 8px; font-size: 15px; letter-spacing: -.15px; }
#delete-board { width: 100%; height: 34px; border: 0; border-radius: 12px; background: #ff383c24; color: #ff383c; font-weight: 500; }
.board-danger p:last-child { color: #6e6e6e; }
.source-post { color: #fefefe; gap: 6px; padding: 4px 16px; text-decoration: none; }
.source-post img { flex: none; }
.account-menu .account-footer { border-top: 0; }
#account-menu #logout { flex-direction: row-reverse; justify-content: flex-end; }
.account-drawer .account-footer { border-top: 0; }
.account-menu { border-radius: 18px; }
#toast { display: none; align-items: center; gap: 10px; background: #131313; border: 1px solid #1e1e1e; padding: 11px 12px; font-size: 14px; width: 361px; box-shadow: 0 0 8px #0004; }
#toast:popover-open { display: flex; }
#toast img { flex: none; }
@media (max-width: 700px) {
  .edit-board-actions .button, #delete-board { height: 40px; }
  .gallery-content { padding-block: 4px 18.5px; }
  .gallery-meta { gap: 12px; min-height: 0; margin-bottom: 16px; letter-spacing: -.225px; }
  #item-count { font-size: 15px; }
  .gallery-content:has(#empty-state:not([hidden])) .gallery-meta { margin-bottom: 0; }
  .empty-state { padding-block: 200px 0; }
  .gallery-content:has(#item-count:empty) { padding-top: 200px; }
  .gallery-meta:has(#item-count:empty) { display: none; }
  .gallery-meta:has(#item-count:empty) ~ .empty-state { padding-top: 0; }
  .detail-image-slot { border-radius: 6px; }
  .board-drawer .board-picker-panel { background: transparent; }
}

.board-create img { flex: none; }
@media (max-width: 700px) {
  #edit-board-dialog .import-header { padding: 20px 16px; }
}
