/* Custom CSS for Portfolio */

/* Font families */
.font-gothic {
  font-family: 'Gothic A1', sans-serif;
}

.font-montserrat {
  font-family: 'Montserrat', sans-serif;
}

.font-hind {
  font-family: 'Hind', sans-serif;
}

.font-brown {
  font-family: 'BrownStd', sans-serif;
}

.font-brandon {
  font-family: 'Brandon Grotesque', sans-serif;
}

.font-hina {
  font-family: 'Hina Mincho', serif;
}

/* Custom colors */
:root {
  --primary-blue: #3a41e4;
  --bg-light: #ececec;
  --bg-dark: #000000;
  --text-dark: #232323;
  --text-dark-alt: #231f20;
  --text-gray: #333333;
  --text-gray-light: #bababa;
}

/* Smooth scrolling */
html {
  scroll-behavior: smooth;
}

/* Custom line styling */
.divider-line {
  height: 1px;
  background-color: currentColor;
  opacity: 0.2;
}

/* Responsive improvements */
@media (max-width: 768px) {
  /* Better spacing on mobile */
  section {
    padding-top: 2rem;
    padding-bottom: 2rem;
  }
  
  /* Adjust navigation padding */
  nav {
    padding-top: 1rem;
    padding-bottom: 1rem;
  }
  
  /* Better image handling */
  img {
    max-width: 100%;
    height: auto;
  }
}

/* Ensure images are responsive */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Better text rendering */
body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  cursor: none; /* Hide default cursor */
}

/* Custom Cursor */
.custom-cursor {
  position: fixed;
  width: 20px;
  height: 20px;
  border: 2px solid #3a41e4;
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: width 0.2s ease, height 0.2s ease, border-color 0.2s ease, background-color 0.2s ease;
  background-color: rgba(58, 65, 228, 0.1);
}

.custom-cursor.cursor-white {
  border-color: white;
  background-color: rgba(255, 255, 255, 0.1);
}

.custom-cursor-dot {
  position: fixed;
  width: 4px;
  height: 4px;
  background-color: #3a41e4;
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: transform 0.1s ease, background-color 0.2s ease;
}

.custom-cursor-dot.cursor-white {
  background-color: white;
}

/* Cursor hover states */
body:has(a:hover) .custom-cursor,
body:has(button:hover) .custom-cursor,
body:has(.say-hi-button:hover) .custom-cursor {
  width: 40px;
  height: 40px;
  border-color: #3a41e4;
}

body:has(a:hover) .custom-cursor-dot,
body:has(button:hover) .custom-cursor-dot,
body:has(.say-hi-button:hover) .custom-cursor-dot {
  transform: translate(-50%, -50%) scale(1.5);
}

/* Fallback for users who prefer reduced motion or don't have JavaScript */
@media (prefers-reduced-motion: reduce) {
  body {
    cursor: auto;
  }
  
  .custom-cursor,
  .custom-cursor-dot {
    display: none;
  }
}

/* Scroll Animation Classes */
.scroll-animate {
  opacity: 0;
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.scroll-animate.fade-in {
  opacity: 0;
  transform: translateY(30px);
}

.scroll-animate.fade-in-left {
  opacity: 0;
  transform: translateY(30px);
}

.scroll-animate.fade-in-right {
  opacity: 0;
  transform: translateY(30px);
}

.scroll-animate.fade-in-up {
  opacity: 0;
  transform: translateY(30px);
}

.scroll-animate.fade-in-down {
  opacity: 0;
  transform: translateY(-30px);
}

.scroll-animate.scale-in {
  opacity: 0;
  transform: scale(0.95);
}

/* Animated state */
.scroll-animate.animated {
  opacity: 1;
  transform: translateY(0) translateX(0) scale(1);
}

/* Staggered animation delay */
.scroll-animate.stagger-1 { transition-delay: 0.1s; }
.scroll-animate.stagger-2 { transition-delay: 0.2s; }
.scroll-animate.stagger-3 { transition-delay: 0.3s; }
.scroll-animate.stagger-4 { transition-delay: 0.4s; }
.scroll-animate.stagger-5 { transition-delay: 0.5s; }
.scroll-animate.stagger-6 { transition-delay: 0.6s; }

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
  .scroll-animate {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* Say Hi Button Hover Effects */
.say-hi-button {
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.say-hi-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  background-color: #f8f8f8;
}

.say-hi-button:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

/* Waving Hand Animation */
.wave-hand {
  display: inline-block;
  transform-origin: 70% 70%;
}

.say-hi-button:hover .wave-hand {
  animation: wave 0.5s ease-in-out 3;
}

@keyframes wave {
  0%, 100% {
    transform: rotate(0deg);
  }
  25% {
    transform: rotate(20deg);
  }
  75% {
    transform: rotate(-20deg);
  }
}

/* Text Link Animations */
a[href]:not(.say-hi-button):not(.say-hi-button *):not(footer a) {
  transition: text-decoration-color 0.3s ease, text-decoration-thickness 0.3s ease;
  display: inline;
  line-height: inherit;
  vertical-align: baseline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
  opacity: 1 !important;
  color: inherit;
}

/* Footer links should remain block */
footer a[href] {
  display: block;
}

/* Links without underline class - no underline by default */
a[href]:not(.say-hi-button):not(.say-hi-button *):not(footer a):not(.underline) {
  text-decoration: none;
}

/* Links without underline class - show underline on hover */
a[href]:not(.say-hi-button):not(.say-hi-button *):not(footer a):not(.underline):hover {
  text-decoration: underline;
  text-decoration-color: currentColor;
  text-decoration-thickness: 1px;
}

/* Links with underline class - always underlined */
a[href]:not(.say-hi-button):not(.say-hi-button *):not(footer a).underline {
  text-decoration: underline;
  text-decoration-color: currentColor;
  text-decoration-thickness: 1px;
}

/* Links with underline and hover:no-underline - remove underline on hover with animation */
a[href]:not(.say-hi-button):not(.say-hi-button *):not(footer a).underline.hover\:no-underline {
  text-decoration: underline;
  text-decoration-color: currentColor;
  text-decoration-thickness: 1px;
}

a[href]:not(.say-hi-button):not(.say-hi-button *):not(footer a).underline.hover\:no-underline:hover {
  text-decoration: none;
}

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
  .wave-hand {
    animation: none;
  }
  
  .say-hi-button:hover {
    transform: none;
  }
  
  a[href]::after {
    transition: none;
  }
}

