/* Global Styles */
:root {
  --primary: #635bff;
  --primary-dark: #4c46cc;
  --secondary: #00d4ff;
  --dark: #0a2540;
  --light: #f6f9fc;
  --white: #ffffff;
  --gray: #adb5bd;
  --success: #32D583;
}

body {
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--dark);
  line-height: 1.6;
  background: var(--light);
  overflow-x: hidden;
  padding-top: 56px; /* This needs to be adjusted */
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1rem;
  color: var(--dark);
}

/* Navbar Styles */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    padding: 0.75rem 0;
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    z-index: 1030;
}
/* Logo Styles */
.navbar-brand {
    font-size: 1.6rem;
    transition: transform 0.3s ease;
}
/* Increase shadow intensity for better visibility */
.navbar-brand .fw-bold,
.navbar-brand .fw-normal {
    text-shadow: 0 2px 15px rgba(0,0,0,0.25);  /* Increased shadow intensity */
}
.gradient-text {
    background: linear-gradient(
        137.48deg,
        #ffdb3b 10%,
        #fe53bb 45%,
        #8f51ea 67%,
        #0044ff 87%
    );
    background-size: 300% 300%;
    animation: gradient_301 5s ease infinite;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
    font-weight: 600;
    margin-left: 2px;
    filter: drop-shadow(0 2px 10px rgba(99,91,255,0.35));  /* Increased shadow opacity */
}
/* Add hover effect for the entire logo */
.navbar-brand:hover {
    transform: translateY(-2px);
}
/* Add hover effect specifically for the gradient text */
.navbar-brand:hover .gradient-text {
    animation: gradient_301 2s ease infinite;  /* Speed up animation on hover */
    filter: drop-shadow(0 4px 12px rgba(99,91,255,0.5));  /* Enhance shadow on hover */
}
/* Add hover effect for the regular text */
.navbar-brand:hover .fw-bold,
.navbar-brand:hover .fw-normal {
    text-shadow: 0 4px 20px rgba(0,0,0,0.35);  /* Enhanced shadow on hover */
}
/* Optional: Add a subtle scale effect to the logo image */
.navbar-brand:hover img {
    transform: scale(1.05);
    transition: transform 0.3s ease;
}

