:root {
  color-scheme: light;
  --bg: #f7f5ef;
  --panel: #ffffff;
  --ink: #1d2522;
  --muted: #66736e;
  --line: #dde4df;
  --green: #176c4f;
  --green-dark: #0d4f39;
  --gold: #dba835;
  --red: #b84a3c;
  --blue: #2f6fa3;
  --shadow: 0 22px 60px rgba(31, 49, 42, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: "Microsoft YaHei", "PingFang SC", "Segoe UI", sans-serif;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.app-shell {
  min-height: 100vh;
}

.hidden {
  display: none !important;
}

.auth-view {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(360px, 480px);
  gap: 40px;
  align-items: center;
  padding: 48px;
  background:
    linear-gradient(110deg, rgba(23, 108, 79, 0.1), rgba(219, 168, 53, 0.06)),
    url("https://images.unsplash.com/photo-1497366754035-f200968a6e72?auto=format&fit=crop&w=1600&q=80") center/cover;
  position: relative;
}

.auth-view::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(247, 245, 239, 0.78);
}

.brand-panel,
.auth-card {
  position: relative;
  z-index: 1;
}

.brand-panel {
  max-width: 720px;
}

.brand-mark {
  width: 72px;
  height: 72px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  background: var(--green);
  color: #fff;
  font-weight: 800;
  letter-spacing: 0;
  box-shadow: var(--shadow);
}

.brand-mark.small {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  font-size: 15px;
  box-shadow: none;
}

.eyebrow {
  margin: 22px 0 8px;
  color: var(--green);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 18px;
  font-size: clamp(44px, 8vw, 92px);
  line-height: 0.95;
  letter-spacing: 0;
}

.brand-copy {
  max-width: 590px;
  color: #35423d;
  font-size: 22px;
  line-height: 1.65;
}

.value-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 38px;
}

.value-grid div {
  border-left: 4px solid var(--gold);
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.72);
}

.value-grid strong,
.value-grid span {
  display: block;
}

.value-grid span {
  margin-top: 8px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

.auth-card,
.site-dialog form {
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.75);
  border-radius: 8px;
  padding: 28px;
  box-shadow: var(--shadow);
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding: 5px;
  margin-bottom: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f1f4f1;
}

.tab-button,
.ghost-button,
.icon-button {
  border: 0;
  background: transparent;
  color: var(--muted);
}

.tab-button {
  min-height: 42px;
  border-radius: 6px;
  font-weight: 700;
}

.tab-button.active {
  color: var(--green-dark);
  background: #fff;
  box-shadow: 0 5px 16px rgba(16, 61, 46, 0.1);
}

label {
  display: grid;
  gap: 8px;
  margin-bottom: 16px;
  color: #34423d;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  outline: none;
}

input,
select {
  min-height: 48px;
  padding: 0 14px;
}

textarea {
  resize: vertical;
  padding: 12px 14px;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(23, 108, 79, 0.13);
}

.form-message {
  min-height: 22px;
  margin-bottom: 14px;
  color: var(--red);
  font-size: 14px;
}

.primary-button,
.ghost-button {
  min-height: 46px;
  border-radius: 6px;
  padding: 0 18px;
  font-weight: 800;
}

.primary-button {
  width: 100%;
  border: 0;
  background: var(--green);
  color: #fff;
}

.primary-button:hover {
  background: var(--green-dark);
}

.primary-button.compact {
  width: auto;
  min-width: 118px;
}

.ghost-button {
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
}

.dashboard {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
}

.sidebar {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 28px 18px;
  background: #143f32;
  color: #fff;
}

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

.logo-row span {
  display: block;
  margin-top: 4px;
  color: rgba(255, 255, 255, 0.68);
  font-size: 13px;
}

.category-list {
  display: grid;
  gap: 8px;
}

.category-button {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  min-height: 42px;
  border: 0;
  border-radius: 6px;
  padding: 0 12px;
  background: transparent;
  color: rgba(255, 255, 255, 0.76);
  text-align: left;
}

