/**
 * Shared form field styling — planner, modals, dashboard.
 */

/* ── Form sections ── */
section.block {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  margin-bottom: 1.25rem;
  box-shadow: var(--shadow);
}

section.block h3 {
  margin: 0 0 1.125rem;
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--accent-text);
  letter-spacing: -0.01em;
}

.step-header h2 {
  font-family: var(--font-display);
  letter-spacing: -0.02em;
}

/* ── Field layout ── */
.field {
  margin-bottom: 1rem;
}

.field:last-child {
  margin-bottom: 0;
}

/*
 * Floating labels — label sits in the control when empty, rises on focus/value.
 * Structure:
 *   .field.field-float > .field-float-shell > input + label [+ .field-info-btn]
 *   optional .field-hint after the shell
 * Rich text / reference fields keep top labels.
 */
.field-float-shell {
  position: relative;
  display: block;
}

.field-float-shell > input[type="text"],
.field-float-shell > input[type="search"],
.field-float-shell > input[type="email"],
.field-float-shell > input[type="url"],
.field-float-shell > input[type="password"],
.field-float-shell > input[type="tel"],
.field-float-shell > input[type="number"],
.field-float-shell > select,
.field-float-shell > textarea {
  min-height: var(--control-height-float);
  padding: 1.15rem var(--input-float-pad-x) 0.45rem;
  border-color: color-mix(in srgb, var(--border) 88%, transparent);
  background: color-mix(in srgb, var(--surface) 92%, var(--bg));
}

.field-float-shell > textarea {
  min-height: 7.5rem;
  padding-top: 1.45rem;
  resize: vertical;
}

.field-float-shell > select {
  padding-right: 2.25rem;
}

.field-float-shell > label {
  position: absolute;
  left: var(--input-float-pad-x);
  right: 2.5rem;
  top: 50%;
  transform: translateY(-50%);
  margin: 0;
  padding: 0;
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: 0;
  color: var(--placeholder);
  line-height: 1.2;
  pointer-events: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transform-origin: left center;
  transition:
    top 0.18s ease,
    transform 0.18s ease,
    font-size 0.18s ease,
    color 0.18s ease,
    font-weight 0.18s ease;
}

.field-float-shell > textarea + label {
  top: 1.15rem;
  transform: none;
}

.field-float-shell > .field-info-btn {
  position: absolute;
  right: 0.55rem;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  opacity: 0.85;
}

.field-float-shell > textarea ~ .field-info-btn {
  top: 0.85rem;
  transform: none;
}

.field-float-shell > input::placeholder,
.field-float-shell > textarea::placeholder {
  color: transparent;
  opacity: 1;
  transition: color 0.15s ease;
}

.field-float-shell:focus-within > input::placeholder,
.field-float-shell:focus-within > textarea::placeholder {
  color: var(--placeholder);
}

.field-float-shell:has(> input:focus) > label,
.field-float-shell:has(> input:not(:placeholder-shown)) > label,
.field-float-shell:has(> input:-webkit-autofill) > label,
.field-float-shell:has(> select) > label,
.field-float-shell:has(> textarea:focus) > label,
.field-float-shell:has(> textarea:not(:placeholder-shown)) > label,
.field-float-shell.is-floated > label {
  top: 0.45rem;
  transform: none;
  font-size: var(--input-float-label);
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent-text);
}

.field-float-shell:focus-within > label {
  color: var(--accent);
}

.field-float > .field-hint {
  margin: 0.4rem 0 0;
  font-size: 0.75rem;
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem 1.25rem;
}

@media (max-width: 700px) {
  .grid-2 {
    grid-template-columns: 1fr;
  }
}

.field-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1rem;
}

.field-row .field,
.grid-2 .field {
  margin-bottom: 0;
}

label {
  display: block;
  font-family: var(--font-ui);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text);
  margin-bottom: 0.25rem;
}

.label-row {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin-bottom: 0.15rem;
  flex-wrap: wrap;
}

.label-row label {
  margin-bottom: 0;
}

.field-hint {
  display: block;
  font-size: 0.8125rem;
  font-weight: 400;
  color: var(--muted);
  margin: 0 0 0.5rem;
  line-height: 1.45;
}

.field + .field-hint,
.label-row + .field-hint {
  margin-top: -0.1rem;
}

/* Reference / readonly fields */
.field-reference .label-row {
  align-items: center;
}

