/* =========================================================
   PARSYU — EFFECTS, RESPONSIVENESS & ACCESSIBILITY
   Reuse these classes on every future page.
========================================================= */

/* ═══════════════════════════════════════════════════════════
   CUSTOM CURSOR
═══════════════════════════════════════════════════════════ */
.cursor{
  position:fixed;top:0;left:0;
  pointer-events:none;
  z-index:99999;
  mix-blend-mode:difference;
  will-change:transform;
}
.cursor-dot{
  width:6px;height:6px;border-radius:50%;
  background:#fff;
  transform:translate(-50%,-50%);
  transition:opacity .2s ease,transform .15s ease;
}
.cursor-ring{
  width:34px;height:34px;border-radius:50%;
  border:1.5px solid rgba(255,255,255,.75);
  transform:translate(-50%,-50%);
  transition:width .3s var(--ease),height .3s var(--ease),opacity .25s ease,background .3s ease,border-color .3s ease;
  will-change:width,height;
}
.cursor.hover .cursor-ring{
  width:66px;height:66px;
  background:rgba(255,255,255,.12);
  border-color:rgba(255,255,255,.9);
}
.cursor.hover .cursor-dot{opacity:0}
.cursor.down .cursor-ring{width:26px;height:26px;background:rgba(255,255,255,.35)}
body.is-touch .cursor{display:none}

/* ═══════════════════════════════════════════════════════════
   REVEAL
═══════════════════════════════════════════════════════════ */
.reveal{
  opacity:0;
  transform:translateY(34px);
  transition:opacity .9s var(--ease-out),transform .9s var(--ease-out);
}
.reveal.in{opacity:1;transform:none}

/* ═══════════════════════════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════════════════════════ */
@media (max-width:1080px){
  .tool-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
  .bento{grid-template-columns:repeat(2,minmax(0,1fr))}
  .card-feature{grid-column:span 2;grid-row:span 1;min-height:260px}
  .card-wide{grid-column:span 2}
  .footer-grid{grid-template-columns:1.6fr 1fr 1fr}
  .footer-col:last-child{display:none}
}

