/* ═══════════════════════════════════════════════════════════════
   OMNICARDS — Components CSS
   Componentes Avanzados y Variaciones Temáticas
   ═══════════════════════════════════════════════════════════════ */

/* ═══════════════════════════════════════════════════════════════
   [1] CARD VARIATIONS BY THEME
   ═══════════════════════════════════════════════════════════════ */

/* ── OBSIDIAN: Smoked Glass Cards ─────────────────────────── */
[data-theme="obsidian"] .bento-card {
  background: var(--obsidian-glass-fill);
  backdrop-filter: blur(var(--obsidian-glass-blur));
  -webkit-backdrop-filter: blur(var(--obsidian-glass-blur));
  border: 1px solid var(--obsidian-glass-border);
  box-shadow:
    inset 0 1px 0 var(--obsidian-glow-top),
    inset 0 -1px 0 var(--obsidian-glow-bottom),
    0 20px 40px rgba(0, 0, 0, 0.6);
}

[data-theme="obsidian"] .bento-card:hover {
  border-color: var(--obsidian-primary);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.2),
    inset 0 -1px 0 rgba(255, 255, 255, 0.05),
    0 30px 60px rgba(253, 253, 252, 0.1);
}

/* ── VANGUARD: Neon Glass Cards ────────────────────────────── */
[data-theme="vanguard"] .bento-card {
  position: relative;
  background: rgba(31, 31, 38, 0.4);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1.5px solid transparent;
  background-clip: padding-box;
  box-shadow:
    0 0 40px rgba(255, 0, 255, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

[data-theme="vanguard"] .bento-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1.5px;
  background: linear-gradient(135deg, #ff00ff, #00eefc);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

[data-theme="vanguard"] .bento-card:hover {
  box-shadow:
    0 0 60px rgba(255, 0, 255, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

/* ── STRUCTURA: Beveled Glass Cards ───────────────────────── */
[data-theme="structura"] .bento-card {
  background: var(--structura-glass-fill);
  backdrop-filter: blur(var(--structura-glass-blur));
  -webkit-backdrop-filter: blur(var(--structura-glass-blur));
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: var(--structura-border-radius);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.5),
    inset 0 -1px 0 rgba(0, 0, 0, 0.2),
    0 20px 60px rgba(0, 0, 0, 0.4);
}

[data-theme="structura"] .bento-card:hover {
  border-color: var(--structura-primary);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.6),
    inset 0 -1px 0 rgba(0, 0, 0, 0.15),
    0 30px 80px rgba(201, 169, 97, 0.15);
}

/* ── LUMINA: Creative Prism Cards ─────────────────────────── */
[data-theme="lumina"] .bento-card {
  background: #ffffff;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border: 1.5px solid var(--lumina-glass-border);
  border-radius: 12px;
  box-shadow:
    0 4px 24px rgba(217, 70, 239, 0.06),
    0 1px 4px rgba(0, 0, 0, 0.04);
}

[data-theme="lumina"] .bento-card:hover {
  border-color: var(--lumina-primary);
  box-shadow:
    0 8px 40px rgba(217, 70, 239, 0.12),
    0 2px 8px rgba(0, 0, 0, 0.06);
}

/* ═══════════════════════════════════════════════════════════════
   [2] CONTACT & SOCIAL COMPONENTS
   ═══════════════════════════════════════════════════════════════ */

.contact-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--glass-border);
  font-size: 15px;
  color: var(--text-muted);
  transition: color var(--transition-fast);
}

.contact-row:last-child {
  border-bottom: none;
}

.contact-row:hover {
  color: var(--primary);
}

.contact-row svg {
  width: 18px;
  height: 18px;
  min-width: 18px;
  fill: var(--primary);
  opacity: 0.7;
  transition: opacity var(--transition-fast);
}

.contact-row:hover svg {
  opacity: 1;
}

.social-links {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.social-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: var(--border-radius);
  border: 1px solid var(--glass-border);
  background: var(--glass-fill);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  color: var(--primary);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition:
    transform var(--transition-fast),
    border-color var(--transition-fast),
    box-shadow var(--transition-fast);
  box-shadow:
    inset 0 1px 0 var(--glow-top),
    inset 0 -1px 0 var(--glow-bottom);
}

.social-link:hover {
  transform: translateY(-2px);
  border-color: var(--primary);
  box-shadow:
    0 8px 24px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 var(--glow-top),
    inset 0 -1px 0 var(--glow-bottom);
}

.social-link svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

/* ═══════════════════════════════════════════════════════════════
   [3] BADGES & CHIPS
   ═══════════════════════════════════════════════════════════════ */

.badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.badge-primary {
  background: var(--primary);
  color: var(--bg);
}

.badge-glass {
  background: var(--glass-fill);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border: 1px solid var(--glass-border);
  color: var(--primary);
}

.badge-outline {
  background: transparent;
  border: 1px solid var(--glass-border);
  color: var(--primary);
}

/* Project Badges (Portfolio) */
.project-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: var(--glass-fill);
  border: 1px solid var(--glass-border);
  color: var(--text-muted);
  margin-left: auto;
}

