/* ==========================================================================
   KUKUH DWI SAPUTRA - PORTFOLIO DESIGN SYSTEM (INTER UNIVERSAL TYPOGRAPHY)
   ========================================================================== */

:root {
  /* High-Contrast Color Palette */
  --bg-dark: #05070a;
  --bg-card: rgba(12, 16, 28, 0.94);
  --bg-card-hover: rgba(18, 24, 40, 0.98);
  --border-glass: rgba(255, 255, 255, 0.18);
  --border-glass-bright: rgba(0, 240, 255, 0.5);

  /* Ultra-Visible Typography Colors */
  --text-primary: #ffffff;
  --text-secondary: #cbd5e1;
  --text-muted: #94a3b8;

  /* Vibrant Accents */
  --accent-cyan: #00f0ff;
  --accent-purple: #a855f7;
  --accent-gold: #fbbf24;
  --accent-pink: #f43f5e;

  --gradient-primary: linear-gradient(135deg, #a855f7 0%, #00f0ff 100%);
  --gradient-glow: linear-gradient(135deg, rgba(168, 85, 247, 0.4) 0%, rgba(0, 240, 255, 0.4) 100%);

  /* Universal Clean Typography Stack (Inter / System Sans) */
  --font-heading: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  /* Layout */
  --radius-lg: 24px;
  --radius-md: 16px;
  --radius-sm: 10px;
  --transition-fast: 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-normal: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  scroll-behavior: smooth;
  color-scheme: dark;
  background-color: var(--bg-dark);
}

body {
  font-family: var(--font-body);
  color: var(--text-primary);
  background-color: var(--bg-dark);
  overflow-x: hidden;
  line-height: 1.6;
  letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: var(--bg-dark);
}

::-webkit-scrollbar-thumb {
  background: rgba(0, 240, 255, 0.4);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent-cyan);
}

/* Preloader - Full 100% Preload Experience */
.preloader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background-color: var(--bg-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.6s ease;
}

.preloader.fade-out {
  opacity: 0;
  visibility: hidden;
}

.preloader-content {
  text-align: center;
  max-width: 420px;
  width: 90%;
  padding: 40px 30px;
  background: var(--bg-card);
  backdrop-filter: blur(32px);
  -webkit-backdrop-filter: blur(32px);
  border: 1px solid var(--border-glass-bright);
  border-radius: var(--radius-lg);
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.85);
}

.logo-mark {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.logo-spinner {
  width: 24px;
  height: 24px;
  border: 3px solid rgba(255, 255, 255, 0.2);
  border-top-color: var(--accent-cyan);
  border-radius: 50%;
  animation: spin 0.8s infinite linear;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.logo-text {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #fff;
}

.highlight {
  color: var(--accent-cyan);
}

.preloader-subtitle {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin-bottom: 24px;
}

.progress-bar-container {
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 16px;
}

.progress-bar {
  width: 0%;
  height: 100%;
  background: var(--gradient-primary);
  border-radius: 3px;
  transition: width 0.1s linear;
}

.preloader-stats {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  color: var(--text-secondary);
  font-weight: 600;
}

/* Background Canvas */
.canvas-wrapper {
  position: fixed;
  inset: 0;
  z-index: 1;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
}

#motion-canvas {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.canvas-overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(5, 7, 10, 0.25) 0%, rgba(5, 7, 10, 0.75) 100%);
  pointer-events: none;
  transition: background 0.6s ease;
}

/* Header Navigation (High Contrast Floating Glass Bar) */
.main-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 20px 40px;
  transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1), transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.main-header.hidden-nav {
  opacity: 0;
  pointer-events: none;
  transform: translateY(-24px);
}

