/* The brand mark: the claimed logo, or the brand's initials on its color. */
.brand-logo,
.brand-monogram {
  border-radius: 10px;
  flex: none;
  object-fit: contain;
}
.brand-logo.sm,
.brand-monogram.sm {
  width: 34px;
  height: 34px;
}
.brand-logo.md,
.brand-monogram.md {
  width: 40px;
  height: 40px;
}
.brand-logo.lg,
.brand-monogram.lg {
  width: 64px;
  height: 64px;
}
.brand-logo {
  background: white;
}
.brand-monogram {
  display: inline-grid;
  place-items: center;
  background: var(--coral);
  color: white;
  font-weight: 800;
  letter-spacing: 0.5px;
}
.brand-monogram.lg {
  font-size: 22px;
}

/* Claiming the brand: the owner's first screen. */
.claim-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(280px, 0.8fr) minmax(320px, 1.2fr);
  gap: 40px;
  padding: 56px clamp(20px, 5vw, 72px);
  align-items: start;
  background: linear-gradient(160deg, #f6f7fb, #eef0f6);
}
.claim-product {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 48px;
  font-size: 16px;
}
.claim-intro h1 {
  font-size: 40px;
  line-height: 1.1;
  letter-spacing: -1.2px;
  margin: 14px 0 16px;
}
.claim-intro p {
  font-size: 15px;
  line-height: 1.6;
  max-width: 440px;
}
.claim-form .form {
  grid-template-columns: 1fr 1fr;
}
.claim-form input[type="color"] {
  height: 42px;
  padding: 4px;
}
@media (max-width: 860px) {
  .claim-shell {
    grid-template-columns: 1fr;
  }
}

/* The central home's frame: a top bar, a centered column and its hero. */
.portal-top {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 28px;
  padding: 12px clamp(16px, 4vw, 48px);
  background: white;
  border-bottom: 1px solid var(--line);
}
.portal-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}
.portal-brand strong {
  display: block;
  font-size: 16px;
}
.portal-brand small {
  color: var(--muted);
}
.portal-me {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
}
.portal-main {
  max-width: 1120px;
  margin: 0 auto;
  padding: 36px clamp(16px, 4vw, 48px) 80px;
}
.portal-hero h1 {
  font-size: 34px;
  letter-spacing: -1px;
  margin: 10px 0 8px;
}
.portal-hero p {
  font-size: 15px;
  color: #4a4e66;
  max-width: 640px;
  line-height: 1.6;
}
.portal-hero.compact h1 {
  font-size: 28px;
}
.portal-section {
  margin-top: 28px;
}
.portal-section h2 {
  margin: 0;
  font-size: 18px;
}
.empty-state {
  margin-top: 24px;
  text-align: center;
}
@media (max-width: 900px) {
  .portal-top {
    flex-wrap: wrap;
    gap: 12px;
  }
}

/* The owner's Client & publishing page. */
.settings-grid {
  display: grid;
  gap: 16px;
}
.settings-grid h2 {
  margin: 0 0 6px;
}
.member-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.member-row .grow small {
  display: block;
  color: var(--muted);
}
.role-pill {
  padding: 4px 10px;
  border-radius: 999px;
  background: #f1f2f6;
  font-size: 12px;
  font-weight: 700;
}
.signin-link {
  word-break: break-all;
  padding: 12px;
  border-radius: 10px;
  background: #f6f7fb;
  border: 1px dashed var(--line);
  font-family: ui-monospace, monospace;
  font-size: 13px;
}
.publisher-fields {
  display: none;
}
.publisher-fields.active {
  display: contents;
}

/* The workspace sidebar carries the brand. */
.brand-card {
  display: flex;
  align-items: center;
  gap: 12px;
}
.brand-card img.brand-logo {
  width: 40px;
  height: 40px;
}
.brand-card small {
  color: rgb(255 255 255 / 72%);
}
.auth-story .brand img.brand-logo {
  width: 64px;
  height: 64px;
}
.workspace-name {
  background: none;
  border: 0;
  padding: 0;
}
.workspace-name button {
  width: 100%;
  border: 1px solid var(--line);
}

