/* ========== BASIS ========== */
body {
  background-color: #121212;
  color: white;
  font-family: "Segoe UI", Arial, sans-serif;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  min-height: 100vh;
}

strong {
  color: #1db954;
}

a {
  color: #1db954;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* ========== TAAL SELECTOR ========== */
/* Header controls: language + theme switch */
.header-controls {
  position: absolute;
  top: 20px;
  right: 20px;
  display: flex;
  align-items: center;
  gap: 14px;
}

.language-selector {
  position: static;
}

.language-selector select {
  padding: 8px;
  font-size: 16px;
  border: none;
  background-color: #1db954;
  color: white;
  cursor: pointer;
}

/* Theme switch */
.theme-switch {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.theme-switch__checkbox {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}
.theme-switch__label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  user-select: none;
}
.theme-switch__icon {
  display: inline-block;
  line-height: 1;
  font-size: 14px;
}
.theme-switch__track {
  width: 46px;
  height: 28px;
  border-radius: 999px;
  padding: 4px;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(0, 0, 0, 0.2);
  background: #1e1e1e;
}
.theme-switch__thumb {
  width: 20px;
  height: 20px;
  background: #fff;
  border-radius: 50%;
  transform: translateX(0);
  transition: transform 0.2s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}
.theme-switch__checkbox:checked + .theme-switch__label .theme-switch__thumb {
  transform: translateX(18px);
}
.theme-switch__checkbox:checked + .theme-switch__label .theme-switch__track {
  background: #16a34a; /* green accent */
  border-color: #16a34a;
}
.theme-switch__text {
  font-size: 14px;
  color: #bdbdbd;
}

/* Theme-aware track color */
html[data-theme="dark"] .theme-switch__track {
  background: #232323;
  border-color: rgba(255, 255, 255, 0.08);
}
html[data-theme="light"] .theme-switch__track {
  background: #e5e7eb;
  border-color: rgba(0, 0, 0, 0.08);
}
html[data-theme="light"] .theme-switch__thumb {
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25), 0 0 0 1px rgba(0, 0, 0, 0.05);
}

/* ========== LOGO ========== */
img.logo {
  width: 120px;
  margin-bottom: 20px;
}

/* ========== TITELS ========== */
h1 {
  font-size: 38px;
  margin-bottom: 10px;
  color: #1db954;
  text-align: center;
}

h2 {
  color: #1db954;
  margin-top: 20px;
  text-align: center;
  font-size: 24px;
}

section h2 {
  color: #1db954;
  font-size: 24px;
  margin-bottom: 10px;
  text-align: center;
}

/* ========== TEKST ========== */
p,
li {
  font-size: 16px;
  line-height: 1.6;
  text-align: center;
}

p {
  max-width: 800px;
  line-height: 1.6;
  margin: 0 auto 16px auto;
}

ol,
ul {
  text-align: left;
  margin: 0 auto;
  list-style: none;
  padding-left: 0;
}

section ul {
  list-style: none;
  padding: 0;
  margin: 0;
  text-align: center;
}

section ul li {
  margin-bottom: 10px;
}

/* ========== BUTTONS & LINKS ========== */
.button,
button,
.docs-link {
  display: inline-block;
  margin: 16px 0;
  padding: 12px 24px;
  font-size: 18px;
  background-color: #1db954;
  color: white;
  text-decoration: none;
  border-radius: 8px;
  border: none;
  transition: background 0.2s ease;
  cursor: pointer;
  box-sizing: border-box;
  width: 300px;
  max-width: 100%;
  text-align: center;
}

.button:hover,
button:hover,
.docs-link:hover {
  background-color: #1ed760;
}

#copyBtn {
  background-color: #444;
  font-size: 14px;
  padding: 10px 16px;
  width: 100%;
  border-radius: 5px;
}

#copyBtn:hover {
  background-color: #666;
}

