/*
 * ============================================================
 * Browns Digital — Proprietary Software
 * ============================================================
 * Copyright (c) 2026 Robert Brown / Browns Digital. All rights reserved.
 *
 * CONFIDENTIAL — NOT FOR DISTRIBUTION
 *
 * Unauthorised reproduction, distribution, modification, or
 * reverse engineering of this material is strictly prohibited.
 * No licence is granted except by express written agreement.
 *
 * THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND.
 * Governing Law: Republic of South Africa | contact@brownsdigital.org
 * ============================================================
 */
/*
 * Browns Digital — Tools
 */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.tools-body .tools-root {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  box-sizing: border-box;
}

.tools-body .tools-root[aria-busy="true"] {
  min-height: 40vh;
  opacity: 0.55;
}

.tools-wizard--hub {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: stretch;
}

.tools-shell--toolbar {
  padding-bottom: 0;
  padding-top: calc(100px + env(safe-area-inset-top, 0px));
  position: sticky;
  top: calc(68px + env(safe-area-inset-top, 0px));
  z-index: 50;
  margin-bottom: 4px;
  background: linear-gradient(180deg, rgba(248, 250, 255, 0.98) 70%, rgba(248, 250, 255, 0) 100%);
}

/* ── Tools toolbar ── */
.tools-toolbar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 12px;
  margin-bottom: 8px;
}

.tools-toolbar__back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px 8px 10px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  color: #1d1d1f;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.05);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.tools-toolbar__back:hover {
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.08);
  transform: translateY(-1px);
}

.tools-toolbar__back svg {
  opacity: 0.65;
}

.tools-toolbar__sep {
  color: #c7c7cc;
  font-size: 14px;
}

.tools-toolbar__current {
  font-size: 14px;
  font-weight: 500;
  color: #6e6e73;
}

/* ── Hub (toolkit landing) ── */
.tools-page-head--hub {
  text-align: center;
  max-width: 640px;
}

.tools-page-head--hub .tools-lead {
  margin-left: auto;
  margin-right: auto;
}

.tools-shell--hub {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding-top: 8px;
}

.tools-wizard--hub .tools-picker {
  width: 100%;
  max-width: none;
}

/* ── Custom platform select (matches form inputs) ── */
.tools-platform-field {
  margin: 0;
  min-width: min(100%, 300px);
}

.tools-platform-field__label {
  display: block;
  margin-bottom: 8px;
}

.tools-custom-select {
  position: relative;
}

.tools-custom-select__trigger {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  font-family: inherit;
  text-align: left;
  cursor: pointer;
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.92);
  color: #1d1d1f;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.tools-custom-select__trigger:hover,
.tools-custom-select.is-open .tools-custom-select__trigger {
  border-color: rgba(53, 92, 255, 0.45);
  box-shadow: 0 0 0 4px rgba(53, 92, 255, 0.1);
}

.tools-custom-select__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
}

.tools-custom-select__icon img,
.tools-platform-icon img {
  width: 22px;
  height: 22px;
  object-fit: contain;
  display: block;
}

.tools-platform-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
}

.tools-platform-icon--sm {
  width: 24px;
  height: 24px;
}

.tools-platform-icon--sm img {
  width: 16px;
  height: 16px;
}

.tools-platform-icon--md {
  width: 36px;
  height: 36px;
}

.tools-platform-icon--lg {
  width: 44px;
  height: 44px;
}

.tools-platform-icon--lg img {
  width: 26px;
  height: 26px;
}

.tools-custom-select__text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.tools-custom-select__name {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.tools-custom-select__sub {
  font-size: 12px;
  color: #6e6e73;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tools-custom-select__chev {
  flex-shrink: 0;
  color: #6e6e73;
  transition: transform 0.2s ease;
}

.tools-custom-select.is-open .tools-custom-select__chev {
  transform: rotate(180deg);
}

.tools-custom-select__menu {
  position: absolute;
  z-index: 50;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  margin: 0;
  padding: 6px;
  list-style: none;
  max-height: 320px;
  overflow-y: auto;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.98);
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 16px 48px rgba(15, 23, 42, 0.14);
}

.tools-custom-select__option {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border: none;
  border-radius: 10px;
  background: transparent;
  font-family: inherit;
  text-align: left;
  cursor: pointer;
  color: inherit;
  transition: background 0.15s ease;
}