.field-reference-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.12rem 0.45rem;
  border-radius: 999px;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent-text);
  background: var(--accent-soft);
  border: 1px solid var(--tip-border);
}

.input-reference,
input.input-reference[readonly] {
  border: none;
  border-bottom: 1px dashed var(--border);
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  padding-left: 0;
  padding-right: 0;
  color: var(--text);
  font-weight: 500;
  min-height: auto;
}

.input-reference:focus-visible {
  border-bottom-color: var(--accent);
  box-shadow: none;
  outline: none;
}

/* ── Text controls ── */
input[type="text"],
input[type="search"],
input[type="email"],
input[type="url"],
textarea,
select {
  width: 100%;
  font-family: var(--font-ui);
  font-size: 1rem;
  line-height: 1.5;
  color: var(--text);
  background: var(--surface);
  border: var(--input-border);
  border-radius: var(--input-radius);
  box-shadow: var(--input-shadow);
  transition:
    border-color 0.18s ease,
    box-shadow 0.18s ease,
    background-color 0.18s ease;
}

input[type="text"],
input[type="search"],
input[type="email"],
input[type="url"],
select {
  min-height: var(--control-height);
  padding: 0.625rem 1rem;
}

textarea {
  min-height: 140px;
  padding: 0.75rem 1rem;
  resize: vertical;
}

textarea.script {
  min-height: 360px;
  font-family: ui-monospace, Consolas, "Courier New", monospace;
  font-size: 0.9375rem;
  line-height: 1.55;
}

select {
  cursor: pointer;
  padding-right: 2rem;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%234f5863' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.75rem center;
}

input[type="text"]:focus-visible,
input[type="search"]:focus-visible,
input[type="email"]:focus-visible,
input[type="url"]:focus-visible,
textarea:focus-visible,
select:focus-visible {
  border-color: var(--accent);
  box-shadow: var(--input-focus-shadow);
  outline: none;
}

input[readonly]:not(.input-reference) {
  background: var(--bg);
  color: var(--muted);
  cursor: default;
  box-shadow: none;
}

textarea.field-grow {
  min-height: 5rem;
  overflow: hidden;
  resize: none;
  field-sizing: content;
}

@supports not (field-sizing: content) {
  textarea.field-grow {
    resize: vertical;
    min-height: 5rem;
  }
}

/* ── Rich text ── */
.richtext-wrap {
  border: var(--input-border);
  border-radius: var(--input-radius);
  background: var(--surface);
  overflow: hidden;
  box-shadow: var(--input-shadow);
  transition:
    border-color 0.18s ease,
    box-shadow 0.18s ease;
}

.richtext-wrap:focus-within {
  border-color: var(--accent);
  box-shadow: var(--input-focus-shadow);
}

.richtext-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.15rem;
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  padding: 0 0.5rem;
  background: var(--bg);
  border-bottom: 0 solid var(--border);
  transition:
    max-height 0.22s ease,
    opacity 0.18s ease,
    padding 0.18s ease,
    border-bottom-width 0.18s ease;
}

.richtext-wrap:hover .richtext-toolbar,
.richtext-wrap:focus-within .richtext-toolbar {
  max-height: 3.5rem;
  opacity: 1;
  padding: 0.35rem 0.5rem;
  border-bottom-width: 1px;
}

.richtext-btn {
  min-height: 2rem;
  min-width: 2rem;
  padding: 0.2rem 0.45rem;
  font-size: 0.8125rem;
  font-weight: 600;
  border-radius: 6px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text);
  line-height: 1.2;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.richtext-btn:hover {
  background: var(--surface);
  border-color: var(--border);
}

.richtext-btn:focus-visible {
  outline: none;
  border-color: var(--accent);
  box-shadow: var(--input-focus-shadow);
}

.richtext-sep {
  width: 1px;
  height: 1.25rem;
  background: var(--border);
  margin: 0 0.15rem;
}

.richtext-editor {
  min-height: 140px;
  max-height: 480px;
  overflow-y: auto;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  line-height: 1.55;
  outline: none;
}

.richtext-editor.field-grow {
  min-height: 5rem;
}

.richtext-editor.is-empty:not(:focus)::before {
  content: attr(data-placeholder);
  color: var(--placeholder);
  pointer-events: none;
  display: block;
}

.richtext-editor ul,
.richtext-editor ol {
  margin: 0.35rem 0;
  padding-left: 1.5rem;
}

.richtext-editor p {
  margin: 0 0 0.5rem;
}

