/* Kleuren en maten overgenomen uit het Linktree-thema van b.hormann.audio */
:root {
  --bg: #000000;          /* achtergrond pagina/kaart */
  --outer: #1f1f1f;       /* achtergrond rond de kaart op desktop */
  --text: #fcf9ef;        /* tekstkleur */
  --border: #434343;      /* rand van de knoppen */
  --radius: 16px;         /* afronding knoppen */
  --inner-radius: 10px;   /* afronding thumbnails */
  --font: "Oxanium", system-ui, sans-serif;
}

* { box-sizing: border-box; }

html { background: var(--bg); }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
}

.page {
  max-width: 580px;
  margin: 0 auto;
  padding: 16px 16px 64px;
}

/* ---------- Bovenbalk ---------- */
.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 40px;
}

.round-btn {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  border: 0;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.45);
  color: #1f1f1f;
  cursor: pointer;
  transition: background 0.15s;
}
.round-btn:hover { background: rgba(255, 255, 255, 0.65); }

/* ---------- Taalschakelaar ---------- */
.lang-bar { display: flex; justify-content: flex-end; }
.lang {
  position: relative;
  display: inline-grid;
  grid-template-columns: 1fr 1fr;
  padding: 3px;
  border: 1px solid var(--border);
  border-radius: 9999px;
  background: #111;
}
.lang button {
  position: relative;
  z-index: 1;
  min-width: 44px;
  height: 30px;
  padding: 0 12px;
  border: 0;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.5px;
  cursor: pointer;
  opacity: 0.6;
  transition: color 0.2s, opacity 0.2s;
}
.lang button[aria-pressed="true"] { color: #000; opacity: 1; }
.lang-knob {
  position: absolute;
  top: 3px;
  bottom: 3px;
  left: 3px;
  width: calc(50% - 3px);
  border-radius: 9999px;
  background: var(--text);
  transition: transform 0.25s ease;
}
.lang[data-active="en"] .lang-knob { transform: translateX(100%); }
@media (prefers-reduced-motion: reduce) { .lang-knob { transition: none; } }

/* ---------- Profiel ---------- */
.profile {
  text-align: center;
  margin-top: 32px;
}

.avatar {
  width: 96px;
  height: 96px;
  border-radius: 9999px;
  object-fit: cover;
  display: block;
  margin: 0 auto 16px;
}

h1 {
  font-size: 20px;
  font-weight: 600;
  line-height: 1.2;
  margin: 0;
}

.bio {
  font-size: 14px;
  margin: 8px 0 0;
}

.socials {
  display: flex;
  justify-content: center;
  padding: 12px 0 16px;
}
.socials a {
  color: var(--text);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 40px;
  padding: 0 8px;
  text-decoration: none;
  font-size: 16px;
  font-weight: 500;
  transition: opacity 0.15s;
}
.socials a:hover { opacity: 0.75; }

/* ---------- Links ---------- */
.links {
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.link {
  position: relative;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.15s;
}
.link:hover { transform: scale(1.02); }
.link.open:hover { transform: none; }

.link-main {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-height: 64px;
  padding: 12px 64px;
  color: var(--text);
  text-decoration: none;
}

.thumb {
  position: absolute;
  left: 8px;
  top: 8px;
  width: 48px;
  height: 48px;
  border-radius: var(--inner-radius);
  object-fit: cover;
}

.label {
  font-size: 14px;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -0.2px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.sub {
  font-size: 12px;
  font-weight: 400;
  opacity: 0.7;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.dots {
  position: absolute;
  right: 8px;
  top: 12px;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 9999px;
  background: transparent;
  color: var(--text);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  opacity: 0.8;
}
.dots:hover { background: rgba(255, 255, 255, 0.1); }

/* ---------- Embeds (Spotify / YouTube) ---------- */
.embed { padding: 0 8px 8px; }
.embed iframe {
  display: block;
  width: 100%;
  border: 0;
  border-radius: 12px;
}

/* ---------- Spotify-playlists: eigen speler in de stijl van de Spotify-embed ---------- */
.sp-card {
  display: flex;
  flex-direction: column;
  border-radius: 12px;
  overflow: hidden;
  background: #121212;
  color: #fff;
  font-family: "Helvetica Neue", Helvetica, Arial, system-ui, sans-serif;
}

.sp-head {
  flex: none;
  display: flex;
  gap: 24px;
  padding: 24px;
  background: #1f1f1f;
}

.sp-cover {
  flex: none;
  position: relative;
  width: 200px;
  height: 200px;
}
.sp-cover-link { display: block; width: 100%; height: 100%; }
.sp-cover img {
  width: 100%;
  height: 100%;
  border-radius: 8px;
  object-fit: cover;
  display: block;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.5);
  background: #333;
}
/* YouTube-speler op de plek van de hoes (minimaal 200x200, zichtbaar volgens de YouTube-regels) */
.sp-screen-inner {
  display: none;
  position: absolute;
  inset: 0;
  border-radius: 8px;
  overflow: hidden;
  background: #000;
}
.sp-screen-inner > * { width: 100%; height: 100%; border: 0; display: block; }
.sp-card.has-screen .sp-screen-inner { display: block; }
.sp-card.has-screen .sp-cover-link { visibility: hidden; }

.sp-meta {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
}

.sp-title {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.5px;
  line-height: 1.15;
  color: #fff;
  text-decoration: none;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.sp-title:hover { text-decoration: underline; }

.sp-owner { font-size: 14px; color: #b3b3b3; }

.sp-now {
  font-size: 12px;
  color: #fff;
  min-height: 15px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sp-controls {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: -2px;
}
.sp-spacer { flex: 1; }

.sp-btn {
  flex: none;
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 4px;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}
.sp-btn:hover { text-decoration: underline; }

.sp-ctl, .sp-play {
  flex: none;
  border: 0;
  cursor: pointer;
  display: grid;
  place-items: center;
  padding: 0;
}
.sp-ctl {
  width: 36px;
  height: 36px;
  background: transparent;
  color: #b3b3b3;
  border-radius: 50%;
}
.sp-ctl:hover { color: #fff; }
.sp-ctl svg { width: 18px; height: 18px; }

.sp-play {
  width: 48px;
  height: 48px;
  margin-left: 4px;
  border-radius: 50%;
  background: #fff;
  color: #000;
  transition: transform 0.1s;
}
.sp-play:hover { transform: scale(1.06); }
.sp-play svg { width: 22px; height: 22px; }

.sp-progress {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 14px;
  margin-top: 4px;
  visibility: hidden;
}
.sp-card.is-active .sp-progress { visibility: visible; }
.sp-bar {
  flex: 1;
  height: 4px;
  border-radius: 2px;
  background: #4d4d4d;
  cursor: pointer;
  position: relative;
}
.sp-bar::before { content: ""; position: absolute; inset: -6px 0; }
.sp-fill { height: 100%; width: 0; border-radius: 2px; background: #fff; }
.sp-time { font-size: 11px; color: #b3b3b3; font-variant-numeric: tabular-nums; white-space: nowrap; }

.sp-list {
  height: 152px;
  list-style: none;
  margin: 0;
  padding: 8px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #5a5a5a transparent;
}

.sp-item {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) auto 24px;
  align-items: center;
  gap: 8px;
  min-height: 51px;
  padding: 0 8px;
  border-radius: 4px;
  color: #fff;
  cursor: pointer;
  outline: none;
}
.sp-item:hover, .sp-item:focus-visible { background: rgba(255, 255, 255, 0.1); }
.sp-item.playing { background: rgba(255, 255, 255, 0.07); }

.sp-num, .sp-icon {
  grid-column: 1;
  grid-row: 1;
  justify-self: center;
  color: #b3b3b3;
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}
.sp-icon { display: none; color: #fff; }
.sp-icon svg { width: 14px; height: 14px; display: block; }
.sp-item:hover .sp-num, .sp-item.playing .sp-num { visibility: hidden; }
.sp-item:hover .sp-icon, .sp-item.playing .sp-icon { display: block; }
.sp-item.no-preview .sp-icon { display: none; }
.sp-item.no-preview:hover .sp-num { visibility: visible; }

.sp-text { grid-column: 2; display: flex; flex-direction: column; min-width: 0; }
.sp-text strong { font-size: 14px; font-weight: 400; line-height: 20px; }
.sp-text span { font-size: 11px; line-height: 15px; color: #b3b3b3; }
.sp-text strong, .sp-text span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sp-item.playing .sp-text strong { color: #1ed760; }

.sp-dur { grid-column: 3; font-size: 14px; color: #b3b3b3; font-variant-numeric: tabular-nums; }

.sp-ext {
  grid-column: 4;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  color: #b3b3b3;
  opacity: 0;
}
.sp-item:hover .sp-ext, .sp-ext:focus-visible { opacity: 1; }
.sp-ext:hover { color: #fff; }
@media (hover: none) { .sp-ext { opacity: 0.7; } }

@media (max-width: 480px) {
  .sp-head { gap: 14px; padding: 16px; }
  .sp-cover { width: 96px; height: 96px; }
  .sp-card.has-screen .sp-head { flex-direction: column; }
  .sp-card.has-screen .sp-cover { width: 100%; height: auto; aspect-ratio: 1 / 1; max-width: 320px; align-self: center; }
  .sp-title { font-size: 20px; }
  .sp-btn { font-size: 13px; }
  .sp-ctl { width: 30px; }
  .sp-play { width: 40px; height: 40px; }
  .sp-list { height: 180px; }
}

/* ---------- YouTube: speler + videolijst ---------- */
.yt { display: flex; flex-direction: column; gap: 8px; }

.yt-player {
  width: 100%;
  aspect-ratio: 16 / 9;
  border: 0;
  border-radius: 12px;
  background: #111;
}

.yt-list {
  list-style: none;
  margin: 0;
  padding: 0 4px 0 0;
  max-height: 320px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}

.yt-item {
  width: 100%;
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 6px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--text);
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.yt-item:hover { background: rgba(255, 255, 255, 0.07); }
.yt-item.active { background: rgba(255, 255, 255, 0.14); }

.yt-item img {
  width: 96px;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 6px;
  display: block;
  background: #222;
}

.yt-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.yt-text strong { font-size: 14px; font-weight: 600; }
.yt-text span { font-size: 13px; opacity: 0.75; }
.yt-text strong, .yt-text span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.yt-dur { font-size: 12px; opacity: 0.6; font-variant-numeric: tabular-nums; }

/* ---------- Prijzen ---------- */
.thumb-icon {
  display: grid;
  place-items: center;
  background: #1f1f1f;
  color: var(--text);
}
.pr { display: flex; flex-direction: column; gap: 12px; padding: 4px 4px 8px; }
.pr-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.pr-card {
  background: #161616;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.pr-title { margin: 0; font-size: 15px; font-weight: 600; opacity: 0.85; }
.pr-price { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px; }
.pr-price strong { font-size: 26px; font-weight: 600; line-height: 1.1; white-space: nowrap; }
.pr-from, .pr-unit { font-size: 13px; opacity: 0.65; }
.pr-text { margin: 0; font-size: 14px; line-height: 1.45; color: rgba(252, 249, 239, 0.8); }
.pr-text a, .pr-text a:visited {
  color: var(--text);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.pr-text a:hover { opacity: 0.8; }
.pr-note { margin: 4px 0 0; font-size: 13px; color: rgba(252, 249, 239, 0.6); }
.pr-note a, .pr-note a:visited {
  color: var(--text);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.pr-note a:hover { opacity: 0.8; }
.pr-cta {
  align-self: flex-start;
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  padding: 12px 20px;
  border: 0;
  border-radius: 10px;
  background: var(--text);
  color: #000;
  cursor: pointer;
}
.pr-cta:hover { opacity: 0.85; }

/* ---------- Contactformulier ---------- */
.cf { display: flex; flex-direction: column; gap: 12px; padding: 4px 4px 8px; }
.cf-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; }
.cf-field { display: flex; flex-direction: column; gap: 6px; font-size: 13px; }
.cf-field span { opacity: 0.8; }
.cf-field input, .cf-field textarea {
  width: 100%;
  font: inherit;
  font-size: 16px;
  color: var(--text);
  background: #161616;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 14px;
  outline: none;
  transition: border-color 0.15s, background 0.15s;
}
.cf-field textarea { resize: vertical; min-height: 140px; }
.cf-field input:focus, .cf-field textarea:focus { border-color: var(--text); background: #1c1c1c; }
.cf-field.invalid input, .cf-field.invalid textarea { border-color: #e5534b; }
.cf-hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.cf-send {
  font: inherit;
  font-size: 16px;
  font-weight: 600;
  padding: 14px;
  border: 0;
  border-radius: 10px;
  background: var(--text);
  color: #000;
  cursor: pointer;
  transition: opacity 0.15s;
}
.cf-send:hover { opacity: 0.85; }
.cf-send:disabled { opacity: 0.5; cursor: wait; }
.cf-status { margin: 0; font-size: 14px; min-height: 1em; }
.cf-status[data-type="ok"] { color: #1ed760; }
.cf-status[data-type="error"] { color: #ff6b63; }
.cf-alt { margin: 0; font-size: 13px; opacity: 0.6; }
.cf-alt a { color: inherit; }
@media (max-width: 480px) { .cf-row { grid-template-columns: 1fr; } }

/* ---------- Toast ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translate(-50%, 20px);
  background: var(--text);
  color: #000;
  padding: 10px 16px;
  border-radius: 12px;
  font-size: 14px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s, transform 0.2s;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* Thumbnail die (nog) niet bestaat: geen kapot-plaatje-icoon tonen */
.thumb.missing { visibility: hidden; }

/* ---------- Tablet: iets ruimer ---------- */
@media (min-width: 640px) {
  .page { padding: 24px 28px 80px; }
  .profile { margin-top: 48px; }
  h1 { font-size: 24px; }
  .bio { font-size: 16px; }
  .label { font-size: 16px; }
}

/* ---------- Desktop: volwaardige brede layout ---------- */
@media (min-width: 900px) {
  .page {
    max-width: 1120px;
    padding: 32px 48px 96px;
  }

  /* Profiel naast elkaar: grote foto links, tekst rechts */
  .profile {
    display: grid;
    grid-template-columns: auto 1fr;
    grid-template-rows: auto auto auto;
    column-gap: 40px;
    align-items: center;
    text-align: left;
    margin: 40px 0 56px;
  }
  .avatar {
    grid-row: 1 / 4;
    width: 168px;
    height: 168px;
    margin: 0;
  }
  h1 { font-size: 44px; align-self: end; }
  .bio { font-size: 18px; margin-top: 10px; opacity: 0.85; }
  .socials { justify-content: flex-start; padding: 12px 0 0; margin-left: -8px; align-self: start; }

  /* Links als raster: contact en YouTube over de volle breedte, Spotify naast elkaar */
  .links {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 24px;
    margin: 0;
  }
  .link.wide { grid-column: 1 / -1; }
  .link:hover { transform: none; border-color: #6a6a6a; }
  .link { transition: border-color 0.15s; }

  /* Previews staan op desktop altijd open */
  .link[data-embed] .link-main { justify-content: center; }
  .embed { padding: 0 12px 12px; }
  /* YouTube: speler links, videolijst rechts, even hoog */
  .yt {
    position: relative;
    display: block;
    padding-right: calc((100% - 12px) / 3 + 12px);
  }
  .yt-list {
    position: absolute;
    top: 0;
    bottom: 0;
    right: 0;
    width: calc((100% - 12px) / 3);
    max-height: none;
  }
  .yt-item { grid-template-columns: 88px minmax(0, 1fr) auto; gap: 10px; }
  .yt-item img { width: 88px; }
}

/* Zonder previews (bijv. lokaal zonder Cloudflare) geen afspeelknoppen tonen */
.sp-card:not(.sp-has-previews) .sp-controls { display: none; }
