/* ============================
   RESET & BASE
   ============================ */
@font-face {
  font-family: 'Aeonik';
  src: url('../images/Aeonik/Aeonik-Light.otf') format('opentype');
  font-style: normal;
  font-weight: 300;
  font-display: swap;
}

@font-face {
  font-family: 'Aeonik';
  src: url('../images/Aeonik/Aeonik-Regular.otf') format('opentype');
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: 'Aeonik';
  src: url('../images/Aeonik/Aeonik-Medium.otf') format('opentype');
  font-style: normal;
  font-weight: 500;
  font-display: swap;
}

@font-face {
  font-family: 'Aeonik';
  src: url('../images/Aeonik/Aeonik-Bold.otf') format('opentype');
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}

*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --color-bg: #020204;
  --color-surface: rgba(8, 10, 18, 0.88);
  --color-surface-hover: rgba(15, 18, 31, 0.94);
  --color-border: rgba(179, 186, 221, 0.13);
  --color-border-hover: rgba(179, 186, 221, 0.28);
  --color-text: #ffffff;
  --color-text-muted: rgba(255, 255, 255, 0.55);
  --color-text-subtle: rgba(255, 255, 255, 0.3);

  --font-display: 'Aeonik', sans-serif;
  --font-body: 'Aeonik', sans-serif;

  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-out-quart: cubic-bezier(0.25, 1, 0.5, 1);

  --max-width: 520px;
  --side-padding: clamp(1.25rem, 5vw, 2.5rem);
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  background-color: var(--color-bg);
  background-image:
    linear-gradient(180deg, rgba(2, 3, 11, 0.18) 0%, rgba(3, 5, 16, 0.42) 58%, rgba(2, 2, 7, 0.74) 100%),
    radial-gradient(ellipse 95% 65% at 50% 100%, #aebff5 0%, #7188d5 34%, #253054 70%, #080b14 100%);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-attachment: fixed;
  min-height: 100vh;
  min-height: 100dvh;
  color: var(--color-text);
  font-family: var(--font-body);
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
}


.home,
.marquee-section,
.links {
  position: relative;
  z-index: 1;
}


/* ============================
   SEÇÃO 1 — HOME
   ============================ */
.home {
  width: 100%;
  max-width: var(--max-width);
  padding: 3.5rem var(--side-padding) 2rem;
  display: flex;
  justify-content: center;
}

.home__inner {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 1.5rem;
}

/* Photo */
.home__photo-wrapper {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid var(--color-border);
  position: relative;
  flex-shrink: 0;
}

.home__photo-wrapper::after {
  content: none;
}

.home__photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Info */
.home__info {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
}

.home__label {
  font-family: 'Aeonik', sans-serif;
  font-size: 0.625rem;
  font-weight: 400;
  letter-spacing: 0.12em;
  color: var(--color-text-subtle);
}

.home__name {
  font-family: 'Aeonik', sans-serif;
  font-weight: 300;
  font-size: 1.75rem;
  letter-spacing: 0.15em;
  line-height: 1;
  color: var(--color-text);
}

.home__proof {
  font-family: 'Aeonik', sans-serif;
  display: flex;
  width: 100%;
  min-height: 1.35rem;
  align-items: baseline;
  justify-content: center;
  gap: 0.3em;
  font-size: 0.75rem;
  font-weight: 300;
  line-height: 1.5;
  letter-spacing: 0.03em;
  color: var(--color-text-muted);
  white-space: nowrap;
}

.decrypt-word {
  display: inline-block;
  font-family: 'Aeonik', sans-serif;
  font-weight: 500;
  font-size: inherit;
  line-height: inherit;
  color: var(--color-text);
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.decrypt-char--scrambled {
  font-family: 'Aeonik', sans-serif;
  opacity: 0.5;
}


/* ============================
   SEÇÃO 2 — MARQUEE
   ============================ */
.marquee-section {
  width: 100%;
  padding: 2rem 0;
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
  overflow: hidden;
  opacity: 0;
  animation: fadeIn 0.8s var(--ease-out-expo) 0.5s forwards;
}

.marquee {
  width: 100%;
  overflow: hidden;
}

.marquee__track {
  display: flex;
  width: max-content;
  animation: marqueeScroll var(--marquee-duration, 100s) linear infinite;
  will-change: transform;
}

.marquee__track:hover {
  animation-play-state: paused;
}

.marquee__content {
  display: flex;
  align-items: center;
  gap: 0;
  flex-shrink: 0;
  padding-right: 0;
}

.marquee__item {
  font-family: var(--font-display);
  font-size: clamp(0.8rem, 2.5vw, 0.9375rem);
  font-weight: 300;
  letter-spacing: 0.06em;
  color: var(--color-text);
  white-space: nowrap;
  padding: 0 1.25rem;
  transition: color 0.3s ease;
}

.marquee__item:hover {
  color: var(--color-text-muted);
}

.marquee__dot {
  font-size: 0.25rem;
  color: var(--color-text-subtle);
  flex-shrink: 0;
}


/* ============================
   SEÇÃO 3 — LINKS
   ============================ */
.links {
  width: 100%;
  max-width: var(--max-width);
  padding: 2.5rem var(--side-padding) 1.5rem;
  display: flex;
  flex-direction: column;
  flex: 1;
  overflow: hidden;
}

.links__inner {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.links__label {
  font-family: var(--font-body);
  font-size: 0.625rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-text-subtle);
  text-align: center;
}

.links__grid {
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
}

/* Link Card */
.link-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.25rem;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 14px;
  text-decoration: none;
  color: var(--color-text);
  transition:
    background 0.35s ease,
    border-color 0.35s ease,
    transform 0.35s var(--ease-out-expo);
}

