/* Reset sizing para elementos e pseudo-elementos */
*,
*::before,
*::after {
  box-sizing: border-box;
}
hr {
  border: 1px solid white;
}
/* Corpo da página */
body {
  margin: 0;
  padding: 0 1rem 150px;
  font-family: "DM Mono", monospace;
  background-color: #344e41;
  color: #dad7cd;
  text-align: justify;
}

/* Headings responsivos */
h1 {
  text-align: center;
  font-size: clamp(2rem, 6vw, 3rem);
  margin: 0 0 20px;
}
h2,
h3 {
  text-align: center;
  font-size: 2rem;
  padding: 0;
  margin: 1.5rem;
  font-style: italic;
}
h4 {
  padding: 0;
  margin: 2rem;
  text-align: center;
  font-size: clamp(2rem, 6vw, 3rem);
}
h5 {
  text-align: center;
  font-size: 1.1rem;
  font-weight: lighter;
}
h6 {
  margin: 1.5rem;
  padding: 0;
  text-align: center;
  font-size: 1rem;
  font-weight: bold;
}

/* Iframes centrados */
iframe {
  padding: 10px;
  display: block;
  margin: 0 auto;
}

/* Title Links */
a.title-link,
a.title-link:visited {
  color: #dda15e;
  text-decoration: none;
}
a.text-link,
a.text-link:visited {
  background: linear-gradient(120deg, #f94d50 0%, #f94d50 100%);
  background-repeat: no-repeat;
  background-size: 100% 40%;
  background-position: 0 90%;
}
a.text-link:hover {
  background: linear-gradient(120deg, #f94d50 0%, #f94d50 100%);
  background-repeat: no-repeat;
  background-size: 100% 100%;
  transition: 0.2s;
}
/* Text Links */
a,
a:visited,
a:hover {
  color: #dad7cd;
  text-decoration: none;
  background-color: transparent;
}
figcaption {
  font-size: 1rem;
  font-style: italic;
  padding-top: 1rem;
  padding-bottom: 2rem;
  text-align: center;
}
/* Topbar */
.topbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 20px;
  background-color: #171a21;
  color: #dad7cd;
  z-index: 999;
  flex-wrap: wrap;
}
.topbar a {
  margin: 0 15px;
  padding: 6px 8px;
  text-decoration: none;
  font-size: 1rem;
  color: inherit;
  text-align: center;
}
.topbar a:hover {
  background-color: black;
  color: white;
}
.topbar .icon {
  display: none;
  order: -1;
  margin: 0 auto;
}

/* Espaço abaixo da topbar */
.main {
  margin: 0 auto;
  padding: 80px 1rem 0;
  max-width: 90ch;
  min-height: 100vh;
  font-size: 1.1rem;
  box-sizing: border-box;
  word-break: normal;
  hyphens: auto;
}

/* Imagens fluidas */
img {
  display: block;
  margin: 0 auto;
  width: 100%;
  height: auto;
}

.topbar img {
  width: 20px;
  max-width: 24px;
  height: auto;
  display: inline-block;
  margin: 0;
  vertical-align: middle;
}
/* Mosaic de imagens (masonry usando colunas) */
.image-mosaic {
  column-width: 250px;
  column-gap: 0.5rem;
  margin: 50px auto;
  padding: 0 1rem;
}

/* Cartões de imagem */
.card {
  break-inside: avoid;
  margin-bottom: 0.5rem;
  overflow: hidden;
  border-radius: 2px;
  transition: transform 0.2s ease;
  filter: grayscale(1);
}
.card:hover {
  transform: scale(1.02);
  filter: grayscale(0);
}
.card a {
  display: block;
  width: 100%;
  text-decoration: none;
}
.card img {
  width: 100%;
  height: auto;
  object-fit: contain;
}

/* Post mosaic (masonry usando colunas) */
.post-mosaic {
  column-width: 18rem;
  column-gap: 0.5rem;
  margin: 0 auto 2rem;
  padding: 0 1rem;
  width: 100vw; /* Full viewport width */
  position: relative;
  left: 50%;
  transform: translateX(-50%); /* Center it */
}

.post-container {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  break-inside: avoid;
  margin-bottom: 0.75rem;
}
.post-img {
  width: 100%;
  object-fit: cover;
  display: block;
}
.blog-img {
  box-sizing: border-box;
  width: 80%;
  display: block;
}
.post-info {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  color: white;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  opacity: 0;
  transition: opacity 0.3s ease;
  text-align: center;
  padding: 1rem;
}
.post-container:hover .post-info {
  opacity: 1;
}
.post-title {
  margin: 0;
  font-size: 1.1rem;
}
.post-slug {
  margin: 1rem;
  font-size: 1rem;
  opacity: 0.9;
  text-align: justify;
  hyphens: auto;
  word-wrap: break-word;
}
.blog-slug {
  margin: 1.5rem;
  font-size: 1rem;
  opacity: 0.9;
  text-align: center;
  hyphens: auto;
  word-wrap: break-word;
  box-sizing: border-box;
}

/* Botão “voltar” */
.back-button {
  margin: 1rem 0;
  padding: 0.5rem 1rem;
  font-family: "DM Mono", monospace;
  font-size: 1.5rem;
  background-color: #eee;
  border: none;
  cursor: pointer;
  transition: background-color 0.2s ease;
}
.back-button:hover {
  background-color: #ddd;
}

/* Perfil e links */
.profile__container {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.profile__container li {
  width: 100%;
}
.profile__image {
  width: 60%;
  min-width: 120px;
  max-width: 600px;
  border-radius: 50%;
  object-fit: cover;
}
.profile__links {
  display: block;
  width: 100%;
  max-width: 600px;
  margin: 0 auto 20px;
  padding: 20px;
  background: var(--color-disable);
  color: var(--color-primary);
  text-decoration: none;
  font-weight: bold;
  border: 1px solid white;
  border-radius: 10px;
  box-sizing: border-box;
}
.profile__links:hover {
  background: var(--color-secondary);
  border: 1px dashed white;
  transition: 0.5s;
}

/* Títulos e legendas */
.title {
  text-transform: uppercase;
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: bolder;
  margin: 20px 0;
}
.subtitle {
  font-size: clamp(0.9rem, 3vw, 1rem);
  font-weight: 400;
  color: var(--color-primary);
  margin: 10px 0;
}

/* Mobile */
@media screen and (max-width: 980px) {
  /* Ocultar links e mostrar ícone centrado */
  .topbar a:not(.icon) {
    display: none;
  }
  .topbar .icon {
    display: block;
  }

  /* Menu expandido */
  .topbar.responsive {
    flex-direction: column;
    align-items: stretch;
    height: auto;
  }
  .topbar.responsive a {
    display: block;
    width: 100%;
    text-align: center;
    padding: 10px 0;
  }

  /* Ajustes gerais mobile */
  body {
    padding: 0 0.75rem 30px;
  }
  .main {
    padding: 80px 0.75rem 0;
    font-size: 1rem;
  }
  .image-mosaic {
    column-width: 150px;
  }
  .profile__container {
    padding: 0 15px;
  }
  .profile__image {
    width: 40%;
    min-width: 100px;
    max-width: 150px;
  }
  .profile__links {
    font-size: 0.9rem;
    padding: 15px;
    margin-bottom: 15px;
  }
  .title {
    font-size: clamp(1.5rem, 6vw, 2.5rem);
    margin: 15px 0;
  }
  .subtitle {
    font-size: clamp(0.8rem, 4vw, 0.9rem);
    margin: 8px 0;
  }
}

audio {
  margin: 0 auto;
  width: 100%;
  box-sizing: border-box;
  display: block;
}

/* Bandcamp embed responsive container */
.bandcamp-embed {
  width: 100%;
  max-width: 700px;
  margin: 2rem auto;
  padding: 0;
}

.bandcamp-embed iframe {
  width: 100%;
  height: 400px;
  border: 0;
  display: block;
  margin: 0 auto;
}

/* Mobile adjustments for Bandcamp embed */
@media screen and (max-width: 980px) {
  .bandcamp-embed {
    margin: 1.5rem auto;
  }

  .bandcamp-embed iframe {
    height: 350px; /* Slightly smaller on mobile */
  }
}

@media screen and (max-width: 480px) {
  .bandcamp-embed iframe {
    height: 300px; /* Even smaller on very small screens */
  }
}
/* Cores globais */
:root {
  --color-dark: #2f3e46;
  --color-primary: #cad2c5;
  --color-disable: #000;
  --color-secondary: #354f52;
  --color-blue: #0b4ca1;
}