.navbar .nav-link {
    color: var(--dark) !important;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.navbar .nav-link:hover {
    opacity: 1;
}

.navbar .btn-primary {
  background: var(--primary);
  border: none;
  padding: 0.5rem 1.25rem;
  border-radius: 50px;
  color: white;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Hero Section */
.hero-section {
    position: relative;
    padding: 2.75rem 0 10rem;
    background: linear-gradient(-45deg, #635bff, #00d4ff);
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.1'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.hero-title {
    font-size: 4.5rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    line-height: 1.1;
    background: linear-gradient(to right, #fff, rgba(255,255,255,0.9));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 2px 30px rgba(0,0,0,0.15);
}

.hero-subtitle {
    font-size: 1.25rem;
    color: rgba(255,255,255,0.9);
    text-shadow: 0 1px 10px rgba(0,0,0,0.1);
}

.no-card-required {
    color: #fff;
    font-weight: 500;
    background: rgba(255,255,255,0.2);
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.875rem;
}

.hero-title .subtitle {
    font-size: 3.5rem;
    display: block;
    margin-top: 0.5rem;
}

@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Process Section */
.steps-section {
    position: relative;
    padding: 2rem 0;
    background: #fff;
}

.step-card {
    background: #fff;
    border-radius: 1rem;
    padding: 2.5rem;
    height: 100%;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 
        0 1px 1px rgba(0,0,0,0.08), 
        0 2px 2px rgba(0,0,0,0.08), 
        0 4px 4px rgba(0,0,0,0.08), 
        0 8px 8px rgba(0,0,0,0.08);
}

.step-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 32px rgba(99,91,255,0.15);
}

.step-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 1.5rem;
    color: var(--primary);
    animation: float 6s ease-in-out infinite;
}

.step-title {
    color: var(--dark);
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.step-description {
    color: var(--gray);
    font-size: 1rem;
    line-height: 1.6;
}

/* Testimonials Section */
.testimonials-section {
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
  padding: 6rem 0;
  color: var(--white);
  position: relative;
}

.testimonial-card {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border-radius: 1rem;
  padding: 2rem;
  height: 100%;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.stat-number {
    font-size: 3.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, #fff 0%, rgba(255, 255, 255, 0.95) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 2px 20px rgba(0,0,0,0.1);
    margin-bottom: 0.5rem;
}

.stat-description {
    color: rgba(255, 255, 255, 0.95);
    font-size: 1rem;
    font-weight: 500;
}

/* Pricing Section */
.pricing-section {
    padding: 6rem 0;
    background: var(--white);
}

.pricing-card {
    background: var(--white);
    border-radius: 1rem;
    padding: 2rem;
    height: 100%;
    transition: transform 0.3s ease;
    position: relative;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    border: 1px solid rgba(0,0,0,0.1);
}

.pricing-card.featured {
    border: 2px solid var(--primary);
    animation: borderGlow 2s ease-in-out infinite;
}

.pricing-header {
    color: var(--dark); /* Changed from gradient to dark color */
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.pricing-price {
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--primary); /* Changed from dark to primary */
    margin: 1rem 0;
    text-shadow: 0 2px 10px rgba(99,91,255,0.15);
    text-align: center;
}

.pricing-subtitle {
    font-size: 1.1rem;
    color: var(--gray);
    margin-bottom: 1.5rem;
}

.pricing-card li {
    font-size: 1.1rem;
    line-height: 1.6;
    color: var(--dark);
}

.pricing-card.featured::before {
    content: 'Popular';
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary);
    color: white;
    padding: 0.25rem 1rem;
    border-radius: 1rem;
    font-size: 0.875rem;
}

/* Custom button styles */
.sparkle-button {
  background: var(--primary);
  border: none;
  padding: 0.75rem 1.75rem;
  border-radius: 50px;
  color: white;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  position: relative;
  overflow: hidden;
}

.sparkle-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(99,91,255,0.3);
}

.sparkle-button svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

/* Shape divider */
.shape-divider {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  overflow: hidden;
  line-height: 0;
}

.shape-divider svg {
  position: relative;
  display: block;
  width: calc(100% + 1.3px);
  height: 80px;
}

.shape-divider .shape-fill {
  fill: var(--white);
}

/* Footer styles */
.footer-section {
  background: var(--dark);
  padding: 6rem 0;
  color: var(--gray);
}

.footer-section h5 {
  color: var(--white);
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
}

.footer-section a {
  color: var(--gray);
  transition: color 0.3s ease;
  text-decoration: none;
}

.footer-section a:hover {
  color: var(--white);
}

/* Animation keyframes */
@keyframes float {
  0% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
  100% { transform: translateY(0px); }
}

@keyframes borderGlow {
    0% { 
        box-shadow: 0 0 5px rgba(99,91,255,0.2);
        transform: scale(1.05);
    }
    50% { 
        box-shadow: 0 0 20px rgba(99,91,255,0.4);
        transform: scale(1.053);
    }
    100% { 
        box-shadow: 0 0 5px rgba(99,91,255,0.2);
        transform: scale(1.05);
    }
}

/* Features badges */
.features-badges .badge {
  font-weight: 500;
  padding: 0.5rem 1rem;
  margin: 0.25rem;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Auth Modal Styles - Updated to Light Theme */
.modal-content {
    background: var(--white) !important;
    border: 1px solid rgba(0,0,0,0.1);
    border-radius: 1rem;
}

.modal-header {
    border-bottom: none;
}

.modal-header .modal-title {
    color: var(--dark);
    font-weight: 600;
}

.btn-close {
    opacity: 0.5;
}

.modal .input-group {
    position: relative;
    width: 100%;
}

.modal .input {
    border: solid 1.5px var(--gray);
    border-radius: 1rem;
    background: var(--white);
    padding: 1rem;
    font-size: 1rem;
    color: var(--dark);
    transition: all 150ms cubic-bezier(0.4,0,0.2,1);
    width: 100%;
}

.modal .user-label {
    position: absolute;
    left: 15px;
    color: var(--gray);
    pointer-events: none;
    transform: translateY(1rem);
    transition: 150ms cubic-bezier(0.4,0,0.2,1);
}

.modal .input:focus,
.modal .input:valid {
    outline: none;
    border: 1.5px solid var(--primary);
}

.modal .input:focus ~ .user-label,
.modal .input:valid ~ .user-label {
    transform: translateY(-50%) scale(0.8);
    background-color: var(--white);
    padding: 0 .2em;
    color: var(--primary);
}

/* Dashboard & Other Pages Styles */
.main-content {
    padding-top: 2rem;
    margin-top: 1rem; /* Add space between navbar and content */
}
/* Dashboard & Other Pages Styles */
.dashboard-section {
    padding-top: 3rem;
}

.card {
    border-radius: 1rem;
    border: 1px solid rgba(0,0,0,0.1);
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    margin-bottom: 1.5rem;
}
.card-body {
    padding: 1.5rem;
}

.card .btn-primary {
    display: inline-block;
    width: auto;
    min-width: 200px;
    margin: 0 auto;
}

/* Container padding for smaller screens */
@media (max-width: 768px) {
    .container {
        padding-left: 1.5rem;
        padding-right: 1.5rem;
    }
}

/* Table responsive fixes */
.table-responsive {
    border-radius: 0.5rem;
    overflow: hidden;
}
.table {
    margin-bottom: 0;
}

.content-card {
    background: var(--white);
    border-radius: 1rem;
    padding: 2rem;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(0,0,0,0.1);
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.content-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 32px rgba(99,91,255,0.15);
}

/* Form Controls */
.form-control {
    border-radius: 0.75rem;
    border: 1.5px solid var(--gray);
    padding: 0.75rem 1rem;
    transition: all 0.3s ease;
}

.form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.2rem rgba(99,91,255,0.25);
}

/* Alert Styles */
.alert {
    border-radius: 1rem;
    border: none;
    padding: 1rem 1.5rem;
}

.alert-info {
    background: rgba(99,91,255,0.1);
    color: var(--primary);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .pricing-card.featured {
        transform: scale(1);
    }

    body {
        padding-top: 62px;
    }
}

.fixed-try-free {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 1040;
}

.chart-container {
    position: relative;
    width: 300px !important;
    height: 300px !important;
    margin: auto;
}
.match-score-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}
.match-percentage {
    font-size: 2.0rem;
    font-weight: bold;
    color: var(--success);
    text-shadow: 0 0 10px rgba(25, 135, 84, 0.4);
    animation: glow 1.5s ease-in-out infinite alternate;
}
@keyframes glow {
    from {
        text-shadow: 0 0 5px rgba(25, 135, 84, 0.4);
    }
    to {
        text-shadow: 0 0 10px rgba(25, 135, 84, 0.8);
    }
}
.action-buttons {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.btn .loading-text, 
.btn .default-text {
    display: flex;
    align-items: center;
    justify-content: center;
}
.btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}
.delete-button {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    background-color: rgb(20, 20, 20);
    border: none;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0px 0px 20px rgba(0, 0, 0, 0.164);
    cursor: pointer;
    transition-duration: .3s;
    overflow: hidden;
    position: absolute;
    right: 2.5rem; /* Increased this value to move button more to the left */
    top: 50%;
    transform: translateY(-50%);
}
.delete-button .svgIcon {
    width: 12px;
    transition-duration: .3s;
}
.delete-button .svgIcon path {
    fill: white;
}

/* Add a wrapper div for the delete button to maintain spacing */
td.delete-button-cell {
    position: relative;
    width: 90px; /* Set this to the width of the expanded button */
    padding-right: 3rem !important;
}
.delete-button:hover {
    width: 90px;
    border-radius: 50px;
    transform: translateY(-50%) translateX(27.5px); /* Half the difference between expanded and original width */
    background-color: rgb(255, 69, 69);
    align-items: center;
}
.delete-button:hover .svgIcon {
    width: 30px;
    transition-duration: .3s;
    transform: translateY(60%);
}
.delete-button::before {
    position: absolute;
    top: 25%;
    left: 50%;
    transform: translate(-50%, -50%);
    content: "Delete";
    color: white;
    transition-duration: .3s;
    font-size: 2px;
    opacity: 0;
}
.delete-button:hover::before {
    font-size: 13px;
    opacity: 1;
}
.btn-primary.btn-sm {
    min-width: auto !important; /* Override any existing min-width */
    width: fit-content;
    padding: 0.25rem 0.75rem;
}
.table a {
    color: var(--dark);
    transition: color 0.2s ease;
}
.table a:hover {
    color: var(--primary);
}
.privacy-policy {
    padding: 2rem 0;
}
.privacy-policy h1 {
    margin-bottom: 2rem;
}
.privacy-policy h2 {
    margin-top: 2rem;
    margin-bottom: 1rem;
}
.privacy-policy ul {
    margin-bottom: 1.5rem;
}
/* Adding new animated button styles */
.btn-try-free {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 13rem;
  overflow: hidden;
  height: 3rem;
  background-size: 300% 300%;
  cursor: pointer;
  backdrop-filter: blur(1rem);
  border-radius: 5rem;
  transition: 0.5s;
  animation: gradient_301 5s ease infinite;
  border: double 4px transparent;
  background-image: linear-gradient(#212121, #212121),
    linear-gradient(
      137.48deg,
      #ffdb3b 10%,
      #fe53bb 45%,
      #8f51ea 67%,
      #0044ff 87%
    );
  background-origin: border-box;
  background-clip: content-box, border-box;
  position: relative;
}

.btn-try-free #container-stars {
  position: absolute;
  z-index: -1;
  width: 100%;
  height: 100%;
  overflow: hidden;
  transition: 0.5s;
  backdrop-filter: blur(1rem);
  border-radius: 5rem;
}

.btn-try-free strong {
  z-index: 2;
  font-family: inherit;
  font-size: 16px;  /* Increased from 12px */
  letter-spacing: 5px;
  color: #ffffff;
  text-shadow: 0 0 4px white;
}

.btn-try-free #glow {
  position: absolute;
  display: flex;
  width: 12rem;
}

