:root {
  --coffee: #2b1709;
  --coffee-2: #4b2d17;
  --caramel: #e7b779;
  --caramel-2: #c89050;
  --cream: #fff4e4;
  --paper: rgba(255, 244, 228, 0.94);
  --white: #ffffff;
  --muted: rgba(255, 244, 228, 0.76);
  --shadow: 0 24px 90px rgba(15, 7, 2, 0.48);
  --radius: 34px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  min-height: 100vh;
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--cream);
  background: var(--coffee);
  overflow-x: hidden;
}

img, svg { display: block; }

a { color: inherit; text-decoration: none; }

.bg-visual {
  position: fixed;
  inset: 0;
  z-index: -3;
  overflow: hidden;
  background: var(--coffee);
}

.bg-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 50% 7%, rgba(231, 183, 121, .34), transparent 32%),
    radial-gradient(circle at 18% 82%, rgba(231, 183, 121, .18), transparent 34%),
    linear-gradient(180deg, rgba(24, 11, 3, .88) 0%, rgba(43, 23, 9, .75) 48%, rgba(17, 8, 4, .92) 100%);
  z-index: 2;
}

.bg {
  position: absolute;
  inset: -2%;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transform: scale(1.06);
  animation: fadeBg 18s infinite;
}

.bg-1 { background-image: url("assets/brand-cover.webp"); opacity: 1; }
.bg-2 { background-image: url("assets/visual-card.webp"); animation-delay: 6s; }
.bg-3 { background-image: url("assets/logo-tan.webp"); animation-delay: 12s; }

@keyframes fadeBg {
  0% { opacity: 0; transform: scale(1.08); }
  8% { opacity: 1; }
  30% { opacity: 1; }
  42% { opacity: 0; transform: scale(1.02); }
  100% { opacity: 0; transform: scale(1.08); }
}

.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -2;
  opacity: .17;
  background-image:
    linear-gradient(rgba(255,255,255,.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px);
  background-size: 46px 46px;
  mix-blend-mode: soft-light;
}

.linktree-shell {
  width: min(680px, calc(100% - 32px));
  min-height: 100vh;
  margin: 0 auto;
  padding: clamp(22px, 5vw, 54px) 0;
  display: grid;
  align-items: center;
}

.linktree-card {
  position: relative;
  overflow: hidden;
  padding: clamp(22px, 5vw, 38px);
  border: 1px solid rgba(231, 183, 121, 0.32);
  border-radius: var(--radius);
  background:
    linear-gradient(145deg, rgba(43, 23, 9, .91), rgba(43, 23, 9, .68)),
    rgba(255, 244, 228, .06);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.linktree-card::before {
  content: "";
  position: absolute;
  width: 340px;
  height: 340px;
  left: 50%;
  top: -210px;
  transform: translateX(-50%);
  border-radius: 999px;
  background: rgba(231, 183, 121, .24);
  filter: blur(10px);
}

.profile-header,
.links-list,
.card-footer { position: relative; z-index: 1; }

.profile-header { text-align: center; }

.logo-wrap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: clamp(132px, 32vw, 176px);
  aspect-ratio: 1;
  padding: 16px;
  border-radius: 30px;
  background: var(--paper);
  border: 1px solid rgba(231, 183, 121, .6);
  box-shadow: 0 18px 55px rgba(0, 0, 0, .25);
  transition: transform .25s ease, box-shadow .25s ease;
}

.logo-wrap:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 70px rgba(0, 0, 0, .36);
}

.brand-logo {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.eyebrow {
  margin: 22px 0 8px;
  font-size: clamp(.72rem, 1.4vw, .88rem);
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--caramel);
  font-weight: 900;
}

h1 {
  margin: 0;
  font-size: clamp(2.6rem, 9vw, 5.3rem);
  line-height: .88;
  letter-spacing: -.07em;
  color: var(--white);
  text-wrap: balance;
}

.lead {
  max-width: 520px;
  margin: 18px auto 0;
  font-size: clamp(1rem, 2.1vw, 1.18rem);
  line-height: 1.58;
  color: var(--muted);
}

.top-info {
  display: grid;
  gap: 10px;
  margin: 22px 0 0;
}