.tools-custom-select__option:hover,
.tools-custom-select__option.is-selected {
  background: rgba(53, 92, 255, 0.08);
}

/* ── Input mode tabs ── */
.tools-meta-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 20px;
}

.tools-meta-head .tools-glass__heading {
  margin: 0;
}

.tools-mode-tabs {
  display: inline-flex;
  padding: 4px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.05);
  border: 1px solid rgba(0, 0, 0, 0.06);
}

.tools-mode-tabs__btn {
  padding: 8px 16px;
  border: none;
  border-radius: 999px;
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  color: #6e6e73;
  background: transparent;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.tools-mode-tabs__btn.is-active {
  color: #1d1d1f;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.tools-mode-panel[hidden] {
  display: none !important;
}

.tools-markup-editor {
  width: 100%;
  min-height: 220px;
  padding: 16px 18px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 12px;
  line-height: 1.55;
  color: #e5e7eb;
  background: #111827;
  border: 1px solid rgba(0, 0, 0, 0.12);
  border-radius: 12px;
  resize: vertical;
  box-sizing: border-box;
}

.tools-markup-editor:focus {
  outline: none;
  border-color: rgba(53, 92, 255, 0.45);
  box-shadow: 0 0 0 4px rgba(53, 92, 255, 0.12);
}

.tools-markup-editor::selection,
.tools-markup::selection {
  background: rgba(96, 165, 250, 0.55);
  color: #fff;
}

.tools-markup-editor::-moz-selection,
.tools-markup::-moz-selection {
  background: rgba(96, 165, 250, 0.55);
  color: #fff;
}

.tools-mode-hint {
  margin: 10px 0 0;
  font-size: 12px;
  color: #6e6e73;
  line-height: 1.45;
}

.tools-wizard--code-mode .tools-code-panel--output {
  display: none;
}

.tools-field__label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: #1d1d1f;
  margin-bottom: 8px;
  letter-spacing: 0.01em;
}

/* ── Platform dropdown (legacy select removed) ── */
.tools-platform-select-card {
  max-width: 480px;
}

.tools-platform-picker {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.tools-platform-picker--compact {
  gap: 8px;
  min-width: min(100%, 280px);
}

.tools-platform-picker__label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #6e6e73;
}

.tools-select-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.tools-select-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.tools-select {
  flex: 1;
  min-width: 0;
  padding: 13px 40px 13px 15px;
  font-size: 15px;
  font-family: inherit;
  font-weight: 500;
  color: #1d1d1f;
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.92);
  appearance: none;
  cursor: pointer;
}

.tools-workspace-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px 28px;
}