.btn-try-free .circle {
  width: 100%;
  height: 30px;
  filter: blur(2rem);
  animation: pulse_3011 4s infinite;
  z-index: -1;
}

.btn-try-free .circle:nth-of-type(1) {
  background: rgba(254, 83, 186, 0.636);
}

.btn-try-free .circle:nth-of-type(2) {
  background: rgba(142, 81, 234, 0.704);
}

.btn-try-free:hover #container-stars {
  z-index: 1;
  background-color: #212121;
}

.btn-try-free:hover {
  transform: scale(1.1);
}

.btn-try-free:active {
  border: double 4px #fe53bb;
  background-origin: border-box;
  background-clip: content-box, border-box;
  animation: none;
}

.btn-try-free:active .circle {
  background: #fe53bb;
}

.btn-try-free #stars {
  position: relative;
  background: transparent;
  width: 200rem;
  height: 200rem;
}

.btn-try-free #stars::after {
  content: "";
  position: absolute;
  top: -10rem;
  left: -100rem;
  width: 100%;
  height: 100%;
  animation: animStarRotate 90s linear infinite;
}

.btn-try-free #stars::after {
  background-image: radial-gradient(#ffffff 1px, transparent 1%);
  background-size: 50px 50px;
}

.btn-try-free #stars::before {
  content: "";
  position: absolute;
  top: 0;
  left: -50%;
  width: 170%;
  height: 500%;
  animation: animStar 60s linear infinite;
}

