/* ==========================================================================
   MUHAMMED MUBASHIR MK — CLOUD & DEVOPS PORTFOLIO
   Theme: Electric Teal Dark Aesthetic (1:1 Vercel / v0 Architecture)
   Palette: Background (#040609) + Card (#0A0E11) + Primary Teal (#00CAB1)
   Typography: Inter + JetBrains Mono
   ========================================================================== */

/* --------------------------------------------------------------------------
   01. DESIGN TOKENS & VARIABLES
   -------------------------------------------------------------------------- */
:root {
  /* Exact Color Palette */
  --background: #040609;
  --foreground: #eeeeee;
  --card: #0a0e11;
  --card-foreground: #eeeeee;
  --card-hover-border: rgba(0, 202, 177, 0.5);
  
  --popover: #0a0e11;
  --popover-foreground: #eeeeee;
  
  --primary: #00cab1;
  --primary-hover: #00b59f;
  --primary-foreground: #040609;
  --primary-dim: rgba(0, 202, 177, 0.1);
  --primary-border: rgba(0, 202, 177, 0.3);
  --primary-glow: rgba(0, 202, 177, 0.35);

  --secondary: #171b1f;
  --secondary-foreground: #cecece;

  --muted: #171b1f;
  --muted-foreground: #8f8f8f;

  --accent: #00cab1;
  --accent-foreground: #040609;

  --destructive: #e40014;
  --destructive-foreground: #eeeeee;

  --border: #25292e;
  --border-subtle: #171b1f;
  --input: #171b1f;
  --ring: #00cab1;

  /* WhatsApp Brand Color */
  --color-whatsapp: #00c758;
  --color-whatsapp-hover: #00a544;

  /* Radii */
  --radius-xs: 0.125rem;
  --radius-sm: 0.25rem;
  --radius: 0.5rem;
  --radius-lg: 0.625rem;
  --radius-xl: 0.75rem;
  --radius-2xl: 1rem;
  --radius-full: 9999px;

  /* Fonts */
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: "JetBrains Mono", "SF Mono", Consolas, monospace;

  /* Layout */
  --max-width: 1200px;
  --gutter: clamp(1.25rem, 5vw, 2.5rem);
  --header-height: 4.5rem;

  /* Frame & Canvas Tokens (Dark Default) */
  --frame-bg: #080809;
  --frame-border: rgba(255, 255, 255, 0.05);
  --frame-shadow: 0 25px 60px rgba(0, 0, 0, 0.9);
}

/* --------------------------------------------------------------------------
   01B. LIGHT THEME TOKENS (PREMIUM CRISP PALETTE)
   -------------------------------------------------------------------------- */
[data-theme="light"] {
  --background: #f8fafc;
  --foreground: #0f172a;
  --card: #ffffff;
  --card-foreground: #0f172a;
  --card-hover-border: rgba(13, 148, 136, 0.45);
  
  --popover: #ffffff;
  --popover-foreground: #0f172a;
  
  --primary: #0d9488;
  --primary-hover: #0f766e;
  --primary-foreground: #ffffff;
  --primary-dim: rgba(13, 148, 136, 0.1);
  --primary-border: rgba(13, 148, 136, 0.35);
  --primary-glow: rgba(13, 148, 136, 0.25);

  --secondary: #f1f5f9;
  --secondary-foreground: #334155;

  --muted: #f1f5f9;
  --muted-foreground: #64748b;

  --accent: #0d9488;
  --accent-foreground: #ffffff;

  --destructive: #e11d48;
  --destructive-foreground: #ffffff;

  --border: #e2e8f0;
  --border-subtle: #f1f5f9;
  --input: #ffffff;
  --ring: #0d9488;

  --frame-bg: #e2e8f0;
  --frame-border: rgba(0, 0, 0, 0.08);
  --frame-shadow: 0 20px 50px rgba(15, 23, 42, 0.08);
}