/* ========== INPUTS ========== */
input {
  padding: 10px;
  margin: 6px 0;
  border: none;
  border-radius: 5px;
  width: 300px;
  background-color: #1e1e1e;
  color: white;
  box-sizing: border-box;
  font-size: 16px;
}

/* ========== OUTPUT BLOK ========== */
#output {
  margin-top: 30px;
  width: 90%;
  max-width: 600px;
  background: #1e1e1e;
  padding: 15px;
  border-radius: 8px;
  word-break: break-word;
  display: none;
  box-sizing: border-box;
}

#output h3 {
  margin-bottom: 10px;
}

#obsUrl {
  color: #1db954;
  display: block;
  margin-bottom: 10px;
  word-break: break-all;
}

/* ========== CODE BLOKKEN ========== */
code {
  background-color: #282828;
  color: #1db954;
  padding: 2px 4px;
  border-radius: 4px;
  max-width: 90vw;
  text-align: center;
  word-break: break-all;
  font-size: 15px;
}

/* ========== SCREENSHOTS ========== */
.screenshots {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px;
}
.screenshots img {
  width: 100%;
  max-width: 350px;
  border-radius: 10px;
}

/* ========== SECTIES ========== */
section {
  max-width: 800px;
  margin-top: 40px;
  text-align: left;
}

/* ========== FOOTER ========== */
#footer {
  text-align: center;
  padding: 16px 12px;
}
#footer .footer-text {
  margin-bottom: 8px;
  color: #bdbdbd;
}
#footer .footer-text a {
  color: #1db954;
  text-decoration: underline;
}
#footer .footer-text a:hover {
  color: #fff;
}

/* Nieuwe: lijst met SVG bullets als scheiders */
#footer .footer-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 5px 5px; /* horizontale afstand tussen items */
}
#footer .footer-list li {
  display: inline-flex;
  align-items: center;
}
#footer .footer-list li p {
  color: #1db954;
  margin: auto;
}
/* Bullet vóór elk item behalve de eerste */
#footer .footer-list li + li::before {
  content: "";
  display: inline-block;
  width: 25px;
  height: 25px;
  margin-right: 5px;
  background-color: #1db954; /* groen */
  -webkit-mask: url("/spotify-widget/img/svg/bullet.svg") no-repeat center /
    contain;
  mask: url("/spotify-widget/img/svg/bullet.svg") no-repeat center / contain;
}
/* Fallback zonder mask-ondersteuning */
@supports not ((-webkit-mask: url("")) or (mask: url(""))) {
  #footer .footer-list li + li::before {
    background-color: transparent;
    background-image: url("/spotify-widget/img/svg/bullet.svg");
    background-repeat: no-repeat;
    background-size: contain;
  }
}

#footer .social-banner {
  display: flex;
  gap: 14px;
  justify-content: center;
  align-items: center;
  margin: 6px 0 2px;
}
#footer .social-banner a {
  display: inline-flex;
  width: 28px;
  height: 28px;
  color: #1db954;
}
#footer .social-banner a:hover,
#footer .social-banner a:focus-visible {
  color: #fff;
}
#footer .social-banner svg {
  width: 100%;
  height: 100%;
}
#footer .social-banner svg * {
  fill: currentColor !important;
}

/* ========== DOCS SPECIFIEK ========== */
#cssContent {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
}

#cssButton {
  margin: 30px 0 0 0;
}