/* ═══════════════════════════════════════════════════════════
   MOBILE
═══════════════════════════════════════════════════════════ */
@media (max-width:900px){
  /* Hide scrollbar entirely on mobile */
  html{
    scrollbar-width:none;
    -ms-overflow-style:none;
    direction:ltr;
  }
  html::-webkit-scrollbar{
    width:0;
    height:0;
    display:none;
  }

  body{padding-top:var(--header-h-m)}
  body{cursor:auto}
  a,button,.card,.cat-card,.search-shell,.btn,.filter-btn,.cmd-item{cursor:auto}
  .cursor,.pointer-light{display:none}

  .container{width:min(calc(100% - 30px),var(--container))}

  /* ═══════════════════════════════════════════════════════
     FIXED HEADER (webview-safe)
  ═══════════════════════════════════════════════════════ */
  .site-header{
    position:fixed;
    top:0;left:0;right:0;
    width:100%;
    height:var(--header-h-m);
    z-index:9999;
    isolation:isolate;
    background:linear-gradient(180deg,#0F1420 0%,#0A0E18 100%);
    border-bottom:1px solid rgba(99,102,241,.24);
    box-shadow:
      inset 0 1px 0 rgba(255,255,255,.035),
      0 12px 34px -22px rgba(0,0,0,.95);
    backdrop-filter:none;
    -webkit-backdrop-filter:none;
    transform:translateZ(0);
    -webkit-transform:translateZ(0);
    will-change:transform;
    backface-visibility:hidden;
    -webkit-backface-visibility:hidden;
    transition:background .3s ease,border-color .3s ease,box-shadow .3s ease;
  }
  .site-header.scrolled{
    background:linear-gradient(180deg,#0C111C 0%,#070A12 100%);
    border-bottom-color:rgba(99,102,241,.42);
    box-shadow:
      inset 0 1px 0 rgba(255,255,255,.04),
      0 16px 44px -22px rgba(0,0,0,.98);
  }
  .site-header::after{
    content:"";
    position:absolute;
    left:6%;right:6%;bottom:-1px;
    height:1px;
    background:linear-gradient(
      90deg,
      transparent 0%,
      rgba(129,140,248,.7) 22%,
      rgba(34,211,238,.75) 50%,
      rgba(168,85,247,.7) 78%,
      transparent 100%
    );
    background-size:200% 100%;
    animation:headerAccent 7s ease-in-out infinite;
    pointer-events:none;
  }
  @keyframes headerAccent{
    0%,100%{background-position:0% 50%}
    50%{background-position:100% 50%}
  }

  .header-inner{
    min-height:var(--header-h-m);
    height:var(--header-h-m);
    gap:10px;
  }

  .brand{gap:9px}
  .brand-mark{
    width:36px;height:36px;
    font-size:16px;
    border-radius:11px;
    box-shadow:
      0 8px 22px -8px rgba(99,102,241,.85),
      0 0 0 1px rgba(255,255,255,.05);
  }
  .brand-name{font-size:14px;letter-spacing:.15em}
  .brand-tag{display:none}

  .main-nav{display:none}

  .header-right{
    margin-inline-start:auto;
    gap:8px;
  }

  .account-btn{
    width:40px;height:40px;
    padding:0;
    background:rgba(255,255,255,.055);
    border-color:rgba(255,255,255,.1);
    border-radius:11px;
  }
  .account-btn span:last-child{display:none}
  .status-dot{
    width:9px;height:9px;
    box-shadow:0 0 14px rgba(52,211,153,.95);
  }

  .menu-btn{
    display:inline-flex;
    width:40px;height:40px;
    background:rgba(255,255,255,.055);
    border-color:rgba(255,255,255,.1);
    border-radius:11px;
  }

  .account-pop{
    position:fixed;
    top:calc(var(--header-h-m) + 8px);
    left:14px;right:14px;width:auto;
    transform-origin:top center;
    border-radius:16px;
    background:rgba(11,14,24,.98);
    z-index:10001;
  }

  /* ═══════════════════════════════════════════════════════
     MOBILE MENU — full-screen drawer below header
  ═══════════════════════════════════════════════════════ */
  .mobile-menu{
    display:flex;
    position:fixed;
    top:var(--header-h-m);
    left:0;right:0;bottom:0;
    z-index:9998;
    flex-direction:column;
    background:
      radial-gradient(600px circle at 50% -100px, rgba(99,102,241,.12), transparent 60%),
      linear-gradient(180deg, #0A0D16 0%, #05060B 100%);
    overflow-y:auto;
    -webkit-overflow-scrolling:touch;
    opacity:0;
    visibility:hidden;
    transform:translateY(-16px);
    transition:
      opacity .35s var(--ease),
      visibility .35s var(--ease),
      transform .45s var(--ease);
    pointer-events:none;
  }
  .mobile-menu.open{
    opacity:1;
    visibility:visible;
    transform:translateY(0);
    pointer-events:auto;
  }

  .mobile-menu-inner{
    min-height:100%;
    display:flex;
    flex-direction:column;
    padding:22px 22px calc(30px + env(safe-area-inset-bottom));
    gap:0;
  }

  .mobile-menu-label{
    display:block;
    margin-bottom:14px;
    padding:0 4px;
    color:var(--text-3);
    font:600 10px var(--mono);
    letter-spacing:.14em;
    text-transform:uppercase;
  }

  .mobile-menu-links{
    display:flex;
    flex-direction:column;
    gap:8px;
  }

  .mobile-menu-link{
    position:relative;
    display:flex;
    align-items:center;
    gap:14px;
    padding:15px 16px;
    border:1px solid var(--line);
    border-radius:16px;
    background:linear-gradient(150deg, rgba(255,255,255,.03), rgba(255,255,255,.008));
    color:var(--text-2);
    font-size:15px;
    font-weight:600;
    overflow:hidden;
    isolation:isolate;
    opacity:0;
    transform:translateX(24px);
    transition:
      opacity .55s var(--ease-out),
      transform .55s var(--ease-out),
      border-color .3s ease,
      background .3s ease,
      color .3s ease;
  }
  .mobile-menu.open .mobile-menu-link{
    opacity:1;
    transform:translateX(0);
    transition-delay:calc(var(--i, 0) * 55ms + 100ms),
                    calc(var(--i, 0) * 55ms + 100ms),
                    0ms, 0ms, 0ms;
  }
  .mobile-menu-link::before{
    content:"";
    position:absolute;
    inset:0;
    z-index:-1;
    background:linear-gradient(120deg, rgba(99,102,241,.14), rgba(34,211,238,.06));
    opacity:0;
    transition:opacity .3s ease;
  }
  .mobile-menu-link:active,
  .mobile-menu-link:hover{
    color:var(--text);
    border-color:rgba(99,102,241,.42);
    transform:translateX(-4px);
  }
  .mobile-menu-link:active::before,
  .mobile-menu-link:hover::before{
    opacity:1;
  }

  .mml-icon{
    width:42px;height:42px;
    flex-shrink:0;
    display:grid;place-items:center;
    border-radius:12px;
    background:rgba(99,102,241,.12);
    border:1px solid rgba(99,102,241,.22);
    color:#A5B4FC;
    font:800 16px var(--mono);
    transition:transform .4s var(--ease-spring);
  }
  .mobile-menu-link:active .mml-icon,
  .mobile-menu-link:hover .mml-icon{
    transform:rotate(-8deg) scale(1.08);
  }

  .mml-text{flex:1}

  .mml-arrow{
    color:var(--text-3);
    font-size:16px;
    transition:all .3s var(--ease);
  }
  .mobile-menu-link:active .mml-arrow,
  .mobile-menu-link:hover .mml-arrow{
    color:#A5B4FC;
    transform:translateX(-6px);
  }

  /* Menu footer */
  .mobile-menu-foot{
    display:flex;
    flex-direction:column;
    gap:12px;
    margin-top:auto;
    padding-top:26px;
  }

  .mobile-premium-card{
    position:relative;
    display:flex;
    align-items:center;
    gap:14px;
    padding:16px;
    border:1px solid rgba(252,211,77,.28);
    border-radius:18px;
    background:
      radial-gradient(240px circle at 0% 0%, rgba(252,211,77,.16), transparent 60%),
      linear-gradient(150deg, rgba(255,255,255,.045), rgba(255,255,255,.012));
    overflow:hidden;
    transition:all .3s var(--ease);
    opacity:0;
    transform:translateY(16px);
  }
  .mobile-menu.open .mobile-premium-card{
    opacity:1;
    transform:translateY(0);
    transition:
      opacity .55s var(--ease-out) 350ms,
      transform .55s var(--ease-out) 350ms,
      border-color .3s ease,
      box-shadow .3s ease;
  }
  .mobile-premium-card:active,
  .mobile-premium-card:hover{
    border-color:rgba(252,211,77,.55);
    transform:translateY(-2px);
    box-shadow:0 20px 50px -20px rgba(252,211,77,.55);
  }

  .mpc-icon{
    width:46px;height:46px;
    flex-shrink:0;
    display:grid;place-items:center;
    border-radius:14px;
    background:var(--grad-gold);
    color:#241C04;
    font-size:19px;
    box-shadow:0 8px 22px -8px rgba(252,211,77,.85);
  }

  .mpc-copy{
    flex:1;
    min-width:0;
    display:flex;
    flex-direction:column;
    gap:3px;
  }
  .mpc-copy b{
    color:var(--gold);
    font-size:14.5px;
    font-weight:800;
  }
  .mpc-copy span{
    color:var(--text-3);
    font-size:11px;
  }

  .mpc-arrow{
    color:var(--gold);
    font-size:17px;
    opacity:.7;
    transition:all .3s var(--ease);
  }
  .mobile-premium-card:active .mpc-arrow,
  .mobile-premium-card:hover .mpc-arrow{
    opacity:1;
    transform:translateX(-6px);
  }

  .mobile-menu-actions{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:10px;
    opacity:0;
    transform:translateY(12px);
    transition:opacity .5s var(--ease-out) 450ms, transform .5s var(--ease-out) 450ms;
  }
  .mobile-menu.open .mobile-menu-actions{
    opacity:1;
    transform:translateY(0);
  }

  .mobile-action{
    display:flex;
    align-items:center;
    justify-content:center;
    padding:13px;
    border:1px solid var(--line);
    border-radius:13px;
    background:rgba(255,255,255,.02);
    color:var(--text-2);
    font-size:13px;
    font-weight:600;
    transition:all .25s ease;
  }
  .mobile-action:active,
  .mobile-action:hover{
    color:var(--text);
    border-color:rgba(99,102,241,.42);
    background:rgba(99,102,241,.1);
  }
  .mobile-action.primary{
    border-color:rgba(99,102,241,.42);
    background:linear-gradient(120deg, rgba(99,102,241,.22), rgba(34,211,238,.09));
    color:#E0E7FF;
    box-shadow:0 12px 30px -18px rgba(99,102,241,.9);
  }

  /* Hero */
  .hero{padding:64px 0 56px}
  .hero-float{display:none}
  .hero-title{font-size:clamp(40px,9.5vw,68px)}

  .card-feature{min-height:280px}

  .premium-box{padding:40px 34px;gap:26px}
  .premium-art{width:200px;height:200px}
  .core{inset:60px;font-size:34px}

  .about-grid{grid-template-columns:1fr;gap:28px}
  .footer-grid{grid-template-columns:1.6fr 1fr 1fr}
}

@media (max-width:720px){
  .section{padding:68px 0}

  .hero{padding:56px 0 48px}
  .hero-title{font-size:clamp(36px,10.5vw,52px);letter-spacing:-.04em}
  .hero-sub{font-size:13px;margin-top:20px}
  .search-shell{height:56px;border-radius:16px;padding:0 14px;gap:9px}
  .search-kbd{display:none}
  .hero-stats{width:100%;margin-top:26px}
  .hero-stat{min-width:0;flex:1;padding:12px 10px}

  .marquee{padding:22px 0}
  .marquee-group{gap:42px;padding-right:42px}
  .marquee-item{font-size:clamp(19px,4.6vw,28px);gap:12px}

  .section-head{flex-direction:column;align-items:flex-start;gap:12px}
  .section-head.center{display:block;text-align:center}

  .bento{grid-template-columns:1fr;gap:12px}
  .card-feature,.card-wide{grid-column:span 1}

  .cat-grid{grid-template-columns:1fr}
  .tool-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .dir-card{min-height:155px}

  .premium-box{
    min-height:auto;
    padding:32px 24px;
    flex-direction:column;
    align-items:flex-start;
    gap:30px;
  }
  .premium-art{
    position:absolute;
    width:220px;height:220px;
    right:-36px;bottom:-56px;
    opacity:.14;
  }
  [dir="rtl"] .premium-art{right:auto;left:-36px}
  .core{inset:68px;font-size:30px}

  .about-points{grid-template-columns:1fr 1fr}
  .footer-grid{grid-template-columns:1fr 1fr}
  .footer-brand{grid-column:1/-1}
  .footer-col:last-child{display:flex}
  .footer-bottom{flex-direction:column;align-items:flex-start;gap:8px}
}

@media (max-width:470px){
  .tool-grid{grid-template-columns:1fr}
  .dir-card{min-height:145px}
  .about-points{grid-template-columns:1fr}
  .hero-stat b{font-size:15px}
  .hero-stat span{font-size:9.5px}
  .footer-grid{grid-template-columns:1fr 1fr}
}

@media (prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  *,*::before,*::after{
    animation-duration:.001ms!important;
    animation-iteration-count:1!important;
    transition-duration:.001ms!important;
  }
  .pointer-light,.cursor,.bg-grain{display:none}
  .reveal,.reveal-words .word,.hero-title .word{opacity:1;transform:none}
  .marquee-track{animation:none}
  .mobile-menu-link,.mobile-premium-card,.mobile-menu-actions{
    opacity:1!important;transform:none!important;
  }
}