/* --------------------------------------------------------------------------
   02. RESET & BASE ELEMENTS
   -------------------------------------------------------------------------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  background-color: var(--frame-bg);
  color: var(--foreground);
  height: 100%;
  overflow: hidden;
}

body {
  font-family: var(--font-sans);
  background-color: var(--frame-bg);
  color: var(--foreground);
  line-height: 1.6;
  overflow: hidden; /* fixed, non-scrolling outer frame */
  height: 100vh;
  width: 100vw;
  margin: 0;
  padding: 0;
  position: relative;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color 0.35s ease, color 0.35s ease;
}

/* --------------------------------------------------------------------------
   02B. CURVED APP FRAME CANVAS WRAPPER & MINIMALIST SCROLLBAR
   -------------------------------------------------------------------------- */
.portfolio-wrapper {
  position: relative;
  margin: 10px;
  height: calc(100vh - 20px);
  max-height: calc(100vh - 20px);
  width: calc(100vw - 20px);
  max-width: calc(100vw - 20px);
  background-color: var(--background);
  border-radius: 16px;
  border: 1px solid var(--frame-border);
  overflow-y: auto;
  overflow-x: hidden;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-height) + 1rem);
  box-shadow: 
    var(--frame-shadow),
    inset 0 0 0 1px rgba(0, 202, 177, 0.04);
  scrollbar-width: thin;
  scrollbar-color: rgba(20, 233, 171, 0.2) transparent;
  transition: background-color 0.35s ease, border-color 0.35s ease, box-shadow 0.35s ease;
}

/* Minimalist Custom Scrollbar */
.portfolio-wrapper::-webkit-scrollbar {
  width: 6px;
}

.portfolio-wrapper::-webkit-scrollbar-track {
  background: transparent;
}

.portfolio-wrapper::-webkit-scrollbar-thumb {
  background: rgba(20, 233, 171, 0.2);
  border-radius: 9999px;
  transition: background-color 0.25s ease;
}

.portfolio-wrapper::-webkit-scrollbar-thumb:hover {
  background: rgba(20, 233, 171, 0.5);
}

::selection {
  background-color: var(--primary);
  color: var(--primary-foreground);
}

.skip-nav-link {
  position: absolute;
  top: -100px;
  left: 1.5rem;
  background: var(--primary);
  color: var(--primary-foreground);
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 700;
  padding: 0.6rem 1.25rem;
  border-radius: var(--radius);
  z-index: 10000;
  transition: top 0.2s ease;
  text-decoration: none;
}

.skip-nav-link:focus {
  top: 1rem;
  outline: 2px solid #fff;
}

.container {
  width: 100%;
  max-width: var(--max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

main, #main-content {
  position: relative;
  z-index: 2;
}

/* --------------------------------------------------------------------------
   03. THEME BACKGROUND PATTERNS & GLOW
   -------------------------------------------------------------------------- */
.particle-canvas {
  position: fixed;
  top: 10px;
  left: 10px;
  width: calc(100vw - 20px);
  height: calc(100vh - 20px);
  border-radius: 16px;
  pointer-events: none;
  z-index: 1;
}

.bg-grid-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image: 
    linear-gradient(rgba(0, 202, 177, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 202, 177, 0.035) 1px, transparent 1px);
  background-size: 60px 60px;
  min-height: 100%;
}

.bg-ambient-orb {
  position: absolute;
  top: -200px;
  right: -200px;
  width: 800px;
  height: 800px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(0, 202, 177, 0.25) 0%, transparent 68%);
  filter: blur(80px);
  pointer-events: none;
  z-index: 0;
  opacity: 0.65;
}

/* --------------------------------------------------------------------------
   04. TYPOGRAPHY UTILITIES
   -------------------------------------------------------------------------- */
h1, h2, h3, h4, h5, h6 {
  color: var(--foreground);
  font-weight: 700;
  line-height: 1.2;
}