.top-info a {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 46px;
  padding: 12px 14px;
  border: 1px solid rgba(231, 183, 121, .3);
  border-radius: 999px;
  background: rgba(255, 244, 228, .1);
  color: rgba(255, 244, 228, .92);
  font-weight: 800;
  line-height: 1.2;
  transition: transform .2s ease, background .2s ease;
}

.top-info a:hover {
  transform: translateY(-2px);
  background: rgba(255, 244, 228, .16);
}

.icon-dot { flex: 0 0 auto; }

.links-list {
  display: grid;
  gap: 12px;
  margin-top: 26px;
}

.link-btn {
  display: grid;
  grid-template-columns: 52px 1fr;
  align-items: center;
  gap: 14px;
  min-height: 76px;
  padding: 12px 16px;
  border-radius: 24px;
  border: 1px solid rgba(231, 183, 121, .32);
  background: rgba(255, 244, 228, .1);
  color: var(--cream);
  text-align: left;
  box-shadow: 0 14px 34px rgba(0, 0, 0, .17);
  transition: transform .22s ease, box-shadow .22s ease, background .22s ease, border-color .22s ease;
}

.link-btn:hover {
  transform: translateY(-4px);
  background: rgba(255, 244, 228, .16);
  border-color: rgba(231, 183, 121, .6);
  box-shadow: 0 20px 44px rgba(0, 0, 0, .25);
}

.link-btn.featured {
  background: linear-gradient(135deg, var(--caramel), var(--caramel-2));
  color: var(--coffee);
  border-color: rgba(255, 244, 228, .42);
}

.link-icon {
  width: 52px;
  height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 18px;
  background: var(--paper);
  color: var(--coffee);
  border: 1px solid rgba(231, 183, 121, .34);
}

.featured .link-icon {
  background: var(--coffee);
  color: var(--cream);
  border-color: rgba(43, 23, 9, .08);
}

.link-icon svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

.link-btn strong {
  display: block;
  font-size: 1.05rem;
  line-height: 1.15;
  letter-spacing: -.01em;
}

.link-btn small {
  display: block;
  margin-top: 5px;
  color: rgba(255, 244, 228, .72);
  line-height: 1.3;
}

.link-btn.featured small { color: rgba(43, 23, 9, .72); }

.social-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 4px;
}

.social-card {
  min-height: 92px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 10px;
  border-radius: 24px;
  background: var(--paper);
  color: var(--coffee);
  font-weight: 900;
  border: 1px solid rgba(231, 183, 121, .45);
  box-shadow: 0 12px 30px rgba(0, 0, 0, .18);
  transition: transform .22s ease, background .22s ease;
}

.social-card:hover {
  transform: translateY(-4px);
  background: var(--caramel);
}

.social-card svg {
  width: 25px;
  height: 25px;
  fill: currentColor;
}

.card-footer {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 22px;
  color: rgba(255, 244, 228, .68);
  font-size: .9rem;
}

.floating-whatsapp {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 20;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  border-radius: 999px;
  background: #25d366;
  color: #ffffff;
  border: 0;
  box-shadow: 0 18px 42px rgba(0, 0, 0, .32);
  transition: transform .22s ease;
}

.floating-whatsapp:hover { transform: translateY(-4px) scale(1.04); }

.floating-whatsapp svg {
  width: 28px;
  height: 28px;
  fill: currentColor;
}

@media (max-width: 560px) {
  .linktree-shell { width: min(100% - 22px, 680px); padding: 12px 0 76px; }
  .linktree-card { padding: 20px; border-radius: 28px; }
  .logo-wrap { width: 132px; border-radius: 24px; padding: 14px; }
  .eyebrow { margin-top: 18px; letter-spacing: .15em; }
  h1 { font-size: clamp(3rem, 15vw, 4.3rem); }
  .top-info a { justify-content: flex-start; border-radius: 18px; }
  .link-btn { grid-template-columns: 48px 1fr; gap: 12px; border-radius: 22px; padding: 12px; }
  .link-icon { width: 48px; height: 48px; border-radius: 16px; }
  .social-grid { grid-template-columns: 1fr; }
  .social-card { min-height: 58px; flex-direction: row; }
  .card-footer { flex-direction: column; text-align: center; }
  .floating-whatsapp { width: 54px; height: 54px; right: 16px; bottom: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
  }
}
