/* Themalefik — abertura animada, centrada e adaptada a telas móveis. */
.tm-intro {
  --tm-intro-style-ready: 1;
  --tm-intro-gold: #d7ba7c;
  --tm-intro-paper: #f2e9d8;
  position: fixed;
  z-index: 2147483647;
  inset: 0;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  justify-content: safe center;
  gap: clamp(6px, 1.3vh, 14px);
  width: 100%;
  min-width: 0;
  padding: max(12px, env(safe-area-inset-top)) max(18px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom)) max(18px, env(safe-area-inset-left));
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  touch-action: pan-y;
  isolation: isolate;
  color: var(--tm-intro-paper);
  background: #090708;
  font-family: Georgia, 'Times New Roman', serif;
  opacity: 1;
}

.tm-intro *, .tm-intro *::before, .tm-intro *::after { box-sizing: border-box; }

.tm-intro::before, .tm-intro::after {
  position: fixed;
  z-index: -1;
  inset: 0;
  pointer-events: none;
  content: '';
}
.tm-intro::before {
  background: radial-gradient(ellipse at 50% 47%, rgba(86, 51, 32, .26), transparent 42%),
    radial-gradient(ellipse at 12% 82%, rgba(62, 8, 19, .30), transparent 35%),
    radial-gradient(ellipse at 88% 15%, rgba(49, 13, 18, .25), transparent 35%), #090708;
}
.tm-intro::after {
  background: radial-gradient(ellipse 28% 12% at 20% 62%, rgba(182, 159, 132, .13), transparent 76%),
    radial-gradient(ellipse 32% 13% at 75% 79%, rgba(150, 129, 111, .12), transparent 76%),
    radial-gradient(ellipse 30% 12% at 65% 28%, rgba(175, 153, 129, .09), transparent 78%);
  filter: blur(18px);
  animation: tm-intro-mist 16s ease-in-out infinite alternate;
}

.tm-intro__top {
  flex: none;
  display: flex;
  justify-content: center;
  width: 100%;
  min-width: 0;
  line-height: 0;
}
.tm-intro__logo {
  display: block;
  width: min(66vw, 250px);
  height: clamp(64px, 14vh, 125px);
  height: clamp(64px, 14dvh, 125px);
  max-width: 100%;
  object-fit: contain;
  user-select: none;
  -webkit-user-drag: none;
}

.tm-intro__stage {
  position: relative;
  flex: none;
  width: min(84vw, 49vh, 660px);
  width: min(84vw, 49dvh, 660px);
  max-width: 100%;
  aspect-ratio: 1;
  overflow: hidden;
  pointer-events: none;
}
.tm-intro__stage::before {
  position: absolute;
  inset: 19%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(120, 79, 42, .16), transparent 68%);
  filter: blur(12px);
  content: '';
}
.tm-intro__ring, .tm-intro__figure {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  user-select: none;
  -webkit-user-drag: none;
}
.tm-intro__ring {
  /* O centro desenhado difere do centro do arquivo: alinhar o pivô evita a oscilação. */
  inset: auto;
  left: 2.116%;
  top: 3.497%;
  width: 96%;
  height: 96%;
  transform-origin: 49.8794% 48.4409%;
  animation: tm-intro-ring 48s linear infinite;
}
.tm-intro__figure {
  left: -1.7823%;
  right: auto;
  animation: tm-intro-appear 1.8s ease both;
}

.tm-intro__bottom {
  position: relative;
  flex: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(6px, 1vh, 10px);
  width: min(100%, 620px);
  min-width: 0;
  text-align: center;
  animation: tm-intro-copy 1.3s ease both;
}
.tm-intro__title {
  margin: 0;
  color: var(--tm-intro-gold);
  font-size: clamp(17px, 2.2vw, 25px);
  font-weight: 400;
  letter-spacing: .16em;
  line-height: 1.25;
  text-indent: .16em;
}
.tm-intro__announcement {
  max-width: 580px;
  margin: 0;
  color: #ded4c3;
  font: 400 clamp(12px, 1.4vw, 15px)/1.45 Arial, sans-serif;
  text-wrap: balance;
}
.tm-intro__album {
  max-width: 100%;
  margin: 0;
  color: var(--tm-intro-gold);
  font-size: clamp(11px, 1.3vw, 14px);
  font-weight: 700;
  letter-spacing: .09em;
  line-height: 1.4;
  overflow-wrap: anywhere;
  text-wrap: balance;
}
.tm-intro__enter {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  min-width: 150px;
  min-height: 46px;
  margin-top: 3px;
  padding: 12px 24px;
  border: 1px solid rgba(215, 186, 124, .72);
  background: rgba(20, 12, 12, .75);
  color: var(--tm-intro-paper);
  cursor: pointer;
  font: 400 11px/1.2 Georgia, 'Times New Roman', serif;
  letter-spacing: .20em;
  text-decoration: none;
  text-transform: uppercase;
  transition: color 180ms ease, border-color 180ms ease, background-color 180ms ease;
}
.tm-intro__enter:hover { color: #fff; border-color: #e5cd9a; background: rgba(92, 31, 34, .48); }
.tm-intro__enter:focus-visible { outline: 2px solid #f4dba4; outline-offset: 4px; }

@keyframes tm-intro-ring { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
@keyframes tm-intro-appear { from { opacity: 0; } to { opacity: 1; } }
@keyframes tm-intro-copy { from { opacity: 0; } to { opacity: 1; } }
@keyframes tm-intro-mist { from { opacity: .25; } to { opacity: .48; } }

@media (max-height: 620px) and (orientation: portrait) {
  .tm-intro { gap: 5px; padding-top: max(8px, env(safe-area-inset-top)); padding-bottom: max(10px, env(safe-area-inset-bottom)); }
  .tm-intro__logo { height: clamp(48px, 12dvh, 74px); }
  .tm-intro__stage { width: min(80vw, 43dvh, 500px); }
  .tm-intro__bottom { gap: 5px; }
  .tm-intro__title { font-size: 16px; }
  .tm-intro__announcement { font-size: 12px; }
  .tm-intro__album { font-size: 10px; }
  .tm-intro__enter { min-height: 44px; padding: 8px 20px; }
}
@media (max-height: 500px) and (orientation: landscape) {
  .tm-intro {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    grid-template-rows: auto minmax(0, 1fr);
    align-items: center;
    justify-items: center;
    gap: 4px 14px;
    padding: max(8px, env(safe-area-inset-top)) max(14px, env(safe-area-inset-right)) max(8px, env(safe-area-inset-bottom)) max(14px, env(safe-area-inset-left));
  }
  .tm-intro__top { grid-column: 1; grid-row: 1; }
  .tm-intro__logo { width: min(35vw, 150px); height: min(14dvh, 64px); }
  .tm-intro__stage { grid-column: 1; grid-row: 2; width: min(44vw, 65dvh, 360px); }
  .tm-intro__bottom { grid-column: 2; grid-row: 1 / 3; gap: 6px; }
  .tm-intro__title { font-size: 17px; }
  .tm-intro__announcement { font-size: 12px; }
  .tm-intro__album { font-size: 11px; }
  .tm-intro__enter { min-height: 44px; padding: 8px 18px; }
}
@media (prefers-reduced-motion: reduce) {
  .tm-intro::after, .tm-intro__ring, .tm-intro__figure, .tm-intro__bottom, .tm-intro__enter {
    animation: none !important;
    transition: none !important;
  }
}