.category-button.active,
.category-button:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

.sidebar .ghost-button {
  margin-top: auto;
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.28);
}

.workspace {
  padding: 32px;
  overflow: hidden;
}

.topbar,
.section-heading,
.dialog-head,
.dialog-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.topbar h2 {
  margin-bottom: 0;
  font-size: 32px;
}

.search-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px;
  gap: 12px;
  margin: 28px 0 18px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 28px;
}

.stat-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  background: #fff;
}

.stat-card span {
  color: var(--muted);
  font-size: 14px;
}

.stat-card strong {
  display: block;
  margin-top: 10px;
  font-size: 30px;
}

.site-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 14px;
}

.site-card {
  display: grid;
  gap: 14px;
  min-height: 202px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  background: #fff;
  transition: transform 0.16s ease, box-shadow 0.16s ease;
}

.site-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 32px rgba(31, 49, 42, 0.1);
}

.site-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.site-title-row h4 {
  margin: 0;
  font-size: 19px;
}

.favorite-badge {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 4px 8px;
  background: #fff4cf;
  color: #7a5600;
  font-size: 12px;
  font-weight: 800;
}

.site-url,
.site-note {
  color: var(--muted);
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.site-category {
  width: fit-content;
  max-width: 100%;
  border-radius: 999px;
  padding: 5px 10px;
  background: #eaf2ee;
  color: var(--green-dark);
  font-size: 13px;
  font-weight: 800;
}

.site-actions {
  display: grid;
  grid-template-columns: 1fr repeat(4, auto);
  gap: 8px;
  margin-top: auto;
}

.site-actions a,
.site-actions button {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  text-decoration: none;
  display: grid;
  place-items: center;
  padding: 0 12px;
  font-weight: 700;
}

.site-actions a {
  background: var(--blue);
  border-color: var(--blue);
  color: #fff;
}

.site-actions .danger {
  color: var(--red);
}

.empty-state {
  display: grid;
  place-items: center;
  gap: 10px;
  min-height: 220px;
  border: 1px dashed #b8c4be;
  border-radius: 8px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.55);
  text-align: center;
}

.empty-state strong {
  color: var(--ink);
}

.site-dialog {
  width: min(540px, calc(100vw - 28px));
  border: 0;
  padding: 0;
  background: transparent;
}

.site-dialog::backdrop {
  background: rgba(13, 25, 21, 0.46);
}

.dialog-head h3 {
  margin-bottom: 0;
}

.icon-button {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  font-size: 26px;
}

.icon-button:hover {
  background: #f1f4f1;
}

.checkbox-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 4px 0 22px;
}

.checkbox-row input {
  width: 18px;
  min-height: 18px;
}

.dialog-actions {
  justify-content: flex-end;
}

.dialog-actions .primary-button,
.dialog-actions .ghost-button {
  width: auto;
  min-width: 104px;
}

@media (max-width: 900px) {
  .auth-view,
  .dashboard {
    grid-template-columns: 1fr;
  }

  .auth-view {
    padding: 28px 18px;
  }

  .value-grid,
  .stats-grid {
    grid-template-columns: 1fr;
  }

  .sidebar {
    min-height: auto;
  }

  .category-list {
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  }
}

@media (max-width: 620px) {
  .workspace {
    padding: 22px 14px;
  }

  .topbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .primary-button.compact {
    width: 100%;
  }

  .search-panel,
  .site-actions {
    grid-template-columns: 1fr;
  }
}

/* Refined product UI */
:root {
  --bg: #f6f7f8;
  --panel: #ffffff;
  --ink: #18201e;
  --muted: #6b7471;
  --line: #e4e8e6;
  --green: #0f766e;
  --green-dark: #0a5f59;
  --gold: #d99a1e;
  --red: #c24135;
  --blue: #2563eb;
  --shadow: 0 18px 50px rgba(21, 31, 29, 0.09);
}