p {
  color: var(--muted-foreground);
  line-height: 1.65;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

.text-primary {
  color: var(--primary) !important;
}

.text-muted {
  color: var(--muted-foreground) !important;
}

.font-mono {
  font-family: var(--font-mono) !important;
}

/* --------------------------------------------------------------------------
   05. BUTTONS & UI PRIMITIVES
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.65rem 1.4rem;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: var(--radius);
  border: 1px solid transparent;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.25s ease;
}

.btn:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

.btn-primary {
  background-color: var(--primary);
  color: var(--primary-foreground);
  font-weight: 600;
}

.btn-primary:hover {
  background-color: var(--primary-hover);
  transform: translateY(-1px);
}

.btn-outline-primary {
  background-color: transparent;
  color: var(--muted-foreground);
  border-color: var(--primary-border);
}

.btn-outline-primary:hover {
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-1px);
}

.btn-secondary {
  background-color: var(--card);
  color: var(--foreground);
  border-color: var(--border);
}

.btn-secondary:hover {
  background-color: var(--secondary);
  border-color: var(--primary-border);
  color: var(--primary);
  transform: translateY(-1px);
}

.btn-pill-resume {
  background-color: transparent;
  color: var(--primary);
  border: 1px solid var(--primary-border);
  border-radius: var(--radius-full);
  padding: 0.45rem 1.15rem;
  font-size: 0.85rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.btn-pill-resume:hover {
  background-color: var(--primary);
  color: var(--primary-foreground);
  border-color: var(--primary);
  transform: translateY(-1px);
}

.btn-pill-resume:hover svg {
  transform: translate(2px, -2px);
}

.btn-whatsapp {
  background-color: var(--color-whatsapp);
  color: #fff;
  border-radius: var(--radius);
  font-weight: 600;
  padding: 0.85rem 1.5rem;
  width: 100%;
}

.btn-whatsapp:hover {
  background-color: var(--color-whatsapp-hover);
  transform: translateY(-1px);
}

/* --------------------------------------------------------------------------
   06. HEADER & FLOATING PILL NAVIGATION
   -------------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height);
  z-index: 1000;
  background-color: transparent;
  transition: all 0.3s ease;
  margin-bottom: calc(-1 * var(--header-height));
  border-top-left-radius: 16px;
  border-top-right-radius: 16px;
}

.site-header.scrolled {
  background-color: rgba(4, 6, 9, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(37, 41, 46, 0.6);
}

.header-container {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand-wrapper {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.brand-avatar-box {
  width: 40px;
  height: 40px;
  border-radius: var(--radius);
  overflow: hidden;
  border: 2px solid rgba(0, 202, 177, 0.5);
  transition: border-color 0.25s ease;
}

.brand-wrapper:hover .brand-avatar-box {
  border-color: var(--primary);
}

.brand-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

.brand-title {
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--foreground);
}

/* Floating Center Nav Pills */
.nav-pill-bar {
  display: flex;
  align-items: center;
  background-color: rgba(23, 27, 31, 0.6);
  border: 1px solid rgba(37, 41, 46, 0.7);
  border-radius: var(--radius-full);
  padding: 0.25rem 0.5rem;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  list-style: none;
}

.nav-pill-link {
  display: block;
  padding: 0.45rem 1rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--muted-foreground);
  border-radius: var(--radius-full);
  transition: all 0.25s ease;
}

.nav-pill-link:hover {
  color: var(--foreground);
}

.nav-pill-link.active {
  color: var(--foreground);
  background-color: rgba(255, 255, 255, 0.08);
}

.header-actions-group {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

/* Small Refined Theme Switcher Button */
.theme-toggle-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  background-color: var(--card);
  border: 1px solid var(--border);
  color: var(--muted-foreground);
  cursor: pointer;
  transition: all 0.25s ease;
  flex-shrink: 0;
  padding: 0;
}

