/* ==========================================================================
   CREATIVE PORTFOLIO - SUPER MARIO x BINARY CODE DESIGN SYSTEM
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Press+Start+2P&family=Share+Tech+Mono&display=swap');

:root {
  /* Super Mario Color Palette */
  --mario-sky: #5c94fc;
  --mario-sky-deep: #1a3a8a;
  --mario-ground: #c84b11;
  --mario-ground-top: #e8a838;
  --mario-pipe: #3ca041;
  --mario-pipe-dark: #006400;
  --mario-brick: #c84b11;
  --mario-brick-dark: #8b2500;
  --mario-coin: #ffd700;
  --mario-cloud: #ffffff;
  --mario-hill: #52a840;

  /* Binary/Matrix Colors */
  --matrix-green: #00ff41;
  --matrix-green-dim: #003b00;
  --matrix-cyan: #00f2fe;
  --matrix-white: #e0ffe0;

  /* Card / Glass Layers */
  --bg-dark: #05070f;
  --bg-card: rgba(10, 18, 40, 0.82);
  --bg-card-hover: rgba(20, 35, 70, 0.9);
  --glass-border: rgba(255, 215, 0, 0.2);
  --glass-border-hover: rgba(255, 215, 0, 0.5);

  --primary-cyan: #00f2fe;
  --primary-blue: #4facfe;
  --accent-purple: #7000ff;
  --accent-pink: #f72585;
  --accent-glow: rgba(255, 215, 0, 0.15);

  --text-main: #ffffff;
  --text-muted: #cbd5e1;
  --text-dim: #94a3b8;

  /* Fonts */
  --font-pixel: 'Press Start 2P', monospace;
  --font-heading: 'Outfit', sans-serif;
  --font-mono: 'Share Tech Mono', monospace;
  --font-body: 'Outfit', sans-serif;

  /* Transitions */
  --transition-fast: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-smooth: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  --radius-lg: 4px;
  --radius-md: 4px;
  --radius-sm: 2px;
}

/* Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background-color: #1a3a8a;
  color: var(--text-main);
  font-family: var(--font-body);
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
}

body {
  /* Replace default cursor with a custom retro arrow */
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24'%3E%3Cpath fill='%23ffffff' stroke='%23000000' stroke-width='1.5' d='M4,4 L15,8 L10,10 L13,16 L10,17 L7,11 L4,14 Z'/%3E%3C/svg%3E") 4 4, auto;
}

a, button, input, textarea, .filter-btn, .project-card {
  /* Golden retro arrow for links/hover */
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24'%3E%3Cpath fill='%23ffd700' stroke='%23000000' stroke-width='1.5' d='M4,4 L15,8 L10,10 L13,16 L10,17 L7,11 L4,14 Z'/%3E%3C/svg%3E") 4 4, pointer !important;
}

/* =========================================================================
   SUPER MARIO WORLD BACKGROUND
   ========================================================================= */

#mario-bg-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -9;
  pointer-events: none;
  image-rendering: pixelated;
}

#bg-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -7;
  pointer-events: none;
}

/* Scanline CRT effect */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0,0,0,0.025) 2px,
    rgba(0,0,0,0.025) 4px
  );
  pointer-events: none;
  z-index: 9990;
}

/* =========================================================================
   CUSTOM CURSOR
   ========================================================================= */
.custom-cursor {
  position: fixed;
  top: 0;
  left: 0;
  width: 12px;
  height: 12px;
  background: var(--mario-coin);
  border-radius: 0;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  box-shadow: 0 0 10px var(--mario-coin), 0 0 20px rgba(255,215,0,0.5);
}

.custom-cursor-follower {
  position: fixed;
  top: 0;
  left: 0;
  width: 36px;
  height: 36px;
  border: 2px solid rgba(0, 255, 65, 0.6);
  border-radius: 0;
  pointer-events: none;
  z-index: 9998;
  transform: translate(-50%, -50%);
  transition: transform 0.15s cubic-bezier(0.23,1,0.32,1), border-color 0.2s ease, width 0.2s ease, height 0.2s ease;
  background: rgba(0, 255, 65, 0.04);
}

.custom-cursor.hovering {
  background: var(--mario-coin);
  box-shadow: 0 0 16px var(--mario-coin);
  transform: translate(-50%, -50%) scale(1.5);
}

.custom-cursor-follower.hovering {
  width: 52px;
  height: 52px;
  border-color: var(--mario-coin);
  background: rgba(255,215,0,0.08);
}

/* =========================================================================
   NAVIGATION - MARIO BRICK HEADER
   ========================================================================= */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  padding: 0;
  z-index: 100;
  background: #8b2500;
  border-bottom: 4px solid #5a1500;
  box-shadow: 0 4px 0 #3a0e00, 0 8px 20px rgba(0,0,0,0.5);
  overflow: hidden;
}

.navbar::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    repeating-linear-gradient(90deg, transparent 0px, transparent 38px, rgba(0,0,0,0.18) 38px, rgba(0,0,0,0.18) 40px),
    repeating-linear-gradient(180deg, transparent 0px, transparent 18px, rgba(0,0,0,0.12) 18px, rgba(0,0,0,0.12) 20px);
  pointer-events: none;
  z-index: 0;
}

/* Nav container — full-width flex row */
.nav-container {
  display: flex !important;
  flex-direction: row !important;
  justify-content: space-between;
  align-items: center;
  padding: 0.55rem 1.8rem;
  width: 100%;
  max-width: 100%;
  position: relative;
  z-index: 1;
  gap: 0.5rem;
  flex-wrap: nowrap;
}

.navbar-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.8rem 2rem;
  position: relative;
  z-index: 1;
  flex-wrap: nowrap;
  gap: 1rem;
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
}

.navbar-inner::before {
  display: none;
}

.nav-coin-counter {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-pixel);
  font-size: 0.85rem;
  color: #fff;
  letter-spacing: 1px;
  position: relative;
  z-index: 1;
  text-shadow: 1px 1px 0 #000;
}

.nav-coin-icon {
  display: inline-block;
  width: 16px;
  height: 16px;
  background: var(--mario-coin);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--mario-coin);
  animation: coinSpin 1.8s ease-in-out infinite;
}

@keyframes coinSpin {
  0%, 100% { transform: scaleX(1); opacity: 1; }
  40% { transform: scaleX(0.05); opacity: 0.5; }
  50% { transform: scaleX(0.05); opacity: 0.5; }
  90% { transform: scaleX(1); opacity: 1; }
}

.nav-brand {
  font-family: var(--font-pixel);
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--mario-coin);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
  text-shadow: 2px 2px 0 #5a1500, 0 0 15px rgba(255,215,0,0.5);
  position: relative;
  z-index: 1;
  flex-shrink: 0;
  white-space: nowrap;
  transition: transform 0.2s ease, text-shadow 0.2s ease;
}

.nav-brand:hover {
  transform: scale(1.04);
  text-shadow: 2px 2px 0 #5a1500, 0 0 25px rgba(255,215,0,0.9);
}

.brand-dot {
  width: 12px;
  height: 12px;
  background: var(--matrix-green);
  border-radius: 0;
  box-shadow: 0 0 10px var(--matrix-green);
  animation: blinkCursor 1s step-end infinite;
}

