/* Boje su preuzete iz prodajne ponude (prodaja/ponuda-A4.html) da demo i papir izgledaju
   kao ista tvrtka. */
:root {
  --ink: #16181D;
  --accent: #B3421A;
  --muted: #5B6169;
  --line: #E2E4E8;
  --wash: #F4F5F6;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  color: var(--ink);
  background: #fff;
  line-height: 1.5;
}

.page { max-width: 40rem; margin: 0 auto; padding: 3rem 1.25rem; }

.brand { font-size: 1.25rem; font-weight: 700; letter-spacing: -0.4px; margin: 0 0 2rem; }
.brand span { color: var(--accent); }

h1 { font-size: 1.9rem; letter-spacing: -0.4px; margin: 0 0 0.5rem; }
.lead { color: var(--muted); margin: 0 0 2rem; }
.switch { margin-top: 2.5rem; font-size: 0.9rem; }
.switch a { color: var(--muted); }

/* --- widget --- */

.demo {
  border: 1px solid var(--line);
  background: var(--wash);
  border-radius: 10px;
  padding: 1.5rem;
  text-align: center;
}

.demo__btn {
  font: inherit;
  font-weight: 600;
  color: #fff;
  background: var(--ink);
  border: 0;
  border-radius: 6px;
  padding: 0.85rem 1.6rem;
  cursor: pointer;
  transition: background 0.15s ease;
}

.demo__btn:hover:not(:disabled) { background: #2c3038; }
.demo__btn:disabled { opacity: 0.55; cursor: default; }

.demo[data-state="live"] .demo__btn { background: var(--accent); }

.demo__status {
  min-height: 1.4em;          /* rezervirano da tekst ne poskakuje layout */
  margin: 0.9rem 0 0;
  font-size: 0.9rem;
  color: var(--muted);
}

.demo[data-state="live"] .demo__status {
  color: var(--accent);
  font-weight: 600;
}

.demo__hint {
  margin: 0.35rem 0 0;
  font-size: 0.8rem;
  color: #8A9099;
}

/* Vidljiv znak da linija zivi, bez animacije koja ide u nedogled kad je razgovor gotov. */
.demo[data-state="live"] .demo__status::before {
  content: "";
  display: inline-block;
  width: 7px; height: 7px;
  margin-right: 7px;
  border-radius: 50%;
  background: var(--accent);
  animation: pulse 1.4s ease-in-out infinite;
}

@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.25; } }

@media (prefers-reduced-motion: reduce) {
  .demo[data-state="live"] .demo__status::before { animation: none; }
}