.link-card:hover {
  background: var(--color-surface-hover);
  border-color: var(--color-border-hover);
  transform: translateY(-2px);
}

.link-card:active {
  transform: translateY(0) scale(0.985);
}

.link-card__icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: rgba(179, 186, 221, 0.06);
  color: var(--color-text-muted);
  flex-shrink: 0;
  transition: color 0.3s ease, background 0.3s ease;
}

.material-symbols-rounded {
  font-family: 'Material Symbols Rounded';
  font-weight: normal;
  font-style: normal;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  white-space: nowrap;
  word-wrap: normal;
  direction: ltr;
  font-feature-settings: 'liga';
  -webkit-font-feature-settings: 'liga';
  -webkit-font-smoothing: antialiased;
}

.link-card__icon .material-symbols-rounded {
  font-size: 22px;
}

.brand-icon {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.link-card:hover .link-card__icon {
  color: var(--color-text);
  background: rgba(179, 186, 221, 0.12);
}

.link-card__text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.link-card__title {
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 400;
  letter-spacing: 0.01em;
}

.link-card__subtitle {
  font-family: var(--font-body);
  font-size: 0.6875rem;
  font-weight: 300;
  color: var(--color-text-subtle);
  letter-spacing: 0.01em;
}

.link-card__arrow {
  font-size: 18px;
  color: var(--color-text-subtle);
  flex-shrink: 0;
  transition: transform 0.35s var(--ease-out-expo), color 0.3s ease;
}

.link-card:hover .link-card__arrow {
  transform: translate(3px, -3px);
  color: var(--color-text-muted);
}


/* ============================
   FOOTER
   ============================ */
.footer {
  margin-top: auto;
  padding: 3rem var(--side-padding) 1.5rem;
  text-align: center;
  opacity: 0;
  animation: fadeIn 0.8s var(--ease-out-expo) 1s forwards;
}

.footer__inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
}

.footer__logo-link {
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s ease;
}

.footer__logo-link:hover {
  transform: translateY(-2px);
}

.footer__logo {
  width: 16px;
  height: 16px;
  object-fit: contain;
  opacity: 0.4;
  transition: opacity 0.3s ease;
}

.footer__logo-link:hover .footer__logo {
  opacity: 0.8;
}

.footer__text {
  font-family: var(--font-body);
  font-size: 0.625rem;
  font-weight: 400;
  letter-spacing: 0.05em;
  color: var(--color-text-subtle);
}


/* ============================
   ANIMATIONS
   ============================ */

/* Blur Animations (Scroll Triggered) */
[data-blur] {
  opacity: 0;
  filter: blur(10px);
  transform: translateY(20px);
  transition: opacity 0.8s var(--ease-out-expo), filter 0.8s var(--ease-out-expo), transform 0.8s var(--ease-out-expo);
  will-change: opacity, filter, transform;
}

[data-blur].is-visible {
  opacity: 1;
  filter: blur(0);
  transform: translateY(0);
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes marqueeScroll {
  from {
    transform: translate3d(0, 0, 0);
  }
  to {
    /* A distância exata é medida pelo JS para não depender da viewport. */
    transform: translate3d(var(--marquee-offset, -50%), 0, 0);
  }
}

/* ============================
   RESPONSIVE
   ============================ */
@media (max-width: 480px) {
  body {
    background-position: center top;
    background-attachment: scroll;
  }

  .home {
    padding-top: 2rem;
    padding-bottom: 1.5rem;
  }

  .home__name {
    font-size: 1.65rem;
  }

  .marquee-section {
    padding: 1.5rem 0;
  }

  .links {
    padding: 1.75rem var(--side-padding) 1rem;
    flex: 1;
  }

  .link-card {
    padding: 0.875rem 1rem;
  }

  .link-card__icon {
    width: 36px;
    height: 36px;
  }

  .footer {
    margin-top: auto;
    padding: 2rem var(--side-padding) 1.25rem;
  }

  .footer__text {
    font-size: 0.55rem;
    white-space: nowrap;
  }
}
