#guides-support-root {
  display: none !important;
  font-family: inherit;
}

html.guides-support-open #guides-support-root {
  display: block !important;
}

.guides-support-backdrop {
  position: fixed;
  inset: 0;
  z-index: 50000;
  background: rgba(15, 23, 42, 0.45);
}

.guides-support-panel {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: auto;
  z-index: 50001;
  width: min(420px, 100%);
  max-width: 420px;
  overflow: auto;
  background: #fff;
  color: #111827;
  border-radius: 16px 0 0 16px;
  box-shadow: -16px 0 40px rgba(15, 23, 42, 0.28);
  padding: 20px 20px 28px;
  box-sizing: border-box;
}

.guides-support-header {
  display: block;
  padding-right: 40px;
}

.guides-support-header h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
}

.guides-support-lede {
  margin: 6px 0 0;
  font-size: 13px;
  color: #6b7280;
}

.guides-support-close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #6b7280;
  font-size: 24px;
  line-height: 36px;
  text-align: center;
  cursor: pointer;
}

.guides-support-tabs {
  display: flex;
  gap: 8px;
  margin: 16px 0 12px;
}

.guides-support-tabs button {
  flex: 1;
  height: 36px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #f9fafb;
  color: #374151;
  font-weight: 600;
  cursor: pointer;
}

.guides-support-tabs button.is-active {
  background: #111827;
  border-color: #111827;
  color: #fff;
}

.guides-support-body label {
  display: block;
  margin: 10px 0 4px;
  font-size: 13px;
  font-weight: 600;
  color: #111827;
}

.guides-support-body input,
.guides-support-body select,
.guides-support-body textarea {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  padding: 8px 10px;
  font: inherit;
  color: #111827;
  background: #fff;
}

.guides-support-body select {
  height: 36px;
  min-height: 36px;
  max-height: 36px;
  padding: 0 8px;
  line-height: 34px;
  font-size: 14px;
  -webkit-appearance: menulist;
  appearance: menulist;
}

.guides-support-row {
  display: grid;
  gap: 12px;
}

@media (min-width: 640px) {
  .guides-support-row {
    grid-template-columns: 1fr 1fr;
  }
}

.guides-support-submit {
  width: 100%;
  margin-top: 16px;
  height: 40px;
  border: 0;
  border-radius: 8px;
  background: #ea580c;
  color: #fff;
  font-weight: 700;
  cursor: pointer;
}

.guides-support-submit:disabled {
  opacity: 0.7;
  cursor: wait;
}

.guides-support-status {
  margin: 12px 0 0;
  font-size: 13px;
}

.guides-support-status.is-error { color: #dc2626; }
.guides-support-status.is-success { color: #15803d; }

.guides-support-muted {
  color: #6b7280;
  font-size: 13px;
}

.guides-support-ticket {
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  padding: 12px;
  margin-bottom: 10px;
}

.guides-support-ticket-top {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: flex-start;
}

.guides-support-ticket-subject {
  margin: 0;
  font-size: 14px;
  font-weight: 650;
}

.guides-support-meta {
  margin: 6px 0 0;
  font-size: 12px;
  color: #6b7280;
}

.guides-support-url {
  overflow-wrap: anywhere;
  word-break: break-all;
}

.guides-support-notes {
  margin-top: 8px;
  padding: 8px 10px;
  border-radius: 8px;
  background: #f3f4f6;
}

.guides-support-notes-label {
  margin: 0;
  font-size: 11px;
  font-weight: 700;
  color: #374151;
}

.guides-support-notes-body {
  margin: 4px 0 0;
  font-size: 12px;
  white-space: pre-wrap;
  color: #111827;
}

.guides-support-badge {
  flex-shrink: 0;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 999px;
}

.guides-support-badge.is-open { background: #dbeafe; color: #1d4ed8; }
.guides-support-badge.is-progress { background: #fef3c7; color: #b45309; }
.guides-support-badge.is-closed { background: #dcfce7; color: #15803d; }

.guides-product-topbar-help,
.marketing-navbar__help {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 8px;
  background: #fff;
  color: #475569;
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.08);
}

.guides-product-topbar-help:hover,
.marketing-navbar__help:hover {
  color: #0f172a;
  text-decoration: none;
}

.guides-product-topbar--dark .guides-product-topbar-help {
  border-color: rgba(15, 23, 42, 0.08);
  background: #fff;
  color: #2C333A;
}

html.has-guide-product-topbar:not([data-reader-theme="light"]) .guides-support-panel,
html[data-reader-theme="dark"] .guides-support-panel {
  background: #111;
  color: #f3f4f6;
}

html.has-guide-product-topbar:not([data-reader-theme="light"]) .guides-support-lede,
html.has-guide-product-topbar:not([data-reader-theme="light"]) .guides-support-muted,
html.has-guide-product-topbar:not([data-reader-theme="light"]) .guides-support-meta,
html[data-reader-theme="dark"] .guides-support-lede,
html[data-reader-theme="dark"] .guides-support-muted,
html[data-reader-theme="dark"] .guides-support-meta {
  color: #9ca3af;
}

html.has-guide-product-topbar:not([data-reader-theme="light"]) .guides-support-body label,
html[data-reader-theme="dark"] .guides-support-body label {
  color: #f3f4f6;
}

html.has-guide-product-topbar:not([data-reader-theme="light"]) .guides-support-body input,
html.has-guide-product-topbar:not([data-reader-theme="light"]) .guides-support-body select,
html.has-guide-product-topbar:not([data-reader-theme="light"]) .guides-support-body textarea,
html[data-reader-theme="dark"] .guides-support-body input,
html[data-reader-theme="dark"] .guides-support-body select,
html[data-reader-theme="dark"] .guides-support-body textarea {
  background: #1f1f1f;
  color: #f3f4f6;
  border-color: rgba(255, 255, 255, 0.14);
}

html.has-guide-product-topbar:not([data-reader-theme="light"]) .guides-support-tabs button,
html[data-reader-theme="dark"] .guides-support-tabs button {
  background: #1f1f1f;
  border-color: rgba(255, 255, 255, 0.12);
  color: #e5e7eb;
}

html.has-guide-product-topbar:not([data-reader-theme="light"]) .guides-support-tabs button.is-active,
html[data-reader-theme="dark"] .guides-support-tabs button.is-active {
  background: #fff;
  border-color: #fff;
  color: #111827;
}

html.has-guide-product-topbar:not([data-reader-theme="light"]) .guides-support-ticket,
html[data-reader-theme="dark"] .guides-support-ticket {
  border-color: rgba(255, 255, 255, 0.12);
}

html.has-guide-product-topbar:not([data-reader-theme="light"]) .guides-support-notes,
html[data-reader-theme="dark"] .guides-support-notes {
  background: #1f1f1f;
}

html.has-guide-product-topbar:not([data-reader-theme="light"]) .guides-support-notes-label,
html.has-guide-product-topbar:not([data-reader-theme="light"]) .guides-support-notes-body,
html[data-reader-theme="dark"] .guides-support-notes-label,
html[data-reader-theme="dark"] .guides-support-notes-body {
  color: #e5e7eb;
}

html.guides-support-open {
  overflow: hidden;
}