.richtext-editor p:last-child {
  margin-bottom: 0;
}

.richtext-editor h2 {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  margin: 0.75rem 0 0.35rem;
  color: var(--accent-text);
  line-height: 1.35;
}

.richtext-editor h3 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  margin: 0.6rem 0 0.3rem;
  color: var(--accent-text);
  line-height: 1.35;
}

.richtext-editor a {
  color: var(--accent);
  text-decoration: underline;
  word-break: break-word;
}

.richtext-editor img.richtext-img,
.richtext-editor img {
  max-width: 100%;
  height: auto;
  border-radius: 6px;
  margin: 0.5rem 0;
  display: block;
  border: 1px solid var(--border);
}

.virtual-list-host .virtual-list-viewport {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.virtual-spacer {
  flex-shrink: 0;
  width: 100%;
  pointer-events: none;
}

/* ── Record cards ── */
.record-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.record-list-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0 0 0.85rem;
}

.record-list-actions .primary {
  font-size: 0.875rem;
  font-weight: 700;
}

.record-empty {
  text-align: center;
  padding: 2rem 1.25rem;
  color: var(--muted);
  font-size: 1rem;
  background: var(--bg);
  border: 1px dashed var(--border);
  border-radius: var(--radius);
}

.record-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--input-shadow);
  border-left: 4px solid var(--accent);
}

.record-card-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.75rem;
  padding: 0.875rem 1.25rem;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}

.record-card-header .record-remove {
  margin-left: auto;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.25rem 0.55rem;
  min-height: auto;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--bg);
  color: var(--muted);
  cursor: pointer;
}

.record-card-header .record-remove:hover,
.record-card-header .record-remove:focus-visible {
  border-color: var(--danger, #b91c1c);
  color: var(--danger, #b91c1c);
  background: var(--danger-bg, #fef2f2);
}

.record-card-header .record-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--accent-text);
  flex: 1;
  min-width: 0;
  word-wrap: break-word;
}

.record-card-header .record-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
}

.record-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent-text);
  background: var(--accent-soft);
  border: 1px solid var(--tip-border);
  white-space: nowrap;
}

.record-fields > .field:not(.field-float) label,
.record-fields .label-row label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
}

.record-fields {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
}

/* ── Storyboard beat cards ── */
details.beat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--input-shadow);
  border-left: 3px solid transparent;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

details.beat-card[open] {
  border-color: var(--tip-border);
  border-left-color: var(--accent);
  box-shadow: var(--shadow);
}

details.beat-card summary {
  list-style: none;
  cursor: pointer;
  padding: 1rem 1.25rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.75rem;
  background: var(--surface);
  user-select: none;
  transition: background 0.15s ease;
}

details.beat-card summary::-webkit-details-marker {
  display: none;
}

details.beat-card summary::before {
  content: "▸";
  color: var(--accent);
  font-size: 0.9rem;
  transition: transform 0.18s ease;
  flex-shrink: 0;
}

details.beat-card[open] summary::before {
  transform: rotate(90deg);
}

details.beat-card summary:hover {
  background: var(--accent-soft);
}

details.beat-card summary:focus-visible {
  outline: none;
  box-shadow: inset var(--input-focus-shadow);
}

details.beat-card summary .beat-remove {
  margin-left: auto;
  flex-shrink: 0;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.25rem 0.55rem;
  min-height: auto;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--bg);
  color: var(--muted);
  cursor: pointer;
}

