:root {
  --bg-obsidian: #141613;
  --bg-espresso: #1c1f1a;
  --bg-alabaster: #f5f2eb;
  --bg-linen: #ede8df;
  --bg-card-light: #faf8f4;

  --accent-gold: #c5a46d;
  --accent-gold-bright: #dfc18a;
  --accent-gold-soft: rgba(197, 164, 109, 0.35);
  --accent-bronze: #9a7843;

  --text-ivory: #f4f1ea;
  --text-ivory-soft: rgba(244, 241, 234, 0.86);
  --text-ivory-muted: rgba(244, 241, 234, 0.65);
  --text-ink: #1c1e1b;
  --text-stone: #5e615a;
  --border-stone: rgba(28, 30, 27, 0.1);
}

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

html,
body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  font-family: 'Outfit', sans-serif;
  font-weight: 300;
  background-color: #0e100d;
  color: var(--text-ink);
  -webkit-font-smoothing: antialiased;
}

.card-stage {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1rem;
  background:
    radial-gradient(ellipse 65% 50% at 50% 25%, rgba(197, 164, 109, 0.14) 0%, transparent 65%),
    radial-gradient(circle at 50% 100%, rgba(34, 46, 38, 0.35) 0%, transparent 60%),
    #0e100d;
}

.vcard-shell {
  width: 100%;
  max-width: 416px;
  border-radius: 26px;
  overflow: hidden;
  background: var(--bg-alabaster);
  border: 1px solid var(--accent-gold-soft);
  box-shadow:
    0 32px 80px rgba(0, 0, 0, 0.55),
    0 0 0 1px rgba(197, 164, 109, 0.12);
}

/* --- Top Dark Obsidian Header --- */
.vcard-top {
  position: relative;
  padding: 2rem 1.75rem 3.25rem;
  background:
    radial-gradient(circle at 85% 80%, rgba(197, 164, 109, 0.16) 0%, transparent 55%),
    linear-gradient(155deg, #1b1e19 0%, #121411 100%);
  color: var(--text-ivory);
}

.grain-overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: 0.045;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* Solid animated gold chase along the top card border */
.vcard-top-border {
  position: absolute;
  inset: 0;
  border-radius: 25px 25px 0 0;
  padding: 2px;
  pointer-events: none;
  z-index: 4;
  overflow: hidden;
  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  mask-composite: exclude;
}

.vcard-top-border::before {
  content: '';
  position: absolute;
  inset: -65%;
  background: conic-gradient(
    from 0deg,
    rgba(197, 164, 109, 0.28) 0deg 225deg,
    #c5a46d 270deg,
    #f6de9f 315deg,
    #c5a46d 348deg,
    rgba(197, 164, 109, 0.28) 360deg
  );
  animation: borderChase 4.2s linear infinite;
}

@keyframes borderChase {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.vcard-brand {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  text-decoration: none;
  color: var(--text-ivory);
  margin-bottom: 2rem;
}

.vcard-logo {
  width: 34px;
  height: 34px;
  object-fit: contain;
}

.vcard-brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.brand-name {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-gold-bright);
}

.brand-sub {
  font-size: 0.64rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-ivory-muted);
}

.vcard-identity {
  position: relative;
  z-index: 2;
  max-width: 60%;
}

.vcard-name {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 2.35rem;
  font-weight: 500;
  line-height: 1.05;
  margin: 0 0 0.6rem;
  color: var(--text-ivory);
}

.vcard-name em {
  font-style: italic;
  font-weight: 400;
  color: var(--accent-gold-bright);
}

.vcard-org {
  margin: 0;
  font-size: 0.78rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-ivory-muted);
}

/* --- Overlapping Portrait with Animated Gold Halo --- */
.card-portrait-wrap {
  position: absolute;
  right: 1.35rem;
  bottom: -62px;
  width: 158px;
  height: 158px;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gold-halo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  filter: drop-shadow(0 0 10px rgba(223, 193, 138, 0.38));
}

.halo-ring {
  fill: none;
  transform-origin: 110px 110px;
}

.halo-base {
  stroke: rgba(197, 164, 109, 0.32);
  stroke-width: 2.5;
}

.halo-chase {
  stroke: url(#goldArcGrad);
  stroke-width: 3.5;
  stroke-linecap: round;
  stroke-dasharray: 185 450;
  animation: slowSpin 3.4s linear infinite;
}

@keyframes slowSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes haloPulse {
  0%, 100% { opacity: 0.35; }
  50% { opacity: 0.75; }
}

.card-portrait {
  width: 132px;
  height: 132px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--bg-obsidian);
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.35);
}

.card-portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  filter: contrast(1.05) sepia(0.08);
}

/* --- Middle Linen Bio Band --- */
.vcard-bio {
  background: var(--bg-linen);
  padding: 4.25rem 1.75rem 1.35rem;
  border-bottom: 1px solid var(--border-stone);
}

