/* ─────────────────────────────────────────────────────────────────────────
   ProfilePreview – Handyrahmen + Profil. Masse und Farben wie in der
   SvisitScrollExperience (Rahmen 280 px, Radius 46/36, Insel 90×26).
   Akzentfarbe pro Profil über --pp-accent (Feld person.accent_color).
   ───────────────────────────────────────────────────────────────────────── */
.pp-phone {
  --pp-accent: #d90000;
  --pp-screen-h: 560px;
  --pp-bg: #0d0d0f;
  --pp-fg: #ffffff;
  --pp-muted: rgba(255, 255, 255, 0.55);
  --pp-card: rgba(255, 255, 255, 0.06);
  --pp-ph: rgba(255, 255, 255, 0.08);
  --pp-accent-soft: rgba(217, 0, 0, 0.15);
  --pp-accent-soft: color-mix(in srgb, var(--pp-accent) 16%, transparent);
  --pp-open: #22c55e;
  --pp-closed: rgba(255, 255, 255, 0.45);
  position: relative;
  width: 280px;
  max-width: 100%;
  padding: 12px;
  border-radius: 46px;
  background: linear-gradient(145deg, #2a2a2e, #141416);
  box-shadow: 0 40px 80px rgba(17, 24, 39, 0.35), inset 0 0 0 1px rgba(255, 255, 255, 0.06);
  font-family: 'Inter', sans-serif;
}
.pp-phone--light {
  --pp-bg: #ffffff;
  --pp-fg: #111827;
  --pp-muted: #6b7280;
  --pp-card: #f3f4f6;
  --pp-ph: #e5e7eb;
  --pp-open: #15803d;
  --pp-closed: #6b7280;
}
.pp-screen {
  position: relative;
  height: var(--pp-screen-h);
  border-radius: 36px;
  overflow: hidden;
  background: var(--pp-bg);
  color: var(--pp-fg);
}
.pp-island {
  position: absolute;
  top: 12px;
  left: 50%;
  z-index: 3;
  width: 90px;
  height: 26px;
  margin-left: -45px;
  border-radius: 999px;
  background: #000;
  pointer-events: none;
}
.pp-scroll {
  position: relative;
  height: 100%;
  overflow-y: auto;
  overflow-x: hidden;
  scroll-snap-type: y proximity;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.pp-scroll::-webkit-scrollbar { display: none; }
.pp-scroll:focus { outline: none; }
.pp-scroll:focus-visible { box-shadow: inset 0 0 0 3px var(--pp-accent); border-radius: 36px; }

/* Desktop: Scrollen bleibt in der Vorschau. Mobil nicht – die Seite scrollt weiter. */
@media (min-width: 1024px) {
  .pp-scroll { overscroll-behavior: contain; }
}
/* Mobil höchstens 60 % der Bildschirmhöhe */
@media (max-width: 1023px) {
  .pp-phone { --pp-screen-h: min(560px, 60vh); }
  @supports (height: 1svh) {
    .pp-phone { --pp-screen-h: min(560px, 60svh); }
  }
}

.pp-header {
  height: 96px;
  scroll-snap-align: start; /* erster Rastpunkt = ganz oben, sonst rastet der Browser auf den Kopfbereich ein */
  background: linear-gradient(135deg, var(--pp-accent), #a00);
  background: linear-gradient(135deg, var(--pp-accent), color-mix(in srgb, var(--pp-accent) 60%, #000));
}
.pp-header img { display: block; width: 100%; height: 100%; object-fit: cover; }

.pp-head {
  position: relative;
  margin-top: -40px;
  padding: 0 18px;
  text-align: center;
}
.pp-avatar {
  display: grid;
  place-items: center;
  width: 80px;
  height: 80px;
  margin: 0 auto;
  overflow: hidden;
  border-radius: 50%;
  border: 3px solid var(--pp-bg);
  background: linear-gradient(135deg, #444, #222);
  color: #fff;
  font-size: 28px;
  font-weight: 700;
}
.pp-avatar img { width: 100%; height: 100%; object-fit: cover; }
.pp-name { margin: 12px 0 2px; font-size: 21px; font-weight: 700; letter-spacing: -0.02em; line-height: 1.2; }
.pp-role { margin: 0; font-size: 13px; color: var(--pp-muted); }
.pp-save {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 16px;
  padding: 12px;
  border-radius: 12px;
  background: var(--pp-accent);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
}
.pp-save .pp-ico { display: inline-flex; width: 18px; height: 18px; }
.pp-save svg { width: 18px; height: 18px; }

.pp-blocks { padding: 4px 14px 0; }
.pp-block {
  display: grid;
  grid-template-rows: 1fr;
  margin-top: 8px;
  opacity: 1;
  scroll-snap-align: start;
  scroll-margin-top: 48px;
  transition: grid-template-rows 0.35s ease, opacity 0.25s ease, margin-top 0.35s ease;
}
.pp-block-inner { min-height: 0; overflow: hidden; border-radius: 12px; }
.pp-block.is-off { grid-template-rows: 0fr; opacity: 0; margin-top: 0; }
.pp-block.is-highlight .pp-card { box-shadow: inset 0 0 0 2px var(--pp-accent); }

.pp-card { border-radius: 12px; background: var(--pp-card); transition: box-shadow 0.3s ease; }
.pp-card--row { display: flex; align-items: center; gap: 12px; padding: 10px 12px; }
.pp-ico-box,
.pp-thumb {
  display: grid;
  place-items: center;
  flex: none;
  border-radius: 9px;
  background: var(--pp-accent-soft);
  color: var(--pp-accent);
}
.pp-ico-box { width: 34px; height: 34px; }
.pp-ico-box svg { width: 18px; height: 18px; }
.pp-thumb { width: 40px; height: 52px; overflow: hidden; border-radius: 6px; }
.pp-thumb svg { width: 20px; height: 20px; }
.pp-thumb img { width: 100%; height: 100%; object-fit: cover; }
.pp-text { display: flex; flex-direction: column; min-width: 0; flex: 1; text-align: left; }
.pp-title { font-size: 13px; font-weight: 600; line-height: 1.35; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pp-sub { font-size: 11px; line-height: 1.4; color: var(--pp-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pp-trail { display: inline-flex; flex: none; width: 16px; height: 16px; color: var(--pp-muted); }
.pp-trail svg { width: 16px; height: 16px; }

.pp-card--gallery { padding: 10px 0 12px; }
.pp-gallery-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; padding: 0 12px 8px; }
.pp-gallery-head .pp-title { flex: 1; }
.pp-gallery {
  display: flex;
  gap: 8px;
  padding: 0 12px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding: 0 12px;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
}
.pp-gallery::-webkit-scrollbar { display: none; }
.pp-gallery img,
.pp-gallery-ph {
  flex: 0 0 auto;
  width: 132px;
  height: 99px;
  border-radius: 9px;
  scroll-snap-align: start;
}
.pp-gallery img { object-fit: cover; background: var(--pp-ph); }
.pp-gallery-ph { display: grid; place-items: center; background: var(--pp-ph); color: var(--pp-muted); }
.pp-gallery-ph svg { width: 28px; height: 28px; }

/* Social-Media-Shortlinks: runde weisse Icons wie in der App (dort 56 px, Icon 24 px, Abstand 20 px),
   auf die Vorschaugrösse verkleinert: 5 Icons pro Zeile. Innenabstand unten, damit der Schatten
   nicht vom overflow:hidden des Blocks abgeschnitten wird. */
.pp-socials {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  padding: 4px 2px 12px;
  border-radius: 12px;
  transition: box-shadow 0.3s ease;
}
.pp-socials--left { justify-content: flex-start; }
.pp-social {
  display: grid;
  place-items: center;
  flex: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #fff;
  color: var(--pp-accent);
  box-shadow: 0 6px 10px -3px rgba(0, 0, 0, 0.12), 0 3px 5px -3px rgba(0, 0, 0, 0.1);
}
.pp-social svg { width: 16px; height: 16px; }
.pp-block.is-highlight .pp-socials { box-shadow: inset 0 0 0 2px var(--pp-accent); }

/* Öffnungszeiten wie in der App (Überschrift text-xl, Status 17 px fett mit Punkt, «Alle Öffnungszeiten»
   15 px, Wochenliste 17 px; heutiger Tag fett) – auf die Vorschaugrösse verkleinert. */
.pp-card--hours { padding: 12px 12px 4px; text-align: left; }
.pp-hours-title { margin: 0 0 4px; font-size: 15px; font-weight: 600; line-height: 1.3; letter-spacing: -0.01em; overflow-wrap: anywhere; }
.pp-hours-status { display: flex; align-items: flex-start; gap: 7px; margin: 0; font-size: 13px; font-weight: 600; line-height: 1.4; }
.pp-hours-dot { flex: none; width: 7px; height: 7px; margin-top: 5px; border-radius: 50%; background: var(--pp-closed); }
.pp-hours-status[data-open="true"] .pp-hours-dot { background: var(--pp-open); }
.pp-hours-status[data-pending] .pp-hours-dot { visibility: hidden; }
.pp-hours-more summary {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  min-height: 32px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  list-style: none;
  -webkit-user-select: none;
  user-select: none;
}
.pp-hours-more summary::-webkit-details-marker { display: none; }
.pp-hours-more summary:hover { text-decoration: underline; text-underline-offset: 3px; }
.pp-hours-more summary:focus { outline: none; }
.pp-hours-more summary:focus-visible { outline: 2px solid var(--pp-accent); outline-offset: 2px; }
.pp-hours-chev { display: inline-flex; width: 16px; height: 16px; transition: transform 0.2s ease; }
.pp-hours-chev svg { width: 16px; height: 16px; }
.pp-hours-more[open] .pp-hours-chev { transform: rotate(180deg); }
.pp-hours-list { margin: 0; padding: 0 0 8px; font-size: 11px; line-height: 1.65; }
.pp-hours-row { display: flex; justify-content: space-between; gap: 8px; }
.pp-hours-row dt { flex: none; }
.pp-hours-row dd { min-width: 0; margin: 0; text-align: right; overflow-wrap: anywhere; }
.pp-hours-row.is-today { font-weight: 600; }
.pp-nowrap { white-space: nowrap; }
.pp-hours-note { margin: 0 0 8px; font-size: 11px; line-height: 1.5; color: var(--pp-muted); overflow-wrap: anywhere; }

.pp-footer { margin: 0; padding: 18px 0 22px; text-align: center; font-size: 11px; color: var(--pp-muted); }
.pp-footer span { color: var(--pp-accent); font-weight: 700; }

/* Scroll-Hinweis: kein Effekt bei reduzierter Bewegung (JS prüft das zusätzlich) */
@media (prefers-reduced-motion: reduce) {
  .pp-block, .pp-card, .pp-socials, .pp-hours-chev { transition: none; }
}