details.beat-card summary .beat-remove:hover,
details.beat-card summary .beat-remove:focus-visible {
  border-color: var(--danger, #b91c1c);
  color: var(--danger, #b91c1c);
  background: var(--danger-bg, #fef2f2);
}

.beat-badge {
  font-weight: 700;
  font-size: 0.8125rem;
  color: var(--accent-text);
  background: var(--accent-soft);
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  border: 1px solid var(--tip-border);
}

.beat-meta {
  font-size: 0.8125rem;
  color: var(--muted);
}

.beat-preview {
  flex: 1 1 100%;
  font-size: 0.95rem;
  color: var(--text);
  line-height: 1.5;
  margin-top: 0.25rem;
}

@media (min-width: 600px) {
  .beat-preview {
    flex: 1 1 auto;
    margin-top: 0;
  }
}

.beat-expand-hint {
  font-size: 0.8125rem;
  color: var(--muted);
  margin-bottom: 0.75rem;
}

/* ── Field help ── */
.field-info-btn {
  flex-shrink: 0;
  width: 1.125rem;
  height: 1.125rem;
  min-width: 1.125rem;
  min-height: 1.125rem;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  padding: 0;
  line-height: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  opacity: 0.72;
  transition: color 0.15s ease, background 0.15s ease, opacity 0.15s ease;
}

.field-info-btn .field-info-icon {
  width: 1.125rem;
  height: 1.125rem;
  display: block;
}

.field-info-btn:hover {
  color: var(--accent);
  background: var(--accent-soft);
  opacity: 1;
}

.field-info-btn:focus-visible {
  outline: none;
  color: var(--accent);
  opacity: 1;
  box-shadow: var(--input-focus-shadow);
}

.field-help-overlay {
  position: fixed;
  inset: 0;
  background: rgba(26, 26, 26, 0.5);
  z-index: 110;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.field-help-overlay.hidden {
  display: none;
}

.field-help-card {
  background: var(--surface);
  border-radius: var(--radius);
  max-width: 520px;
  width: 100%;
  padding: 1.75rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.18);
  position: relative;
}

.field-help-card h2 {
  font-family: var(--font-display);
  margin: 0 2rem 0.75rem 0;
  font-size: 1.25rem;
  color: var(--accent-text);
}

.field-help-close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  width: 2.25rem;
  height: 2.25rem;
  border: none;
  background: var(--bg);
  border-radius: 8px;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  color: var(--muted);
}

.field-help-close:hover {
  background: var(--border);
  color: var(--text);
}

.field-help-about {
  margin: 0 0 1.25rem;
  font-size: 1rem;
  color: var(--text);
  line-height: 1.6;
}

.field-help-example {
  background: var(--tip-bg);
  border: 1px solid var(--tip-border);
  border-radius: var(--input-radius);
  padding: 1rem 1.125rem;
}

.field-help-example strong {
  display: block;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--accent-text);
  margin-bottom: 0.5rem;
}

.field-help-example-text {
  margin: 0;
  font-size: 0.95rem;
  color: var(--muted);
  line-height: 1.55;
  white-space: pre-wrap;
}

/* ── Modal forms (workspace, feedback, etc.) ── */
.cb-modal-field {
  display: block;
  margin-bottom: 0.85rem;
}

.cb-modal-field.cb-modal-field-float {
  position: relative;
}

.cb-modal-field > span:first-child {
  font-size: 0.8125rem;
  letter-spacing: 0.02em;
}

.cb-modal-field-float > span:first-child {
  position: absolute;
  left: var(--input-float-pad-x);
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  margin: 0;
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: 0;
  color: var(--placeholder);
  pointer-events: none;
  z-index: 1;
  transition:
    top 0.18s ease,
    transform 0.18s ease,
    font-size 0.18s ease,
    color 0.18s ease,
    font-weight 0.18s ease;
}

.cb-modal-field-float:has(textarea) > span:first-child {
  top: 1.15rem;
  transform: none;
}

.cb-modal-field-float:has(input:focus) > span:first-child,
.cb-modal-field-float:has(input:not(:placeholder-shown)) > span:first-child,
.cb-modal-field-float:has(select) > span:first-child,
.cb-modal-field-float:has(textarea:focus) > span:first-child,
.cb-modal-field-float:has(textarea:not(:placeholder-shown)) > span:first-child {
  top: 0.45rem;
  transform: none;
  font-size: var(--input-float-label);
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent-text);
}

.cb-modal-field-float:focus-within > span:first-child {
  color: var(--accent);
}

.cb-modal-field-float .app-feedback-optional {
  text-transform: none;
  letter-spacing: 0;
  font-weight: 500;
}

.cb-modal-field-float .app-feedback-count,
.cb-modal-field-float .app-feedback-field-hint {
  position: static;
  transform: none;
  pointer-events: auto;
  color: var(--muted);
  text-transform: none;
  letter-spacing: 0;
  font-weight: 500;
}