@keyframes blinkCursor {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 0.4rem;
  align-items: center;
  position: relative;
  z-index: 1;
  flex-wrap: nowrap;
  flex-shrink: 1;
}

.nav-link {
  color: #fff;
  text-decoration: none;
  font-family: var(--font-pixel);
  font-size: 0.75rem;
  font-weight: 400;
  letter-spacing: 0.5px;
  padding: 0.5rem 0.75rem;
  border: 2px solid transparent;
  transition: var(--transition-fast);
  position: relative;
  text-shadow: 1px 1px 0 #000;
  white-space: nowrap;
}

.nav-link:hover, .nav-link.active {
  color: var(--mario-coin);
  border: 2px solid var(--mario-coin);
  background: rgba(255,215,0,0.12);
  box-shadow: 0 0 14px rgba(255,215,0,0.4), inset 0 0 8px rgba(255,215,0,0.1);
  transform: translateY(-1px);
}

.nav-link::after { display: none; }

.nav-cta {
  padding: 0.6rem 1.2rem;
  background: var(--mario-coin);
  color: #000;
  font-family: var(--font-pixel);
  font-weight: 700;
  font-size: 0.8rem;
  border-radius: 0;
  text-decoration: none;
  transition: var(--transition-fast);
  border: 3px solid #a07000;
  box-shadow: 3px 3px 0 #000;
  letter-spacing: 1px;
  position: relative;
  z-index: 1;
  white-space: nowrap;
}

.nav-cta:hover {
  background: #ffe34d;
  transform: translate(-2px, -2px);
  box-shadow: 5px 5px 0 #000;
}

.nav-lives {
  font-family: var(--font-pixel);
  font-size: 0.8rem;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 6px;
  position: relative;
  z-index: 1;
  text-shadow: 1px 1px 0 #000;
  white-space: nowrap;
}

.nav-life-icon {
  display: inline-block;
  width: 14px;
  height: 14px;
  background: radial-gradient(circle at 40% 35%, #ff9999, #c0392b);
  border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%;
  box-shadow: 0 0 6px rgba(255,0,0,0.6);
}

.mobile-toggle {
  display: none;
  background: rgba(0,0,0,0.4);
  border: 2px solid var(--mario-coin);
  color: var(--mario-coin);
  font-family: var(--font-pixel);
  font-size: 1rem;
  cursor: pointer;
  padding: 0.4rem 0.8rem;
  position: relative;
  z-index: 101;
  transition: var(--transition-fast);
}

.mobile-toggle:hover, .mobile-toggle.active {
  background: var(--mario-coin);
  color: #000;
  box-shadow: 0 0 10px rgba(255,215,0,0.5);
}

/* =========================================================================
   LAYOUT
   ========================================================================= */
.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

section {
  padding: 7rem 0;
  position: relative;
}

.section-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  margin-bottom: 3.5rem;
}

.section-tag {
  font-family: var(--font-pixel);
  font-size: 0.48rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 3px;
  color: var(--mario-coin);
  margin-bottom: 0.8rem;
  display: inline-block;
  padding: 0.4rem 1rem;
  background: rgba(255, 215, 0, 0.08);
  border-radius: 0;
  border: 2px solid rgba(255, 215, 0, 0.35);
  box-shadow: 0 0 12px rgba(255, 215, 0, 0.18), inset 0 0 10px rgba(255, 215, 0, 0.05);
}

.section-title {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  font-weight: 800;
  color: #ffffff;
  text-shadow: 0 4px 20px rgba(0, 0, 0, 0.6);
  margin-top: 0.8rem;
  text-transform: uppercase;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: block;
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24'%3E%3Cpath fill='%23ffd700' stroke='%23000000' stroke-width='1.5' d='M4,4 L15,8 L10,10 L13,16 L10,17 L7,11 L4,14 Z'/%3E%3C/svg%3E") 4 4, pointer !important;
}

.section-title:hover {
  /* Keep original text color and shadow during wave hover */
}

/* =========================================================================
   HERO SECTION
   ========================================================================= */
.hero-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 5rem;
  position: relative;
  overflow: hidden;
}

.hero-content-wrap {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 2rem;
  width: 100%;
  max-width: 900px;
}

.hero-pixel-box {
  border: 4px solid var(--mario-coin);
  padding: 2.5rem 3rem;
  position: relative;
  background: rgba(5, 7, 15, 0.78);
  backdrop-filter: blur(14px);
  box-shadow: 8px 8px 0 #000, 0 0 40px rgba(255,215,0,0.18), inset 0 0 40px rgba(0,255,65,0.04);
}

.hero-pixel-box::before {
  content: '★ INSERT COIN ★';
  position: absolute;
  top: -0.85rem;
  left: 50%;
  transform: translateX(-50%);
  background: var(--mario-coin);
  color: #000;
  font-family: var(--font-pixel);
  font-size: 0.45rem;
  padding: 0.25rem 1rem;
  letter-spacing: 2px;
  white-space: nowrap;
}

.hero-score {
  font-family: var(--font-pixel);
  font-size: 0.48rem;
  color: rgba(255,255,255,0.7);
  letter-spacing: 3px;
  margin-bottom: 1.5rem;
  text-shadow: 1px 1px 0 #000;
}

.hero-score span {
  color: var(--mario-coin);
  text-shadow: 0 0 8px rgba(255,215,0,0.6);
}

.hero-quote-binary {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--matrix-green);
  opacity: 0.65;
  letter-spacing: 3px;
  margin-bottom: 1rem;
  animation: flickerAnim 4s infinite;
  display: block;
  text-shadow: 0 0 8px rgba(0,255,65,0.5);
}

@keyframes flickerAnim {
  0%, 92%, 100% { opacity: 0.65; }
  93% { opacity: 0.15; }
  94% { opacity: 0.65; }
  95% { opacity: 0.1; }
  96% { opacity: 0.65; }
}

.hero-quote-main {
  font-family: var(--font-pixel);
  font-size: 1.35rem;
  line-height: 2.2;
  color: var(--mario-coin);
  text-shadow: 3px 3px 0 #8b2500, 0 0 30px rgba(255,215,0,0.55), 0 0 60px rgba(255,215,0,0.25);
  letter-spacing: 2px;
  animation: pixelGlowAnim 2.5s ease-in-out infinite alternate;
}