body {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.72), rgba(246, 247, 248, 0.94)),
    radial-gradient(circle at 78% 8%, rgba(37, 99, 235, 0.09), transparent 34%),
    var(--bg);
}

.auth-view {
  background:
    linear-gradient(120deg, rgba(255, 255, 255, 0.84), rgba(246, 247, 248, 0.72)),
    url("https://images.unsplash.com/photo-1551434678-e076c223a692?auto=format&fit=crop&w=1800&q=80") center/cover;
}

.auth-view::before {
  background: rgba(246, 247, 248, 0.42);
  backdrop-filter: blur(2px);
}

.brand-mark {
  border-radius: 14px;
  background: #111827;
}

h1 {
  max-width: 760px;
  font-size: clamp(48px, 7.6vw, 88px);
}

.brand-copy {
  max-width: 620px;
  color: #2c3634;
}

.value-grid div,
.auth-card,
.stat-card,
.site-card,
.site-dialog form {
  border: 1px solid rgba(228, 232, 230, 0.9);
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(12px);
}

.value-grid div {
  border-left: 0;
  border-radius: 8px;
}

.auth-card,
.site-dialog form {
  box-shadow: 0 24px 70px rgba(20, 30, 28, 0.16);
}

.primary-button {
  background: #111827;
}

.primary-button:hover {
  background: #0f766e;
}

.dashboard {
  background: var(--bg);
}

.sidebar {
  background: #111827;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
}

.workspace {
  max-width: 1440px;
  width: 100%;
}

.topbar {
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.search-panel {
  grid-template-columns: minmax(0, 1fr) 170px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 12px 36px rgba(21, 31, 29, 0.05);
}

.command-input-wrap {
  position: relative;
  min-width: 0;
}

.command-input-wrap input {
  padding-right: 152px;
}

.command-hint {
  position: absolute;
  top: 50%;
  right: 12px;
  transform: translateY(-50%);
  color: #8a9692;
  font-size: 12px;
  font-weight: 800;
  pointer-events: none;
}

.search-panel input,
.search-panel select {
  border: 0;
  background: #f7f8f8;
}

.daily-launch {
  margin: 0 0 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  background: #fff;
  box-shadow: 0 14px 34px rgba(21, 31, 29, 0.05);
}

.daily-launch-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.daily-launch-head .eyebrow {
  margin: 0 0 6px;
}

.daily-launch-head h3 {
  margin-bottom: 0;
  font-size: 22px;
}

.daily-launch-head .ghost-button {
  width: auto;
  min-width: 108px;
}

.launch-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
}

.launch-tile {
  min-width: 0;
  min-height: 70px;
  display: grid;
  grid-template-columns: auto auto minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  border: 1px solid #e1e7e5;
  border-radius: 8px;
  padding: 10px;
  background: #f8faf9;
  color: var(--ink);
  text-align: left;
}

.launch-tile:hover,
.launch-tile:focus-visible {
  border-color: #111827;
  background: #fff;
  box-shadow: 0 10px 24px rgba(17, 24, 39, 0.08);
}

.launch-rank {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: #111827;
  color: #fff;
  font-size: 12px;
  font-weight: 900;
}

