/* Tap profilecard — Premium Light/White Design System & 3D Card Engine */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&family=Inter:wght@400;500;600;700&display=swap');

:root {
  --font-main: 'Outfit', sans-serif;
  --font-sub: 'Plus Jakarta Sans', sans-serif;

  /* Brand Accents */
  --brand-coral: #F0997B;
  --brand-orange: #EF9F27;
  --brand-teal: #1D9E75;
  --brand-gradient: linear-gradient(135deg, #F0997B 0%, #EF9F27 100%);
  --brand-gradient-hover: linear-gradient(135deg, #ea8865 0%, #df8f13 100%);
  --brand-gradient-teal: linear-gradient(135deg, #1D9E75 0%, #0D9488 100%);

  /* Premium White Theme Tokens */
  --bg-main: #F8FAFC;
  --bg-surface: #FFFFFF;
  --bg-surface-hover: #F1F5F9;
  --bg-card: #FFFFFF;
  --border-color: #E2E8F0;
  --border-subtle: #F1F5F9;
  --border-focus: rgba(240, 153, 123, 0.6);

  --text-main: #0F172A;
  --text-heading: #0F172A;
  --text-muted: #64748B;
  --text-sub: #475569;

  --card-radius: 20px;
  --button-radius: 12px;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.06), 0 4px 6px -4px rgba(0, 0, 0, 0.04);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.08), 0 8px 10px -6px rgba(0, 0, 0, 0.04);
  --shadow-glow: 0 10px 25px -5px rgba(240, 153, 123, 0.3);

  --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
  font-family: var(--font-main);
  background-color: var(--bg-main);
  color: var(--text-main);
  min-height: 100vh;
  line-height: 1.5;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

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

/* Glass & Surface Panels */
.glass-panel {
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  border-radius: var(--card-radius);
  box-shadow: 0 4px 20px -2px rgba(0, 0, 0, 0.04), 0 2px 6px -1px rgba(0, 0, 0, 0.02);
}

.glass-nav {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid #E2E8F0;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
}

/* Gradient Utilities */
.gradient-text {
  background: var(--brand-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.gradient-bg {
  background: var(--brand-gradient);
}

/* Buttons */
.btn-primary {
  background: var(--brand-gradient);
  color: #FFFFFF;
  font-weight: 600;
  border: none;
  border-radius: var(--button-radius);
  padding: 10px 22px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: var(--transition);
  box-shadow: 0 4px 14px rgba(240, 153, 123, 0.35);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(240, 153, 123, 0.5);
  background: var(--brand-gradient-hover);
}

.btn-secondary {
  background: #FFFFFF;
  color: #1E293B;
  font-weight: 600;
  border: 1px solid #CBD5E1;
  border-radius: var(--button-radius);
  padding: 10px 20px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}
.btn-secondary:hover {
  background: #F8FAFC;
  border-color: #94A3B8;
  color: #0F172A;
  transform: translateY(-1px);
}

.btn-teal {
  background: var(--brand-gradient-teal);
  color: #FFFFFF;
  font-weight: 600;
  border: none;
  border-radius: var(--button-radius);
  padding: 10px 20px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition);
  box-shadow: 0 4px 14px rgba(29, 158, 117, 0.3);
}
.btn-teal:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(29, 158, 117, 0.45);
}

.btn-danger {
  background: #FEE2E2;
  color: #DC2626;
  border: 1px solid #FECACA;
  border-radius: var(--button-radius);
  padding: 8px 14px;
  cursor: pointer;
  font-weight: 600;
  transition: var(--transition);
}
.btn-danger:hover {
  background: #EF4444;
  color: #FFFFFF;
}

/* Dashboard Grid */
.dashboard-grid {
  display: grid;
  grid-template-columns: 270px 1fr;
  min-height: 100vh;
  background-color: #F8FAFC;
}

@media (max-width: 992px) {
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
}

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  font-size: 0.75rem;
  font-weight: 700;
  border-radius: 9999px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge-active {
  background: #ECFDF5;
  color: #059669;
  border: 1px solid #A7F3D0;
}

.badge-disabled {
  background: #FEF2F2;
  color: #DC2626;
  border: 1px solid #FECACA;
}

.badge-dest {
  background: #FFF7ED;
  color: #EA580C;
  border: 1px solid #FFEDD5;
}

/* Forms */
.form-group {
  margin-bottom: 18px;
}

.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: #334155;
  margin-bottom: 6px;
}

.form-input, .form-select, .form-textarea {
  width: 100%;
  background: #FFFFFF;
  border: 1px solid #CBD5E1;
  color: #0F172A;
  border-radius: var(--button-radius);
  padding: 11px 16px;
  font-size: 0.95rem;
  font-family: inherit;
  transition: var(--transition);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.form-input:focus, .form-select:focus, .form-textarea:focus {
  outline: none;
  border-color: var(--brand-coral);
  box-shadow: 0 0 0 3px rgba(240, 153, 123, 0.25);
  background: #FFFFFF;
}

/* Toast Alerts */
.toast-container {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.toast {
  padding: 16px 22px;
  border-radius: 14px;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  color: #0F172A;
  box-shadow: 0 15px 35px -5px rgba(0, 0, 0, 0.12), 0 5px 15px rgba(0, 0, 0, 0.05);
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 320px;
  font-size: 0.9rem;
  font-weight: 500;
  animation: slideIn 0.3s ease forwards;
}

.toast-success {
  border-left: 5px solid #10B981;
}
.toast-error {
  border-left: 5px solid #EF4444;
}

@keyframes slideIn {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* Modals */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(6px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}

.modal-overlay.active {
  display: flex;
}

.modal-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 24px;
  max-width: 540px;
  width: 100%;
  padding: 28px;
  box-shadow: 0 25px 50px -12px rgba(15, 23, 42, 0.25);
  animation: scaleUp 0.25s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes scaleUp {
  from { transform: scale(0.92); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

/* ===================================================
   3D FLIP CARD ANIMATION ENGINE
   =================================================== */
/* 3D Smart Card Interactive Scene */
.card-3d-scene {
  width: 100%;
  max-width: 380px;
  height: 236px;
  perspective: 1200px;
  perspective-origin: 50% 50%;
  margin: 0 auto;
  position: relative;
}

.card-3d-object {
  width: 100%;
  height: 100%;
  position: relative;
  transform-style: preserve-3d;
  transform-origin: 50% 50%;
  transition: transform 0.65s cubic-bezier(0.2, 0.8, 0.2, 1);
  cursor: pointer;
}

.card-3d-object.is-flipped {
  transform: rotateY(180deg);
}

/* Front & Back Faces */
.card-3d-face {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  border-radius: 20px;
  padding: 20px 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 20px 40px -10px rgba(15, 23, 42, 0.3), 0 0 0 1px rgba(255, 255, 255, 0.12) inset;
  user-select: none;
  overflow: hidden;
  transform-style: preserve-3d;
  transition: opacity 0.25s ease;
}

/* Front Face: Luxury Matte Obsidian with Gold Accents */
.card-3d-face-front {
  background: linear-gradient(145deg, #1E293B 0%, #0F172A 60%, #020617 100%);
  color: #FFFFFF;
  border: 1px solid rgba(255, 255, 255, 0.15);
  transform: rotateY(0deg);
  z-index: 2;
  opacity: 1;
}

/* Back Face: Luxury Matte Obsidian with Magnetic & QR */
.card-3d-face-back {
  background: linear-gradient(145deg, #0F172A 0%, #1E293B 100%);
  color: #FFFFFF;
  border: 1px solid rgba(255, 255, 255, 0.15);
  transform: rotateY(180deg);
  z-index: 1;
  opacity: 0;
  pointer-events: none;
}

.card-3d-object.is-flipped .card-3d-face-front {
  z-index: 1;
  opacity: 0;
  pointer-events: none;
}

.card-3d-object.is-flipped .card-3d-face-back {
  z-index: 2;
  opacity: 1;
  pointer-events: auto;
}

/* Metallic EMV / NFC Chip */
.emv-chip {
  width: 42px;
  height: 32px;
  border-radius: 6px;
  background: linear-gradient(135deg, #FDE68A 0%, #F59E0B 50%, #D97706 100%);
  border: 1px solid #B45309;
  box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.5), 0 2px 4px rgba(0, 0, 0, 0.1);
  position: relative;
  overflow: hidden;
}

.emv-chip::after {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(90deg, transparent, transparent 6px, rgba(0, 0, 0, 0.15) 6px, rgba(0, 0, 0, 0.15) 8px);
}

/* NFC Contactless Badge & Symbol */
.nfc-waves {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.25);
  color: #34D399;
  flex-shrink: 0;
  box-shadow: 0 0 15px rgba(16, 185, 129, 0.15);
}

/* Dynamic Gloss Sheen Sweep */
.gloss-sheen {
  position: relative;
  overflow: hidden;
}
.gloss-sheen::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(
    60deg,
    rgba(255, 255, 255, 0) 20%,
    rgba(255, 255, 255, 0.4) 50%,
    rgba(255, 255, 255, 0) 80%
  );
  transform: rotate(25deg) translateY(-100%);
  transition: transform 0.8s ease-in-out;
  pointer-events: none;
}
.gloss-sheen:hover::after {
  transform: rotate(25deg) translateY(100%);
}

/* Interactive NFC Phone Tap Ripple Animation */
.tap-ripple-container {
  position: relative;
}
.tap-ripple-wave {
  position: absolute;
  border-radius: 50%;
  border: 3px solid rgba(29, 158, 117, 0.8);
  animation: tapRippleAnim 1s cubic-bezier(0, 0.2, 0.8, 1) forwards;
  pointer-events: none;
}
@keyframes tapRippleAnim {
  0% {
    width: 0;
    height: 0;
    opacity: 1;
    transform: translate(-50%, -50%) scale(0.2);
  }
  100% {
    width: 260px;
    height: 260px;
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.6);
  }
}

/* Ambient Floating Glow Orbs */
.ambient-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
  opacity: 0.45;
  z-index: 0;
}
.ambient-coral {
  background: radial-gradient(circle, #F0997B 0%, rgba(240, 153, 123, 0) 70%);
}
.ambient-teal {
  background: radial-gradient(circle, #1D9E75 0%, rgba(29, 158, 117, 0) 70%);
}
.ambient-amber {
  background: radial-gradient(circle, #EF9F27 0%, rgba(239, 159, 39, 0) 70%);
}

/* Subtle Animated Grid Background */
.mesh-grid-bg {
  background-size: 32px 32px;
  background-image: 
    linear-gradient(to right, rgba(226, 232, 240, 0.6) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(226, 232, 240, 0.6) 1px, transparent 1px);
}

/* Floating Badges Animation */
@keyframes floatSlow {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}
.float-slow {
  animation: floatSlow 4s ease-in-out infinite;
}
.float-slow-delayed {
  animation: floatSlow 4.5s ease-in-out infinite 1.5s;
}

/* Premium Auth Showcase & Split Layout */
.auth-wrapper {
  min-height: 100vh;
  display: flex;
  background-color: #F8FAFC;
}
.auth-side-showcase {
  background: linear-gradient(135deg, #0F172A 0%, #1E293B 50%, #0F172A 100%);
  position: relative;
  overflow: hidden;
  color: #FFFFFF;
}

/* Desktop Executive Profile Card Styles */
.desktop-preview-frame {
  background: linear-gradient(145deg, #FFFFFF 0%, #F8FAFC 100%);
  border: 1px solid #CBD5E1;
  box-shadow: 0 25px 50px -12px rgba(15, 23, 42, 0.12), 0 0 0 1px rgba(255, 255, 255, 0.8) inset;
}
.executive-nfc-badge {
  background: linear-gradient(135deg, #1E293B 0%, #0F172A 100%);
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.3);
}
