/* ============================================================
   Ahao Portfolio. Modern Micro-Animations & Interactivity
   ============================================================ */

@font-face {
  font-family: "Unbounded";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/unbounded-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Unbounded";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/unbounded-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

#art-main {
  position: relative;
  z-index: 1;
}

#ahao-stars {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

/* 1. Scroll Progress Indicator */
#ahao-scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0%;
  background: linear-gradient(90deg, #4da6ff, #9b51e0, #00d084);
  z-index: 99999;
  box-shadow: 0 0 10px rgba(77, 166, 255, 0.8), 0 0 20px rgba(155, 81, 224, 0.6);
  transition: width 0.1s ease-out;
  pointer-events: none;
}

/* 2. Scroll Reveal Animations (Fade-Up) */
.ahao-reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.ahao-reveal.ahao-revealed {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger delay helpers */
.ahao-delay-1 { transition-delay: 0.04s; }
.ahao-delay-2 { transition-delay: 0.08s; }
.ahao-delay-3 { transition-delay: 0.12s; }
.ahao-delay-4 { transition-delay: 0.16s; }
.ahao-delay-5 { transition-delay: 0.20s; }

/* 3. Enhanced Gallery Cards (Glow & Kinetic Physics) */
.ahao-gallery-card {
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.35s ease, filter 0.35s ease !important;
  will-change: transform, box-shadow;
}

.ahao-gallery-card:hover {
  transform: translateY(-6px) scale(1.02) !important;
}

.ahao-gallery-card a {
  position: relative !important;
  transition: box-shadow 0.4s ease, border-color 0.4s ease !important;
}

.ahao-gallery-card:hover a {
  box-shadow: 0 10px 30px rgba(77, 166, 255, 0.45), 0 0 18px rgba(155, 81, 224, 0.35) !important;
  border-color: rgba(77, 166, 255, 0.6) !important;
}

.ahao-gallery-card img {
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1), filter 0.4s ease !important;
}

.ahao-gallery-card:hover img {
  transform: scale(1.07) !important;
  filter: brightness(1.12) contrast(1.05) !important;
}

.ahao-gallery-card:active {
  transform: translateY(-2px) scale(0.98) !important;
  transition-duration: 0.1s !important;
}

.ahao-photo-id {
  transition: color 0.3s ease, transform 0.3s ease, letter-spacing 0.3s ease !important;
}

.ahao-gallery-card:hover .ahao-photo-id {
  color: #4da6ff !important;
  letter-spacing: 0.2em !important;
  transform: translateY(2px) !important;
}

/* 4. Interactive Hero, Features & SEO Blocks */
.ahao-hero-block,
.ahao-features-block,
.ahao-cta-block,
.seo-section {
  transition: box-shadow 0.4s ease, transform 0.4s ease, border-color 0.4s ease !important;
}

.ahao-hero-block:hover,
.ahao-features-block:hover,
.seo-section:hover {
  border-color: rgba(77, 166, 255, 0.3) !important;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), 0 0 15px rgba(77, 166, 255, 0.15) !important;
}

/* 5. Shimmer / Pulse Effects on Buttons */
.art-postcontent a[style*="background: #0088cc"],
.art-postcontent a[style*="background: #25D366"],
.ahao-cta-block a {
  position: relative;
  overflow: hidden;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s ease, filter 0.25s ease !important;
}

.art-postcontent a[style*="background: #0088cc"]:hover,
.art-postcontent a[style*="background: #25D366"]:hover,
.ahao-cta-block a:hover {
  transform: translateY(-3px) scale(1.04) !important;
  box-shadow: 0 8px 24px rgba(77, 166, 255, 0.4) !important;
  filter: brightness(1.15) !important;
}

.art-postcontent a[style*="background: #0088cc"]:active,
.art-postcontent a[style*="background: #25D366"]:active,
.ahao-cta-block a:active {
  transform: translateY(0) scale(0.98) !important;
}

/* 6. Navigation Menu. High Contrast Visible Hover Fix */
ul.art-hmenu a,
ul.art-hmenu li a,
.desktop ul.art-hmenu > li > a,
.desktop ul.art-hmenu > li:hover > a,
ul.art-hmenu > li > a:hover,
ul.art-hmenu > li.active > a,
ul.art-hmenu > li.active:hover > a {
  color: #ffffff !important;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9) !important;
  visibility: visible !important;
  opacity: 1 !important;
  transition: all 0.3s ease !important;
}