.launch-copy {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.launch-copy strong,
.launch-copy span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.launch-copy strong {
  font-size: 15px;
}

.launch-copy span {
  color: var(--muted);
  font-size: 12px;
}

.stat-card {
  box-shadow: none;
}

.stat-card strong {
  font-size: 28px;
}

.site-section {
  padding-top: 2px;
}

.site-card {
  min-height: 184px;
  box-shadow: 0 8px 28px rgba(21, 31, 29, 0.04);
}

.site-name-lockup {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 10px;
}

.site-icon {
  position: relative;
  width: 36px;
  height: 36px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #eef2ff;
  color: #1d4ed8;
  font-weight: 900;
  overflow: hidden;
}

.site-icon img {
  position: relative;
  z-index: 1;
  width: 24px;
  height: 24px;
  display: block;
  border-radius: 5px;
}

.site-icon-fallback {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
}

.site-title-row h4 {
  overflow-wrap: anywhere;
}

.site-url {
  font-size: 13px;
}

.site-note {
  min-height: 44px;
}

.visit-meta {
  min-height: 20px;
  color: #7c8783;
  font-size: 12px;
}

.site-actions a {
  background: #111827;
  border-color: #111827;
}

.site-actions a:hover {
  background: var(--green);
  border-color: var(--green);
}

.custom-category-row {
  margin-top: -8px;
}

.site-dialog form {
  padding: 24px;
}

.site-dialog .form-message {
  margin: -8px 0 14px;
}

button:disabled {
  cursor: progress;
  opacity: 0.65;
}

/* Public AI directory */
.public-view {
  min-height: 100vh;
  padding: 22px 32px 44px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(246, 247, 248, 0.98)),
    radial-gradient(circle at 20% 0%, rgba(15, 118, 110, 0.08), transparent 32%),
    radial-gradient(circle at 90% 12%, rgba(37, 99, 235, 0.08), transparent 28%),
    #f6f7f8;
}