.theme-toggle-btn:hover {
  color: var(--primary);
  border-color: var(--primary-border);
  background-color: var(--secondary);
  transform: translateY(-1px);
}

.theme-toggle-btn:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

.theme-toggle-btn:active {
  transform: scale(0.92);
}

.theme-toggle-btn svg {
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.2s ease;
}

.theme-toggle-btn:hover svg {
  transform: rotate(20deg);
}

/* Icon Switching: Dark Default (Sun visible), Light (Moon visible) */
.theme-icon-sun {
  display: block;
}
.theme-icon-moon {
  display: none;
}

[data-theme="light"] .theme-icon-sun {
  display: none;
}
[data-theme="light"] .theme-icon-moon {
  display: block;
}

/* Light Theme Component Overrides */
[data-theme="light"] .site-header.scrolled {
  background-color: rgba(248, 250, 252, 0.9);
  border-bottom: 1px solid rgba(226, 232, 240, 0.85);
}

[data-theme="light"] .nav-pill-bar {
  background-color: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(226, 232, 240, 0.9);
  box-shadow: 0 4px 15px rgba(15, 23, 42, 0.05);
}

[data-theme="light"] .nav-pill-link.active {
  background-color: rgba(15, 23, 42, 0.07);
  color: var(--foreground);
}

[data-theme="light"] .bg-grid-layer {
  background-image: 
    linear-gradient(rgba(13, 148, 136, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(13, 148, 136, 0.06) 1px, transparent 1px);
}

[data-theme="light"] .bg-ambient-orb {
  background: radial-gradient(circle, rgba(13, 148, 136, 0.12) 0%, transparent 68%);
  opacity: 0.5;
}

[data-theme="light"] .section-alt-bg {
  background-color: rgba(241, 245, 249, 0.65);
}

[data-theme="light"] .portrait-offset-frame {
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.1);
}

[data-theme="light"] .skill-card,
[data-theme="light"] .timeline-card,
[data-theme="light"] .edu-card,
[data-theme="light"] .contact-info-card,
[data-theme="light"] .contact-form-container {
  box-shadow: 0 4px 20px rgba(15, 23, 42, 0.05);
}

.mobile-nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  background-color: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--foreground);
  cursor: pointer;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s ease;
}

.mobile-nav-toggle:hover {
  background-color: var(--secondary);
}

/* Mobile Drawer */
.mobile-drawer {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 2000;
  visibility: hidden;
  pointer-events: none;
  transition: visibility 0.3s ease;
}

.mobile-drawer.open {
  visibility: visible;
  pointer-events: auto;
}

.mobile-drawer-backdrop {
  position: absolute;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.mobile-drawer.open .mobile-drawer-backdrop {
  opacity: 1;
}

.mobile-drawer-card {
  position: absolute;
  top: 0;
  right: 0;
  width: min(85vw, 360px);
  height: 100%;
  background-color: var(--card);
  border-left: 1px solid var(--border);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.mobile-drawer.open .mobile-drawer-card {
  transform: translateX(0);
}

.mobile-drawer-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--border);
}

.drawer-close-btn {
  background: transparent;
  border: none;
  color: var(--muted-foreground);
  font-size: 1.5rem;
  cursor: pointer;
}

.mobile-drawer-links {
  list-style: none;
  margin-top: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.mobile-drawer-item a {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--muted-foreground);
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border-subtle);
}

.mobile-drawer-item a:hover {
  color: var(--primary);
}

/* --------------------------------------------------------------------------
   07. HERO SECTION
   -------------------------------------------------------------------------- */
.hero-section {
  min-height: calc(100vh - 20px);
  display: flex;
  align-items: center;
  position: relative;
  padding-top: calc(var(--header-height) + 2.5rem);
  padding-bottom: 5rem;
  z-index: 2;
}

/* Ensure hero text, headers, visual cards and buttons are above canvas and fully interactive */
.hero-container {
  position: relative;
  z-index: 2;
}