ul.art-hmenu a:hover,
ul.art-hmenu li:hover > a,
.desktop ul.art-hmenu > li:hover > a,
ul.art-hmenu > li > a:hover,
ul.art-hmenu > li > a.active:hover {
  color: #ffffff !important;
  background: linear-gradient(135deg, #00567A 0%, #0088cc 60%, #4da6ff 100%) !important;
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.9), 0 0 15px rgba(77, 166, 255, 0.8) !important;
  border-color: #4da6ff !important;
  box-shadow: 0 4px 15px rgba(77, 166, 255, 0.5) !important;
}

/* 7. Logo Hover Animation (Zoom + Rotation + Glow) */
#logo {
  display: inline-block;
  perspective: 1000px;
}

#logo img {
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1), filter 0.5s ease !important;
  transform-origin: center center;
  will-change: transform;
}

#logo:hover img,
#logo a:hover img {
  transform: scale(1.15) rotate(5deg) !important;
  filter: drop-shadow(0 0 12px rgba(77, 166, 255, 0.8)) drop-shadow(0 0 25px rgba(155, 81, 224, 0.6)) !important;
}

#logo:active img,
#logo a:active img {
  transform: scale(0.98) rotate(0deg) !important;
  transition-duration: 0.15s !important;
}

#logo img.ahao-logo-pulse {
  transition: none !important;
  animation: ahao-logo-pulse 1.8s ease-in-out;
}

#logo:hover img.ahao-logo-pulse,
#logo a:hover img.ahao-logo-pulse {
  animation: none;
}

@keyframes ahao-logo-pulse {
  0%,
  100% {
    transform: scale(1) rotate(0deg);
    filter: drop-shadow(0 0 0 transparent);
  }
  35% {
    transform: scale(1.1) rotate(0deg);
    filter: drop-shadow(0 0 10px rgba(77, 166, 255, 0.7)) drop-shadow(0 0 22px rgba(192, 132, 252, 0.45));
  }
  55% {
    transform: scale(1.02);
    filter: drop-shadow(0 0 6px rgba(77, 166, 255, 0.35));
  }
  75% {
    transform: scale(1.07);
    filter: drop-shadow(0 0 12px rgba(192, 132, 252, 0.4));
  }
}

@media (prefers-reduced-motion: reduce) {
  #logo img.ahao-logo-pulse {
    animation: none;
  }
}

/* 8. Scroll to Top Floating Button */
#ahao-scroll-top {
  position: fixed;
  bottom: 28px;
  right: 28px;
  width: 46px;
  height: 46px;
  padding: 0;
  margin: 0;
  border: 0;
  border-radius: 50%;
  appearance: none;
  -webkit-appearance: none;
  background: rgba(8, 10, 18, 0.72);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: #d7ecff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 99990;
  opacity: 0;
  transform: translateY(16px) scale(0.92);
  pointer-events: none;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.45);
  outline: none;
  transition: opacity 0.35s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
    background 0.25s ease,
    color 0.25s ease,
    box-shadow 0.25s ease;
}

#ahao-scroll-top.visible {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

#ahao-scroll-top-ring,
.ahao-scroll-top-ring {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
  pointer-events: none;
}

.ahao-scroll-top-ring-bg,
.ahao-scroll-top-ring-fg {
  fill: none;
  stroke-width: 1.6;
}

.ahao-scroll-top-ring-bg {
  stroke: rgba(255, 255, 255, 0.12);
}

.ahao-scroll-top-ring-fg {
  stroke: #4da6ff;
  stroke-linecap: round;
  filter: drop-shadow(0 0 4px rgba(77, 166, 255, 0.7));
  transition: stroke-dashoffset 0.12s linear;
}

.ahao-scroll-top-icon {
  position: relative;
  width: 18px;
  height: 18px;
  display: block;
}

#ahao-scroll-top:hover {
  background: rgba(0, 136, 204, 0.28);
  color: #ffffff;
  transform: translateY(-3px);
  box-shadow: 0 10px 28px rgba(77, 166, 255, 0.28), 0 0 18px rgba(77, 166, 255, 0.2);
}