/* ═══════════════════════════════════════════════════════════════
   [4] MODAL VARIATIONS
   ═══════════════════════════════════════════════════════════════ */

.modal-header {
  display: flex;
  align-items: center;
  gap: 16px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--glass-border);
  margin-bottom: 20px;
}

.modal-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  border: 2px solid var(--glass-border);
}

.modal-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.modal-name {
  font-family: inherit;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--primary);
  margin: 0 0 4px;
}

.modal-title {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin: 0;
}

.modal-section {
  margin-bottom: 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--glass-border);
}

.modal-section:last-of-type {
  border-bottom: none;
}

/* ── QR Code Section (universal contact sharing) ── */
.qr-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  width: 100%;
}

.qr-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0 0 12px 0;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  text-align: center;
}

.qr-container {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 12px;
  border-radius: 12px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

#contact-qr {
  display: block;
  margin: 0 auto;
  border-radius: 8px;
  /* QR canvas is white background with black modules — rounded for aesthetics */
}

.qr-hint {
  font-size: 12px;
  color: var(--text-muted);
  margin: 12px auto 0;
  line-height: 1.4;
  max-width: 240px;
  text-align: center;
}

/* ═══════════════════════════════════════════════════════════════
   [5] LOADER VARIATIONS
   ═══════════════════════════════════════════════════════════════ */