.hero-text-block,
.hero-visual-block,
.hero-btn-row {
  position: relative;
  z-index: 2;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: clamp(2.5rem, 5vw, 4.5rem);
  align-items: center;
}

.hero-text-block {
  display: flex;
  flex-direction: column;
}

.hero-name-title {
  font-size: clamp(2.8rem, 5.5vw + 0.5rem, 5rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.035em;
  margin-bottom: 1rem;
}

.hero-subtitle {
  font-size: clamp(1.4rem, 2.2vw, 1.85rem);
  font-weight: 300;
  color: var(--muted-foreground);
  margin-bottom: 1.5rem;
}

.hero-lead-desc {
  font-size: 1.125rem;
  line-height: 1.7;
  color: var(--muted-foreground);
  max-width: 580px;
  margin-bottom: 2.25rem;
}

.hero-btn-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
}

/* Signature Offset Framed Portrait with Responsive 3D Parallax */
.portrait-offset-container {
  position: relative;
  width: 100%;
  max-width: 360px;
  margin: 0 auto;
  perspective: 1000px;
}

.portrait-offset-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: var(--radius-xl);
  overflow: hidden;
  background-color: var(--card);
  border: 1px solid var(--border);
  transform-style: preserve-3d;
  transition: transform 0.22s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
}

.portrait-offset-frame.ambient-floating {
  animation: portrait-ambient-float 6.5s ease-in-out infinite;
}

@keyframes portrait-ambient-float {
  0%, 100% {
    transform: perspective(1000px) translateY(0px) rotateX(0deg) rotateY(0deg);
  }
  50% {
    transform: perspective(1000px) translateY(-8px) rotateX(2deg) rotateY(-2deg);
  }
}

/* Offset Backdrop Border Frame */
.portrait-offset-backdrop {
  position: absolute;
  inset: -6px;
  border: 2px solid var(--primary);
  border-radius: calc(var(--radius-xl) + 2px);
  z-index: -1;
  transform: translate(16px, 16px);
  transition: transform 0.3s ease, border-color 0.3s ease;
  pointer-events: none;
  opacity: 0.85;
}

.portrait-offset-container:hover .portrait-offset-backdrop {
  transform: translate(8px, 8px);
  border-color: var(--primary);
  opacity: 1;
}

.portrait-image-tint {
  position: absolute;
  inset: 0;
  background-color: rgba(0, 202, 177, 0.08);
  transition: background-color 0.3s ease;
  z-index: 2;
  pointer-events: none;
}

.portrait-offset-frame:hover .portrait-image-tint {
  background-color: transparent;
}

.portrait-image-el {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 16%;
  display: block;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.portrait-offset-frame:hover .portrait-image-el {
  transform: scale(1.04);
}

.portrait-glare-sheen {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 3;
  opacity: 0;
  mix-blend-mode: overlay;
  transition: opacity 0.3s ease;
}

.portrait-offset-frame:hover .portrait-glare-sheen {
  opacity: 1;
}

/* --------------------------------------------------------------------------
   08. SECTION HEADINGS WITH HORIZONTAL DIVIDER LINE
   -------------------------------------------------------------------------- */
.section {
  padding-top: 6rem;
  padding-bottom: 6rem;
  position: relative;
  z-index: 2;
}

.section-alt-bg {
  background-color: rgba(10, 14, 17, 0.5);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}

.section-heading-wrap {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  margin-bottom: 3.5rem;
}

.section-heading-title {
  font-size: clamp(1.65rem, 3vw, 2.25rem);
  font-weight: 700;
  color: var(--foreground);
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  white-space: nowrap;
}

.section-prefix-num {
  font-family: var(--font-mono);
  color: var(--primary);
  font-size: 1.25rem;
  font-weight: 500;
}

.section-divider-line {
  height: 1px;
  background-color: var(--border);
  flex: 1;
  max-width: 320px;
}

/* --------------------------------------------------------------------------
   09. ABOUT SECTION
   -------------------------------------------------------------------------- */
.about-grid-content {
  max-width: 860px;
}

.about-body-text p {
  margin-bottom: 1.25rem;
  font-size: 1.05rem;
}

.tech-bullet-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 0.85rem 1.5rem;
  margin-top: 1.75rem;
  list-style: none;
}