#ahao-scroll-top:hover .ahao-scroll-top-ring-fg {
  stroke: #80c0ff;
}

#ahao-scroll-top:active {
  transform: translateY(0) scale(0.96);
  transition-duration: 0.1s;
}

#ahao-scroll-top:focus-visible {
  box-shadow: 0 0 0 2px #0b0d14, 0 0 0 4px #4da6ff;
}

/* 9. Display H1 */
h1.art-postheader,
.art-postheader.entry-title {
  position: relative;
  font-family: "Unbounded", "Open Sans", system-ui, sans-serif !important;
  font-size: clamp(17px, 2.4vw, 28px) !important;
  font-weight: 700 !important;
  line-height: 1.22 !important;
  color: #ffffff !important;
  text-transform: none !important;
  text-align: center !important;
  margin: 8px auto 32px auto !important;
  max-width: 920px !important;
  letter-spacing: 0.01em !important;
  padding: 6px 18px 28px !important;
  isolation: isolate;
  overflow: visible;
  background:
    radial-gradient(
      ellipse 78% 95% at 50% 46%,
      rgba(221, 190, 255, 0.24) 0%,
      rgba(192, 132, 252, 0.14) 36%,
      rgba(155, 81, 224, 0.06) 58%,
      transparent 74%
    ) !important;
  -webkit-text-fill-color: inherit;
  filter: none;
}

h1.art-postheader::before {
  content: "";
  display: block;
  width: 36px;
  height: 3px;
  margin: 0 auto 16px;
  border-radius: 99px;
  background: linear-gradient(90deg, #4da6ff, #9b51e0);
  box-shadow: 0 0 12px rgba(77, 166, 255, 0.6), 0 0 22px rgba(155, 81, 224, 0.32);
}

h1.art-postheader::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 8px;
  width: min(240px, 58%);
  height: 1px;
  transform: translateX(-50%);
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(77, 166, 255, 0.1) 18%,
    #4da6ff 50%,
    rgba(155, 81, 224, 0.63) 52%,
    #4da6ff 54%,
    rgba(77, 166, 255, 0.1) 82%,
    transparent 100%
  );
  box-shadow: 0 0 10px rgba(77, 166, 255, 0.32);
}

h1.art-postheader .ahao-h1-text {
  position: relative;
  z-index: 1;
  display: inline-block;
  max-width: 100%;
  background-image: linear-gradient(
    90deg,
    #ffffff 0%,
    #eaf4ff 18%,
    #7ec4ff 38%,
    #c084fc 58%,
    #4da6ff 78%,
    #ffffff 100%
  );
  background-size: 280% 100%;
  background-position: 0% 50%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 6px 20px rgba(77, 166, 255, 0.2));
  animation: ahao-h1-sheen 11s ease-in-out infinite;
}

h1.art-postheader .ahao-h1-text::before {
  content: "";
  position: absolute;
  z-index: -1;
  left: 50%;
  top: 48%;
  width: 130%;
  height: 170%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  background: radial-gradient(
    ellipse at center,
    rgba(232, 213, 255, 0.39) 0%,
    rgba(196, 132, 252, 0.27) 28%,
    rgba(155, 81, 224, 0.11) 52%,
    transparent 72%
  );
  filter: blur(26px);
  animation: ahao-h1-glow 7.5s ease-in-out infinite;
}

@keyframes ahao-h1-glow {
  0%,
  100% {
    opacity: 0.5;
    transform: translate(-50%, -50%) scale(0.96);
  }
  50% {
    opacity: 0.7;
    transform: translate(-50%, -50%) scale(1.08);
  }
}

@keyframes ahao-h1-sheen {
  0%,
  100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

@media (prefers-reduced-motion: reduce) {
  h1.art-postheader .ahao-h1-text {
    animation: none;
    background-position: 35% 50%;
  }
  h1.art-postheader .ahao-h1-text::before {
    animation: none;
    opacity: 0.6;
  }
}

@media (max-width: 600px) {
  #ahao-scroll-top {
    bottom: 18px;
    right: 16px;
    width: 42px;
    height: 42px;
  }
  h1.art-postheader,
  .art-postheader.entry-title {
    font-size: 15px !important;
    margin: 6px auto 24px auto !important;
    padding: 4px 10px 24px !important;
    letter-spacing: 0.005em !important;
  }
}




