/* ═══════════════════════════════════════════
   MILLICRAFT — Global Stylesheet
   ═══════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Press+Start+2P&family=Exo+2:ital,wght@0,400;0,600;0,700;0,800;0,900;1,700&family=Nunito:wght@300;400;500;600;700;800&display=swap');

:root {
  /* Colors */
  --green:        #3ddc84;
  --green-bright: #57ff9f;
  --green-dark:   #1a7a3f;
  --green-glow:   rgba(61,220,132,.35);
  --gold:         #f5c842;
  --gold-dark:    #c49a10;
  --gold-glow:    rgba(245,200,66,.3);
  --diamond:      #4fc3f7;
  --dirt:         #8b5e3c;
  --red:          #ff5555;

  --bg:           #060c08;
  --bg2:          #0a140c;
  --bg3:          #0e1c10;
  --surface:      rgba(255,255,255,.028);
  --surface2:     rgba(255,255,255,.05);
  --border:       rgba(61,220,132,.14);
  --border-hover: rgba(61,220,132,.4);

  --text:         #dff5e8;
  --text-dim:     #8aab95;
  --text-faint:   #3d6648;

  /* Fonts */
  --font-pixel:   'Press Start 2P', 'Exo 2', monospace;
  --font-title:   'Exo 2', 'Cinzel', sans-serif;
  --font-body:    'Nunito', sans-serif;

  /* Sizes */
  --nav-h:        68px;
  --radius:       3px;
}

/* ─── RESET ─── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
button { cursor: pointer; font-family: var(--font-body); }
img { display: block; max-width: 100%; }
ul { list-style: none; }

/* ─── SCROLLBAR ─── */
::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--green-dark); border-radius: 3px; }

/* ─── PIXEL GRID BACKGROUND ─── */
.pixel-grid {
  background-image:
    linear-gradient(rgba(61,220,132,.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(61,220,132,.03) 1px, transparent 1px);
  background-size: 48px 48px;
}

/* ─── NOISE TEXTURE ─── */
body::before {
  content: '';
  position: fixed; inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none; z-index: 0; opacity: .4;
}

/* ─── NAV ─── */
.nav {
  position: fixed; top: 0; left: 0; right: 0;
  height: var(--nav-h);
  z-index: 1000;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 3rem;
  background: rgba(6,12,8,.92);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--border);
}

.nav-logo {
  font-family: var(--font-pixel);
  font-size: .85rem;
  color: var(--green);
  letter-spacing: 2px;
  text-shadow: 0 0 18px var(--green-glow);
  white-space: nowrap;
}
.nav-logo span { color: var(--gold); }

.nav-links {
  display: flex; gap: 2.5rem;
}
.nav-links a {
  font-family: var(--font-body);
  font-size: .9rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--text-dim);
  transition: color .2s;
  position: relative;
}
.nav-links a::after {
  content: '';
  position: absolute; bottom: -5px; left: 0;
  width: 0; height: 2px;
  background: var(--green);
  transition: width .3s;
}
.nav-links a:hover,
.nav-links a.active { color: var(--green); }
.nav-links a:hover::after,
.nav-links a.active::after { width: 100%; }

.nav-cta {
  font-family: var(--font-title);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  background: var(--green-dark);
  color: #fff;
  border: none;
  padding: .65rem 1.5rem;
  transition: background .2s, transform .15s, box-shadow .2s;
  clip-path: polygon(6px 0%,100% 0%,calc(100% - 6px) 100%,0% 100%);
  white-space: nowrap;
}
.nav-cta:hover {
  background: var(--green);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px var(--green-glow);
}

.hamburger {
  display: none; background: none; border: none;
  color: var(--green); font-size: 1.5rem;
}

/* ─── SECTION BASE ─── */
.section { position: relative; z-index: 1; }
.container { max-width: 1120px; margin: 0 auto; padding: 0 2rem; }
.section-pad { padding: 7rem 0; }