.vcard-bio p {
  margin: 0;
  font-size: 0.96rem;
  line-height: 1.6;
  color: var(--text-ink);
}

/* --- Bottom Contact List --- */
.vcard-body {
  padding: 1.35rem 1.5rem 1.75rem;
  background: var(--bg-alabaster);
}

.vcard-list {
  list-style: none;
  margin: 0 0 1.15rem;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.vcard-row {
  display: flex;
  align-items: center;
  gap: 0.95rem;
  padding: 0.75rem 0.9rem;
  border-radius: 14px;
  background: var(--bg-card-light);
  border: 1px solid var(--border-stone);
  text-decoration: none;
  color: var(--text-ink);
  transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1), border-color 0.25s ease, box-shadow 0.25s ease;
}

.vcard-row:hover {
  transform: translateY(-2px);
  border-color: var(--accent-gold);
  box-shadow: 0 10px 24px rgba(28, 30, 27, 0.06);
}

.vcard-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-obsidian);
  border: 1px solid var(--accent-gold-soft);
  color: var(--accent-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
  flex-shrink: 0;
}

.vcard-icon-wa {
  color: #82c39d;
}

.vcard-meta {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1;
}

.vcard-value {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.vcard-label {
  font-size: 0.74rem;
  color: var(--text-stone);
  letter-spacing: 0.04em;
}

.vcard-arrow {
  font-size: 0.72rem;
  color: var(--accent-bronze);
  opacity: 0.55;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.vcard-row:hover .vcard-arrow {
  opacity: 1;
  transform: translate(2px, -2px);
}

/* Social Pills */
.vcard-socials {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem;
  margin-bottom: 1.15rem;
}

.social-pill {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  padding: 0.6rem 0.85rem;
  border-radius: 12px;
  background: var(--bg-card-light);
  border: 1px solid var(--border-stone);
  color: var(--text-ink);
  text-decoration: none;
  font-size: 0.84rem;
  font-weight: 400;
  transition: border-color 0.25s ease, color 0.25s ease, transform 0.25s ease;
}

.social-pill i {
  color: var(--accent-bronze);
}

.social-pill:hover {
  border-color: var(--accent-gold);
  color: var(--accent-bronze);
  transform: translateY(-2px);
}

/* Save Contact Button with Luxe Gold Shimmer */
.save-contact-btn {
  position: relative;
  overflow: hidden;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.95rem 1.25rem;
  border-radius: 14px;
  border: 1px solid var(--accent-gold);
  background: linear-gradient(135deg, #1b1e19 0%, #111310 100%);
  color: var(--accent-gold-bright);
  font-family: 'Outfit', sans-serif;
  font-size: 0.92rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: 0 12px 28px rgba(20, 22, 19, 0.22);
  transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.25s ease;
}

.save-contact-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 34px rgba(20, 22, 19, 0.3);
}

.btn-shimmer {
  position: absolute;
  top: 0;
  left: -120%;
  width: 65%;
  height: 100%;
  background: linear-gradient(105deg, transparent 20%, rgba(223, 193, 138, 0.22) 50%, transparent 80%);
  animation: btnSweep 4.2s ease-in-out infinite;
  pointer-events: none;
}

@keyframes btnSweep {
  0%, 40% { left: -120%; }
  75%, 100% { left: 160%; }
}

@media (max-width: 520px) {
  .card-stage {
    padding: 0;
    min-height: 100vh;
    min-height: 100dvh;
    height: 100vh;
    height: 100dvh;
    align-items: stretch;
  }

  .vcard-shell {
    max-width: 100%;
    height: 100%;
    border-radius: 0;
    border: 0;
    box-shadow: none;
    display: flex;
    flex-direction: column;
  }

  .vcard-top-border {
    border-radius: 0;
  }

  .vcard-top {
    padding: max(1.35rem, env(safe-area-inset-top)) 1.35rem 2.35rem;
    flex-shrink: 0;
  }

  .vcard-brand {
    margin-bottom: 1.35rem;
  }

  .vcard-name {
    font-size: 1.95rem;
  }

  .card-portrait-wrap {
    width: 134px;
    height: 134px;
    right: 1rem;
    bottom: -52px;
  }

  .card-portrait {
    width: 112px;
    height: 112px;
  }

  .vcard-bio {
    padding: 3.55rem 1.35rem 1.05rem;
    flex-shrink: 0;
  }

  .vcard-bio p {
    font-size: 0.9rem;
    line-height: 1.5;
  }

  .vcard-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 1rem 1.25rem max(1.15rem, env(safe-area-inset-bottom));
  }

  .vcard-list {
    gap: 0.5rem;
    margin-bottom: 0.75rem;
  }

  .vcard-row {
    padding: 0.62rem 0.85rem;
  }

  .vcard-icon {
    width: 36px;
    height: 36px;
    font-size: 0.88rem;
  }

  .vcard-socials {
    margin-bottom: 0.75rem;
  }

  .save-contact-btn {
    padding: 0.85rem 1.1rem;
  }
}