@keyframes pixelGlowAnim {
  from { text-shadow: 3px 3px 0 #8b2500, 0 0 20px rgba(255,215,0,0.45); }
  to   { text-shadow: 3px 3px 0 #8b2500, 0 0 50px rgba(255,215,0,0.9), 0 0 90px rgba(255,215,0,0.4); }
}

.hero-quote-sub {
  font-family: var(--font-mono);
  font-size: 1rem;
  color: var(--matrix-green);
  letter-spacing: 5px;
  margin-top: 1.2rem;
  text-shadow: 0 0 15px rgba(0,255,65,0.7);
  animation: matrixPulseAnim 1.8s ease-in-out infinite alternate;
  display: block;
}

@keyframes matrixPulseAnim {
  from { opacity: 0.65; }
  to   { opacity: 1; text-shadow: 0 0 25px rgba(0,255,65,1), 0 0 40px rgba(0,255,65,0.4); }
}

.hero-cursor {
  display: inline-block;
  width: 12px;
  height: 1.1em;
  background: var(--mario-coin);
  margin-left: 5px;
  vertical-align: middle;
  animation: blinkCursor 0.75s step-end infinite;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-top: 2rem;
}

/* =========================================================================
   BUTTONS - PIXEL STYLE
   ========================================================================= */
.btn-primary {
  padding: 0.8rem 2rem;
  background: var(--mario-coin);
  color: #000;
  font-family: var(--font-pixel);
  font-weight: 400;
  font-size: 0.5rem;
  border-radius: 0;
  text-decoration: none;
  transition: var(--transition-fast);
  border: 3px solid #a07000;
  box-shadow: 4px 4px 0 #000;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  letter-spacing: 1px;
}

.btn-primary:hover {
  background: #ffe34d;
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 #000;
}

.btn-secondary {
  padding: 0.8rem 2rem;
  background: transparent;
  border: 3px solid var(--matrix-green);
  color: var(--matrix-green);
  font-family: var(--font-pixel);
  font-weight: 400;
  font-size: 0.5rem;
  border-radius: 0;
  text-decoration: none;
  transition: var(--transition-fast);
  box-shadow: 4px 4px 0 rgba(0,255,65,0.25);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  letter-spacing: 1px;
}

.btn-secondary:hover {
  background: rgba(0,255,65,0.08);
  box-shadow: 6px 6px 0 rgba(0,255,65,0.4);
  transform: translate(-2px, -2px);
}

/* =========================================================================
   ABOUT SECTION
   ========================================================================= */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.about-card {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  border: 2px solid var(--glass-border);
  border-radius: 0;
  padding: 2.5rem;
  position: relative;
  transition: var(--transition-smooth);
  box-shadow: 5px 5px 0 rgba(0,0,0,0.4);
}

.about-card:hover {
  border-color: var(--glass-border-hover);
  transform: translate(-4px, -4px);
  box-shadow: 9px 9px 0 rgba(0,255,65,0.15);
}

.about-card::before {
  content: '//';
  position: absolute;
  top: 0.8rem;
  left: 1rem;
  font-family: var(--font-pixel);
  font-size: 0.4rem;
  color: var(--matrix-green);
  opacity: 0.4;
}

.about-text p {
  color: var(--text-muted);
  margin-bottom: 1.5rem;
  font-size: 1.02rem;
  font-family: var(--font-mono);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 2rem;
}

.stat-item {
  text-align: center;
  padding: 1rem;
  background: rgba(0,255,65,0.04);
  border: 2px solid var(--glass-border);
  border-radius: 0;
}

.stat-number {
  font-family: var(--font-pixel);
  font-size: 1.1rem;
  font-weight: 400;
  color: var(--mario-coin);
  display: block;
  text-shadow: 0 0 12px rgba(255,215,0,0.55);
}

.stat-label {
  font-family: var(--font-pixel);
  font-size: 0.38rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-top: 0.4rem;
  display: block;
}

/* =========================================================================
   SKILLS MATRIX
   ========================================================================= */
.skills-filter {
  display: flex;
  justify-content: center;
  gap: 0.8rem;
  margin-bottom: 3rem;
  flex-wrap: wrap;
}

.filter-btn {
  padding: 0.5rem 1.2rem;
  background: rgba(0,255,65,0.04);
  border: 2px solid var(--glass-border);
  color: var(--text-muted);
  border-radius: 0;
  font-family: var(--font-pixel);
  font-size: 0.42rem;
  font-weight: 400;
  cursor: pointer;
  transition: var(--transition-fast);
  letter-spacing: 1px;
}

.filter-btn:hover, .filter-btn.active {
  background: var(--matrix-green);
  color: #000;
  border-color: var(--matrix-green);
  box-shadow: 3px 3px 0 #000, 0 0 15px rgba(0,255,65,0.3);
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.5rem;
}

.skill-card {
  background: var(--bg-card);
  border: 2px solid var(--glass-border);
  border-radius: 0;
  padding: 1.5rem;
  transition: var(--transition-smooth);
  display: flex;
  flex-direction: column;
  gap: 1rem;
  box-shadow: 3px 3px 0 rgba(0,0,0,0.4);
}

.skill-card:hover {
  border-color: var(--glass-border-hover);
  transform: translate(-3px, -3px);
  box-shadow: 6px 6px 0 rgba(0,255,65,0.2);
}

.skill-header {
  display: flex;
  align-items: center;
  gap: 12px;
}

.skill-icon {
  width: 42px;
  height: 42px;
  border-radius: 0;
  background: rgba(0,255,65,0.06);
  border: 2px solid var(--glass-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  color: var(--matrix-green);
}

.skill-name {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text-main);
}

.skill-bar-bg {
  width: 100%;
  height: 10px;
  background: rgba(0,255,65,0.06);
  border-radius: 0;
  overflow: hidden;
  border: 1px solid rgba(0,255,65,0.1);
}

.skill-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--matrix-green), var(--mario-coin));
  border-radius: 0;
  width: 0%;
  transition: width 1.2s ease-out;
  box-shadow: 0 0 10px rgba(0,255,65,0.5);
  position: relative;
}

/* =========================================================================
   PROJECTS
   ========================================================================= */
.projects-grid {
/* =========================================================================
   PROJECTS SECTION (HORIZONTAL CARD LAYOUT & LIVE WEBSITE PEEK)
   ========================================================================= */
.projects-grid {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}

.project-card.horizontal-card {
  display: grid;
  grid-template-columns: 460px 1fr;
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  border: 3px solid var(--glass-border);
  border-radius: 0;
  overflow: hidden;
  box-shadow: 6px 6px 0 rgba(0,0,0,0.5);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}

.project-card.horizontal-card:hover {
  border-color: var(--mario-coin);
  box-shadow: 10px 10px 0 rgba(0, 255, 65, 0.25), 0 0 25px rgba(255, 215, 0, 0.2);
  transform: translateY(-4px);
}

/* Browser Window Header & Controls */
.project-thumb-wrapper {
  display: flex;
  flex-direction: column;
  background: #050b1a;
  border-right: 2px solid var(--glass-border);
  position: relative;
  overflow: hidden;
}

.browser-bar {
  background: rgba(5, 11, 26, 0.98);
  border-bottom: 2px solid var(--glass-border);
  padding: 0.6rem 0.9rem;
  display: flex;
  align-items: center;
  gap: 12px;
}

.browser-dots {
  display: flex;
  gap: 6px;
}

.b-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
}
.b-dot.red { background: #e03020; }
.b-dot.yellow { background: #ffd700; }
.b-dot.green { background: #00ff41; }

.browser-address-bar {
  flex-grow: 1;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 0.25rem 0.6rem;
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-dim);
  overflow: hidden;
}

.browser-address-bar .lock-icon {
  color: #00ff41;
  font-size: 0.65rem;
}

.browser-address-bar .address-text {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex-grow: 1;
}

.browser-address-bar .status-live {
  font-family: var(--font-pixel);
  font-size: 0.38rem;
  color: #00ff41;
  letter-spacing: 1px;
}

/* Viewport & Hover Peek Iframe Container */
.browser-viewport {
  position: relative;
  flex-grow: 1;
  min-height: 280px;
  overflow: hidden;
  background: #081228;
}

.project-thumb-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 15px;
  background: linear-gradient(135deg, rgba(0,255,65,0.05), rgba(255,215,0,0.05));
  font-size: 3.2rem;
  color: var(--matrix-green);
  transition: opacity 0.3s ease;
}

.hover-peek-badge {
  font-family: var(--font-pixel);
  font-size: 0.42rem;
  color: var(--mario-coin);
  background: rgba(0, 0, 0, 0.8);
  border: 1.5px solid var(--mario-coin);
  padding: 5px 12px;
  letter-spacing: 1px;
  box-shadow: 3px 3px 0 #000;
}

.iframe-peek-container {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1), transform 0.4s ease;
  transform: scale(0.96);
  background: #ffffff;
}

