/* Shared visual system inspired by the debut share card. Presentation only: no flow, data, or permission behavior changes. */
:root {
  color-scheme: dark;
  --ui-bg: #0c0714;
  --ui-surface: #171023;
  --ui-surface-raised: #21162e;
  --ui-line: #3a2949;
  --ui-text: #fff7ff;
  --ui-muted: #c0aec9;
  --ui-pink: #f13caa;
  --ui-violet: #8f35e8;
  --ui-cyan: #20d7dc;
  --ui-shadow: 0 18px 48px #05030a80;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  color: var(--ui-text);
  background: var(--ui-bg);
}

html { min-height: 100%; background: var(--ui-bg); }
body {
  min-height: 100vh;
  margin: 0;
  color: var(--ui-text);
  background:
    radial-gradient(ellipse at 85% 0%, #782ba533 0, transparent 32rem),
    radial-gradient(ellipse at 0% 45%, #c42d7e17 0, transparent 38rem),
    var(--ui-bg);
}

body, body :is(h1,h2,h3,h4,p,li,label,legend,summary,small,strong,span,dt,dd,th,td) {
  color: inherit;
}
body :is(p,li,small,.muted,.hint,.help,.note,.description,.subtitle,.lead) {
  color: var(--ui-muted);
}
a { color: #ffa6df; }
a:hover { color: #ffd5ef; }

body :is(header,.nav,.topbar,.toolbar,.site-header) {
  color: var(--ui-text);
  background: #120b1eee;
  border-color: var(--ui-line);
  backdrop-filter: blur(16px);
}
body :is(header a,.nav a,.topbar a,.toolbar a,.site-header a) { color: inherit; }

body :is(main,.main,.container,.page,.page-shell,#app) { color: var(--ui-text); }
body :is(.panel,.panel-card,.card,.market-panel,.invite-card,.offer-card,.profile-card,
  .guild-tile,.step-card,.flow-card,.question-card,.result-card,.auth-box,.surface,
  fieldset,details,.modal,.dialog,.confirm-card,.share-card,.trial-card) {
  color: var(--ui-text);
  background-color: var(--ui-surface);
  border-color: var(--ui-line);
  box-shadow: var(--ui-shadow);
}
body :is(.panel-card,.card,.market-panel,.invite-card,.offer-card,.profile-card,
  .guild-tile,.step-card,.flow-card,.question-card,.result-card,.auth-box,
  .surface,.confirm-card,.share-card,.trial-card) {
  border-radius: 22px;
}
body :is(.panel-card h1,.panel-card h2,.card h1,.card h2,.market-panel h1,
  .market-panel h2,.invite-card h2,.offer-card h2,.profile-card h2) { color: var(--ui-text); }

body :is(button,.button,[role="button"],input[type="submit"]) {
  min-height: 44px;
  border: 1px solid #70417d;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(110deg, var(--ui-pink), var(--ui-violet));
  box-shadow: 0 8px 24px #c62c8b35;
  font-weight: 750;
}
body :is(button,.button,[role="button"],input[type="submit"]):hover { filter: brightness(1.08); }
body :is(button.secondary,.secondary,.text-button,.back,.quiet-button) {
  color: var(--ui-text);
  background: #21182d;
  border-color: var(--ui-line);
  box-shadow: none;
}
body :is(button.danger-button,.danger-button,.delete-button) {
  color: #fff;
  background: #a92851;
  border-color: #d94b78;
}
body :is(.guild-cta,.institution-cta,.org-cta,[data-role="institution"]) {
  color: #eaffff;
  background: linear-gradient(110deg,#087d91,#12aab0);
  border-color: #1adbe0;
}

body :is(input:not([type=checkbox]):not([type=radio]),textarea,select) {
  min-height: 44px;
  color: var(--ui-text);
  background: #100b19;
  border: 1px solid #493453;
  border-radius: 12px;
  accent-color: var(--ui-pink);
}
body :is(input,textarea,select)::placeholder { color: #94839f; }
body :is(input,textarea,select):focus-visible, body :is(button,a):focus-visible {
  outline: 3px solid #20d7dc;
  outline-offset: 2px;
}
body :is(table,th,td) { border-color: var(--ui-line); }
body :is(th,thead) { color: #ffd0ed; background: #24162f; }
body :is(hr,.divider) { border-color: var(--ui-line); }
body :is(.primary,.cta,.hero-cta,.pilot-cta) {
  color: #fff;
  background: linear-gradient(105deg,var(--ui-pink),var(--ui-violet));
  border-color: transparent;
}
body :is(.badge,.tag,.chip,.pill) { border-color: #754878; }
body :is(.error,.danger,.alert-error) { color: #ff9fb1; }
body :is(.success,.alert-success) { color: #8ff4d7; }

@media (max-width: 720px) {
  body :is(.panel-card,.card,.market-panel,.invite-card,.offer-card,.profile-card,
    .guild-tile,.step-card,.flow-card,.question-card,.result-card,.auth-box,
    .surface,.confirm-card,.share-card,.trial-card) { border-radius: 18px; }
  body :is(button,.button,[role="button"],input[type="submit"]) { min-height: 46px; }
  body :is(.actions,.hero-actions,.market-actions,.share-card-actions) { gap: 9px; }
  body :is(input:not([type=checkbox]):not([type=radio]),textarea,select) { font-size: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  *,*::before,*::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
