/* =============================================================================
 * DashboardTour.css
 * -----------------------------------------------------------------------------
 * Light-theme product tour styles, themed in Coin Careers green.
 * ============================================================================= */

/* Root overlay */
.cc-tour {
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
  animation: cc-tour-overlay-in 0.5s ease forwards;
}

.cc-tour--exiting {
  animation: cc-tour-overlay-out 0.45s ease forwards;
  pointer-events: none !important;
}

.cc-tour--exiting * {
  pointer-events: none !important;
}

@keyframes cc-tour-overlay-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes cc-tour-overlay-out {
  from { opacity: 1; }
  to { opacity: 0; }
}

/* ============================================================================
   Welcome screen
   ============================================================================ */
.cc-tour-welcome-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(8, 12, 22, 0.7);
  pointer-events: auto;
}

.cc-tour-welcome-card {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 10002;
  pointer-events: auto;
  width: 400px;
  max-width: calc(100vw - 2rem);
  transform: translate(-50%, -50%);
  animation: cc-tour-welcome-in 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes cc-tour-welcome-in {
  from {
    opacity: 0;
    transform: translate(-50%, -46%);
  }
  to {
    opacity: 1;
    transform: translate(-50%, -50%);
  }
}

.cc-tour-welcome-inner {
  background: var(--white-color, #ffffff);
  border: 1px solid var(--color-gray-200, #e5e7eb);
  border-radius: 1rem;
  padding: 2.25rem 2rem;
  text-align: center;
  box-shadow:
    0 32px 80px -16px rgba(15, 23, 42, 0.35),
    0 0 0 1px rgba(15, 23, 42, 0.04),
    0 0 120px -30px rgba(99, 234, 113, 0.25);
  position: relative;
  overflow: hidden;
  font-family: "DM Sans", system-ui, -apple-system, sans-serif;
}

.cc-tour-welcome-inner::before {
  content: "";
  position: absolute;
  top: 0;
  left: 10%;
  right: 10%;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(99, 234, 113, 0.55),
    transparent
  );
}

.cc-tour-welcome-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 1.25rem;
  border-radius: 16px;
  background: rgba(99, 234, 113, 0.12);
  border: 1px solid rgba(99, 234, 113, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary-color-dark, #27b079);
}

.cc-tour-welcome-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-color-primary, #0f172a);
  letter-spacing: -0.04em;
  margin: 0 0 0.6rem;
  line-height: 1.15;
}

.cc-tour-welcome-text {
  font-size: 0.9rem;
  color: var(--text-color-secondary, #334155);
  line-height: 1.6;
  margin: 0 auto 1.5rem;
  max-width: 320px;
}

.cc-tour-welcome-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.65rem 1.5rem;
  border-radius: 12px;
  background: var(--primary-color, #63ea71);
  border: none;
  color: var(--black-color, #000);
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
}

.cc-tour-welcome-btn:hover {
  background: var(--primary-color-hover, #4fd85f);
  box-shadow: 0 8px 32px rgba(99, 234, 113, 0.45);
  transform: translateY(-1px);
}

.cc-tour-welcome-btn:active {
  transform: translateY(0);
}

.cc-tour-welcome-skip {
  display: block;
  margin: 1rem auto 0;
  padding: 0;
  font-size: 0.78rem;
  color: var(--text-color-muted, #6b7280);
  background: none;
  border: none;
  cursor: pointer;
  transition: color 0.15s ease;
  font-family: inherit;
}

.cc-tour-welcome-skip:hover {
  color: var(--text-color-secondary, #334155);
}

/* ============================================================================
   SVG mask + animated highlight border
   ============================================================================ */
.cc-tour-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: auto;
  overflow: visible;
}

.cc-tour-cutout,
.cc-tour-border {
  transition:
    x 0.45s cubic-bezier(0.4, 0, 0.2, 1),
    y 0.45s cubic-bezier(0.4, 0, 0.2, 1),
    width 0.45s cubic-bezier(0.4, 0, 0.2, 1),
    height 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

.cc-tour-border {
  animation: cc-tour-glow 2.5s ease-in-out infinite;
}

@keyframes cc-tour-glow {
  0%, 100% { stroke: rgba(99, 234, 113, 0.3); }
  50% { stroke: rgba(99, 234, 113, 0.7); }
}

/* ============================================================================
   Click-to-advance + pulse ring
   ============================================================================ */
.cc-tour-click-target {
  position: fixed;
  z-index: 10002;
  border-radius: 18px;
  cursor: pointer;
  pointer-events: auto;
}

.cc-tour-pulse {
  position: fixed;
  border-radius: 18px;
  pointer-events: none;
  z-index: 10000;
}

.cc-tour-pulse::before,
.cc-tour-pulse::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  border: 1.5px solid rgba(99, 234, 113, 0.45);
  opacity: 0;
  animation: cc-tour-sonar 2.8s ease-out infinite;
}

.cc-tour-pulse::after {
  animation-delay: 0.9s;
}

@keyframes cc-tour-sonar {
  0%   { inset: 0;     opacity: 0.6; }
  40%  { inset: -14px; opacity: 0; }
  100% { inset: -14px; opacity: 0; }
}

/* ============================================================================
   Tooltip
   ============================================================================ */
.cc-tour-tooltip {
  position: fixed;
  z-index: 10001;
  pointer-events: auto;
  width: 360px;
  font-family: "DM Sans", system-ui, -apple-system, sans-serif;
}

.cc-tour-tooltip-anim {
  animation: cc-tour-tip-in 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes cc-tour-tip-in {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

.cc-tour-tooltip-inner {
  background: var(--white-color, #ffffff);
  border: 1px solid var(--color-gray-200, #e5e7eb);
  border-radius: 1rem;
  padding: 0;
  box-shadow:
    0 24px 64px -12px rgba(15, 23, 42, 0.25),
    0 0 0 1px rgba(15, 23, 42, 0.03),
    0 0 80px -20px rgba(99, 234, 113, 0.25);
  position: relative;
  overflow: hidden;
}

.cc-tour-tooltip-inner::after {
  content: "";
  position: absolute;
  top: -40%;
  left: -20%;
  width: 140%;
  height: 80%;
  background: radial-gradient(
    ellipse at center,
    rgba(99, 234, 113, 0.08) 0%,
    transparent 60%
  );
  pointer-events: none;
}

/* Progress bar */
.cc-tour-progress-track {
  width: 100%;
  height: 3px;
  background: var(--color-gray-100, #f3f4f6);
  border-radius: 3px 3px 0 0;
  overflow: hidden;
  position: relative;
  z-index: 1;
}

.cc-tour-progress-fill {
  height: 100%;
  background: var(--primary-color, #63ea71);
  border-radius: inherit;
  transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 0 12px rgba(99, 234, 113, 0.5);
  position: relative;
}

.cc-tour-progress-fill::after {
  content: "";
  position: absolute;
  right: 0;
  top: -1px;
  width: 20px;
  height: 5px;
  background: rgba(99, 234, 113, 0.6);
  filter: blur(6px);
  border-radius: 50%;
}

/* Header */
.cc-tour-tooltip-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.85rem;
  padding: 1.25rem 1.5rem 0;
  position: relative;
  z-index: 1;
}

.cc-tour-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--primary-color-dark, #27b079);
  background: rgba(99, 234, 113, 0.12);
  border: 1px solid rgba(99, 234, 113, 0.3);
  padding: 0.3rem 0.7rem;
  border-radius: 100px;
}

.cc-tour-badge-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.cc-tour-close-btn {
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  color: var(--text-color-muted, #6b7280);
  background: var(--color-gray-50, #f9fafb);
  border: 1px solid var(--color-gray-200, #e5e7eb);
  cursor: pointer;
  transition: all 0.15s ease;
  font-family: inherit;
}

.cc-tour-close-btn:hover {
  color: var(--text-color-primary, #0f172a);
  background: var(--color-gray-100, #f3f4f6);
  border-color: var(--color-gray-300, #d1d5db);
}

/* Body */
.cc-tour-tooltip-title {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--text-color-primary, #0f172a);
  letter-spacing: -0.035em;
  margin: 0 0 0.5rem;
  line-height: 1.15;
  padding: 0 1.5rem;
  position: relative;
  z-index: 1;
}

.cc-tour-tooltip-content {
  font-size: 0.92rem;
  color: var(--text-color-secondary, #334155);
  line-height: 1.6;
  letter-spacing: -0.01em;
  margin: 0 0 1.25rem;
  padding: 0 1.5rem;
  position: relative;
  z-index: 1;
}

/* Footer */
.cc-tour-tooltip-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding: 0 1.5rem 1.25rem;
  position: relative;
  z-index: 1;
}

.cc-tour-nav-btns {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.cc-tour-prev-btn {
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: var(--color-gray-50, #f9fafb);
  border: 1px solid var(--color-gray-200, #e5e7eb);
  color: var(--text-color-muted, #6b7280);
  cursor: pointer;
  transition: all 0.15s ease;
  font-family: inherit;
}

.cc-tour-prev-btn:hover {
  background: var(--color-gray-100, #f3f4f6);
  color: var(--text-color-primary, #0f172a);
  border-color: var(--color-gray-300, #d1d5db);
}

.cc-tour-next-btn {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.5rem 1rem;
  border-radius: 10px;
  background: var(--primary-color, #63ea71);
  border: none;
  color: var(--black-color, #000);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
}

.cc-tour-next-btn:hover {
  background: var(--primary-color-hover, #4fd85f);
  box-shadow: 0 6px 24px rgba(99, 234, 113, 0.45);
  transform: translateY(-1px);
}

.cc-tour-next-btn:active {
  transform: translateY(0);
}

.cc-tour-skip-btn {
  display: block;
  width: 100%;
  text-align: center;
  margin-top: -0.4rem;
  padding: 0.7rem 1.5rem;
  border: none;
  border-top: 1px solid var(--color-gray-200, #e5e7eb);
  font-size: 0.76rem;
  color: var(--text-color-muted, #6b7280);
  background: none;
  cursor: pointer;
  transition: color 0.15s ease;
  letter-spacing: -0.01em;
  position: relative;
  z-index: 1;
  font-family: inherit;
}

.cc-tour-skip-btn:hover {
  color: var(--text-color-secondary, #334155);
}