.tools-workspace-head__title {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.tools-workspace-head__copy {
  min-width: 0;
}

.tools-workspace-head__title h1 {
  margin: 0 0 6px;
  line-height: 1.08;
}

.tools-workspace-head__title .tools-platform-icon--lg {
  margin-top: 0.2em;
}

/* ── Collapsible platform tips ── */
.tools-notes-wrap {
  margin-top: 16px;
  border-radius: 12px;
  border: 1px solid rgba(0, 0, 0, 0.06);
  background: rgba(255, 255, 255, 0.5);
  overflow: hidden;
}

.tools-notes-wrap summary {
  padding: 12px 16px;
  font-size: 13px;
  font-weight: 500;
  color: #6e6e73;
  cursor: pointer;
  list-style: none;
  user-select: none;
}

.tools-notes-wrap summary::-webkit-details-marker {
  display: none;
}

.tools-notes-wrap summary::after {
  content: "+";
  float: right;
  font-size: 15px;
  font-weight: 400;
  color: #86868b;
}

.tools-notes-wrap[open] summary::after {
  content: "−";
}

.tools-notes-wrap .tools-notes {
  margin: 0;
  padding: 0 16px 14px 2.2em;
  border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.tools-notes-wrap[open] summary {
  padding-bottom: 10px;
}

/* ── Page headers ── */
.tools-page-head {
  max-width: 720px;
  margin: 0 auto;
  padding: 88px 22px 36px;
  text-align: center;
}

.tools-page-head--compact {
  padding: 12px 22px 20px;
  text-align: left;
  max-width: 1200px;
}

.tools-eyebrow {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #355cff;
  margin: 0 0 12px;
}

.tools-page-head h1 {
  font-size: clamp(36px, 5vw, 48px);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.08;
  margin: 0 0 14px;
  color: #1d1d1f;
}

.tools-lead {
  font-size: 17px;
  line-height: 1.5;
  color: #6e6e73;
  margin: 0;
  max-width: 560px;
}

.tools-lead a {
  color: #2563eb;
  font-weight: 500;
  text-decoration: none;
}

.tools-lead a:hover {
  text-decoration: underline;
}

.tools-page-head--compact .tools-lead {
  font-size: 15px;
}

.tools-breadcrumb {
  font-size: 13px;
  color: #6e6e73;
  margin: 0 0 20px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.tools-breadcrumb a {
  color: #2563eb;
  text-decoration: none;
}

.tools-breadcrumb a:hover {
  text-decoration: underline;
}

.tools-workspace-title {
  display: flex;
  align-items: center;
  gap: 16px;
}

.tools-workspace-title__logo {
  flex-shrink: 0;
  border-radius: 10px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.tools-shell {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 22px 88px;
}

/* ── Glass panels ── */
.tools-glass {
  padding: 28px 28px 32px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.58);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.82);
  box-shadow:
    0 2px 8px rgba(15, 23, 42, 0.04),
    0 24px 56px rgba(15, 23, 42, 0.09),
    inset 0 1px 0 rgba(255, 255, 255, 0.95);
}

.tools-glass__heading {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #6e6e73;
  margin: 0 0 20px;
}

/* ── Tool picker ── */
.tools-picker {
  list-style: none;
  margin: 0 auto;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  width: 100%;
  max-width: 1100px;
}

@media (min-width: 768px) {
  .tools-picker {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.tools-picker > li {
  min-width: 0;
  display: flex;
}

.tools-picker-card {
  display: flex;
  flex-direction: column;
  flex: 1;
  width: 100%;
  padding: 28px 32px;
  border-radius: 24px;
  text-decoration: none;
  color: inherit;
  background: rgba(255, 255, 255, 0.58);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.82);
  box-shadow: 0 20px 48px rgba(15, 23, 42, 0.08);
  transition: box-shadow 0.25s ease;
}

.tools-picker-card:hover {
  box-shadow: 0 28px 64px rgba(15, 23, 42, 0.12);
}

.tools-picker-card__tier {
  align-self: flex-start;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 999px;
  margin-bottom: 4px;
}

.tools-picker-card__tier--free {
  background: rgba(52, 199, 89, 0.12);
  color: #248a3d;
}

.tools-picker-card__tier--pro {
  background: rgba(0, 113, 227, 0.12);
  color: #0071e3;
}

.tools-picker-card__title {
  display: block;
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
}

.tools-picker-card__desc {
  display: block;
  font-size: 15px;
  color: #6e6e73;
  line-height: 1.45;
  flex: 1;
}

.tools-picker-card::after {
  content: "Open →";
  display: block;
  margin-top: 18px;
  font-size: 15px;
  font-weight: 500;
  color: #86868b;
  transition: color 0.2s ease;
}

.tools-picker-card:hover::after {
  color: #1d1d1f;
}

/* ── Platform grid ── */
.tools-platform-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(168px, 1fr));
  gap: 14px;
}

.tools-platform-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  padding: 20px 18px;
  border-radius: 18px;
  text-decoration: none;
  color: inherit;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.05);
  transition:
    box-shadow 0.22s ease,
    border-color 0.22s ease;
}

.tools-platform-card:hover {
  border-color: rgba(53, 92, 255, 0.25);
  box-shadow: 0 12px 32px rgba(53, 92, 255, 0.12);
}

.tools-platform-card__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.tools-platform-card__icon img {
  display: block;
}

.tools-platform-card__name {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.tools-platform-card__tagline {
  font-size: 12px;
  color: #6e6e73;
  line-height: 1.35;
}

/* ── Editor layout ── */
.tools-editor {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  gap: 24px;
  align-items: start;
}

.tools-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.tools-field label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: #1d1d1f;
  margin-bottom: 8px;
  letter-spacing: 0.01em;
}

.tools-field__hint {
  font-weight: 500;
  color: #6e6e73;
}

.tools-input,
.tools-field select {
  width: 100%;
  padding: 13px 15px;
  font-size: 15px;
  font-family: inherit;
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.92);
  color: #1d1d1f;
  box-sizing: border-box;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.tools-input:focus,
.tools-field select:focus {
  outline: none;
  border-color: rgba(53, 92, 255, 0.45);
  box-shadow: 0 0 0 4px rgba(53, 92, 255, 0.12);
}