.cb-modal-field input,
.cb-modal-field select,
.cb-modal-field textarea {
  width: 100%;
  min-height: var(--control-height);
  padding: 0.625rem 1rem;
  border: var(--input-border);
  border-radius: var(--input-radius);
  box-shadow: var(--input-shadow);
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.cb-modal-field-float input,
.cb-modal-field-float select {
  min-height: var(--control-height-float);
  padding: 1.15rem var(--input-float-pad-x) 0.45rem;
  background: color-mix(in srgb, var(--surface) 92%, var(--bg));
}

.cb-modal-field-float textarea {
  min-height: 7.5rem;
  padding: 1.45rem var(--input-float-pad-x) 0.75rem;
  background: color-mix(in srgb, var(--surface) 92%, var(--bg));
}

.cb-modal-field-float input::placeholder,
.cb-modal-field-float textarea::placeholder {
  color: transparent;
}

.cb-modal-field-float:focus-within input::placeholder,
.cb-modal-field-float:focus-within textarea::placeholder {
  color: var(--placeholder);
}

.cb-modal-field input:focus-visible,
.cb-modal-field select:focus-visible,
.cb-modal-field textarea:focus-visible {
  border-color: var(--accent);
  box-shadow: var(--input-focus-shadow);
  outline: none;
}

.cb-modal h2 {
  font-family: var(--font-display);
}

/* ── High contrast ── */
html[data-contrast="high"] input[type="text"],
html[data-contrast="high"] textarea,
html[data-contrast="high"] select,
html[data-contrast="high"] .richtext-wrap {
  border-width: 2px;
  box-shadow: none;
}

html[data-contrast="high"] .field-float-shell > input[type="text"],
html[data-contrast="high"] .field-float-shell > textarea,
html[data-contrast="high"] .field-float-shell > select,
html[data-contrast="high"] .cb-modal-field-float input,
html[data-contrast="high"] .cb-modal-field-float textarea {
  border-width: 2px;
  background: var(--surface);
}

html[data-contrast="high"] .field-float-shell > label,
html[data-contrast="high"] .cb-modal-field-float > span:first-child,
html[data-contrast="high"] .auth-field span {
  color: var(--text);
}

html[data-contrast="high"] input[type="text"]:focus-visible,
html[data-contrast="high"] textarea:focus-visible,
html[data-contrast="high"] select:focus-visible,
html[data-contrast="high"] .richtext-wrap:focus-within {
  box-shadow: 0 0 0 3px var(--focus-ring);
}

html[data-contrast="high"] .richtext-toolbar {
  max-height: none;
  opacity: 1;
  padding: 0.35rem 0.5rem;
  border-bottom-width: 1px;
}

/* ── Team workspace switcher (planner, dashboard, lean launch) ── */
.org-switcher-mount,
.launch-org-switcher {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.org-switcher-label,
.launch-workspace-label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--muted);
  white-space: nowrap;
}

.org-switcher-hint {
  font-size: 0.6875rem;
  color: var(--muted);
  line-height: 1.3;
  max-width: 11rem;
}

.org-switcher-select,
.org-switcher-btn,
.launch-workspace-select,
.launch-workspace-create {
  font-family: var(--font-ui);
  font-size: 0.8125rem;
  font-weight: 600;
  min-height: var(--control-height);
  padding: 0.45rem 0.85rem;
  border-radius: var(--input-radius);
  border: var(--input-border);
  background: var(--surface);
  box-shadow: var(--input-shadow);
  color: var(--text);
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.org-switcher-btn,
.launch-workspace-create {
  cursor: pointer;
}

.org-switcher-btn:hover {
  border-color: var(--accent);
  color: var(--accent-text);
}

.launch-workspace-create {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.launch-workspace-create:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  color: #fff;
}

.org-switcher-select:focus-visible,
.launch-workspace-select:focus-visible,
.org-switcher-btn:focus-visible,
.launch-workspace-create:focus-visible {
  border-color: var(--accent);
  box-shadow: var(--input-focus-shadow);
  outline: none;
}

.launch-workspace-select,
.org-switcher-select {
  min-width: 10rem;
  max-width: 100%;
  cursor: pointer;
}

@media (prefers-reduced-motion: reduce) {
  input[type="text"],
  input[type="search"],
  textarea,
  select,
  .richtext-wrap,
  .richtext-toolbar,
  details.beat-card,
  details.beat-card summary::before,
  .field-float-shell > label,
  .cb-modal-field-float > span:first-child {
    transition: none;
  }
}

@supports not (background: color-mix(in srgb, white 50%, black)) {
  .field-float-shell > input[type="text"],
  .field-float-shell > input[type="search"],
  .field-float-shell > input[type="email"],
  .field-float-shell > input[type="url"],
  .field-float-shell > input[type="password"],
  .field-float-shell > select,
  .field-float-shell > textarea,
  .cb-modal-field-float input,
  .cb-modal-field-float select,
  .cb-modal-field-float textarea {
    background: var(--bg);
  }
}