.btn-try-free #stars::before {
  background-image: radial-gradient(#ffffff 1px, transparent 1%);
  background-size: 50px 50px;
  opacity: 0.5;
}

@keyframes animStar {
  from {
    transform: translateY(0);
  }

  to {
    transform: translateY(-135rem);
  }
}

@keyframes animStarRotate {
  from {
    transform: rotate(360deg);
  }

  to {
    transform: rotate(0);
  }
}

@keyframes gradient_301 {
  0% {
    background-position: 0% 50%;
  }

  50% {
    background-position: 100% 50%;
  }

  100% {
    background-position: 0% 50%;
  }
}

@keyframes pulse_3011 {
  0% {
    transform: scale(0.75);
    box-shadow: 0 0 0 0 rgba(0, 0, 0, 0.7);
  }

  70% {
    transform: scale(1);
    box-shadow: 0 0 0 10px rgba(0, 0, 0, 0);
  }

  100% {
    transform: scale(0.75);
    box-shadow: 0 0 0 0 rgba(0, 0, 0, 0);
  }
}
.download-button {
  position: relative;
  border-width: 0;
  color: white;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  border-radius: 4px;
  z-index: 1;
  width: fit-content; /* Add this to remove extra space */
  padding: 0; /* Add this to remove padding */
}
.download-button .docs {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 40px;
  padding: 0 10px;
  border-radius: 4px;
  z-index: 1;
  background-color: #242a35;
  border: solid 1px #e8e8e82d;
  transition: all 0.5s cubic-bezier(0.77, 0, 0.175, 1);
  width: 100%; /* Add this to ensure proper width */
}
.download-button:hover {
  box-shadow:
    rgba(0, 0, 0, 0.25) 0px 54px 55px,
    rgba(0, 0, 0, 0.12) 0px -12px 30px,
    rgba(0, 0, 0, 0.12) 0px 4px 6px,
    rgba(0, 0, 0, 0.17) 0px 12px 13px,
    rgba(0, 0, 0, 0.09) 0px -3px 5px;
}
.download {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 100%; /* Change from 90% to 100% */
  margin: 0; /* Remove margin */
  z-index: -1;
  border-radius: 4px;
  transform: translateY(0%);
  background-color: #01e056;
  border: solid 1px #01e0572d;
  transition: all 0.5s cubic-bezier(0.77, 0, 0.175, 1);
  overflow: hidden; /* Add this to hide overflow */
}
.download-button:hover .download {
  transform: translateY(100%);
}
.download svg polyline,
.download svg line {
  animation: docs 1s infinite;
}
@keyframes docs {
  0% {
    transform: translateY(0%);
  }
  50% {
    transform: translateY(-15%);
  }
  100% {
    transform: translateY(0%);
  }
}
.sparkle-button {
  --active: 0;
  --bg: radial-gradient(
            40% 50% at center 100%,
            hsl(270 calc(var(--active) * 97%) 72% / var(--active)),
            transparent
        ),
        radial-gradient(
            80% 100% at center 120%,
            hsl(260 calc(var(--active) * 97%) 70% / var(--active)),
            transparent
        ),
        hsl(260 calc(var(--active) * 97%) calc((var(--active) * 44%) + 12%));
  background: var(--bg);
  justify-content: center;
  font-size: 1.2rem;
  font-weight: 500;
  border: 0;
  cursor: pointer;
  padding: 0.5em 1.25em;
  display: flex;
  align-items: center;
  gap: 0.25em;
  white-space: nowrap;
  border-radius: 100px;
  position: relative;
  box-shadow: 0 0 calc(var(--active) * 3em) calc(var(--active) * 1em) hsl(260 97% 61% / 0.75),
        0 0em 0 0 hsl(260 calc(var(--active) * 97%) calc((var(--active) * 50%) + 30%)) inset,
        0 -0.05em 0 0 hsl(260 calc(var(--active) * 97%) calc(var(--active) * 60%)) inset;
  transition: box-shadow var(--transition), scale var(--transition), background var(--transition);
  scale: calc(1 + (var(--active) * 0.1));
  transition: .3s;
}