.tools-field textarea.tools-input {
  min-height: 88px;
  resize: vertical;
  line-height: 1.45;
}

.tools-field__count {
  display: block;
  font-size: 11px;
  color: #6e6e73;
  margin-top: 6px;
  text-align: right;
}

.tools-field__count.is-over {
  color: #dc2626;
  font-weight: 600;
}

.tools-image-drop {
  position: relative;
  width: 100%;
  aspect-ratio: 1.91 / 1;
  max-height: 200px;
  border-radius: 14px;
  border: 1px dashed rgba(0, 0, 0, 0.14);
  background: rgba(0, 0, 0, 0.03) center / cover no-repeat;
  margin-bottom: 10px;
  overflow: hidden;
}

.tools-image-drop.has-image .tools-image-drop__placeholder {
  opacity: 0;
}

.tools-image-drop__placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  font-size: 13px;
  color: #6e6e73;
  text-align: center;
  pointer-events: none;
}

.tools-advanced {
  margin-top: 4px;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
  padding-top: 16px;
}

.tools-advanced summary {
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  color: #6e6e73;
  list-style: none;
}

.tools-advanced summary::-webkit-details-marker {
  display: none;
}

.tools-advanced__inner {
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.tools-form-actions {
  margin-top: 8px;
  padding-top: 16px;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
}

.tools-text-btn {
  font-size: 14px;
  font-weight: 500;
  color: #2563eb;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  font-family: inherit;
  text-decoration: none;
}

.tools-text-btn:hover {
  text-decoration: underline;
}

/* ── Preview frame ── */
.tools-preview-frame {
  border-radius: 16px;
  background: #f5f5f7;
  border: 1px solid rgba(0, 0, 0, 0.06);
  overflow: hidden;
  min-height: 200px;
}

.tools-preview-frame__label {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  font-size: 12px;
  font-weight: 600;
  color: #6e6e73;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: rgba(255, 255, 255, 0.7);
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.tools-preview-mount {
  padding: 24px 20px 28px;
}

.tools-notes {
  margin: 20px 0 0;
  padding-left: 1.15em;
  font-size: 13px;
  color: #6e6e73;
  line-height: 1.55;
}

.tools-notes li {
  margin-bottom: 6px;
}

/* ── Code panel ── */
.tools-code-panel {
  margin-top: 24px;
}

.tools-code-panel__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 4px;
}

.tools-code-panel__head .tools-glass__heading {
  margin: 0;
}

.tools-markup {
  margin: 0;
  padding: 20px 22px;
  border-radius: 14px;
  background: #111827;
  color: #e5e7eb;
  font-size: 12px;
  line-height: 1.55;
  overflow-x: auto;
  white-space: pre-wrap;
  word-break: break-word;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

.tools-nav-row {
  margin-top: 36px;
}

.tools-error {
  text-align: center;
  padding: 80px 22px;
  color: #6e6e73;
}

.tools-error--setup {
  max-width: 520px;
  margin: 0 auto;
  text-align: left;
  padding: 48px 28px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(0, 0, 0, 0.08);
}

/* ── Preview components ── */
.tools-prev__title {
  font-weight: 600;
  word-break: break-word;
}

.tools-prev__desc {
  font-size: 13px;
  color: #6e6e73;
  margin-top: 4px;
  word-break: break-word;
}

.tools-prev__host {
  font-size: 12px;
  color: #6e6e73;
  margin-top: 4px;
}

.tools-prev__img img,
.tools-prev__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.tools-prev__img.is-broken,
.tools-prev__thumb.is-broken {
  background: #e8e8ed;
  min-height: 80px;
}

/* Google SERP */
.tools-prev--google .tools-prev__serp {
  max-width: 600px;
  font-family: Arial, Helvetica, sans-serif;
}

.tools-prev__serp-title {
  font-size: 20px;
  line-height: 1.3;
  color: #1a0dab;
  margin: 0 0 4px;
  font-weight: 400;
}

.tools-prev__serp-title:hover {
  text-decoration: underline;
  cursor: default;
}

.tools-prev__serp-site {
  font-size: 14px;
  color: #202124;
  margin-bottom: 4px;
}

.tools-prev__serp-desc {
  font-size: 14px;
  line-height: 1.58;
  color: #4d5156;
}

/* WhatsApp */
.tools-prev--whatsapp .tools-prev__bubble {
  max-width: 320px;
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(11, 20, 26, 0.14);
}

.tools-prev--whatsapp .tools-prev__row {
  display: flex;
}

.tools-prev--whatsapp .tools-prev__thumb {
  width: 84px;
  min-height: 84px;
  flex-shrink: 0;
  background: #e9edef;
}

.tools-prev--whatsapp .tools-prev__text {
  padding: 10px 12px;
  flex: 1;
  min-width: 0;
}

.tools-prev--whatsapp .tools-prev__title {
  font-size: 14px;
  color: #111b21;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Discord */
.tools-prev--discord .tools-prev__embed {
  display: flex;
  max-width: 440px;
  background: #2b2d31;
  border-radius: 4px;
  overflow: hidden;
}

.tools-prev--discord .tools-prev__embed-bar {
  width: 4px;
  flex-shrink: 0;
  background: var(--embed-accent, #5865f2);
}

.tools-prev--discord .tools-prev__embed-body {
  padding: 12px 16px 14px;
  flex: 1;
}

.tools-prev--discord .tools-prev__site {
  font-size: 12px;
  font-weight: 600;
  color: #949ba4;
  margin-bottom: 4px;
}

.tools-prev--discord .tools-prev__title--link {
  color: #00a8fc;
  font-size: 16px;
}

.tools-prev--discord .tools-prev__desc {
  color: #dbdee1;
}

.tools-prev--discord .tools-prev__img {
  margin-top: 10px;
  border-radius: 4px;
  overflow: hidden;
  max-height: 260px;
}

/* Facebook */
.tools-prev--facebook .tools-prev__card {
  max-width: 500px;
  background: #fff;
  border: 1px solid #dddfe2;
  overflow: hidden;
}

.tools-prev--facebook .tools-prev__img {
  aspect-ratio: 1.91 / 1;
  background: #f0f2f5;
}

.tools-prev--facebook .tools-prev__card-body {
  padding: 10px 12px;
  background: #f2f3f5;
}

.tools-prev--facebook .tools-prev__host {
  text-transform: uppercase;
  font-size: 12px;
  color: #65676b;
}

/* X */
.tools-prev--twitter .tools-prev__card {
  max-width: 504px;
  border: 1px solid #eff3f4;
  border-radius: 16px;
  overflow: hidden;
  background: #fff;
}

.tools-prev--twitter .tools-prev__img {
  aspect-ratio: 2 / 1;
  background: #f7f9f9;
}

.tools-prev--twitter .tools-prev__card-body {
  padding: 12px 14px;
}

.tools-prev--twitter .tools-prev__from {
  font-size: 13px;
  color: #536471;
  margin-top: 4px;
}

/* LinkedIn */
.tools-prev--linkedin .tools-prev__card {
  max-width: 552px;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 8px;
  overflow: hidden;
}

.tools-prev--linkedin .tools-prev__desc--top {
  padding: 12px 16px 0;
  font-size: 14px;
  color: rgba(0, 0, 0, 0.6);
}

.tools-prev--linkedin .tools-prev__img {
  aspect-ratio: 1.91 / 1;
}

.tools-prev--linkedin .tools-prev__card-body {
  padding: 10px 16px 14px;
}

/* Slack */
.tools-prev--slack .tools-prev__card {
  display: flex;
  max-width: 480px;
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 8px;
  overflow: hidden;
}

.tools-prev--slack .tools-prev__slack-bar {
  width: 4px;
}

.tools-prev--slack .tools-prev__card-body {
  padding: 12px 16px;
  flex: 1;
}

.tools-prev--slack .tools-prev__img--inline {
  margin-top: 10px;
  border-radius: 6px;
  overflow: hidden;
  max-height: 180px;
}

/* Telegram / iMessage */
.tools-prev--telegram .tools-prev__bubble,
.tools-prev--imessage .tools-prev__bubble {
  max-width: 340px;
  background: #fff;
  border-radius: 12px;
  border: 1px solid #e5e5ea;
  overflow: hidden;
}

.tools-prev--imessage .tools-prev__bubble {
  background: #e9e9eb;
  border: none;
  border-radius: 18px;
}

.tools-prev--telegram .tools-prev__row,
.tools-prev--imessage .tools-prev__row {
  display: flex;
}

.tools-prev--telegram .tools-prev__text,
.tools-prev--imessage .tools-prev__text {
  flex: 1;
  padding: 10px 12px;
}

.tools-prev--telegram .tools-prev__thumb--right,
.tools-prev--imessage .tools-prev__thumb--right {
  width: 72px;
  min-height: 72px;
  flex-shrink: 0;
  background: #f2f2f7;
}

html.low-power .tools-glass,
html.low-power .tools-picker-card,
html.low-power .tools-platform-card {
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  background: rgba(255, 255, 255, 0.94) !important;
}

@media (max-width: 900px) {
  .tools-editor {
    grid-template-columns: 1fr;
  }

  .tools-page-head--hub {
    text-align: center;
    width: 100%;
    box-sizing: border-box;
    padding-left: max(20px, env(safe-area-inset-left));
    padding-right: max(20px, env(safe-area-inset-right));
  }

  .tools-shell--hub,
  .tools-shell {
    width: 100%;
    box-sizing: border-box;
    padding-left: max(16px, env(safe-area-inset-left));
    padding-right: max(16px, env(safe-area-inset-right));
  }

  .tools-picker {
    margin-left: auto;
    margin-right: auto;
  }

  .tools-page-head--compact {
    text-align: left;
    padding-top: 8px;
  }

  .tools-shell--toolbar {
    padding-top: calc(108px + env(safe-area-inset-top, 0px));
    top: calc(72px + env(safe-area-inset-top, 0px));
  }

  .tools-workspace-head {
    flex-direction: column;
    align-items: stretch;
  }

  .tools-workspace-head__title {
    flex-direction: row;
    align-items: center;
  }

  .tools-platform-picker--compact {
    width: 100%;
  }
}

@media (max-width: 480px) {
  .tools-platform-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .tools-glass {
    padding: 22px 18px 26px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .tools-picker-card:hover,
  .tools-platform-card:hover {
    transform: none;
  }
}

/* ── Favicon generator ── */
.tools-favicon-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr);
  gap: 24px;
  align-items: start;
}

.favicon-drop {
  position: relative;
  min-height: 240px;
  border-radius: 16px;
  border: 2px dashed rgba(0, 0, 0, 0.12);
  background: rgba(0, 0, 0, 0.02);
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.favicon-drop:hover,
.favicon-drop.is-dragover {
  border-color: rgba(53, 92, 255, 0.45);
  background: rgba(53, 92, 255, 0.04);
}

.favicon-drop.is-loading {
  opacity: 0.6;
  pointer-events: none;
}

.favicon-drop__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 236px;
  padding: 32px 24px;
  text-align: center;
  background: center / contain no-repeat;
}

.favicon-drop__inner.has-preview .favicon-drop__icon,
.favicon-drop__inner.has-preview .favicon-drop__title,
.favicon-drop__inner.has-preview .favicon-drop__sub,
.favicon-drop__inner.has-preview .favicon-drop__btn {
  opacity: 0;
}

.favicon-drop__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  margin-bottom: 14px;
  border-radius: 14px;
  background: rgba(53, 92, 255, 0.1);
  color: #355cff;
  font-size: 22px;
  font-weight: 600;
}

.favicon-drop__title {
  font-size: 16px;
  font-weight: 600;
  color: #1d1d1f;
  margin-bottom: 6px;
}

.favicon-drop__sub {
  font-size: 13px;
  color: #6e6e73;
  margin-bottom: 18px;
}

.favicon-drop__btn {
  pointer-events: none;
}

.tools-favicon-preview__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.tools-favicon-preview__head .tools-glass__heading {
  margin: 0;
}

.favicon-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 12px;
}

.favicon-grid__empty {
  grid-column: 1 / -1;
  padding: 32px 16px;
  text-align: center;
  font-size: 14px;
  color: #6e6e73;
}

.favicon-grid__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 14px 10px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(0, 0, 0, 0.06);
}

.favicon-grid__thumb {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 72px;
  height: 72px;
  border-radius: 10px;
  background: #f5f5f7;
}

.favicon-grid__thumb img {
  image-rendering: auto;
}

.favicon-grid__name {
  font-size: 11px;
  font-weight: 600;
  color: #1d1d1f;
  text-align: center;
  word-break: break-all;
}

.favicon-grid__size {
  font-size: 11px;
  color: #6e6e73;
}

@media (max-width: 900px) {
  .tools-favicon-layout {
    grid-template-columns: 1fr;
  }
}