.iframe-peek-container iframe {
  width: 100%;
  height: 100%;
  border: none;
  pointer-events: none;
}

/* On Card Hover: Peek Live Website! */
.project-card.horizontal-card:hover .iframe-peek-container {
  opacity: 1;
  pointer-events: auto;
  transform: scale(1);
}

.iframe-peek-container.mockup-screen {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem;
  color: #ffffff;
}

.mockup-content h4 {
  font-family: var(--font-pixel);
  font-size: 0.7rem;
  color: var(--mario-coin);
  margin-bottom: 0.5rem;
}

.mockup-content p {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Card Content & Action Buttons */
.project-content {
  padding: 2rem 2.4rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.project-actions {
  display: flex;
  gap: 14px;
  margin-top: 1.8rem;
  flex-wrap: wrap;
}

.project-actions .live-btn {
  background: #e03020;
  color: #fff;
  border-color: #000;
}

.project-actions .live-btn:hover {
  background: #ff4030;
}

/* Interactive Site Peek Modal */
.site-peek-modal {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.site-peek-modal.active {
  opacity: 1;
  pointer-events: auto;
}

.site-peek-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(8px);
}

.site-peek-window {
  position: relative;
  width: 100%;
  max-width: 1200px;
  height: 85vh;
  background: #050b1a;
  border: 3px solid var(--mario-coin);
  box-shadow: 12px 12px 0 #000, 0 0 35px rgba(255, 215, 0, 0.4);
  display: flex;
  flex-direction: column;
  transform: scale(0.9);
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.site-peek-modal.active .site-peek-window {
  transform: scale(1);
}

.site-peek-header {
  background: #0a1228;
  border-bottom: 2px solid var(--glass-border);
  padding: 0.8rem 1.4rem;
  display: flex;
  align-items: center;
  gap: 15px;
}

.modal-address-bar {
  flex-grow: 1;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 0.4rem 1rem;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--matrix-cyan);
  display: flex;
  align-items: center;
  gap: 10px;
}

.modal-controls {
  display: flex;
  gap: 10px;
}

.modal-btn-icon {
  font-family: var(--font-pixel);
  font-size: 0.45rem;
  padding: 0.5rem 0.9rem;
  background: var(--mario-coin);
  color: #000;
  border: 2px solid #000;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 2px 2px 0 #000;
  display: flex;
  align-items: center;
  gap: 6px;
}

.modal-btn-icon.close-btn {
  background: #e03020;
  color: #fff;
}

.site-peek-body {
  flex-grow: 1;
  position: relative;
  background: #ffffff;
}

.site-peek-body iframe {
  width: 100%;
  height: 100%;
  border: none;
}

@media (max-width: 992px) {
  .project-card.horizontal-card {
    grid-template-columns: 1fr;
  }
  .project-thumb-wrapper {
    border-right: none;
    border-bottom: 2px solid var(--glass-border);
  }
  .site-peek-window {
    height: 92vh;
  }
}
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}

/* =========================================================================
   TIMELINE & SCROLLING YEAR TRACKER
   ========================================================================= */
.timeline {
  position: relative;
  max-width: 850px;
  margin: 0 auto;
  padding-top: 1rem;
}

/* Background Center Line */
.timeline::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 4px;
  background: rgba(255, 255, 255, 0.12);
  transform: translateX(-50%);
  border-radius: 2px;
}

/* Dynamic Illuminated Scroll Line Beam */
.timeline-progress {
  position: absolute;
  top: 0;
  left: 50%;
  width: 4px;
  height: 0%;
  background: linear-gradient(180deg, var(--mario-coin) 0%, var(--matrix-cyan) 100%);
  transform: translateX(-50%);
  box-shadow: 0 0 12px var(--mario-coin), 0 0 20px var(--matrix-cyan);
  border-radius: 2px;
  transition: height 0.1s linear;
  z-index: 1;
}

/* Floating Sticky Year Follower Badge */
.timeline-year-follower {
  position: absolute;
  left: 50%;
  transform: translate(-50%, -50%);
  top: 24px;
  font-family: var(--font-pixel);
  font-size: 0.85rem;
  color: #000;
  background: var(--mario-coin);
  border: 3px solid #000;
  box-shadow: 4px 4px 0 #000, 0 0 20px rgba(255, 215, 0, 0.8);
  padding: 8px 18px;
  z-index: 25;
  display: flex;
  align-items: center;
  gap: 10px;
  letter-spacing: 1px;
  transition: top 0.22s cubic-bezier(0.16, 1, 0.3, 1), transform 0.22s ease;
  pointer-events: none;
}

.timeline-year-follower .follower-icon {
  font-size: 0.7rem;
  color: #e03020;
  animation: bounceArrow 1.2s infinite ease-in-out;
}

@keyframes bounceArrow {
  0%, 100% { transform: translateY(-2px); }
  50% { transform: translateY(3px); }
}