/* The central home: every client someone runs content for. */
.home {
  min-height: 100vh;
  background: #f6f7fa;
}
.client-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 14px;
  margin-top: 18px;
}
.client-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 18px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: white;
  color: inherit;
  text-decoration: none;
  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease;
}
.client-card:hover {
  border-color: var(--coral);
  box-shadow: 0 10px 28px rgb(15 20 40 / 10%);
}
.client-card .row {
  align-items: center;
  gap: 12px;
}
.client-card strong {
  font-size: 16px;
}
.client-card small {
  display: block;
  color: var(--muted);
}
.client-authority {
  text-align: right;
}
.client-authority strong {
  font-size: 24px;
  display: block;
}
.client-counts {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 13px;
}
.client-counts strong {
  color: #20243e;
}
.client-counts .hot strong,
.client-counts .hot {
  color: var(--coral);
}
/* Writing samples in three groups: the start dialog and Edit brand. */
.samples-editor {
  display: grid;
  gap: 12px;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}
.samples-editor legend {
  padding: 0;
  margin-bottom: 6px;
  font-size: 15px;
  font-weight: 750;
}
.samples-editor > p {
  font-size: 12px;
  line-height: 1.6;
}
.samples-nudge {
  padding: 10px 12px;
  border-radius: 8px;
  background: #f7f3fc;
  color: #6a587c;
}
.samples-nudge.done {
  background: #eaf4ed;
  color: #477b59;
}
.sample-group {
  display: grid;
  gap: 10px;
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fbfbfd;
}
.sample-group-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.sample-group > button {
  justify-self: start;
}
.sample-hint {
  font-size: 12px;
  line-height: 1.55;
}
.sample-rows {
  display: grid;
  gap: 10px;
}
.sample-rows:empty {
  display: none;
}
.sample-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: white;
}
.sample-row .full {
  grid-column: 1 / -1;
}
.sample-row textarea {
  min-height: 120px;
}
.sample-link {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  min-width: 0;
}
.sample-link label {
  flex: 1;
  min-width: 0;
}
.sample-row-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.sample-status {
  flex: 1;
  line-height: 1.5;
}
.sample-status.error {
  color: #a03030;
}
@media (max-width: 760px) {
  .sample-row {
    grid-template-columns: minmax(0, 1fr);
  }
  .sample-link {
    flex-wrap: wrap;
  }
}

/* Setup: the samples beside the voice guide drawn from them. */
.voice-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 20px;
  margin-top: 14px;
  align-items: start;
}
.voice-group {
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.voice-group:first-child {
  padding-top: 0;
}
.voice-group > p {
  margin-top: 6px;
  font-size: 12px;
}
.voice-samples {
  display: grid;
  gap: 6px;
  margin: 8px 0 0;
  padding-left: 18px;
  font-size: 13px;
  overflow-wrap: anywhere;
}
.voice-samples small {
  display: block;
}
.voice-guide-box {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fbfbfd;
}
.voice-guide-box h3 {
  margin: 0;
}
.voice-guide-box > button {
  justify-self: start;
}
@media (max-width: 760px) {
  .voice-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Setup checklist inside a client's workspace. */
.setup-step-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
}
.setup-step-head h2 {
  margin: 0;
  flex: 1;
}
.setup-check {
  display: inline-grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #f1f2f6;
  color: var(--navy);
  font-weight: 800;
}
.setup-step.done .setup-check {
  background: var(--coral);
  color: white;
}
.kickoff-preview {
  max-height: 420px;
  overflow: auto;
  padding: 16px 18px;
  border-radius: 12px;
  background: #f7f7fa;
  border: 1px solid var(--line);
  margin-top: 10px;
}
