/* shared/styles.css — shared look for ozira-pro/ and ozira/, built on the real brand
   gradient (violet → magenta → coral, from brand/ozira.png's own sparkle) and the Pro
   indigo, not the placeholder palette auth/index.html's own inline CSS still uses. Scope
   an accent per app via <body data-brand="pro"> (indigo) or <body data-brand="ozira">
   (gradient). Class names are unchanged from the first pass — only this file moved. */
@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap");

:root {
  --ink: #16181f;
  --ink-soft: #666c7a;
  --ink-faint: #9aa0ad;
  --ground: #f4f3f8;
  --surface: #ffffff;
  --border: #e6e4ee;
  --error: #c0392b;
  --error-soft: #fbeae8;
  --success: #1c8a5a;
  --success-soft: #e8f7f0;
  --accent: #6810e0;
  --accent-soft: #efe6fb;
  --accent-2: #c03090;
  --grad: linear-gradient(120deg, #6810e0 0%, #c03090 55%, #f84850 100%);
  --radius: 14px;
  --shadow-sm: 0 1px 2px rgba(22, 24, 31, 0.06);
  --shadow-md: 0 10px 28px rgba(40, 20, 70, 0.1);
  --shadow-lift: 0 16px 36px rgba(40, 20, 70, 0.16);
}
body[data-brand="pro"] {
  --accent: #241c84;
  --accent-2: #4b3fc9;
  --accent-soft: #e9e7f8;
  --grad: linear-gradient(120deg, #241c84 0%, #4b3fc9 100%);
}
body[data-brand="ozira"] {
  --accent: #6810e0;
  --accent-soft: #efe6fb;
  --grad: linear-gradient(120deg, #6810e0 0%, #c03090 55%, #f84850 100%);
}
* { box-sizing: border-box; }
body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(900px 420px at 100% -10%, var(--accent-soft), transparent 60%),
    var(--ground);
  color: var(--ink);
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

/* ---------- topbar ---------- */
.topbar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 22px;
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 10;
}
.topbar::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -3px;
  height: 3px;
  background: var(--grad);
  opacity: 0.9;
}
.topbar img { height: 26px; display: block; }
.topbar .spacer { flex: 1; }
.topbar a, .topbar button {
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--ink-soft);
  text-decoration: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px 10px;
  border-radius: 8px;
  transition: background 0.15s ease, color 0.15s ease;
}
.topbar a:hover, .topbar button:hover { background: var(--accent-soft); color: var(--accent); }

main { max-width: 640px; margin: 0 auto; padding: 28px 20px 70px; }

/* ---------- cards ---------- */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
  margin-bottom: 18px;
  box-shadow: var(--shadow-md);
  animation: rise 0.35s ease both;
}
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

h1 { font-size: 1.35rem; font-weight: 800; margin: 0 0 4px; letter-spacing: -0.01em; }
h2 { font-size: 1.05rem; font-weight: 700; margin: 0 0 12px; }
p.subtitle { color: var(--ink-soft); font-size: 0.88rem; line-height: 1.5; margin: 0 0 20px; }

/* ---------- forms ---------- */
label { display: block; font-size: 0.78rem; font-weight: 600; color: var(--ink-soft); margin-bottom: 6px; }
input, select, textarea {
  width: 100%;
  padding: 11px 13px;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  font-size: 0.95rem;
  margin-bottom: 12px;
  background: var(--ground);
  color: var(--ink);
  font-family: inherit;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
textarea { resize: vertical; min-height: 76px; line-height: 1.45; }
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-soft);
}
input::placeholder, textarea::placeholder { color: var(--ink-faint); }

.input-mode-row { display: flex; gap: 8px; margin: -4px 0 12px; }
.input-mode-row button {
  flex: 1;
  padding: 9px 10px;
  border: 1.5px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink-soft);
  font-size: 0.83rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}