.tag {
  display: inline-block;
  font-family: var(--font-title);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--gold);
  background: rgba(245,200,66,.08);
  border: 1px solid rgba(245,200,66,.25);
  padding: .45rem .9rem;
  margin-bottom: 1.2rem;
}
.section-title {
  font-family: var(--font-title);
  font-size: clamp(1.8rem, 4vw, 3.2rem);
  font-weight: 900;
  color: var(--text);
  line-height: 1.15;
  margin-bottom: 1rem;
  letter-spacing: .5px;
}
.section-title .accent { color: var(--green); }
.section-sub {
  font-size: 1.05rem;
  color: var(--text-dim);
  line-height: 1.8;
  max-width: 560px;
}

/* ─── BUTTONS ─── */
.btn {
  display: inline-flex; align-items: center; gap: .6rem;
  font-family: var(--font-title);
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 1rem 2rem;
  border: none;
  transition: transform .15s, box-shadow .2s, background .2s;
  clip-path: polygon(6px 0%,100% 0%,calc(100% - 6px) 100%,0% 100%);
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }
.btn-green {
  background: var(--green-dark);
  color: #fff;
  box-shadow: 0 4px 18px rgba(26,122,63,.4);
}
.btn-green:hover { background: var(--green); box-shadow: 0 8px 28px var(--green-glow); }
.btn-outline {
  background: transparent;
  color: var(--text-dim);
  border: 2px solid var(--border);
}
.btn-outline:hover { color: var(--green); border-color: var(--green); }
.btn-gold {
  background: var(--gold-dark);
  color: #000;
}
.btn-gold:hover { background: var(--gold); }

/* ─── CARD ─── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 2rem;
  position: relative;
  overflow: hidden;
  transition: border-color .3s, transform .3s, box-shadow .3s;
}
.card:hover {
  border-color: var(--border-hover);
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0,0,0,.4);
}
.card::before {
  content: '';
  position: absolute; top: 0; left: -100%; right: -100%; height: 1px;
  background: linear-gradient(90deg, transparent, var(--green), transparent);
  transition: left .4s, right .4s;
}
.card:hover::before { left: 0; right: 0; }

/* ─── FORM ELEMENTS ─── */
.form-label {
  display: block;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: .4rem;
}
.form-input {
  width: 100%;
  background: rgba(0,0,0,.5);
  border: 1px solid var(--border);
  color: var(--text);
  padding: .9rem 1.1rem;
  font-family: var(--font-body);
  font-size: 1rem;
  outline: none;
  border-radius: var(--radius);
  transition: border-color .2s, box-shadow .2s;
}
.form-input:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(61,220,132,.12);
}
.form-input::placeholder { color: var(--text-faint); }
.form-input.error { border-color: var(--red); }
.form-input.ok { border-color: var(--green); }

/* ─── TOAST ─── */
#toast {
  position: fixed; bottom: 2rem; left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--bg3);
  border: 1px solid var(--green);
  color: var(--green);
  font-family: var(--font-pixel);
  font-size: .5rem;
  letter-spacing: 1px;
  padding: .8rem 2rem;
  z-index: 9999;
  opacity: 0;
  transition: opacity .3s, transform .3s;
  clip-path: polygon(6px 0%,100% 0%,calc(100% - 6px) 100%,0% 100%);
  pointer-events: none;
}
#toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ─── REVEAL ANIMATION ─── */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity .7s cubic-bezier(.16,1,.3,1), transform .7s cubic-bezier(.16,1,.3,1);
}
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal-left  { opacity:0; transform:translateX(-28px); transition: opacity .7s cubic-bezier(.16,1,.3,1), transform .7s cubic-bezier(.16,1,.3,1); }
.reveal-right { opacity:0; transform:translateX(28px);  transition: opacity .7s cubic-bezier(.16,1,.3,1), transform .7s cubic-bezier(.16,1,.3,1); }
.reveal-left.visible, .reveal-right.visible { opacity:1; transform:translateX(0); }
.delay-1 { transition-delay: .1s !important; }
.delay-2 { transition-delay: .2s !important; }
.delay-3 { transition-delay: .3s !important; }
.delay-4 { transition-delay: .4s !important; }
.delay-5 { transition-delay: .5s !important; }

