@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@400;600;700;800;900&family=Fredoka:wght@400;500;600;700&display=swap');

:root {
  --pink: #ff6b9d;
  --orange: #ff8a47;
  --yellow: #ffc233;
  --mint: #2dd4a8;
  --sky: #38bdf8;
  --purple: #a78bfa;
  --lavender: #c4b5fd;
  --coral: #fb7185;
  --bg: #fffbf5;
  --card: #ffffff;
  --text: #1e293b;
  --muted: #64748b;
}

[x-cloak] { display: none !important; }

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

body {
  font-family: 'Nunito', sans-serif;
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
}

h1, h2, h3, h4, .font-display { font-family: 'Fredoka', sans-serif; }

/* Fun gradient backgrounds */
.bg-fun-gradient {
  background: linear-gradient(135deg, #fff1f2 0%, #fef3c7 25%, #ecfdf5 50%, #eff6ff 75%, #faf5ff 100%);
}
.bg-hero {
  background: linear-gradient(135deg, #fce7f3 0%, #fef9c3 30%, #d1fae5 60%, #dbeafe 100%);
  position: relative;
}

/* Floating shapes */
.shape {
  position: absolute;
  border-radius: 50%;
  opacity: 0.15;
  pointer-events: none;
  animation: floaty 6s ease-in-out infinite;
}
.shape-1 { width: 200px; height: 200px; background: var(--pink); top: 10%; left: 5%; animation-delay: 0s; }
.shape-2 { width: 150px; height: 150px; background: var(--yellow); top: 60%; right: 10%; animation-delay: 2s; }
.shape-3 { width: 100px; height: 100px; background: var(--sky); bottom: 15%; left: 20%; animation-delay: 4s; }
.shape-4 { width: 120px; height: 120px; background: var(--mint); top: 20%; right: 25%; animation-delay: 1s; border-radius: 30%; }

@keyframes floaty {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-20px) rotate(5deg); }
}