.public-header {
  max-width: 1360px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.public-logo {
  color: var(--ink);
}

.public-logo span {
  color: var(--muted);
}

.public-actions {
  display: flex;
  gap: 10px;
}

.public-actions .primary-button,
.public-actions .ghost-button {
  width: auto;
  min-width: 82px;
}

.positioning-bar {
  max-width: 1360px;
  min-height: 48px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 18px auto 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px;
  background: rgba(255, 255, 255, 0.84);
  box-shadow: 0 10px 26px rgba(17, 24, 39, 0.04);
}

.positioning-bar a,
.positioning-bar button {
  min-height: 32px;
  border: 0;
  border-radius: 6px;
  padding: 0 12px;
  background: transparent;
  color: #334155;
  text-decoration: none;
  display: grid;
  place-items: center;
  font-size: 13px;
  font-weight: 900;
}

.positioning-bar a:hover,
.positioning-bar button:hover {
  background: #f1f5f9;
  color: #0f766e;
}

.positioning-bar button {
  margin-left: auto;
  background: #111827;
  color: #fff;
}

.positioning-bar button:hover {
  background: #0f766e;
  color: #fff;
}

.public-hero {
  max-width: 1360px;
  margin: 42px auto 26px;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 28px;
  align-items: start;
}

.public-hero.auth-open {
  grid-template-columns: minmax(0, 1fr) 390px;
}

.hero-copy {
  min-height: 332px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 44px;
  background:
    linear-gradient(135deg, rgba(17, 24, 39, 0.94), rgba(15, 118, 110, 0.88)),
    url("https://images.unsplash.com/photo-1558494949-ef010cbdcc31?auto=format&fit=crop&w=1600&q=80") center/cover;
  color: #fff;
  overflow: hidden;
}

.hero-copy .eyebrow {
  color: #99f6e4;
  margin-top: 0;
}

.hero-copy h1 {
  max-width: 780px;
  margin-bottom: 18px;
  font-size: clamp(38px, 5.6vw, 72px);
  line-height: 1.02;
}

.hero-copy .brand-copy {
  max-width: 680px;
  color: rgba(255, 255, 255, 0.84);
  font-size: 20px;
}

.quick-launch {
  display: grid;
  gap: 12px;
  max-width: 760px;
  margin-top: 26px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
}

.quick-launch input {
  min-height: 52px;
  border: 0;
  background: rgba(255, 255, 255, 0.95);
}

.quick-launch-actions {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.quick-launch-actions button {
  min-height: 40px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 8px;
  background: rgba(17, 24, 39, 0.74);
  color: #fff;
  font-weight: 900;
}

.quick-launch-actions button:hover {
  background: #0f766e;
}

.scenario-quick-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.scenario-quick-actions button {
  min-height: 34px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 999px;
  padding: 0 12px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 13px;
  font-weight: 900;
}

.scenario-quick-actions button:hover {
  border-color: #99f6e4;
  background: rgba(15, 118, 110, 0.92);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 18px;
}

.hero-actions .primary-button {
  width: auto;
}

.hero-actions a {
  color: #ccfbf1;
  font-weight: 900;
  text-decoration: none;
}

.hero-actions a:hover {
  color: #fff;
  text-decoration: underline;
}

.value-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.value-strip span {
  border: 1px solid rgba(153, 246, 228, 0.22);
  border-radius: 8px;
  padding: 7px 10px;
  background: rgba(17, 24, 39, 0.38);
  color: #ccfbf1;
  font-size: 13px;
  font-weight: 900;
}

.public-hero .auth-card {
  position: sticky;
  top: 22px;
  box-shadow: 0 16px 48px rgba(17, 24, 39, 0.1);
}

.scenario-showcase {
  max-width: 1360px;
  margin: 0 auto 26px;
}

.decision-principles {
  max-width: 1360px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin: 0 auto 26px;
}

.decision-principles article {
  display: grid;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  background: #fff;
}

.decision-principles strong {
  font-size: 18px;
}

.decision-principles span {
  color: var(--muted);
  line-height: 1.55;
}

.scenario-showcase .section-heading {
  margin-bottom: 14px;
}

.scenario-showcase .section-heading h3 {
  margin-bottom: 0;
  font-size: 24px;
}

.scenario-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.scenario-card {
  min-height: 214px;
  display: grid;
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(17, 24, 39, 0.04);
}

.scenario-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.scenario-card h4 {
  margin: 0;
  font-size: 18px;
}

.scenario-card p {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.55;
}

.scenario-labels {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.scenario-labels span {
  border-radius: 999px;
  padding: 4px 8px;
  background: #ecfdf5;
  color: #047857;
  font-size: 12px;
  font-weight: 900;
}

.scenario-card button {
  min-height: 34px;
  border: 1px solid #111827;
  border-radius: 6px;
  padding: 0 12px;
  background: #111827;
  color: #fff;
  font-weight: 900;
}

.scenario-picks {
  display: grid;
  gap: 8px;
  margin-top: auto;
}

.scenario-picks a {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 9px 10px;
  background: #f8fafc;
  color: var(--ink);
  text-decoration: none;
}

.pick-role {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 3px 7px;
  background: #111827;
  color: #fff !important;
  font-size: 11px !important;
  font-weight: 900;
}

.scenario-picks strong {
  flex: 1 1 auto;
}

.scenario-picks a:hover {
  border-color: #0f766e;
  background: #ecfdf5;
}

.scenario-picks span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-align: right;
}

.today-recommendations {
  max-width: 1360px;
  margin: 0 auto 26px;
}

.today-recommendations .section-heading {
  margin-bottom: 14px;
}

.today-recommendations .section-heading h3 {
  margin-bottom: 0;
  font-size: 24px;
}

.recommendation-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.recommendation-card {
  min-height: 142px;
  display: grid;
  align-content: start;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  background: #fff;
  color: var(--ink);
  text-decoration: none;
  box-shadow: 0 10px 28px rgba(17, 24, 39, 0.04);
}

.recommendation-card:hover {
  border-color: #111827;
  transform: translateY(-1px);
  box-shadow: 0 18px 36px rgba(17, 24, 39, 0.09);
}

.recommendation-label {
  width: fit-content;
  border-radius: 999px;
  padding: 4px 9px;
  background: #ecfdf5;
  color: #047857;
  font-size: 12px;
  font-weight: 900;
}

.recommendation-card strong {
  font-size: 19px;
}

.recommendation-card span:last-child {
  color: var(--muted);
  line-height: 1.55;
}

.recommendation-card small {
  color: #475569;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.5;
}

.public-directory {
  max-width: 1360px;
  margin: 0 auto;
}

.public-search {
  display: grid;
  margin-bottom: 16px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 14px 34px rgba(17, 24, 39, 0.05);
}

.public-search input {
  border: 0;
  min-height: 54px;
  background: #f7f8f8;
  font-size: 16px;
}

.public-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 22px;
}

.public-category-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 14px;
  background: #fff;
  color: #33403c;
  font-weight: 800;
}