/* Timeline Item Layout */
.timeline-item {
  margin-bottom: 4rem;
  position: relative;
  width: 50%;
  padding: 0 3rem;
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.timeline-item:nth-child(odd)  { left: 0; text-align: right; }
.timeline-item:nth-child(even) { left: 50%; text-align: left; }

.timeline-dot {
  position: absolute;
  top: 24px;
  width: 20px;
  height: 20px;
  background: rgba(255, 255, 255, 0.3);
  border: 2.5px solid var(--glass-border);
  border-radius: 0;
  z-index: 2;
  transition: all 0.3s ease;
}

.timeline-item.active-item .timeline-dot {
  background: var(--mario-coin);
  border-color: #000;
  box-shadow: 0 0 16px var(--mario-coin), 0 0 30px rgba(255, 215, 0, 0.9);
  transform: scale(1.35);
}

.timeline-item:nth-child(odd)  .timeline-dot { right: -10px; }
.timeline-item:nth-child(even) .timeline-dot { left: -10px; }

/* Timeline Box & Spacing */
.timeline-box {
  background: var(--bg-card);
  border: 2px solid var(--glass-border);
  border-radius: 0;
  padding: 2.2rem 2.2rem;
  backdrop-filter: blur(14px);
  box-shadow: 6px 6px 0 rgba(0,0,0,0.5);
  transition: var(--transition-smooth);
  position: relative;
}

.timeline-item.active-item .timeline-box {
  border-color: var(--mario-coin);
  box-shadow: 8px 8px 0 rgba(0, 255, 65, 0.25), 0 0 25px rgba(255, 215, 0, 0.3);
  transform: translateY(-5px);
}

.timeline-date {
  font-family: var(--font-pixel);
  font-size: 0.58rem;
  color: var(--mario-coin);
  font-weight: 400;
  letter-spacing: 1.5px;
  display: inline-block;
  background: rgba(255, 215, 0, 0.08);
  border: 1.5px solid rgba(255, 215, 0, 0.35);
  padding: 6px 14px;
  margin-bottom: 1.4rem;
  box-shadow: 2px 2px 0 #000;
}

.timeline-title {
  font-family: var(--font-mono);
  font-size: 1.3rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 0.6rem;
  line-height: 1.4;
  letter-spacing: 0.5px;
}

.timeline-company {
  display: block;
  font-family: var(--font-mono);
  font-size: 1.0rem;
  font-weight: 600;
  color: var(--matrix-cyan);
  margin-bottom: 1.2rem;
  letter-spacing: 0.5px;
}

.timeline-desc {
  color: #e2e8f0;
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.7;
}

/* =========================================================================
   CONTACT
   ========================================================================= */
.contact-container {
  max-width: 700px;
  margin: 0 auto;
  background: var(--bg-card);
  border: 2px solid var(--glass-border);
  border-radius: 0;
  padding: 3rem;
  backdrop-filter: blur(20px);
  box-shadow: 8px 8px 0 rgba(0,0,0,0.45);
}

.form-group { margin-bottom: 1.5rem; }

.form-label {
  display: block;
  font-family: var(--font-pixel);
  font-size: 0.42rem;
  color: var(--matrix-green);
  margin-bottom: 0.5rem;
  letter-spacing: 2px;
}

.form-label::before { content: '> '; }

.form-input, .form-textarea {
  width: 100%;
  padding: 0.9rem 1.2rem;
  background: rgba(0,0,0,0.45);
  border: 2px solid var(--glass-border);
  border-radius: 0;
  color: var(--matrix-green);
  font-family: var(--font-mono);
  font-size: 1rem;
  outline: none;
  transition: var(--transition-fast);
  caret-color: var(--matrix-green);
}

.form-input::placeholder, .form-textarea::placeholder {
  color: rgba(0,255,65,0.28);
  font-family: var(--font-mono);
}

.form-input:focus, .form-textarea:focus {
  border-color: var(--matrix-green);
  box-shadow: 0 0 15px rgba(0,255,65,0.18), 4px 4px 0 rgba(0,255,65,0.08);
  color: #fff;
}

.form-textarea { resize: vertical; min-height: 140px; }

/* =========================================================================
   TOAST
   ========================================================================= */
.toast {
  position: fixed;
  bottom: 30px;
  right: 30px;
  padding: 1rem 1.5rem;
  background: #000;
  border: 3px solid var(--matrix-green);
  color: var(--matrix-green);
  border-radius: 0;
  box-shadow: 6px 6px 0 rgba(0,0,0,0.5), 0 0 20px rgba(0,255,65,0.25);
  font-family: var(--font-pixel);
  font-size: 0.45rem;
  display: flex;
  align-items: center;
  gap: 10px;
  transform: translateY(100px);
  opacity: 0;
  transition: var(--transition-smooth);
  z-index: 1000;
  letter-spacing: 1px;
}

/* =========================================================================
   ARCADE SKILLS TYPEWRITER TERMINAL
   ========================================================================= */
.arcade-terminal-viewport {
  background: #040914;
  border: 2px solid var(--glass-border);
  padding: 1.5rem;
  font-family: var(--font-mono);
  min-height: 280px;
  max-height: 380px;
  overflow-y: auto;
  box-shadow: inset 0 0 25px rgba(0, 0, 0, 0.9);
  position: relative;
}

.terminal-prompt-bar {
  display: flex;
  gap: 10px;
  font-size: 0.9rem;
  margin-bottom: 1.2rem;
  border-bottom: 1px dashed rgba(0, 255, 65, 0.25);
  padding-bottom: 0.8rem;
}

.terminal-prompt-bar .prompt-user {
  color: var(--mario-coin);
  font-weight: 700;
}

.terminal-prompt-bar .prompt-cmd {
  color: var(--matrix-cyan);
}

.terminal-typewriter-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.98rem;
  line-height: 1.6;
}

.term-line {
  white-space: pre-wrap;
  word-break: break-word;
}