@keyframes bounce-soft {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

@keyframes wiggle {
  0%, 100% { transform: rotate(-3deg); }
  50% { transform: rotate(3deg); }
}

@keyframes pop-in {
  0% { transform: scale(0.8); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

.animate-bounce-soft { animation: bounce-soft 2s ease-in-out infinite; }
.animate-wiggle { animation: wiggle 3s ease-in-out infinite; }
.animate-pop { animation: pop-in 0.4s ease-out; }

/* Navbar */
.navbar {
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(12px);
  border-bottom: 2px solid #fce7f3;
  position: sticky;
  top: 0;
  z-index: 40;
}

/* Cards */
.card {
  background: white;
  border-radius: 24px;
  box-shadow: 0 4px 24px rgba(0,0,0,0.06);
  border: 2px solid #f1f5f9;
  transition: all 0.3s;
  overflow: hidden;
}
.card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 40px rgba(0,0,0,0.1);
  border-color: var(--pink);
}

.card-pink { border-color: #fce7f3; }
.card-pink:hover { border-color: var(--pink); }
.card-yellow { border-color: #fef3c7; }
.card-yellow:hover { border-color: var(--orange); }
.card-mint { border-color: #d1fae5; }
.card-mint:hover { border-color: var(--mint); }

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 14px;
  border-radius: 50px;
  font-size: 12px;
  font-weight: 700;
}
.badge-pink { background: #fce7f3; color: #be185d; }
.badge-orange { background: #ffedd5; color: #c2410c; }
.badge-mint { background: #d1fae5; color: #047857; }
.badge-sky { background: #dbeafe; color: #1d4ed8; }
.badge-purple { background: #ede9fe; color: #6d28d9; }
.badge-yellow { background: #fef3c7; color: #a16207; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 16px;
  font-weight: 800;
  font-size: 15px;
  border: none;
  cursor: pointer;
  transition: all 0.25s;
  text-decoration: none;
}
.btn-sm {
  padding: 8px 16px;
  font-size: 13px;
  border-radius: 12px;
}
.btn-xs {
  padding: 6px 12px;
  font-size: 12px;
  border-radius: 8px;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn-pink { background: linear-gradient(135deg, #ff6b9d, #f43f5e); color: white; box-shadow: 0 6px 20px rgba(244,63,94,0.3); }
.btn-pink:hover { box-shadow: 0 8px 30px rgba(244,63,94,0.4); }
.btn-orange { background: linear-gradient(135deg, #ff8a47, #f59e0b); color: white; box-shadow: 0 6px 20px rgba(245,158,11,0.3); }
.btn-mint { background: linear-gradient(135deg, #2dd4a8, #10b981); color: white; box-shadow: 0 6px 20px rgba(16,185,129,0.3); }
.btn-sky { background: linear-gradient(135deg, #38bdf8, #3b82f6); color: white; box-shadow: 0 6px 20px rgba(59,130,246,0.3); }
.btn-outline { background: white; color: var(--text); border: 2px solid #e2e8f0; }
.btn-outline:hover { border-color: var(--pink); color: var(--pink); }

/* Stats */
.stat-card {
  background: white;
  border-radius: 20px;
  padding: 24px;
  border: 2px solid #f1f5f9;
  position: relative;
  overflow: hidden;
}
.stat-card .stat-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  margin-bottom: 12px;
}

/* Step circles */
.step-circle {
  width: 56px;
  height: 56px;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 22px;
  font-family: 'Fredoka', sans-serif;
}

/* Tabs */
.tab-btn {
  padding: 10px 20px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all 0.2s;
  background: transparent;
  color: var(--muted);
}
.tab-btn.active {
  background: white;
  color: var(--pink);
  border-color: #fce7f3;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}

/* Table */
.fun-table { width: 100%; text-align: left; font-size: 14px; border-collapse: collapse; }
.fun-table th { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: 0.05em; padding: 12px 8px; border-bottom: 2px solid #f1f5f9; }
.fun-table td { padding: 14px 8px; border-bottom: 1px solid #f8fafc; }
.fun-table tr:hover { background: #fefce8; }

/* Input */
.fun-input {
  width: 100%;
  padding: 14px 16px;
  border: 2px solid #e2e8f0;
  border-radius: 14px;
  font-size: 14px;
  font-family: 'Nunito', sans-serif;
  transition: border-color 0.2s;
  outline: none;
  background: #fafafa;
}
.fun-input:focus { border-color: var(--pink); background: white; }
.fun-input::placeholder { color: #94a3b8; }

.fun-select {
  width: 100%;
  padding: 14px 16px;
  border: 2px solid #e2e8f0;
  border-radius: 14px;
  font-size: 14px;
  font-family: 'Nunito', sans-serif;
  background: #fafafa;
  outline: none;
  cursor: pointer;
}

/* Modal */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.3);
  backdrop-filter: blur(4px);
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}
.modal-box {
  background: white;
  border-radius: 28px;
  width: 100%;
  max-width: 480px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 24px 60px rgba(0,0,0,0.15);
}

/* Toast */
@keyframes toast-slide-in {
  0% { transform: translate(-50%, -40%) scale(0.95); opacity: 0; }
  100% { transform: translate(-50%, -50%) scale(1); opacity: 1; }
}

.toast {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 99999;
  background: white;
  border-radius: 24px;
  padding: 24px;
  width: calc(100% - 32px);
  max-width: 400px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.15);
  border: 2px solid #d1fae5;
  animation: toast-slide-in 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

/* Referral bar */
.ref-bar {
  background: linear-gradient(90deg, #fce7f3, #dbeafe, #d1fae5);
  padding: 10px 16px;
  text-align: center;
  font-size: 13px;
  font-weight: 700;
  position: sticky;
  top: 0;
  z-index: 50;
}

/* Footer */
.footer {
  background: linear-gradient(135deg, #fce7f3, #fef3c7, #d1fae5);
  padding: 48px 16px;
  text-align: center;
  margin-top: 64px;
  border-top: 2px solid #fce7f3;
}

/* Responsive grid utilities */
.grid-2 { display: grid; grid-template-columns: 1fr; gap: 24px; }
.grid-3 { display: grid; grid-template-columns: 1fr; gap: 24px; }
.grid-4 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.grid-sidebar { display: grid; grid-template-columns: 1fr; gap: 32px; }

/* Hero Button Group - responsive equal-width buttons */
.hero-btn-group {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 100%;
}
.hero-btn {
  width: 100%;
  justify-content: center;
}
@media (min-width: 480px) {
  .hero-btn-group {
    flex-direction: row;
    flex-wrap: wrap;
    width: auto;
  }
  .hero-btn {
    width: auto;
    flex: 1 1 auto;
    min-width: 160px;
  }
}

/* Mobile App Additions */
.mobile-bottom-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: white;
  border-top: 2px solid #fce7f3;
  box-shadow: 0 -10px 30px rgba(0,0,0,0.05);
  z-index: 100;
  padding-bottom: env(safe-area-inset-bottom);
}
.mobile-nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 12px 0;
  color: var(--muted);
  text-decoration: none;
  font-size: 10px;
  font-weight: 800;
  gap: 6px;
  text-transform: uppercase;
  transition: all 0.2s;
  background: transparent;
  border: none;
}
.mobile-nav-item i { font-size: 20px; transition: transform 0.2s; }
.mobile-nav-item.active { color: var(--pink); }
.mobile-nav-item.active i { transform: scale(1.15); }

@media (max-width: 767px) {
  .mobile-bottom-nav { display: flex; }
  .navbar .hidden-desktop { display: none !important; }
  body { padding-bottom: 70px; }
  .grid-4 { grid-template-columns: 1fr 1fr; }

  /* Fix hero section overflow on mobile */
  .bg-hero { padding: 40px 0 60px !important; overflow: hidden; }
  .bg-hero img.animate-bounce-soft {
    transform: none !important;
    border-radius: 20px !important;
    margin-top: 24px;
  }
  /* Hide floating badge to prevent overflow on mobile */
  .bg-hero [style*="position: absolute; bottom: -20px"] {
    display: none !important;
  }

  /* Container horizontal padding on mobile */
  .container { padding: 0 16px; }
}

@media (min-width: 768px) {
  .grid-2 { grid-template-columns: 1fr 1fr; }
  .grid-3 { grid-template-columns: 1fr 1fr 1fr; }
  .grid-4 { grid-template-columns: repeat(4, 1fr); }
  .grid-sidebar { grid-template-columns: 2fr 1fr; }
}

.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.text-center { text-align: center; }
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.gap-2 { gap: 8px; }
.gap-3 { gap: 12px; }
.gap-4 { gap: 16px; }
.gap-6 { gap: 24px; }
.flex-wrap { flex-wrap: wrap; }
.w-full { width: 100%; }
.font-mono { font-family: monospace; }
.hidden-mobile { display: none; }
@media (min-width: 768px) { .hidden-mobile { display: flex; } .hidden-desktop { display: none; } }

/* Badge Coral for Rejected States */
.badge-coral { background: #ffe4e6; color: #e11d48; }

/* Elegant Minimal Custom Scrollbars */
.custom-scrollbar::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
.custom-scrollbar::-webkit-scrollbar-track {
  background: #f8fafc;
  border-radius: 8px;
}
.custom-scrollbar::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 8px;
}
.custom-scrollbar::-webkit-scrollbar-thumb:hover {
  background: var(--pink);
}

/* --- High-Quality Light Admin Tabs (preview.html) --- */
.tab-light-btn {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}
.tab-light-btn:hover:not(.tab-light-wd-active):not(.tab-light-ord-active):not(.tab-light-prod-active) {
  background: #f8fafc;
  transform: translateY(-1px);
}

.tab-light-wd-active {
  background: linear-gradient(135deg, #ffedd5 0%, #ffd8a8 100%) !important;
  color: #ea580c !important;
  font-weight: 800 !important;
  box-shadow: 0 4px 14px rgba(249, 115, 22, 0.15);
  transform: scale(1.04) translateY(-1px);
  border: 1px solid #ffe8cc !important;
}
.tab-light-wd-active i {
  animation: rotate-slow 2.5s linear infinite;
  display: inline-block;
}

.tab-light-ord-active {
  background: linear-gradient(135deg, #e0f2fe 0%, #bee3f8 100%) !important;
  color: #0284c7 !important;
  font-weight: 800 !important;
  box-shadow: 0 4px 14px rgba(56, 189, 248, 0.15);
  transform: scale(1.04) translateY(-1px);
  border: 1px solid #e0f2fe !important;
}
.tab-light-ord-active i {
  animation: wiggle-gentle 1.2s ease-in-out infinite;
  display: inline-block;
}

.tab-light-prod-active {
  background: linear-gradient(135deg, #fce7f3 0%, #fbcfe8 100%) !important;
  color: #db2777 !important;
  font-weight: 800 !important;
  box-shadow: 0 4px 14px rgba(244, 63, 94, 0.15);
  transform: scale(1.04) translateY(-1px);
  border: 1px solid #fce7f3 !important;
}
.tab-light-prod-active i {
  animation: bounce-gentle 1.2s ease-in-out infinite;
  display: inline-block;
}


/* --- High-Quality Dark Admin Tabs (dashboard.blade.php) --- */
.tab-dark-btn {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}
.tab-dark-btn:hover:not(.tab-dark-wd-active):not(.tab-dark-ord-active):not(.tab-dark-prod-active) {
  background: rgba(255, 255, 255, 0.05);
  transform: translateY(-1px);
}

.tab-dark-wd-active {
  background: linear-gradient(135deg, #f97316, #ea580c) !important;
  color: #ffffff !important;
  font-weight: 800 !important;
  box-shadow: 0 6px 20px rgba(249, 115, 22, 0.4);
  transform: scale(1.04) translateY(-2px);
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
}
.tab-dark-wd-active i {
  animation: rotate-slow 2.5s linear infinite;
  display: inline-block;
}

.tab-dark-ord-active {
  background: linear-gradient(135deg, #0ea5e9, #0284c7) !important;
  color: #ffffff !important;
  font-weight: 800 !important;
  box-shadow: 0 6px 20px rgba(14, 165, 233, 0.4);
  transform: scale(1.04) translateY(-2px);
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
}
.tab-dark-ord-active i {
  animation: wiggle-gentle 1.2s ease-in-out infinite;
  display: inline-block;
}

.tab-dark-prod-active {
  background: linear-gradient(135deg, #ec4899, #db2777) !important;
  color: #ffffff !important;
  font-weight: 800 !important;
  box-shadow: 0 6px 20px rgba(236, 72, 153, 0.4);
  transform: scale(1.04) translateY(-2px);
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
}
.tab-dark-prod-active i {
  animation: bounce-gentle 1.2s ease-in-out infinite;
  display: inline-block;
}

/* Keyframes for Gentle Animations */
@keyframes rotate-slow {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

@keyframes bounce-gentle {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
}

@keyframes wiggle-gentle {
  0%, 100% { transform: rotate(0deg); }
  25% { transform: rotate(-8deg); }
  75% { transform: rotate(8deg); }
}

/* Toast Notification Styles */
@keyframes slide-in-up {
  0% { transform: translateY(50px) scale(0.9); opacity: 0; }
  100% { transform: translateY(0) scale(1); opacity: 1; }
}

.animate-slide-in {
  animation: slide-in-up 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.custom-toast {
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