/* ========== MOBIELVRIENDELIJK ========== */
@media (max-width: 600px) {
  body {
    padding: 8px;
    min-height: unset;
  }
  h1 {
    font-size: 24px;
    margin-bottom: 8px;
  }
  h2,
  section h2 {
    font-size: 18px;
    margin-bottom: 8px;
    margin-top: 14px;
  }
  p,
  li,
  section ul li {
    font-size: 15px;
    margin-bottom: 8px;
  }
  .button,
  button,
  .docs-link {
    font-size: 16px;
    padding: 12px 0;
    margin: 12px 0;
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
  }
  input {
    width: 100%;
    font-size: 15px;
    padding: 12px;
    margin: 8px 0;
  }
  img.logo {
    width: 80px;
    margin-bottom: 12px;
  }
  .screenshots {
    flex-direction: column;
    gap: 10px;
  }
  .screenshots img {
    max-width: 98vw;
    width: 100%;
  }
  section {
    max-width: 100vw;
    margin-top: 20px;
    padding: 0 2vw;
  }
  section #themeButtons {
    text-align: center;
  }
  .language-selector {
    margin: 0;
  }

  .header-controls {
    position: static;
    margin: 10px 0 20px 0;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    gap: 10px;
  }
  #cssContent {
    gap: 6px;
  }
  code {
    font-size: 13px;
    max-width: 98vw;
    padding: 2px 2px;
  }
  ol,
  ul {
    padding-left: 0;
    margin-left: 0;
  }
  footer {
    margin-top: 30px;
    font-size: inherit; /* keep footer text same size as desktop */
  }
  #output {
    width: 100%;
    padding: 12px;
    font-size: 15px;
  }
}

.flag {
  width: 2.5rem;
  height: 2.5rem;
  display: inline-block;
  object-fit: contain;
  vertical-align: middle;
  margin: 0 0.2em;
  transition: transform 0.15s, box-shadow 0.15s;
  cursor: pointer;
  border-radius: 6px;
  box-shadow: 0 1px 4px #0002;
}

.flag:hover {
  transform: scale(1.15) rotate(-5deg);
  box-shadow: 0 4px 12px #0004;
}

/* Centered feature list: icon + text als één blok in het midden */
#featuresList {
  text-align: center;
  display: flex;
  flex-direction: column;
  flex-wrap: wrap;
  align-content: center;
  align-items: center;
}
#featuresList li {
  /* overschrijft eerdere layout */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding-left: 0; /* geen ruimte meer nodig links */
  position: static; /* reset eventueel relative */
}

/* icoon vóór de tekst, niet absoluut gepositioneerd */
#featuresList li::before {
  position: static !important; /* overschrijft absolute */
  left: auto;
  top: auto; /* reset coordinaten */
  display: inline-block;
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
  margin-right: 8px;
  content: "";

  background-color: #1db954; /* accentkleur */
  -webkit-mask: url("/spotify-widget/img/svg/checkbox.svg") no-repeat center /
    contain;
  mask: url("/spotify-widget/img/svg/checkbox.svg") no-repeat center / contain;
}

/* Fallback zonder mask-ondersteuning */
@supports not ((-webkit-mask: url("")) or (mask: url(""))) {
  #featuresList li::before {
    background-color: transparent;
    background-image: url("/spotify-widget/img/svg/checkbox.svg");
    background-repeat: no-repeat;
    background-size: contain;
  }
}

/* Custom bullets met SVG (groen) */
ul.bulletSvg {
  list-style: none;
  margin: 0 0 1rem;
  padding: 0;
}
ul.bulletSvg li {
  display: inline-flex;
  align-items: center; /* icoon netjes in het midden naast de tekst */
  gap: 10px;
  margin: 6px 0;
}
ul.bulletSvg li::before {
  content: "";
  flex: 0 0 12px;
  width: 12px;
  height: 12px;

  /* Groen gekleurde SVG via mask */
  background-color: #1db954;
  -webkit-mask: url("/spotify-widget/img/svg/bullet.svg") no-repeat center /
    contain;
  mask: url("/spotify-widget/img/svg/bullet.svg") no-repeat center / contain;
}

/* Fallback zonder mask-ondersteuning */
@supports not ((-webkit-mask: url("")) or (mask: url(""))) {
  ul.bulletSvg li::before {
    background-color: transparent;
    background-image: url("/spotify-widget/img/svg/bullet.svg");
    background-repeat: no-repeat;
    background-size: contain;
  }
}