.term-muted { color: #64748b; }
.term-cyan { color: var(--matrix-cyan); font-weight: 600; }
.term-border { color: #334155; }
.term-highlight { color: #ffffff; font-weight: 600; text-shadow: 0 0 8px rgba(0, 255, 65, 0.3); }
.term-success { color: var(--matrix-green); font-weight: 700; }

.term-cursor {
  display: inline-block;
  color: var(--mario-coin);
  animation: blinkCursor 0.8s infinite step-end;
  margin-left: 2px;
}

@keyframes blinkCursor {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

/* =========================================================================
   CERTIFICATES SHOWCASE GRID & MODAL
   ========================================================================= */
/* =========================================================================
   CERTIFICATES SHOWCASE GRID & 3D HOLOGRAM EMITTER SYSTEM
   ========================================================================= */
.certificates-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  gap: 2.5rem;
  perspective: 1200px;
}

/* Container for the folding card and independent hologram */
.cert-card-container {
  position: relative;
  width: 100%;
  perspective: 1500px;
  z-index: 1;
  cursor: pointer;
}

.cert-card-projector {
  background: var(--bg-card);
  border: 3px solid var(--glass-border);
  border-radius: 0;
  overflow: visible;
  box-shadow: 6px 6px 0 rgba(0,0,0,0.5), 0 0 20px rgba(0,0,0,0.5);
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.6s ease, border-color 0.3s ease;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  position: relative;
  transform-style: preserve-3d;
  transform-origin: bottom center;
}

.cert-card-container.is-folding .cert-card-projector, 
.cert-card-container.is-projecting .cert-card-projector {
  border-color: var(--matrix-cyan);
  box-shadow: 12px 12px 0 rgba(0, 255, 65, 0.3), 0 0 45px rgba(0, 242, 254, 0.45);
  z-index: 10;
  transform: rotateX(80deg); /* Fold down into a platform */
}

/* Cyber AR HUD Corner Brackets */
.ar-hud-corner {
  position: absolute;
  width: 16px;
  height: 16px;
  border: 2px solid var(--matrix-cyan);
  pointer-events: none;
  z-index: 9;
  opacity: 0.4;
  transition: all 0.3s ease;
  transform: translateZ(45px);
}
.ar-hud-corner.tl { top: -3px; left: -3px; border-right: none; border-bottom: none; }
.ar-hud-corner.tr { top: -3px; right: -3px; border-left: none; border-bottom: none; }
.ar-hud-corner.bl { bottom: -3px; left: -3px; border-right: none; border-top: none; }
.ar-hud-corner.br { bottom: -3px; right: -3px; border-left: none; border-top: none; }

.cert-card-container:hover .ar-hud-corner {
  opacity: 1;
  border-color: var(--mario-coin);
  box-shadow: 0 0 10px var(--mario-coin);
}

/* =========================================================================
   3D FOLDING HOLOGRAM SYSTEM
   ========================================================================= */

/* The flat image wrapper */
.cert-img-wrapper {
  display: none; /* User requested removing the extra space in the card to just show text */
}

.cert-img-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: none; /* User requested removing image on the card, only showing in hologram */
}

/* Hologram Overlay Container */
.holo-system-overlay {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  pointer-events: none;
  transform-style: preserve-3d;
  z-index: 15;
}

/* Energy Rings Base (Attached to Card) */
.energy-rings {
  position: absolute;
  bottom: 20px;
  left: 50%;
  width: 140px;
  height: 140px;
  transform: translateX(-50%) rotate(0deg);
  border-radius: 50%;
  border: 2px dashed rgba(0, 242, 254, 0.8);
  box-shadow: 0 0 20px rgba(0, 242, 254, 0.5), inset 0 0 20px rgba(0, 242, 254, 0.5);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
  z-index: 5;
}

.cert-card-container.is-projecting .energy-rings {
  opacity: 1;
  animation: spinRings 4s linear infinite;
}

@keyframes spinRings {
  100% { transform: translateX(-50%) rotate(360deg); }
}

/* Volumetric Light Beam */
.holo-light-beam {
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 80%;
  height: 0; /* Starts hidden */
  transform: translateX(-50%) translateZ(10px);
  background: linear-gradient(to top, rgba(0, 216, 255, 0.3), rgba(0, 216, 255, 0.05), transparent);
  opacity: 0;
  transition: all 0.5s ease;
  filter: drop-shadow(0 0 15px rgba(0, 216, 255, 0.5));
  mix-blend-mode: screen;
}

.cert-card-container.is-projecting .holo-light-beam {
  height: 250px;
  opacity: 0.5;
  animation: pulseBeam 2s ease-in-out infinite alternate;
}

@keyframes pulseBeam {
  0% { opacity: 0.3; height: 230px; }
  100% { opacity: 0.6; height: 260px; }
}

/* The Projected Hologram Certificate */
.holo-projection {
  position: absolute;
  top: 40px;
  left: 10%;
  width: 80%;
  height: 180px;
  transform-origin: bottom center;
  transform: translateY(0) scale(0.5);
  opacity: 0;
  transition: all 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  transform-style: preserve-3d;
  pointer-events: none;
}

.holo-projection img {
  width: 100%;
  height: 100%;
  object-fit: contain; /* Changed from cover to contain to prevent cropping */
  border: 1px solid rgba(127, 239, 255, 0.6);
  box-shadow: 0 0 15px rgba(0, 216, 255, 0.5);
  /* Restore original colors by removing screen blend and brightness/contrast tweaks */
  filter: drop-shadow(0 0 10px rgba(0, 216, 255, 0.6));
  opacity: 0.85; /* Increased opacity to show original colors clearly */
}

.cert-card-container.is-projecting .holo-projection {
  /* Lowered height further to be just above projector */
  transform: translateY(-20px) scale(1.1);
  opacity: 1;
  animation: floatHolo 4s ease-in-out infinite;
}

.cert-card-container.is-projecting .holo-projection img {
  animation: glitchHoloImg 4s infinite;
}

@keyframes floatHolo {
  0%, 100% { transform: translateY(-20px) scale(1.1) rotateY(-4deg); }
  50% { transform: translateY(-5px) scale(1.1) rotateY(4deg); }
}

/* Glitch and Scanlines */
.holo-projection::before {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    rgba(127, 239, 255, 0.15) 0px,
    rgba(127, 239, 255, 0.15) 1px,
    transparent 1px,
    transparent 3px
  );
  pointer-events: none;
  z-index: 2;
  mix-blend-mode: screen;
}

@keyframes glitchHoloImg {
  0%, 96%, 98%, 100% { opacity: 0.85; transform: none; }
  97% { opacity: 0.6; transform: skewX(1deg); filter: drop-shadow(3px 0 0 rgba(0,216,255,0.8)) drop-shadow(-3px 0 0 rgba(127,239,255,0.8)); }
  99% { opacity: 0.7; transform: skewX(-1deg); }
}

/* Particles Dissolve Effect */
.holo-particles {
  position: absolute;
  inset: -20px;
  pointer-events: none;
  background-image: 
    radial-gradient(circle, var(--matrix-cyan) 1px, transparent 1px),
    radial-gradient(circle, var(--mario-coin) 1px, transparent 1px);
  background-size: 20px 20px, 35px 35px;
  background-position: 0 0, 15px 15px;
  opacity: 0;
  transition: opacity 0.3s;
}

.cert-card-container.is-projecting .holo-particles {
  opacity: 0.6;
  animation: orbitParticles 20s linear infinite;
}

@keyframes orbitParticles {
  0% { background-position: 0 0, 15px 15px; }
  100% { background-position: 100px 100px, -50px 200px; }
}

/* Dissolve State on Mouse Leave */
.cert-card-container.is-dissolving .holo-projection {
  transform: translateY(-20px) scale(1.1);
  opacity: 0 !important;
  filter: blur(10px) brightness(2);
  transition: all 0.4s ease-out;
}
.cert-card-container.is-dissolving .holo-light-beam,
.cert-card-container.is-dissolving .energy-rings {
  opacity: 0 !important;
  height: 0 !important;
}

.cert-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  font-family: var(--font-pixel);
  font-size: 0.42rem;
  padding: 5px 12px;
  color: #000;
  border: 2px solid #000;
  box-shadow: 3px 3px 0 #000;
  letter-spacing: 1px;
  transform: translateZ(55px);
  z-index: 5;
}
.cert-badge.google { background: #4285f4; color: #fff; }
.cert-badge.meta { background: #0668e1; color: #fff; }
.cert-badge.alibaba { background: #ff6a00; color: #fff; }

.ar-peek-badge {
  position: absolute;
  bottom: 10px;
  left: 10px;
  font-family: var(--font-pixel);
  font-size: 0.4rem;
  padding: 4px 8px;
  background: rgba(5, 11, 26, 0.9);
  color: var(--matrix-cyan);
  border: 1px solid var(--matrix-cyan);
  letter-spacing: 1px;
  transform: translateZ(50px);
  opacity: 0.85;
  transition: all 0.3s ease;
}

.cert-card:hover .ar-peek-badge {
  background: var(--mario-coin);
  color: #000;
  border-color: #000;
  box-shadow: 2px 2px 0 #000;
  opacity: 1;
}

.cert-info {
  padding: 1.8rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  flex-grow: 1;
  transform-style: preserve-3d;
  transform: translateZ(20px);
}

.cert-title {
  font-family: var(--font-mono);
  font-size: 1.15rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 0.5rem;
  line-height: 1.4;
  transform: translateZ(40px);
}

.cert-issuer {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--matrix-cyan);
  margin-bottom: 0.8rem;
  display: block;
  transform: translateZ(35px);
}

.cert-desc {
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 1.4rem;
  transform: translateZ(25px);
}

.cert-actions {
  margin-top: auto;
  transform: translateZ(45px);
}

.cert-view-btn {
  width: 100%;
  justify-content: center;
  font-size: 0.42rem;
  padding: 0.7rem 1.2rem;
}

/* =========================================================================
   2D CERTIFICATE VIEWER (IN MODAL)
   ========================================================================= */
.cert-modal-image-container {
  position: relative;
  width: 90%;
  max-width: 900px;
  height: 85%;
  max-height: 700px;
  display: flex;
  align-items: center;
  justify-content: center;
}

#cert-modal-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border: 4px solid var(--matrix-cyan);
  box-shadow: 0 0 30px rgba(0, 242, 254, 0.5);
  border-radius: 4px;
}

.cert-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  font-family: var(--font-pixel);
  font-size: 0.42rem;
  padding: 5px 12px;
  color: #000;
  border: 2px solid #000;
  box-shadow: 3px 3px 0 #000;
  letter-spacing: 1px;
  transform: translateZ(55px);
  z-index: 5;
}
.cert-badge.google { background: #4285f4; color: #fff; }
.cert-badge.meta { background: #0668e1; color: #fff; }
.cert-badge.alibaba { background: #ff6a00; color: #fff; }

.ar-peek-badge {
  position: absolute;
  bottom: 10px;
  left: 10px;
  font-family: var(--font-pixel);
  font-size: 0.4rem;
  padding: 4px 8px;
  background: rgba(5, 11, 26, 0.9);
  color: var(--matrix-cyan);
  border: 1px solid var(--matrix-cyan);
  letter-spacing: 1px;
  transform: translateZ(50px);
  opacity: 0.85;
  transition: all 0.3s ease;
}

.cert-card:hover .ar-peek-badge {
  background: var(--mario-coin);
  color: #000;
  border-color: #000;
  box-shadow: 2px 2px 0 #000;
  opacity: 1;
}

.cert-info {
  padding: 1.8rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  flex-grow: 1;
  transform-style: preserve-3d;
  transform: translateZ(20px);
}

.cert-title {
  font-family: var(--font-mono);
  font-size: 1.15rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 0.5rem;
  line-height: 1.4;
  transform: translateZ(40px);
}

.cert-issuer {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--matrix-cyan);
  margin-bottom: 0.8rem;
  display: block;
  transform: translateZ(35px);
}

.cert-desc {
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 1.4rem;
  transform: translateZ(25px);
}

.cert-actions {
  margin-top: auto;
  transform: translateZ(45px);
}

.cert-view-btn {
  width: 100%;
  justify-content: center;
  font-size: 0.42rem;
  padding: 0.7rem 1.2rem;
}

/* Full-Screen AR 3D Hologram Lightbox Modal */
.cert-modal {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

.cert-modal.active {
  opacity: 1;
  pointer-events: auto;
}

.cert-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 6, 18, 0.92);
  backdrop-filter: blur(12px);
}

.cert-modal-window {
  position: relative;
  width: 100%;
  max-width: 1100px;
  height: 85vh;
  background: rgba(2, 6, 18, 0.6);
  backdrop-filter: blur(25px);
  border: 1px solid rgba(127, 239, 255, 0.2);
  border-radius: 16px;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.8), inset 0 0 40px rgba(127, 239, 255, 0.05);
  display: flex;
  flex-direction: column;
  transform: scale(0.95) translateY(20px);
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  overflow: hidden;
}