.tech-bullet-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--muted-foreground);
}

.bullet-caret {
  color: var(--primary);
  font-size: 0.95rem;
}

/* --------------------------------------------------------------------------
   10. SKILLS SECTION — THEME CARDS
   -------------------------------------------------------------------------- */
.skills-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 1.5rem;
}

.theme-card {
  background-color: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 1.75rem;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
}

.theme-card:hover {
  border-color: var(--card-hover-border);
  transform: translateY(-2px);
}

.card-top-head {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin-bottom: 1.25rem;
}

.card-icon-square {
  padding: 0.55rem;
  border-radius: var(--radius);
  background-color: var(--primary-dim);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.theme-card:hover .card-icon-square {
  background-color: var(--primary);
  color: var(--primary-foreground);
}

.card-title-text {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--foreground);
}

.skill-pills-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.5rem;
}

.tag-pill {
  padding: 0.35rem 0.85rem;
  background-color: var(--secondary);
  color: var(--secondary-foreground);
  font-size: 0.8rem;
  border-radius: var(--radius-full);
  font-family: var(--font-mono);
  border: 1px solid transparent;
  transition: border-color 0.2s ease;
}

.tag-pill:hover {
  border-color: var(--primary-border);
}

.skill-status-tag {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  padding: 0.2rem 0.55rem;
  border-radius: var(--radius-full);
  background-color: var(--primary-dim);
  color: var(--primary);
  border: 1px solid var(--primary-border);
}

/* --------------------------------------------------------------------------
   11. LEARNING JOURNEY TIMELINE
   -------------------------------------------------------------------------- */
.timeline-stem-wrapper {
  position: relative;
  max-width: 860px;
  margin: 0 auto;
  padding-left: 2rem;
  border-left: 2px solid var(--border);
}

.timeline-entry-block {
  position: relative;
  padding-bottom: 2.5rem;
}

.timeline-entry-block:last-child {
  padding-bottom: 0;
}

.timeline-bullet-node {
  position: absolute;
  left: calc(-2rem - 9px);
  top: 4px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background-color: var(--primary);
  border: 4px solid var(--background);
}

.timeline-card-box {
  background-color: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 1.75rem;
  transition: all 0.3s ease;
}

.timeline-card-box:hover {
  border-color: var(--card-hover-border);
}

.timeline-entry-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--foreground);
  margin-bottom: 0.25rem;
}

.timeline-inst-name {
  color: var(--primary);
  font-weight: 500;
  font-size: 0.95rem;
  margin-bottom: 0.75rem;
}

/* --------------------------------------------------------------------------
   12. PROJECTS SECTION
   -------------------------------------------------------------------------- */
.projects-showcase-container {
  display: flex;
  flex-direction: column;
  gap: 4rem;
}

.project-feature-card {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 2.5rem;
  align-items: center;
}

.project-visual-preview {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: linear-gradient(135deg, rgba(0, 202, 177, 0.05), var(--card), rgba(0, 202, 177, 0.1));
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  text-align: center;
}

.project-visual-preview-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.project-preview-icon-box {
  width: 80px;
  height: 80px;
  border-radius: 1.25rem;
  background: linear-gradient(135deg, rgba(0, 202, 177, 0.3), rgba(0, 202, 177, 0.1));
  border: 1px solid rgba(0, 202, 177, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
}

.project-feature-details {
  display: flex;
  flex-direction: column;
}

.project-badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-full);
  border: 1px solid var(--primary-border);
  background-color: var(--primary-dim);
  color: var(--primary);
  font-size: 0.75rem;
  font-family: var(--font-mono);
  width: fit-content;
  margin-bottom: 0.75rem;
}