.loader-spinner {
  width: 48px;
  height: 48px;
  border: 3px solid var(--glass-border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ═══════════════════════════════════════════════════════════════
   [6] SCROLL INDICATOR
   ═══════════════════════════════════════════════════════════════ */

.scroll-indicator {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  opacity: 0.7;
  animation: bounceTail 2s infinite cubic-bezier(0.175, 0.885, 0.32, 1.275);
  pointer-events: none;
}

.scroll-indicator .mouse {
  width: 24px;
  height: 36px;
  border: 2px solid var(--text-muted);
  border-radius: 12px;
  position: relative;
}

.scroll-indicator .wheel {
  width: 4px;
  height: 8px;
  background: var(--primary);
  border-radius: 2px;
  position: absolute;
  top: 6px;
  left: 50%;
  transform: translateX(-50%);
  animation: scrollWheel 2s infinite;
}

@keyframes bounceTail {

  0%,
  20%,
  50%,
  80%,
  100% {
    transform: translateY(0) translateX(-50%);
  }

  40% {
    transform: translateY(-10px) translateX(-50%);
  }

  60% {
    transform: translateY(-5px) translateX(-50%);
  }
}

@keyframes scrollWheel {
  0% {
    transform: translate(-50%, 0);
    opacity: 1;
  }

  100% {
    transform: translate(-50%, 12px);
    opacity: 0;
  }
}

/* ═══════════════════════════════════════════════════════════════
   [7] ICON WRAPPERS
   ═══════════════════════════════════════════════════════════════ */

.icon-wrapper {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg,
      rgba(255, 255, 255, 0.1),
      rgba(255, 255, 255, 0.05));
  border: 1px solid var(--glass-border);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  color: var(--primary);
  box-shadow:
    inset 0 1px 0 var(--glow-top),
    inset 0 -1px 0 var(--glow-bottom);
}

.icon-wrapper svg {
  width: 28px;
  height: 28px;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
}

/* ═══════════════════════════════════════════════════════════════
   [8] LIST STYLES
   ═══════════════════════════════════════════════════════════════ */

.card-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.card-list li {
  padding: 12px 0;
  border-bottom: 1px solid var(--glass-border);
  font-size: 15px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 12px;
  transition: color var(--transition-fast);
}

.card-list li:last-child {
  border-bottom: none;
}

.card-list li:hover {
  color: var(--primary);
}

.card-list li::before {
  content: '';
  width: 6px;
  height: 6px;
  min-width: 6px;
  border-radius: 50%;
  background: var(--primary);
  opacity: 0.6;
}

/* ═══════════════════════════════════════════════════════════════
   [9] THEME-SPECIFIC BUTTON VARIATIONS
   ═══════════════════════════════════════════════════════════════ */

/* OBSIDIAN: Solid Silver Buttons */
[data-theme="obsidian"] .btn-primary {
  background: var(--obsidian-primary);
  color: var(--obsidian-bg);
  box-shadow:
    0 4px 20px rgba(253, 253, 252, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

/* VANGUARD: Neon Gradient Buttons */
[data-theme="vanguard"] .btn-primary {
  background: linear-gradient(135deg, #ff00ff, #00eefc);
  color: #131319;
  box-shadow:
    0 4px 20px rgba(255, 0, 255, 0.35),
    0 0 40px rgba(0, 238, 252, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

/* AURA: Clean Flat Buttons */
[data-theme="aura"] .btn-primary {
  background: var(--aura-primary);
  color: var(--aura-bg);
  border-radius: 100px;
  font-family: var(--font-sora);
  font-weight: 600;
  letter-spacing: 0.05em;
  box-shadow: none;
}

[data-theme="aura"] .btn-primary:hover {
  transform: none;
  box-shadow: none;
}

/* STRUCTURA: Brushed Brass Buttons */
[data-theme="structura"] .btn-primary {
  background: linear-gradient(135deg, #C9A961, #B8860B);
  color: var(--structura-bg);
  box-shadow:
    0 4px 20px rgba(201, 169, 97, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

/* LUMINA: Magenta Glow Buttons */
[data-theme="lumina"] .btn-primary {
  background: var(--lumina-primary);
  color: #ffffff;
  border-radius: 100px;
  font-weight: 600;
  box-shadow:
    0 4px 20px rgba(217, 70, 239, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

[data-theme="lumina"] .btn-primary:hover {
  transform: translateY(-2px);
  box-shadow:
    0 8px 30px rgba(217, 70, 239, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

/* ═══════════════════════════════════════════════════════════════
   [10] ACCESSIBILITY & STATES
   ═══════════════════════════════════════════════════════════════ */

/* Focus States */
.btn:focus-visible,
.bento-card:focus-visible,
.social-link:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

/* Disabled States */
.btn:disabled,
.bento-card.disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

/* Loading States */
.btn.loading {
  position: relative;
  color: transparent !important;
  pointer-events: none;
}

.btn.loading::after {
  content: '';
  position: absolute;
  width: 16px;
  height: 16px;
  top: 50%;
  left: 50%;
  margin-left: -8px;
  margin-top: -8px;
  border: 2px solid var(--primary);
  border-top-color: transparent;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

/* ═══════════════════════════════════════════════════════════════
   MOBILE ADJUSTMENTS — compact modal content
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
  .modal-header {
    gap: 12px;
    padding-bottom: 14px;
    margin-bottom: 14px;
  }

  .modal-avatar {
    width: 52px;
    height: 52px;
  }

  .modal-name {
    font-size: 1.05rem;
  }

  .modal-section {
    margin-bottom: 14px;
    padding-bottom: 14px;
  }

  .qr-section {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
  }
}

/* ═══════════════════════════════════════════════════════════════
   WALLET ENGINE — OS-aware "Add to Wallet" button
   ═══════════════════════════════════════════════════════════════ */

/* Hidden state — ready for future activation via WalletEngine.activateWalletButton() */
#btn-add-to-wallet.hidden {
  display: none;
}

/* Wallet button uses the same .btn-primary styling as sibling buttons.
   WalletEngine injects the OS-specific icon and label at runtime. */
#btn-add-to-wallet {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

#btn-add-to-wallet .wallet-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 0;
}

#btn-add-to-wallet .wallet-label {
  white-space: nowrap;
}

/* OS badge appended to the "Guardar Contacto" button in the modal */
.wallet-os-badge {
  display: inline-flex;
  align-items: center;
  vertical-align: middle;
}

/* ═══════════════════════════════════════════════════════════════
   END OF COMPONENTS.CSS
   ═══════════════════════════════════════════════════════════════ */