.cert-modal.active .cert-modal-window {
  transform: scale(1) translateY(0);
}

.cert-modal-header {
  position: absolute;
  top: 0;
  right: 0;
  width: 100%;
  background: transparent;
  border-bottom: none;
  padding: 1.5rem 1.5rem;
  display: flex;
  justify-content: flex-end;
  pointer-events: none; /* allow clicks to pass through header bg */
  z-index: 20;
}

.cert-modal-header .browser-dots,
.cert-modal-header .modal-address-bar {
  display: none !important;
}

.cert-modal-header .modal-controls {
  pointer-events: auto;
}

.cert-modal .modal-btn-icon.close-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(2, 6, 18, 0.4);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(127, 239, 255, 0.3);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
  font-size: 0; /* Hides the "CLOSE" text */
  padding: 0;
  transition: all 0.3s ease;
}

.cert-modal .modal-btn-icon.close-btn i {
  font-size: 1.3rem; /* Keep icon visible */
  margin: 0;
}

.cert-modal .modal-btn-icon.close-btn:hover {
  background: rgba(0, 216, 255, 0.15);
  border-color: #00D8FF;
  box-shadow: 0 0 15px rgba(0, 216, 255, 0.5);
  transform: rotate(90deg);
}

.cert-modal-body {
  flex-grow: 1;
  padding: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  background: transparent;
}

#cert-modal-reset-3d {
  display: none !important; /* Remove legacy 3D reset button */
}

.ar-3d-stage-viewport {
  position: relative;
  width: 100%;
  height: 68vh;
  min-height: 420px;
  display: flex;
  align-items: center;
  justify-content: center;
  perspective: 1200px;
  cursor: grab;
  overflow: hidden;
  user-select: none;
}

.ar-3d-stage-viewport:active {
  cursor: grabbing;
}

/* AR Grid Floor Backdrop */
.ar-grid-backdrop {
  position: absolute;
  inset: 0;
  background-image: 
    linear-gradient(rgba(0, 242, 254, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 242, 254, 0.08) 1px, transparent 1px);
  background-size: 30px 30px;
  pointer-events: none;
}

/* Target Reticles in corners */
.ar-reticle {
  position: absolute;
  font-family: var(--font-pixel);
  font-size: 0.9rem;
  color: var(--matrix-cyan);
  opacity: 0.6;
  pointer-events: none;
}
.ar-reticle.tl { top: 20px; left: 20px; }
.ar-reticle.tr { top: 20px; right: 20px; }
.ar-reticle.bl { bottom: 20px; left: 20px; }
.ar-reticle.br { bottom: 20px; right: 20px; }

/* AR Laser Scanning Beam */
.ar-laser-scanner {
  position: absolute;
  left: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--matrix-cyan), var(--mario-coin), var(--matrix-cyan), transparent);
  box-shadow: 0 0 15px var(--matrix-cyan), 0 0 30px var(--matrix-cyan);
  pointer-events: none;
  z-index: 5;
  animation: arScanBeam 3.5s ease-in-out infinite alternate;
}

@keyframes arScanBeam {
  0% { top: 5%; opacity: 0.2; }
  50% { opacity: 0.9; }
  100% { top: 92%; opacity: 0.2; }
}

/* 3D Certificate Card Stage */
.ar-3d-card-stage {
  position: relative;
  width: min(85%, 820px);
  height: min(80%, 520px);
  transform-style: preserve-3d;
  transition: transform 0.1s ease-out;
}

.ar-3d-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
  border: 3px solid var(--mario-coin);
  box-shadow: 0 0 35px rgba(255, 215, 0, 0.4), 15px 20px 35px rgba(0, 0, 0, 0.7);
  background: #020612;
}

.ar-3d-card-inner img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.ar-card-shine {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 6;
  background: radial-gradient(
    circle at var(--modal-shine-x, 50%) var(--modal-shine-y, 50%),
    rgba(255, 255, 255, 0.35) 0%,
    rgba(0, 242, 254, 0.15) 35%,
    transparent 65%
  );
  mix-blend-mode: overlay;
}

.ar-badge-seal {
  position: absolute;
  bottom: -15px;
  right: -15px;
  font-family: var(--font-pixel);
  font-size: 0.45rem;
  padding: 6px 12px;
  background: var(--mario-coin);
  color: #000;
  border: 2px solid #000;
  box-shadow: 4px 4px 0 #000;
  letter-spacing: 1px;
  transform: translateZ(40px);
}

.ar-modal-footer-hint {
  padding: 0.8rem 1.4rem;
  background: #050b1a;
  border-top: 2px solid var(--glass-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-pixel);
  font-size: 0.45rem;
  color: var(--matrix-cyan);
  letter-spacing: 1px;
}