.public-category-button span:last-child {
  color: var(--muted);
  font-weight: 700;
}

.public-category-button.active,
.public-category-button:hover {
  border-color: #111827;
  background: #111827;
  color: #fff;
}

.public-category-button.active span:last-child,
.public-category-button:hover span:last-child {
  color: rgba(255, 255, 255, 0.72);
}

.public-directory .section-heading {
  margin-bottom: 14px;
}

.public-directory .section-heading h3 {
  margin-bottom: 0;
  font-size: 24px;
}

.public-site-grid {
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}

.public-site-grid .site-card {
  min-height: 242px;
}

.open-link {
  width: 100%;
}

.topbar-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.topbar-actions .primary-button,
.topbar-actions .ghost-button {
  width: auto;
}

.inline-message {
  min-height: 22px;
  margin: -8px 0 18px;
  color: var(--muted);
  font-size: 14px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-height: 24px;
}

.tag-row span {
  border: 1px solid #dbeafe;
  border-radius: 999px;
  padding: 3px 8px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 12px;
  font-weight: 800;
}

.public-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-height: 24px;
}

.public-meta span {
  border-radius: 6px;
  padding: 4px 8px;
  background: #f1f5f9;
  color: #475569;
  font-size: 12px;
  font-weight: 800;
}

.value-note {
  border-left: 3px solid #0f766e;
  padding-left: 10px;
  color: #334155;
  font-size: 13px;
  line-height: 1.5;
}

.value-note strong {
  color: #0f766e;
}

.public-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 12px;
}

.public-filter-button {
  min-height: 40px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 0 14px;
  background: #fff;
  color: #111827;
  font-weight: 900;
}

.public-filter-button.active,
.public-filter-button:hover {
  border-color: #0f766e;
  background: #0f766e;
  color: #fff;
}

.public-site-grid .site-actions {
  grid-template-columns: 1fr;
}

@media (max-width: 980px) {
  .public-hero.auth-open,
  .public-hero {
    grid-template-columns: 1fr;
  }

  .public-hero .auth-card {
    position: static;
  }

  .recommendation-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .scenario-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .decision-principles {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  .public-view {
    padding: 18px 14px 30px;
  }

  .public-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .public-actions {
    width: 100%;
  }

  .public-actions .primary-button,
  .public-actions .ghost-button {
    flex: 1;
  }

  .positioning-bar {
    align-items: stretch;
    flex-direction: column;
  }

  .positioning-bar button {
    margin-left: 0;
  }

  .hero-copy {
    min-height: 280px;
    padding: 26px;
  }

  .hero-copy .brand-copy {
    font-size: 17px;
  }

  .quick-launch-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .hero-actions .primary-button {
    width: 100%;
  }

  .recommendation-grid {
    grid-template-columns: 1fr;
  }

  .scenario-grid {
    grid-template-columns: 1fr;
  }

  .scenario-picks a {
    align-items: flex-start;
    flex-direction: column;
  }

  .scenario-picks span {
    text-align: left;
  }

  .command-input-wrap input {
    padding-right: 14px;
  }

  .command-hint {
    display: none;
  }

  .daily-launch {
    padding: 14px;
  }

  .daily-launch-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .daily-launch-head .ghost-button {
    width: 100%;
  }

  .launch-grid {
    grid-template-columns: 1fr;
  }

  .topbar-actions {
    width: 100%;
  }

  .topbar-actions .primary-button,
  .topbar-actions .ghost-button {
    flex: 1;
  }

  .site-actions {
    grid-template-columns: 1fr;
  }
}