.project-headline {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.project-desc-card {
  background-color: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  margin-bottom: 1.25rem;
}

.project-links-row {
  display: flex;
  gap: 1.25rem;
  margin-top: 0.5rem;
}

.project-ext-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.875rem;
  color: var(--muted-foreground);
}

.project-ext-link:hover {
  color: var(--primary);
}

/* --------------------------------------------------------------------------
   13. CREDENTIALS / EDUCATION SECTION
   -------------------------------------------------------------------------- */
.credentials-dual-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
}

/* --------------------------------------------------------------------------
   14. CONTACT SECTION & WHATSAPP CARD
   -------------------------------------------------------------------------- */
.contact-section-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}

.contact-info-cards-stack {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.contact-info-unit {
  background-color: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  transition: border-color 0.3s ease;
}

.contact-info-unit:hover {
  border-color: var(--card-hover-border);
}

.contact-icon-wrap {
  padding: 0.75rem;
  border-radius: var(--radius);
  background-color: var(--primary-dim);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
}

.contact-unit-text-title {
  font-size: 0.8rem;
  color: var(--muted-foreground);
}

.contact-unit-text-val {
  font-size: 1rem;
  font-weight: 500;
  color: var(--foreground);
}

.contact-unit-text-val:hover {
  color: var(--primary);
}

/* WhatsApp Card Match */
.whatsapp-feature-box {
  background: linear-gradient(135deg, var(--card), rgba(10, 14, 17, 0.6));
  border: 1px solid var(--border);
  border-radius: var(--radius-2xl);
  padding: 2.5rem 2rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.whatsapp-icon-bubble {
  width: 72px;
  height: 72px;
  border-radius: 1.25rem;
  background: linear-gradient(135deg, rgba(0, 199, 88, 0.2), rgba(0, 165, 68, 0.1));
  border: 1px solid rgba(0, 199, 88, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-whatsapp);
  margin-bottom: 1.5rem;
}

.whatsapp-box-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
}

.whatsapp-box-desc {
  font-size: 0.95rem;
  color: var(--muted-foreground);
  margin-bottom: 1.75rem;
  max-width: 380px;
}

/* --------------------------------------------------------------------------
   15. FOOTER
   -------------------------------------------------------------------------- */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 2.5rem 0;
  position: relative;
  z-index: 2;
}

.footer-content-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.footer-social-icons {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.footer-social-link {
  color: var(--muted-foreground);
  transition: color 0.2s ease;
}

.footer-social-link:hover {
  color: var(--primary);
}

.footer-meta-text {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--muted-foreground);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

/* --------------------------------------------------------------------------
   16. TOAST NOTIFICATIONS
   -------------------------------------------------------------------------- */
.toast-container {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  pointer-events: none;
}

.toast {
  background-color: var(--card);
  border: 1px solid var(--border);
  border-left: 3px solid var(--primary);
  padding: 0.85rem 1.25rem;
  border-radius: var(--radius);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.6);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--foreground);
  display: flex;
  align-items: center;
  gap: 0.65rem;
  pointer-events: auto;
  transform: translateY(12px);
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

/* --------------------------------------------------------------------------
   17. RESPONSIVE BREAKPOINTS
   -------------------------------------------------------------------------- */
@media (max-width: 1024px) {
  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 3.5rem;
  }

  .hero-text-block {
    align-items: center;
  }

  .hero-lead-desc {
    margin-left: auto;
    margin-right: auto;
  }

  .hero-btn-row {
    justify-content: center;
  }

  .about-grid-content {
    grid-template-columns: 1fr;
  }

  .project-feature-card {
    grid-template-columns: 1fr;
  }

  .contact-section-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .nav-pill-bar {
    display: none;
  }

  .btn-pill-resume {
    display: none;
  }

  .mobile-nav-toggle {
    display: flex;
  }

  .section-divider-line {
    display: none;
  }

  .skills-cards-grid {
    grid-template-columns: 1fr;
  }

  .footer-content-row {
    flex-direction: column;
    text-align: center;
  }
}