.ar-status-pulse {
  color: var(--matrix-green);
  animation: blinkCursor 1s step-end infinite;
}

/* =========================================================================
   FOOTER
   ========================================================================= */
footer {
  padding: 2.5rem 0;
  border-top: 4px solid #5a1500;
  background: #8b2500;
  text-align: center;
  position: relative;
  overflow: hidden;
}

footer::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    repeating-linear-gradient(90deg, transparent 0px, transparent 38px, rgba(0,0,0,0.18) 38px, rgba(0,0,0,0.18) 40px),
    repeating-linear-gradient(180deg, transparent 0px, transparent 18px, rgba(0,0,0,0.12) 18px, rgba(0,0,0,0.12) 20px);
  pointer-events: none;
}

footer p {
  color: var(--mario-coin);
  font-family: var(--font-pixel);
  font-size: 0.45rem;
  letter-spacing: 2px;
  text-shadow: 1px 1px 0 #000;
  position: relative;
  z-index: 1;
}

/* =========================================================================
   SCROLLBAR
   ========================================================================= */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #000; }
::-webkit-scrollbar-thumb { background: var(--mario-coin); border-radius: 0; }
::-webkit-scrollbar-thumb:hover { background: var(--matrix-green); }

/* =========================================================================
   SECTION GLASS OVERLAY
   ========================================================================= */
#about, #skills, #projects, #journey, #contact {
  background: rgba(5, 7, 15, 0.85);
  backdrop-filter: blur(6px);
  border-top: 3px solid rgba(0,255,65,0.08);
}

/* Hide old ambient glows */
.ambient-glow { display: none; }
.glow-3 { display: none; }

/* =========================================================================
   RESPONSIVE
   ========================================================================= */
@media (max-width: 1180px) {
  .nav-link {
    font-size: 0.68rem;
    padding: 0.45rem 0.55rem;
  }
  .nav-brand {
    font-size: 1.05rem;
  }
}

@media (max-width: 960px) {
  .hero-quote-main { font-size: 0.9rem; }
  .about-grid { grid-template-columns: 1fr; }
  .timeline::before { left: 20px; }
  .timeline-item { width: 100%; padding-left: 50px; text-align: left !important; }
  .timeline-item:nth-child(odd) .timeline-dot,
  .timeline-item:nth-child(even) .timeline-dot { left: 12px; right: auto; }
  .navbar-inner { padding: 0.7rem 1.2rem; }
  .nav-coin-counter, .nav-lives, .nav-cta { display: none; }
  
  .mobile-toggle { display: block; }
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(100, 25, 0, 0.96);
    backdrop-filter: blur(14px);
    border-bottom: 4px solid #5a1500;
    box-shadow: 0 12px 30px rgba(0,0,0,0.85);
    flex-direction: column;
    padding: 1.2rem 1rem;
    gap: 0.6rem;
    z-index: 1000;
  }
  .nav-links.active {
    display: flex;
  }
  .nav-link {
    font-size: 0.85rem;
    padding: 0.85rem 1rem;
    width: 100%;
    text-align: center;
    border: 2px solid rgba(255, 215, 0, 0.2);
    background: rgba(0, 0, 0, 0.3);
  }
  .nav-link:hover, .nav-link.active {
    border-color: var(--mario-coin);
    background: rgba(255, 215, 0, 0.25);
  }
}

@media (max-width: 768px) {
  .hero-quote-main { font-size: 0.72rem; line-height: 2.5; }
  .section-title { font-size: 2rem; }
  .hero-pixel-box { padding: 1.5rem 1rem; }
}

/* =========================================================================
   BINARY QUOTE CANVAS (hero center)
   ========================================================================= */
#binary-quote-canvas {
  display: block;
  width: 100%;
  height: 200px;
  margin: 0.8rem 0 1.2rem 0;
  image-rendering: pixelated;
}

@media (max-width: 768px) {
  #binary-quote-canvas { height: 150px; }
}

/* =========================================================================
   HERO SECTION - Full screen, canvas renders the quote
   ========================================================================= */
.hero-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 0;
  position: relative;
}

/* =========================================================================
   3D MARIO ARCADE STAGE & VOXEL ENGINE
   ========================================================================= */

.arcade-3d-card {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  border: 3px solid var(--glass-border);
  box-shadow: 8px 8px 0 rgba(0, 0, 0, 0.6), 0 0 25px rgba(255, 215, 0, 0.15);
  position: relative;
  overflow: hidden;
  margin-top: 1rem;
}

.arcade-3d-header {
  background: rgba(5, 11, 26, 0.95);
  border-bottom: 2px solid var(--glass-border);
  padding: 0.8rem 1.4rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.arcade-3d-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-pixel);
  font-size: 0.6rem;
  color: var(--mario-coin);
  letter-spacing: 1px;
}

.arcade-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
}
.arcade-dot.red { background: #e03020; box-shadow: 0 0 6px #e03020; }
.arcade-dot.yellow { background: #ffd700; box-shadow: 0 0 6px #ffd700; }
.arcade-dot.green { background: #00ff41; box-shadow: 0 0 6px #00ff41; }

.arcade-3d-hint {
  font-family: var(--font-pixel);
  font-size: 0.42rem;
  color: var(--matrix-cyan);
  background: rgba(0, 242, 254, 0.08);
  border: 1px solid rgba(0, 242, 254, 0.3);
  padding: 0.4rem 0.8rem;
  letter-spacing: 1px;
}

.arcade-3d-canvas-container {
  position: relative;
  width: 100%;
  height: 440px;
  background: radial-gradient(circle at 50% 40%, #1a3a8a 0%, #050b1a 85%);
  cursor: grab;
  overflow: hidden;
}

.arcade-3d-canvas-container:active {
  cursor: grabbing;
}

#mario-3d-stage-canvas {
  width: 100%;
  height: 100%;
  display: block;
}

#arcade-coin-popup {
  position: absolute;
  top: 40%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.5);
  font-family: var(--font-pixel);
  font-size: 1.2rem;
  color: #ffd700;
  text-shadow: 3px 3px 0 #000, 0 0 15px rgba(255, 215, 0, 0.9);
  pointer-events: none;
  opacity: 0;
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.4s ease;
  z-index: 20;
}

#arcade-coin-popup.active {
  transform: translate(-50%, -90%) scale(1.2);
  opacity: 1;
}

.arcade-3d-controls {
  padding: 1rem 1.4rem;
  background: rgba(5, 11, 26, 0.95);
  border-top: 2px solid var(--glass-border);
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}

.arcade-btn {
  font-family: var(--font-pixel);
  font-size: 0.45rem;
  padding: 0.6rem 1rem;
  background: rgba(255, 215, 0, 0.05);
  color: var(--text-main);
  border: 2px solid var(--glass-border);
  cursor: pointer;
  transition: var(--transition-fast);
  display: flex;
  align-items: center;
  gap: 8px;
  letter-spacing: 1px;
}

.arcade-btn:hover,
.arcade-btn.active {
  background: var(--mario-coin);
  color: #000;
  border-color: var(--mario-coin);
  box-shadow: 3px 3px 0 #000, 0 0 12px rgba(255, 215, 0, 0.4);
}

@media (max-width: 768px) {
  .arcade-3d-canvas-container {
    height: 320px;
  }
  .arcade-3d-hint {
    display: none;
  }
}