/* ─── FOOTER ─── */
.footer {
  position: relative; z-index: 1;
  background: var(--bg2);
  border-top: 1px solid var(--border);
  padding: 4rem 0 2.5rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}
.footer-logo {
  font-family: var(--font-pixel);
  font-size: .85rem;
  color: var(--green);
  text-shadow: 0 0 16px var(--green-glow);
  margin-bottom: 1rem;
  letter-spacing: 2px;
}
.footer-logo span { color: var(--gold); }
.footer-desc { color: var(--text-dim); font-size: .95rem; line-height: 1.7; max-width: 240px; }
.footer-col h4 {
  font-family: var(--font-pixel);
  font-size: .5rem;
  color: var(--gold);
  letter-spacing: 2px;
  margin-bottom: 1.2rem;
}
.footer-col ul li { margin-bottom: .7rem; }
.footer-col ul li a { color: var(--text-dim); font-size: .9rem; transition: color .2s; }
.footer-col ul li a:hover { color: var(--green); }
.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 2rem;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 1rem;
}
.footer-copy {
  font-family: var(--font-pixel);
  font-size: .45rem;
  color: var(--text-faint);
  letter-spacing: 1px;
}
.footer-social { display: flex; gap: 1rem; }
.footer-social a {
  width: 36px; height: 36px;
  border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem;
  color: var(--text-dim);
  transition: border-color .2s, color .2s;
  border-radius: var(--radius);
}
.footer-social a:hover { border-color: var(--green); color: var(--green); }

/* ─── MOBILE ─── */
@media (max-width: 900px) {
  .nav { padding: 0 1.2rem; gap: .5rem; }
  .nav-links { display: none; }
  .hamburger { display: flex; }
  .nav-cta { display: none; }
  .nav-links.open {
    display: flex; flex-direction: column;
    position: absolute; top: var(--nav-h); left: 0; right: 0;
    background: rgba(6,12,8,.97); padding: 1.5rem 1.5rem;
    border-bottom: 1px solid var(--border);
    gap: 1.2rem; z-index: 999;
  }
  .nav-links.open a { font-size: 1rem; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .section-pad { padding: 4.5rem 0; }
  .container { padding: 0 1.1rem; }
}
@media (max-width: 600px) {
  .nav { padding: 0 .85rem; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; text-align: center; }
  .section-pad { padding: 3rem 0; }
  .section-title { font-size: clamp(1.4rem, 6vw, 1.9rem) !important; }
  .section-sub { font-size: .93rem; }
  .btn { font-size: .8rem; padding: .8rem 1.3rem; }
  .card { padding: 1.4rem; }
  #toast {
    font-size: .7rem; padding: .7rem 1rem;
    width: 88vw; white-space: normal; text-align: center;
  }
  /* Cart drawer — full width on phones */
  .cart-drawer { width: 100vw !important; }
  .promo-row { flex-direction: column; }
  .promo-apply { width: 100%; }
}

/* ─── SHARED SCRIPT HELPERS ─── */

/* ═══════════════════════════════════════════
   MILLICRAFT — Enhanced Animations & Polish
   ═══════════════════════════════════════════ */

/* ─── NAV LOGO GLOW PULSE ─── */
.nav-logo {
  animation: logoGlowPulse 4s ease-in-out infinite;
}
@keyframes logoGlowPulse {
  0%,100% { text-shadow: 0 0 18px var(--green-glow); }
  50%      { text-shadow: 0 0 42px rgba(61,220,132,.75), 0 0 80px rgba(61,220,132,.22); }
}

/* ─── FLOAT ─── */
@keyframes floatY {
  0%,100% { transform: translateY(0px); }
  50%     { transform: translateY(-7px); }
}
.float-anim {
  animation: floatY 3.2s ease-in-out infinite;
  display: inline-block;
}

/* ─── TAG SHIMMER ─── */
.tag {
  position: relative;
  overflow: hidden;
}
.tag::after {
  content: '';
  position: absolute; top: 0; left: -120%;
  width: 60%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(245,200,66,.18), transparent);
  animation: tagShimmer 3.5s ease-in-out infinite;
  pointer-events: none;
}
@keyframes tagShimmer {
  0%     { left: -120%; }
  50%,100% { left: 180%; }
}