.sparkle-button:active {
  scale: 1;
  transition: .3s;
}

.sparkle path {
  color: hsl(0 0% calc((var(--active, 0) * 70%) + var(--base)));
  transform-box: fill-box;
  transform-origin: center;
  fill: currentColor;
  stroke: currentColor;
  animation-delay: calc((var(--transition) * 1.5) + (var(--delay) * 1s));
  animation-duration: 0.6s;
  transition: color var(--transition);
}

.sparkle-button:is(:hover, :focus-visible) path {
  animation-name: bounce;
}

@keyframes bounce {
  35%, 65% {
    scale: var(--scale);
  }
}

.sparkle path:nth-of-type(1) {
  --scale: 0.5;
  --delay: 0.1;
  --base: 40%;
}

.sparkle path:nth-of-type(2) {
  --scale: 1.5;
  --delay: 0.2;
  --base: 20%;
}

.sparkle path:nth-of-type(3) {
  --scale: 2.5;
  --delay: 0.35;
  --base: 30%;
}

.sparkle-button:before {
  content: "";
  position: absolute;
  inset: -0.2em;
  z-index: -1;
  border: 0.25em solid hsl(260 97% 50% / 0.5);
  border-radius: 100px;
  opacity: var(--active, 0);
  transition: opacity var(--transition);
}