.main-header.visible-nav {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.header-container {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 24px;
  background: rgba(10, 14, 26, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 100px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: #ffffff;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
}

.brand-dot {
  width: 10px;
  height: 10px;
  background: var(--accent-cyan);
  border-radius: 50%;
  box-shadow: 0 0 12px var(--accent-cyan);
}

.accent {
  color: var(--accent-cyan);
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-link {
  color: #e2e8f0;
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 600;
  transition: color var(--transition-fast);
}

.nav-link:hover,
.nav-link.active {
  color: var(--accent-cyan);
  text-shadow: 0 0 10px rgba(0, 240, 255, 0.4);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 100px;
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  border: none;
  letter-spacing: -0.01em;
  transition: all var(--transition-fast);
}

.btn-primary {
  background: #ffffff;
  color: var(--bg-dark);
}

.btn-primary:hover {
  background: var(--accent-cyan);
  color: var(--bg-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 240, 255, 0.4);
}

.btn-glass {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.btn-glass:hover {
  background: rgba(255, 255, 255, 0.22);
  border-color: var(--accent-cyan);
  transform: translateY(-2px);
}

.btn-glow {
  background: var(--gradient-primary);
  color: #ffffff;
  box-shadow: 0 0 24px rgba(168, 85, 247, 0.5);
}

.btn-glow:hover {
  box-shadow: 0 0 35px rgba(0, 240, 255, 0.7);
  transform: translateY(-2px);
}

.btn-full {
  width: 100%;
  justify-content: center;
  padding: 14px;
}

.btn-ai-hero {
  border-color: rgba(0, 240, 255, 0.5);
  background: rgba(0, 240, 255, 0.15);
  color: var(--accent-cyan);
}

.btn-ai-hero:hover {
  background: var(--gradient-primary);
  color: #ffffff;
  border-color: transparent;
  box-shadow: 0 0 25px rgba(0, 240, 255, 0.6);
}

/* ==========================================================================
   PHASE 1: MOTION TRACK SHOWCASE (VIDEO FIRST WITH SIMPLE BOTTOM WELCOME)
   ========================================================================== */
.motion-scroll-track {
  position: relative;
  height: 250vh;
  z-index: 10;
}

.bottom-welcome-prompt {
  position: fixed;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 15;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  pointer-events: none;
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1), transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  width: 90%;
  max-width: 380px;
}

.welcome-badge {
  background: rgba(10, 14, 26, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(0, 240, 255, 0.45);
  padding: 8px 22px;
  border-radius: 100px;
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 1px;
  color: var(--accent-cyan);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.75);
  text-align: center;
}

.scroll-down-hint {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #f1f5f9;
  font-size: 0.85rem;
  font-weight: 600;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.95);
}

.bounce-icon {
  animation: bounce 2s infinite;
  color: var(--accent-cyan);
}

@keyframes bounce {

  0%,
  20%,
  50%,
  80%,
  100% {
    transform: translateY(0);
  }

  40% {
    transform: translateY(6px);
  }

  60% {
    transform: translateY(3px);
  }
}

/* ==========================================================================
   PHASE 2: PORTFOLIO CONTENT CONTAINER (HIGH CONTRAST GLASS CARDS)
   ========================================================================== */
.content-wrapper {
  position: relative;
  z-index: 20;
  background: linear-gradient(180deg, rgba(5, 7, 10, 0.5) 0%, rgba(5, 7, 10, 0.95) 180px, rgba(5, 7, 10, 0.99) 100%);
  margin-top: -60px;
  padding-top: 60px;
  transition: opacity 0.5s ease;
}

.portfolio-section {
  min-height: 90vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 90px 20px;
  box-sizing: border-box;
}

.section-content {
  max-width: 1100px;
  width: 100%;
  margin: 0 auto;
}

/* Glass Card Component with Maximum Visibility */
.glass-card {
  background: var(--bg-card);
  backdrop-filter: blur(32px);
  -webkit-backdrop-filter: blur(32px);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 44px;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.75);
  transition: border-color var(--transition-fast);
}

.glass-card:hover {
  border-color: var(--border-glass-bright);
}

/* Hero Section */
.hero-title {
  font-family: var(--font-heading);
  letter-spacing: -0.03em;
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  line-height: 1.15;
}

.hero-subtitle {
  font-size: 1.1rem;
  line-height: 1.7;
}

.hero-cta-group {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 24px;
}

/* Biodata Card Styling */
.biodata-card {
  position: relative;
}

.biodata-header {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-bottom: 32px;
}

.profile-avatar {
  width: 76px;
  height: 76px;
  border-radius: 50%;
  background: var(--gradient-glow);
  border: 2px solid var(--accent-cyan);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-cyan);
  flex-shrink: 0;
  box-shadow: 0 0 24px rgba(0, 240, 255, 0.35);
}

.profile-avatar svg {
  width: 36px;
  height: 36px;
}

.profile-subtitle {
  color: var(--text-secondary);
  font-size: 1rem;
  font-weight: 500;
  margin-top: 4px;
}

.biodata-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-bottom: 28px;
}

.bio-detail-item {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 14px 18px;
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.detail-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
}

.detail-label svg {
  width: 15px;
  height: 15px;
  color: var(--accent-cyan);
}

.detail-val {
  font-size: 0.98rem;
  font-weight: 700;
  color: #ffffff;
}