/* ─── IP BOX GLOW ─── */
.ip-box {
  transition: box-shadow .4s;
  animation: ipBoxGlow 3.5s ease-in-out infinite;
}
@keyframes ipBoxGlow {
  0%,100% { box-shadow: 0 0 0 rgba(61,220,132,0); }
  50%     { box-shadow: 0 0 22px rgba(61,220,132,.18), inset 0 0 18px rgba(61,220,132,.04); }
}

/* ─── IP ADDRESS TEXT GLOW ─── */
.ip-box-addr {
  animation: ipAddrPulse 2.5s ease-in-out infinite;
}
@keyframes ipAddrPulse {
  0%,100% { text-shadow: 0 0 12px var(--green); }
  50%     { text-shadow: 0 0 24px var(--green), 0 0 40px rgba(61,220,132,.35); }
}

/* ─── CTA BUTTON PULSE ─── */
.btn-green {
  animation: btnGreenPulse 3s ease-in-out infinite;
}
@keyframes btnGreenPulse {
  0%,100% { box-shadow: 0 4px 18px rgba(26,122,63,.4); }
  50%     { box-shadow: 0 6px 32px rgba(61,220,132,.55), 0 0 0 5px rgba(61,220,132,.09); }
}

/* ─── CARD SHINE SWEEP ─── */
.card {
  overflow: hidden;
}
.card::after {
  content: '';
  position: absolute; top: 0; left: -100%;
  width: 55%; height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,.045), transparent);
  transition: left .65s ease;
  pointer-events: none;
}
.card:hover::after { left: 155%; }

/* ─── MODE CARD ICONS FLOAT ─── */
.mode-icon {
  animation: floatY 3s ease-in-out infinite;
  display: inline-block;
}
.mode-card:nth-child(2) .mode-icon { animation-delay: .55s; }
.mode-card:nth-child(3) .mode-icon { animation-delay: 1.1s; }

/* ─── WHY CARD ICONS FLOAT ─── */
.why-icon {
  animation: floatY 4s ease-in-out infinite;
  display: inline-block;
}
.why-card:nth-child(2) .why-icon { animation-delay: .4s; }
.why-card:nth-child(3) .why-icon { animation-delay: .8s; }
.why-card:nth-child(4) .why-icon { animation-delay: 1.2s; }
.why-card:nth-child(5) .why-icon { animation-delay: 1.6s; }
.why-card:nth-child(6) .why-icon { animation-delay: 2s; }

/* ─── GRADIENT HEADING TEXT ─── */
.gradient-flow-text {
  background: linear-gradient(90deg, var(--green) 0%, #57ff9f 30%, var(--gold) 60%, var(--green) 100%);
  background-size: 300% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: gradientFlow 5s linear infinite;
}
@keyframes gradientFlow {
  0%   { background-position: 0% center; }
  100% { background-position: 300% center; }
}

/* ─── HERO TITLE ENTER ─── */
.hero-title .line2 {
  animation: heroLine2Glow 4s ease-in-out infinite;
}
@keyframes heroLine2Glow {
  0%,100% { text-shadow: 0 0 50px rgba(61,220,132,.45), 0 0 100px rgba(61,220,132,.15); }
  50%     { text-shadow: 0 0 70px rgba(61,220,132,.7),  0 0 130px rgba(61,220,132,.28); }
}

/* ─── RANK CARD SHINE ─── */
.rank-card {
  overflow: hidden;
}
.rank-card::after {
  content: '';
  position: absolute; top: 0; left: -100%;
  width: 55%; height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,.055), transparent);
  transition: left .7s ease;
  pointer-events: none;
}
.rank-card:hover::after { left: 155%; }

/* ─── RANK CARD ICON FLOAT ─── */
.rank-icon {
  animation: floatY 3.5s ease-in-out infinite;
  display: inline-block;
}
.rank-card:nth-child(2) .rank-icon { animation-delay: .4s; }
.rank-card:nth-child(3) .rank-icon { animation-delay: .8s; }
.rank-card:nth-child(4) .rank-icon { animation-delay: 1.2s; }

