.custom-cursor {
  cursor: none;
}

a, button, input, textarea, .clickable {
  cursor: pointer;
}

#theme-toggle {
  position: relative;
  overflow: hidden;
}

#theme-toggle::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, var(--color-primary-100), transparent 70%);
  opacity: 0;
  transition: opacity 0.5s ease;
}

#theme-toggle:hover::before {
  opacity: 0.5;
}

.mobile-nav {
  backdrop-filter: blur(10px);
}

.mobile-nav-link {
  position: relative;
  transition: var(--transition-all);
}

.mobile-nav-link::after {
  content: '';
  position: absolute;
  bottom: var(--space-3);
  left: 50%;
  width: 0;
  height: 2px;
  background-color: var(--color-primary-500);
  transform: translateX(-50%);
  transition: width 0.3s ease;
}

.mobile-nav-link:hover::after {
  width: 30px;
}

.project-card {
  position: relative;
  overflow: hidden;
}

.project-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 0;
  background-color: var(--color-primary-100);
  opacity: 0.1;
  transition: height 0.3s ease;
  z-index: 0;
}

.project-card:hover::before {
  height: 100%;
}

.project-info {
  position: relative;
  z-index: 1;
}

.form-group {
  position: relative;
}

.form-group input,
.form-group textarea {
  background-color: transparent;
  border: 1px solid var(--color-border);
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--color-primary-500);
  box-shadow: 0 0 0 3px var(--color-primary-100);
}

.button {
  position: relative;
  z-index: 1;
  overflow: hidden;
}

.button::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(to right, rgba(255, 255, 255, 0.13), rgba(255, 255, 255, 0));
  transform: skewX(-25deg);
  transition: left 0.5s ease;
  z-index: -1;
}

.button:hover::before {
  left: 100%;
}

.social-link {
  position: relative;
  overflow: hidden;
}

.social-link::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, var(--color-primary-100), transparent 70%);
  opacity: 0;
  transition: opacity 0.5s ease;
}

.social-link:hover::before {
  opacity: 0.5;
}

.highlight {
  position: relative;
  z-index: 1;
}

.highlight::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 0.3em;
  background-color: var(--color-primary-100);
  z-index: -1;
  transform-origin: bottom;
  transition: height 0.3s ease, background-color 0.3s ease;
}

.highlight:hover::before {
  height: 1em;
}

.image-container {
  overflow: hidden;
}

.image-container img {
  transition: transform 0.5s ease;
}

.image-container:hover img {
  transform: scale(1.05);
}

.stat-item {
  position: relative;
  overflow: hidden;
}

.stat-item::after {
  content: '';
  position: absolute;
  top: -100%;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.2), transparent);
  transform: skewY(10deg);
  transition: transform 0.5s ease;
}

.stat-item:hover::after {
  transform: skewY(10deg) translateY(200%);
}

.tool-item {
  transition: var(--transition-all);
  position: relative;
  overflow: hidden;
}

.tool-item span {
  position: relative;
  z-index: 2;
}

.tool-item::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--color-primary-50);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
  z-index: 1;
}

.tool-item:hover::after {
  transform: scaleX(1);
}

.header-scrolled {
  background-color: var(--color-bg-primary);
  box-shadow: var(--shadow-md);
}

.back-to-top {
  position: relative;
  font-weight: var(--font-medium);
}

.back-to-top svg {
  transition: transform 0.3s ease;
}

.back-to-top:hover svg {
  transform: translateY(-5px);
}

[data-theme="dark"] {
  --color-accent-100: rgba(236, 72, 153, 0.2);
  --color-primary-100: rgba(14, 165, 233, 0.2);
}

.filter-btn {
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.filter-btn::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 0;
  background-color: var(--color-primary-500);
  opacity: 0.1;
  transition: height 0.3s ease;
  z-index: -1;
}

.filter-btn:hover::after,
.filter-btn.active::after {
  height: 100%;
}

.section-bg-pattern {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0.03;
  z-index: -1;
  background-image: radial-gradient(var(--color-primary-900) 1px, transparent 1px);
  background-size: 20px 20px;
}

.contact-form button {
  overflow: hidden;
  position: relative;
}

.contact-form button::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 5px;
  height: 5px;
  background: rgba(255, 255, 255, 0.3);
  opacity: 0;
  border-radius: 100%;
  transform: scale(1, 1) translate(-50%);
  transform-origin: 50% 50%;
}

.contact-form button:hover::after {
  animation: buttonRipple 1s ease-out;
}

@keyframes buttonRipple {
  0% {
    transform: scale(0, 0);
    opacity: 0.5;
  }
  100% {
    transform: scale(20, 20);
    opacity: 0;
  }
}

.project-card .view-project {
  position: relative;
}

.project-card .view-project::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1px;
  background-color: var(--color-primary-500);
  transition: width 0.3s ease;
}

.project-card:hover .view-project::after {
  width: 100%;
}

.section-header {
  position: relative;
}

.section-header::after {
  content: '';
  position: absolute;
  bottom: -20px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background-color: var(--color-primary-500);
}

.skill-progress {
  transform-origin: left;
  transform: scaleX(0);
  transition: transform 1.5s cubic-bezier(0.17, 0.67, 0.83, 0.67);
}

.skill-progress.animate {
  transform: scaleX(1);
}

.footer-nav a {
  position: relative;
}

.footer-nav a::after {
  content: '';
  position: absolute;
  bottom: -3px;
  left: 0;
  width: 0;
  height: 1px;
  background-color: var(--color-primary-500);
  transition: width 0.3s ease;
}

.footer-nav a:hover::after {
  width: 100%;
}

::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: var(--color-bg-secondary);
}

::-webkit-scrollbar-thumb {
  background: var(--color-primary-200);
  border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--color-primary-300);
}

:focus {
  outline: 2px solid var(--color-primary-500);
  outline-offset: 2px;
}

:focus:not(:focus-visible) {
  outline: none;
}

:focus-visible {
  outline: 2px solid var(--color-primary-500);
  outline-offset: 2px;
}