.text-accent {
  color: var(--accent-cyan);
}

/* Contact Quick Pills */
.contact-quick-pills {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.quick-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 100px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-decoration: none;
  transition: all var(--transition-fast);
}

.quick-pill svg {
  width: 15px;
  height: 15px;
  color: var(--accent-cyan);
}

a.quick-pill:hover {
  background: rgba(0, 240, 255, 0.2);
  border-color: var(--accent-cyan);
  color: #ffffff;
}

.card-divider {
  border: none;
  height: 1px;
  background: rgba(255, 255, 255, 0.15);
  margin: 28px 0;
}

.subsection-title {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 14px;
  color: var(--accent-purple);
}

.card-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  color: var(--accent-cyan);
  margin-bottom: 12px;
}

.card-title {
  font-family: var(--font-heading);
  font-size: clamp(1.9rem, 3.5vw, 2.6rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
  color: #ffffff;
}

.card-text {
  color: var(--text-secondary);
  font-size: 1.02rem;
  line-height: 1.75;
  margin-bottom: 30px;
}

/* Stats Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 20px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.stat-item {
  text-align: center;
}

.stat-number {
  font-family: var(--font-heading);
  font-size: 2.2rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--accent-cyan);
  text-shadow: 0 0 15px rgba(0, 240, 255, 0.3);
}

.stat-label {
  font-size: 0.85rem;
  color: var(--text-secondary);
  font-weight: 600;
}

/* Experience Styling */
.exp-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 20px;
}

.exp-role {
  font-family: var(--font-heading);
  font-size: 1.45rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #ffffff;
}

.exp-period {
  background: rgba(0, 240, 255, 0.18);
  border: 1px solid rgba(0, 240, 255, 0.4);
  padding: 6px 16px;
  border-radius: 100px;
  font-size: 0.85rem;
  font-weight: 800;
  color: var(--accent-cyan);
}

.exp-bullet-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.exp-bullet-list li {
  position: relative;
  padding-left: 26px;
  color: var(--text-secondary);
  font-size: 0.98rem;
  line-height: 1.65;
}

.exp-bullet-list li::before {
  content: "▹";
  position: absolute;
  left: 0;
  color: var(--accent-cyan);
  font-weight: 800;
  font-size: 1.1rem;
}

.exp-bullet-list li strong {
  color: #ffffff;
  font-weight: 700;
}

/* Projects Section */
.section-header {
  text-align: center;
  margin-bottom: 48px;
}

.section-subtitle {
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 1px;
  color: var(--accent-cyan);
  display: block;
  margin-bottom: 8px;
}

.section-title {
  font-family: var(--font-heading);
  font-size: clamp(2.1rem, 4vw, 3.2rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: #ffffff;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.project-card {
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.project-banner {
  height: 180px;
  position: relative;
  background-size: cover;
  background-position: center;
  padding: 16px;
  display: flex;
  align-items: flex-start;
}

.project-bg-1 {
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.5), rgba(5, 7, 10, 0.95));
}

.project-bg-2 {
  background: linear-gradient(135deg, rgba(0, 240, 255, 0.5), rgba(5, 7, 10, 0.95));
}

.project-bg-3 {
  background: linear-gradient(135deg, rgba(244, 63, 94, 0.5), rgba(5, 7, 10, 0.95));
}

.badge {
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.25);
  padding: 5px 12px;
  border-radius: 100px;
  font-size: 0.75rem;
  font-weight: 800;
  color: #ffffff;
}

.project-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.project-title {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 10px;
  color: #ffffff;
}

.project-desc {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin-bottom: 20px;
  flex-grow: 1;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.project-tags span {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-secondary);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 4px 10px;
  border-radius: 6px;
}

.btn-link {
  background: none;
  border: none;
  color: var(--accent-cyan);
  font-weight: 800;
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  padding: 0;
  transition: gap var(--transition-fast);
}

.btn-link:hover {
  gap: 10px;
  color: #ffffff;
}

/* Skills Section */
.skills-columns {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 30px;
  margin-top: 20px;
}

.skill-category h4 {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--accent-cyan);
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.skill-pill {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 8px 16px;
  border-radius: 100px;
  font-size: 0.88rem;
  font-weight: 600;
  color: #ffffff;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.skill-pill:hover {
  background: rgba(168, 85, 247, 0.25);
  border-color: var(--accent-purple);
}

.badge-cert {
  border-color: rgba(0, 240, 255, 0.5);
  background: rgba(0, 240, 255, 0.15);
  color: var(--accent-cyan);
  font-weight: 700;
}