@media (max-width: 480px) {
  .portfolio-wrapper {
    margin: 6px;
    height: calc(100vh - 12px);
    max-height: calc(100vh - 12px);
    width: calc(100vw - 12px);
    max-width: calc(100vw - 12px);
    border-radius: 12px;
  }

  .particle-canvas {
    top: 6px;
    left: 6px;
    width: calc(100vw - 12px);
    height: calc(100vh - 12px);
    border-radius: 12px;
  }

  .site-header {
    border-top-left-radius: 12px;
    border-top-right-radius: 12px;
  }

  .hero-section {
    min-height: calc(100vh - 12px);
  }

  .hero-btn-row {
    flex-direction: column;
    width: 100%;
  }

  .hero-btn-row .btn {
    width: 100%;
  }
}

/* --------------------------------------------------------------------------
   18. REDUCED MOTION PREFERENCE
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .portrait-offset-frame.ambient-floating {
    animation: none !important;
  }
  .char-inner {
    transform: translateY(0) !important;
    opacity: 1 !important;
  }
}

/* --------------------------------------------------------------------------
   19. MAGNETIC CUSTOM CURSOR WITH INERTIA
   -------------------------------------------------------------------------- */
@media (pointer: fine) {
  body, a, button, input, textarea, select, [role="button"], label {
    cursor: none !important;
  }
}

.custom-cursor-dot {
  position: fixed;
  top: 0;
  left: 0;
  width: 7px;
  height: 7px;
  background-color: var(--primary);
  border-radius: 50%;
  pointer-events: none;
  z-index: 99999;
  transform: translate3d(-50%, -50%, 0);
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s cubic-bezier(0.25, 1, 0.5, 1);
  box-shadow: 0 0 8px rgba(0, 202, 177, 0.75);
}

.custom-cursor-ring {
  position: fixed;
  top: 0;
  left: 0;
  width: 38px;
  height: 38px;
  border: 1.5px solid var(--primary);
  background-color: transparent;
  border-radius: 50%;
  pointer-events: none;
  z-index: 99998;
  transform: translate3d(-50%, -50%, 0);
  opacity: 0;
  transition: width 0.35s cubic-bezier(0.25, 1, 0.5, 1),
              height 0.35s cubic-bezier(0.25, 1, 0.5, 1),
              background-color 0.35s cubic-bezier(0.25, 1, 0.5, 1),
              border-color 0.35s cubic-bezier(0.25, 1, 0.5, 1),
              opacity 0.2s ease;
  will-change: transform, width, height;
}

.custom-cursor-dot.visible,
.custom-cursor-ring.visible {
  opacity: 1;
}

/* --------------------------------------------------------------------------
   20. KINETIC TEXT REVEAL & SHUFFLE
   -------------------------------------------------------------------------- */
.hero-name-title {
  /* Ensure container mask doesn't clip whole title during line layout */
  overflow: visible;
}

.hero-name-line {
  display: inline-block;
  white-space: nowrap;
}

.char-mask {
  display: inline-block;
  overflow: hidden;
  vertical-align: top;
  line-height: 1.1;
  position: relative;
}

.char-mask.space {
  width: 0.3em;
}

.char-inner {
  display: inline-block;
  transform: translateY(115%);
  opacity: 0;
  transition: transform 0.65s cubic-bezier(0.25, 1, 0.5, 1),
              opacity 0.45s cubic-bezier(0.25, 1, 0.5, 1),
              color 0.25s ease;
  will-change: transform, opacity;
}

.char-inner.revealed {
  transform: translateY(0);
  opacity: 1;
}

.char-inner.shuffling {
  color: var(--primary);
  text-shadow: 0 0 10px rgba(0, 202, 177, 0.8);
}