/* ─── STAT CARD REVEAL ─── */
.stat-card {
  animation: statFadeIn .6s ease both;
}
@keyframes statFadeIn {
  from { opacity: 0; transform: translateY(14px) scale(.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
.stat-card:nth-child(2) { animation-delay: .1s; }
.stat-card:nth-child(3) { animation-delay: .2s; }
.stat-card:nth-child(4) { animation-delay: .3s; }

/* ─── PROFILE AVATAR GLOW ─── */
.profile-avatar {
  animation: avatarGlow 4s ease-in-out infinite;
}
@keyframes avatarGlow {
  0%,100% { box-shadow: 0 0 0 rgba(61,220,132,0); }
  50%     { box-shadow: 0 0 20px rgba(61,220,132,.35), 0 0 40px rgba(61,220,132,.12); }
}

/* ─── REVEAL TRANSITION OVERRIDE ─── */
/* (main reveal definition is earlier in file) */

/* ─── SECTION TITLE WEIGHT ─── */
.section-title {
  font-weight: 900;
  letter-spacing: .5px;
}

/* ─── HERO KICKER ENHANCED ─── */
.hero-kicker {
  letter-spacing: 4px;
}

/* ─── FEAT VISUAL ICON FLOAT ─── */
.big-icon {
  animation: floatY 3.5s ease-in-out infinite;
  display: inline-block;
}

/* ─── SMALL FEATURE CARD ICON FLOAT ─── */
.fsm-icon {
  animation: floatY 3.8s ease-in-out infinite;
  display: inline-block;
}
.fsm-card:nth-child(2) .fsm-icon { animation-delay: .3s; }
.fsm-card:nth-child(3) .fsm-icon { animation-delay: .6s; }
.fsm-card:nth-child(4) .fsm-icon { animation-delay: .9s; }
.fsm-card:nth-child(5) .fsm-icon { animation-delay: 1.2s; }
.fsm-card:nth-child(6) .fsm-icon { animation-delay: 1.5s; }
.fsm-card:nth-child(7) .fsm-icon { animation-delay: 1.8s; }
.fsm-card:nth-child(8) .fsm-icon { animation-delay: 2.1s; }

/* ─── TIMELINE DOT PULSE ─── */
.update-date-col::after {
  animation: dotPulse 2.5s ease-in-out infinite;
}
@keyframes dotPulse {
  0%,100% { box-shadow: 0 0 10px var(--green-glow); }
  50%     { box-shadow: 0 0 18px rgba(61,220,132,.7), 0 0 30px rgba(61,220,132,.25); }
}

/* ─── TICKET ITEM HOVER ─── */
.ticket-item {
  transition: border-color .25s, transform .25s, box-shadow .25s;
}
.ticket-item:hover {
  box-shadow: 0 4px 20px rgba(61,220,132,.08);
}

/* ─── STATUS OPEN PULSE ─── */
.status-open {
  animation: statusOpenPulse 2.2s ease-in-out infinite;
}
@keyframes statusOpenPulse {
  0%,100% { box-shadow: none; }
  50%     { box-shadow: 0 0 10px rgba(61,220,132,.35); }
}

/* ─── FOOTER LOGO GLOW ─── */
.footer-logo {
  animation: logoGlowPulse 5s ease-in-out infinite;
}

/* ─── WHY CARD SHINE ─── */
.why-card {
  position: relative;
  overflow: hidden;
}
.why-card::after {
  content: '';
  position: absolute; top: 0; left: -100%;
  width: 50%; height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,.04), transparent);
  transition: left .6s ease;
  pointer-events: none;
}
.why-card:hover::after { left: 150%; }

/* ─── HAMBURGER NAV OPEN ANIMATION ─── */
.nav-links.open {
  animation: slideDown .25s ease;
}
@keyframes slideDown {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ─── SCROLLBAR ENHANCED ─── */
::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: linear-gradient(180deg, var(--green-dark), var(--green)); border-radius: 3px; }

/* ─── SECTION TITLE LINE2 ─── */
.hero-title .line1 {
  letter-spacing: 3px;
}