/* Education Section */
.edu-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.edu-header h3 {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 800;
  color: #ffffff;
}

.edu-year {
  color: var(--accent-cyan);
  font-size: 0.9rem;
  font-weight: 800;
}

.edu-degree {
  color: var(--text-secondary);
  font-size: 1.02rem;
  margin-top: 4px;
}

/* Contact Form */
.contact-card {
  max-width: 700px;
  margin: 0 auto;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 30px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group label {
  font-size: 0.88rem;
  font-weight: 700;
  color: #ffffff;
}

.form-group input,
.form-group select,
.form-group textarea {
  background: rgba(5, 7, 10, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  color: #ffffff;
  font-family: var(--font-body);
  font-size: 0.98rem;
  outline: none;
  transition: border-color var(--transition-fast);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 12px rgba(0, 240, 255, 0.3);
}

.social-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.social-icon {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: all var(--transition-fast);
}

.social-icon:hover {
  background: var(--accent-cyan);
  color: var(--bg-dark);
  transform: translateY(-3px);
  box-shadow: 0 0 20px rgba(0, 240, 255, 0.5);
}

/* ==========================================================================
   ULTRA-PREMIUM FLOATING AI ASSISTANT CHAT WIDGET STYLES (INTER CLEAN)
   ========================================================================== */
.ai-chat-widget {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 1000;
}

.ai-chat-trigger {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 22px;
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.95), rgba(0, 240, 255, 0.95));
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 100px;
  color: #ffffff;
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  cursor: pointer;
  box-shadow: 0 12px 35px rgba(0, 240, 255, 0.45);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.ai-chat-trigger:hover {
  transform: translateY(-4px) scale(1.03);
  box-shadow: 0 18px 45px rgba(168, 85, 247, 0.65);
}

.ai-trigger-pulse {
  position: absolute;
  inset: -3px;
  border-radius: 100px;
  background: var(--gradient-primary);
  opacity: 0.5;
  filter: blur(8px);
  z-index: -1;
  animation: auraPulse 2.5s infinite ease-in-out;
}

@keyframes auraPulse {

  0%,
  100% {
    opacity: 0.4;
    transform: scale(1);
  }

  50% {
    opacity: 0.8;
    transform: scale(1.06);
  }
}

.ai-trigger-icon {
  display: flex;
  align-items: center;
  justify-content: center;
}

.ai-trigger-icon svg {
  width: 20px;
  height: 20px;
  color: #ffffff;
}

/* Chat Modal Window Panel (Strict Flexible Box Model Layout) */
.ai-chat-panel {
  position: fixed;
  bottom: 86px;
  right: 24px;
  width: 420px;
  max-width: calc(100vw - 32px);
  height: 560px;
  max-height: 80vh;
  padding: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  z-index: 1001;
  background: rgba(10, 14, 26, 0.96);
  backdrop-filter: blur(36px);
  -webkit-backdrop-filter: blur(36px);
  border: 1px solid rgba(0, 240, 255, 0.45);
  border-radius: 24px;
  box-shadow: 0 35px 80px rgba(0, 0, 0, 0.95);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.ai-chat-header {
  flex-shrink: 0;
  padding: 16px 20px;
  background: linear-gradient(135deg, rgba(18, 24, 40, 0.98), rgba(10, 14, 26, 0.98));
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.ai-avatar-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

.ai-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--gradient-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  box-shadow: 0 0 16px rgba(0, 240, 255, 0.5);
  border: 2px solid rgba(255, 255, 255, 0.3);
  flex-shrink: 0;
}

.ai-avatar svg {
  width: 20px;
  height: 20px;
}

.ai-title {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #ffffff;
  line-height: 1.2;
}

.ai-status-text {
  font-size: 0.73rem;
  color: var(--accent-cyan);
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 700;
}

.status-dot {
  width: 7px;
  height: 7px;
  background: var(--accent-cyan);
  border-radius: 50%;
  box-shadow: 0 0 10px var(--accent-cyan);
  flex-shrink: 0;
}

.ai-close-btn {
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #ffffff;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
  flex-shrink: 0;
}

.ai-close-btn:hover {
  background: var(--accent-pink);
  border-color: var(--accent-pink);
}

/* Quick Question Suggestions Bar (Horizontal Smooth Scroll Container) */
.ai-suggestions-bar {
  flex-shrink: 0;
  padding: 10px 14px;
  background: rgba(5, 7, 10, 0.85);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  gap: 8px;
  overflow-x: auto;
  white-space: nowrap;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.ai-suggestions-bar::-webkit-scrollbar {
  display: none;
}

.ai-chip {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.22);
  color: var(--text-secondary);
  padding: 6px 14px;
  border-radius: 100px;
  font-size: 0.78rem;
  font-weight: 700;
  white-space: nowrap;
  cursor: pointer;
  box-sizing: border-box;
  transition: all var(--transition-fast);
}

.ai-chip:hover,
.ai-chip:active {
  background: rgba(0, 240, 255, 0.25);
  border-color: var(--accent-cyan);
  color: #ffffff;
  transform: translateY(-1px);
}

/* Chat History Window (Flexible Scrollable Message Area) */
.ai-chat-history {
  flex-grow: 1;
  flex-shrink: 1;
  min-height: 0;
  padding: 16px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
  box-sizing: border-box;
}

.chat-bubble {
  max-width: 86%;
  padding: 12px 16px;
  border-radius: 18px;
  font-size: 0.9rem;
  line-height: 1.55;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
  word-break: break-word;
}

.assistant-bubble {
  align-self: flex-start;
  background: rgba(18, 24, 40, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-left: 4px solid var(--accent-cyan);
  color: #f8fafc;
  border-bottom-left-radius: 4px;
}

.user-bubble {
  align-self: flex-end;
  background: var(--gradient-primary);
  color: #ffffff;
  border-bottom-right-radius: 4px;
  font-weight: 600;
}

.system-note {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 8px;
  padding-top: 6px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  font-weight: 600;
}

/* Chat Input Form */
.ai-chat-input-form {
  flex-shrink: 0;
  padding: 12px 14px;
  background: rgba(18, 24, 40, 0.98);
  border-top: 1px solid rgba(255, 255, 255, 0.18);
  display: flex;
  gap: 10px;
}

.ai-chat-input-form input {
  flex-grow: 1;
  background: rgba(5, 7, 10, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 100px;
  padding: 10px 16px;
  color: #ffffff;
  font-family: var(--font-body);
  font-size: 0.88rem;
  outline: none;
}

.ai-chat-input-form input:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 12px rgba(0, 240, 255, 0.35);
}

.ai-send-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--gradient-primary);
  border: none;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: transform var(--transition-fast);
}

.ai-send-btn:hover {
  transform: scale(1.08);
}

/* Modal */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(5, 7, 10, 0.9);
  backdrop-filter: blur(20px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  transition: opacity 0.3s ease;
}

.modal-overlay.hidden {
  opacity: 0;
  pointer-events: none;
}

.modal-content {
  position: relative;
  max-width: 650px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
}

.modal-close-btn {
  position: absolute;
  top: 20px;
  right: 20px;
  background: rgba(255, 255, 255, 0.15);
  border: none;
  color: #ffffff;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-close-btn:hover {
  background: var(--accent-cyan);
  color: var(--bg-dark);
}

.hidden {
  display: none !important;
}

/* ==========================================================================
   MOBILE & TABLET RESPONSIVE BREAKPOINTS (< 768px & < 480px)
   ========================================================================== */
@media (max-width: 768px) {
  .main-header {
    padding: 12px 16px;
  }

  .header-container {
    padding: 10px 16px;
  }

  .nav-menu {
    display: none;
  }

  .portfolio-section {
    padding: 60px 16px;
    min-height: auto;
  }

  .glass-card {
    padding: 28px 20px;
    border-radius: 18px;
  }

  .hero-title {
    font-size: clamp(1.7rem, 6vw, 2.2rem);
  }

  .biodata-header {
    flex-direction: column;
    text-align: center;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .bottom-welcome-prompt {
    bottom: 24px;
  }

  .ai-chat-widget {
    bottom: 16px;
    right: 16px;
  }

  .ai-chat-trigger {
    padding: 10px 16px;
    font-size: 0.82rem;
  }

  .ai-chat-panel {
    right: 12px;
    left: 12px;
    width: auto;
    max-width: calc(100vw - 24px);
    bottom: 74px;
    height: 72vh;
    border-radius: 20px;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .hero-cta-group {
    flex-direction: column;
    width: 100%;
  }

  .hero-cta-group .btn {
    width: 100%;
    justify-content: center;
  }

  .stats-grid {
    grid-template-columns: 1fr 1fr;
  }

  .ai-chat-panel {
    right: 8px;
    left: 8px;
    bottom: 68px;
    height: 75vh;
  }
}