.input-mode-row button:hover:not(:disabled) { border-color: var(--accent); color: var(--accent); }
.input-mode-row button.active {
  border-color: var(--accent);
  color: #fff;
  background: var(--grad);
  animation: pulse 1.4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(104, 16, 224, 0.35); }
  50% { box-shadow: 0 0 0 7px rgba(104, 16, 224, 0); }
}
.input-mode-row button:disabled { opacity: 0.4; cursor: not-allowed; }

.phone-row { display: flex; gap: 8px; }
.phone-row select { flex: 0 0 102px; width: 102px; }
.phone-row input { flex: 1; min-width: 0; }

/* ---------- buttons ---------- */
button.primary {
  width: 100%;
  padding: 12px 14px;
  border: none;
  border-radius: 10px;
  background: var(--grad);
  color: white;
  font-size: 0.94rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(104, 16, 224, 0.22);
  transition: transform 0.12s ease, box-shadow 0.12s ease, opacity 0.12s ease;
}
button.primary:disabled { opacity: 0.5; cursor: not-allowed; box-shadow: none; }
button.primary:hover:not(:disabled) { transform: translateY(-1px); box-shadow: 0 12px 24px rgba(104, 16, 224, 0.3); }
button.primary:active:not(:disabled) { transform: translateY(0); }

/* ---------- status ---------- */
.status {
  font-size: 0.85rem;
  color: var(--ink-soft);
  background: var(--accent-soft);
  border-radius: 10px;
  padding: 11px 14px;
  min-height: 1.1em;
  margin-top: 12px;
  transition: background 0.2s ease, color 0.2s ease;
}
.status.error { color: var(--error); background: var(--error-soft); }
.status::before { content: "● "; font-size: 0.6rem; vertical-align: middle; opacity: 0.6; }
.status.error::before { content: "⚠ "; }

/* ---------- chips ---------- */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: #fff;
  background: var(--grad);
  border-radius: 999px;
  padding: 4px 11px 4px 9px;
  margin: 2px 6px 6px 0;
  box-shadow: var(--shadow-sm);
  animation: pop 0.25s ease both;
}
.chip::before { content: "✓"; font-size: 0.7rem; }
@keyframes pop { from { opacity: 0; transform: scale(0.7); } to { opacity: 1; transform: scale(1); } }

/* ---------- chat ---------- */
.chat-thread { display: flex; flex-direction: column; gap: 12px; margin-bottom: 18px; }
.bubble {
  max-width: 85%;
  padding: 11px 15px;
  border-radius: 16px;
  font-size: 0.92rem;
  line-height: 1.45;
  box-shadow: var(--shadow-sm);
  animation: rise 0.25s ease both;
  white-space: pre-wrap;
}
.bubble.provider { align-self: flex-end; background: var(--grad); color: #fff; border-bottom-right-radius: 4px; }
.bubble.ozira { align-self: flex-start; background: var(--surface); border: 1px solid var(--border); border-bottom-left-radius: 4px; }

/* ---------- provider cards ---------- */
.provider-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 14px;
  padding: 16px 18px;
  margin-bottom: 12px;
  cursor: pointer;
  transition: transform 0.14s ease, box-shadow 0.14s ease, border-color 0.14s ease;
}
.provider-card::before {
  content: attr(data-initial);
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--grad);
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.provider-card:hover { border-color: var(--accent); box-shadow: var(--shadow-lift); transform: translateY(-2px); }
.provider-card h3 { margin: 0 0 3px; font-size: 1rem; font-weight: 700; }
.provider-card p { margin: 0; font-size: 0.85rem; color: var(--ink-soft); line-height: 1.4; }

/* ---------- facts ---------- */
.facts-group { margin-bottom: 16px; }
.facts-group h4 {
  margin: 0 0 8px;
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.facts-group ul { margin: 0; padding-left: 0; list-style: none; font-size: 0.9rem; }
.facts-group li {
  padding: 8px 12px;
  background: var(--ground);
  border-radius: 8px;
  margin-bottom: 6px;
  line-height: 1.4;
}
.empty-note { color: var(--ink-faint); font-size: 0.85rem; font-style: italic; }