.spark {
  position: absolute;
  inset: 0;
  border-radius: 100px;
  rotate: 0deg;
  overflow: hidden;
  mask: linear-gradient(white, transparent 50%);
  animation: flip calc(var(--spark) * 2) infinite steps(2, end);
}

@keyframes flip {
  to {
    rotate: 360deg;
  }
}

.spark:before {
  content: "";
  position: absolute;
  width: 200%;
  aspect-ratio: 1;
  top: 0%;
  left: 50%;
  z-index: -1;
  translate: -50% -15%;
  rotate: 0;
  transform: rotate(-90deg);
  opacity: calc((var(--active)) + 0.4);
  background: conic-gradient(
        from 0deg,
        transparent 0 340deg,
        white 360deg
    );
  transition: opacity var(--transition);
  animation: rotate var(--spark) linear infinite both;
}

.spark:after {
  content: "";
  position: absolute;
  inset: var(--cut);
  border-radius: 100px;
}

.backdrop {
  position: absolute;
  inset: var(--cut);
  background: var(--bg);
  border-radius: 100px;
  transition: background var(--transition);
}

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

@supports(selector(:has(:is(+ *)))) {
  body:has(button:is(:hover, :focus-visible)) {
    --active: 1;
    --play-state: running;
  }

  .bodydrop {
    display: none;
  }
}

.sparkle-button:is(:hover, :focus-visible) ~ :is(.bodydrop, .particle-pen) {
  --active: 1;
  --play-state: runnin;
}

.sparkle-button:is(:hover, :focus-visible) {
  --active: 1;
  --play-state: running;
}

.sp {
  position: relative;
}

.particle-pen {
  position: absolute;
  width: 200%;
  aspect-ratio: 1;
  top: 50%;
  left: 50%;
  translate: -50% -50%;
  -webkit-mask: radial-gradient(white, transparent 65%);
  z-index: -1;
  opacity: var(--active, 0);
  transition: opacity var(--transition);
}

.particle {
  fill: white;
  width: calc(var(--size, 0.25) * 1rem);
  aspect-ratio: 1;
  position: absolute;
  top: calc(var(--y) * 1%);
  left: calc(var(--x) * 1%);
  opacity: var(--alpha, 1);
  animation: float-out calc(var(--duration, 1) * 1s) calc(var(--delay) * -1s) infinite linear;
  transform-origin: var(--origin-x, 1000%) var(--origin-y, 1000%);
  z-index: -1;
  animation-play-state: var(--play-state, paused);
}

.particle path {
  fill: hsl(0 0% 90%);
  stroke: none;
}

.particle:nth-of-type(even) {
  animation-direction: reverse;
}

@keyframes float-out {
  to {
    rotate: 360deg;
  }
}

.text {
  translate: 2% -6%;
  letter-spacing: 0.01ch;
  background: linear-gradient(90deg, hsl(0 0% calc((var(--active) * 100%) + 65%)), hsl(0 0% calc((var(--active) * 100%) + 26%)));
  -webkit-background-clip: text;
  color: transparent;
  transition: background var(--transition);
}

.sparkle-button svg {
  inline-size: 1.25em;
  translate: -25% -5%;
}