/* ==========================================================================
   Ayush Shivam - High-Editorial "Warm Atelier & Organic Sage" Design System
   Color Palette: Charcoal Brown, Charcoal, Grey Olive, Ash Grey, Tea Green
   ========================================================================== */

/* --- Google Fonts --- */
@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;0,600;0,700;1,300;1,400;1,500;1,600&family=Plus+Jakarta+Sans:ital,wght@0,400;0,500;0,600;0,700;1,400;1,500&display=swap');

/* --- 1. Root Color Palette & Surface Hierarchy --- */
:root {
  /* CSS HEX Palette */
  --charcoal-brown: #313628;
  --charcoal: #595358;
  --grey-olive: #857f74;
  --ash-grey: #a4ac96;
  --tea-green: #cadf9e;

  /* CSS HSL Palette */
  --charcoal-brown-hsl: hsla(81, 15%, 18%, 1);
  --charcoal-hsl: hsla(310, 3%, 34%, 1);
  --grey-olive-hsl: hsla(39, 7%, 49%, 1);
  --ash-grey-hsl: hsla(82, 12%, 63%, 1);
  --tea-green-hsl: hsla(79, 50%, 75%, 1);

  /* SCSS RGB Palette */
  --charcoal-brown-rgb: 49, 54, 40;
  --charcoal-rgb: 89, 83, 88;
  --grey-olive-rgb: 133, 127, 116;
  --ash-grey-rgb: 164, 172, 150;
  --tea-green-rgb: 202, 223, 158;

  /* Gradients */
  --gradient-top: linear-gradient(0deg, #313628, #595358, #857f74, #a4ac96, #cadf9e);
  --gradient-right: linear-gradient(90deg, #313628, #595358, #857f74, #a4ac96, #cadf9e);
  --gradient-bottom: linear-gradient(180deg, #313628, #595358, #857f74, #a4ac96, #cadf9e);
  --gradient-left: linear-gradient(270deg, #313628, #595358, #857f74, #a4ac96, #cadf9e);
  --gradient-top-right: linear-gradient(45deg, #313628, #595358, #857f74, #a4ac96, #cadf9e);
  --gradient-bottom-right: linear-gradient(135deg, #313628, #595358, #857f74, #a4ac96, #cadf9e);
  --gradient-top-left: linear-gradient(225deg, #313628, #595358, #857f74, #a4ac96, #cadf9e);
  --gradient-bottom-left: linear-gradient(315deg, #313628, #595358, #857f74, #a4ac96, #cadf9e);
  --gradient-radial: radial-gradient(#313628, #595358, #857f74, #a4ac96, #cadf9e);

  /* --- Surface Tokens (Derived from Palette) --- */
  /* Canvas Backgrounds */
  --bg-primary: #F7F8F4;          /* Warm linen canvas with subtle ash-grey warmth */
  --bg-secondary: #EDF1E8;        /* Soft Oat Alabaster derived from tea-green & ash-grey */
  
  /* Bento & Card Surfaces */
  --bg-card: #E4EAE0;             /* Soft ash-grey / tea-green milk */
  --bg-card-alt: #ECF1E7;         /* Lighter tint for timetable / secondary bento cards */
  --bg-card-hover: #D8E2D2;       /* Tactile hover elevation tint */
  
  /* High-Contrast Anchor Accent */
  --bg-dark: var(--charcoal-brown);     /* #313628 Deep Forest / Charcoal Brown */
  --bg-dark-hover: #24291D;             /* Deepened Charcoal Brown */
  --bg-dark-surface: #3E4534;           /* Elevated dark card surface */
  
  /* Text & Contrast */
  --text-primary: var(--charcoal-brown); /* #313628 Headings & High-Contrast Text */
  --text-secondary: var(--charcoal);    /* #595358 Charcoal Body Paragraphs */
  --text-muted: var(--grey-olive);      /* #857f74 Grey Olive Captions & Footnotes */
  --text-inverse: #F7F8F4;              /* Linen Ivory on Dark Forest backgrounds */
  --text-inverse-muted: var(--ash-grey);/* #a4ac96 Soft Mist Green on Dark backgrounds */
  
  /* Accent Hues */
  --accent-olive: var(--charcoal-brown);/* Signature Charcoal Brown tone */
  --accent-gold: #938766;               /* Warm Brass / Ochre pairing with grey-olive */
  --accent-highlight: var(--tea-green); /* #cadf9e Fresh Tea Green highlight */
  --accent-danger: #9E3529;             /* Deep Venetian Red */
  
  /* Borders & Dividers */
  --border-light: rgba(49, 54, 40, 0.12);
  --border-medium: rgba(49, 54, 40, 0.20);
  --border-dark: rgba(202, 223, 158, 0.22);
  
  /* Elevation & Tactile Shadows */
  --shadow-sm: 0 2px 8px rgba(49, 54, 40, 0.05);
  --shadow-md: 0 8px 24px rgba(49, 54, 40, 0.08);
  --shadow-lg: 0 16px 40px rgba(49, 54, 40, 0.11);
  --shadow-dark: 0 20px 48px rgba(25, 28, 20, 0.35);
  
  /* Geometry */
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 36px;
  --radius-full: 9999px;          /* Oblong luxury pill buttons and capsules */

  /* Typography System */
  --font-heading: 'Cormorant Garamond', Georgia, serif;
  --font-body: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --font-serif: 'Cormorant Garamond', Georgia, serif;

  /* Transitions */
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-smooth: 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-tactile: 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  overflow-x: hidden;
  background-color: var(--bg-primary);
}

body {
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-body);
  line-height: 1.7;
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Ambient Background Texture using Tea Green & Ash Grey radial warmth */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: -1;
  background-image: 
    radial-gradient(circle at 10% 20%, rgba(202, 223, 158, 0.32) 0%, transparent 45%),
    radial-gradient(circle at 90% 80%, rgba(164, 172, 150, 0.28) 0%, transparent 48%);
}

/* Custom Tactile Scrollbar */
::-webkit-scrollbar {
  width: 9px;
}
::-webkit-scrollbar-track {
  background: var(--bg-secondary);
}
::-webkit-scrollbar-thumb {
  background: var(--ash-grey);
  border-radius: var(--radius-full);
  border: 2px solid var(--bg-secondary);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--charcoal-brown);
}

/* Canvas / Background fallbacks (disabled for clean ambient linen aesthetic) */
#starfield,
.nebula-glow {
  display: none !important;
}

/* --- Typography & Editorial Hierarchy --- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.12;
  letter-spacing: -0.01em;
}

p {
  color: var(--text-secondary);
  line-height: 1.72;
  font-size: 1.05rem;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition-fast);
}

button, input, textarea {
  font-family: inherit;
}

/* --- Container & Section Styles --- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

section {
  padding: 100px 0;
  position: relative;
}

/* --- Two-Tier Pretitles on Responsive Screens --- */
.section-header {
  text-align: center;
  margin-bottom: 60px;
}

.pretitle-stack {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px 12px;
  margin-bottom: 1.2rem;
}

.pretitle-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 14px;
  border-radius: var(--radius-full);
  background: rgba(202, 223, 158, 0.35);
  color: var(--charcoal-brown);
  border: 1px solid rgba(49, 54, 40, 0.22);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}

.pretitle-category {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--grey-olive);
}

.section-header h2 {
  font-size: 3.1rem;
  font-family: var(--font-heading);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.01em;
  line-height: 1.1;
  margin-bottom: 15px;
  color: var(--text-primary);
}

.section-header h2 .header-italic {
  display: inline-block;
  font-style: italic;
  font-weight: 300;
  text-transform: none;
  color: var(--grey-olive);
  margin-left: 6px;
}

.section-header p {
  color: var(--text-secondary);
  font-size: 1.08rem;
  max-width: 620px;
  margin: 0 auto;
  line-height: 1.65;
}

/* --- Oblong Luxury Pill Buttons & Tactile Micro-Interactions --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 0.78rem 1.85rem;
  border-radius: var(--radius-full);
  font-size: 0.92rem;
  font-weight: 600;
  font-family: var(--font-body);
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: var(--transition-smooth);
  position: relative;
  text-decoration: none;
  white-space: nowrap;
  border: none;
}

.btn-primary {
  background: var(--charcoal-brown);
  color: var(--text-inverse);
  border: 1px solid var(--charcoal-brown);
  box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
  background: var(--bg-dark-hover);
  border-color: var(--bg-dark-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(49, 54, 40, 0.28);
  color: var(--text-inverse);
}

.btn-secondary {
  background: var(--bg-card);
  color: var(--charcoal-brown);
  border: 1px solid var(--border-medium);
  box-shadow: var(--shadow-sm);
}

.btn-secondary:hover {
  background: var(--bg-card-hover);
  border-color: var(--charcoal-brown);
  color: var(--charcoal-brown);
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(49, 54, 40, 0.15);
}

.btn-outline {
  background: transparent;
  color: var(--charcoal);
  border: 1px solid var(--border-medium);
}

.btn-outline:hover {
  background: rgba(202, 223, 158, 0.25);
  border-color: var(--charcoal-brown);
  color: var(--charcoal-brown);
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(49, 54, 40, 0.10);
}

.btn-inverse {
  background: var(--tea-green);
  color: var(--charcoal-brown);
  border: 1px solid var(--tea-green);
  box-shadow: var(--shadow-sm);
  font-weight: 700;
}

.btn-inverse:hover {
  background: #d8ecb0;
  color: var(--charcoal-brown);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(202, 223, 158, 0.45);
}

/* --- Header / Navigation (Frosted Atelier Surface) --- */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background: rgba(247, 248, 244, 0.90);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-light);
  transition: var(--transition-smooth);
}

header.scrolled {
  background: rgba(247, 248, 244, 0.97);
  box-shadow: var(--shadow-md);
  border-bottom-color: var(--border-medium);
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 80px;
}

.logo {
  font-family: var(--font-heading);
  font-size: 2.1rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--charcoal-brown);
  text-decoration: none;
  display: inline-flex;
  align-items: baseline;
}

.logo-period {
  color: var(--tea-green);
  font-size: 2.4rem;
  line-height: 0;
  margin-left: 2px;
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 1.8rem;
  align-items: center;
}

.nav-link {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--charcoal);
  text-decoration: none;
  position: relative;
  padding: 6px 2px;
  letter-spacing: 0.02em;
  transition: var(--transition-fast);
}

.nav-link:hover, .nav-link.active {
  color: var(--charcoal-brown);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--charcoal-brown);
  transition: var(--transition-smooth);
  border-radius: var(--radius-full);
}

.nav-link:hover::after, .nav-link.active::after {
  width: 100%;
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
}

.scroll-progress {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0%;
  height: 3px;
  background: var(--charcoal-brown);
  transition: width 0.1s ease-out;
}

/* --- Hero Section --- */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  padding: 130px 0 90px 0;
}

.hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  opacity: 0.04;
  filter: grayscale(1);
  mix-blend-mode: multiply;
  pointer-events: none;
  z-index: -1;
}

.hero .container {
  display: grid;
  grid-template-columns: 1.25fr 0.85fr;
  align-items: center;
  gap: 4rem;
  width: 100%;
}

.hero-content {
  z-index: 2;
}

.hero-pretitle {
  justify-content: flex-start;
  margin-bottom: 1.4rem;
}

.hero-title {
  font-family: var(--font-heading);
  font-size: 4.4rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  line-height: 1.06;
  color: var(--charcoal-brown);
  margin-bottom: 1.4rem;
}

.hero-title-italic {
  display: block;
  font-style: italic;
  font-weight: 300;
  text-transform: none;
  font-size: 2rem;
  letter-spacing: 0.01em;
  color: var(--grey-olive);
  margin-top: 0.4rem;
}

.hero-typewriter-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 1.8rem;
  font-size: 1.15rem;
}

.typewriter-prefix {
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--grey-olive);
}

.typewriter-text {
  font-family: var(--font-body);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--charcoal-brown);
  min-height: 1.8rem;
  display: inline-block;
  border-right: 2px solid var(--charcoal-brown);
  animation: blink-caret 0.8s step-end infinite;
}

@keyframes blink-caret {
  from, to { border-color: transparent; }
  50% { border-color: var(--charcoal-brown); }
}

.hero-desc {
  font-size: 1.12rem;
  color: var(--charcoal);
  max-width: 580px;
  margin-bottom: 2.4rem;
  line-height: 1.72;
  border-left: 2px solid var(--ash-grey);
  padding-left: 1.5rem;
}

.hero-buttons {
  display: flex;
  gap: 1.1rem;
  flex-wrap: wrap;
  align-items: center;
}

/* Organic Undulating Hero Frame */
.hero-image-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  z-index: 2;
}

.hero-contour-wrap {
  position: relative;
  width: 360px;
  max-width: 100%;
  margin: 0 auto;
  padding-top: 26px;
}

.hero-floating-pill {
  position: absolute;
  top: 15px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 18px;
  background: var(--bg-card);
  color: var(--charcoal-brown);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-full);
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  box-shadow: var(--shadow-md);
  white-space: nowrap;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: var(--transition-smooth);
}

.hero-floating-pill:hover {
  transform: translateX(-50%) translateY(-2px);
  box-shadow: 0 6px 18px rgba(49, 54, 40, 0.22);
}

.pill-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--tea-green);
  box-shadow: 0 0 0 3px rgba(202, 223, 158, 0.45);
  animation: pulse-dot 2.5s infinite;
}

@keyframes pulse-dot {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(202, 223, 158, 0.6); }
  70% { transform: scale(1); box-shadow: 0 0 0 6px rgba(202, 223, 158, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(202, 223, 158, 0); }
}

.hero-undulating-frame {
  width: 330px;
  height: 380px;
  margin: 0 auto;
  border-radius: 46% 54% 48% 52% / 18% 16%;
  overflow: hidden;
  border: 3px solid var(--bg-card);
  outline: 1.5px solid var(--border-medium);
  box-shadow: var(--shadow-lg);
  background: var(--bg-card);
  position: relative;
  transition: var(--transition-smooth);
}

.hero-showcase-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.hero-contour-wrap:hover .hero-showcase-img {
  transform: scale(1.04);
}

.hero-archival-seal {
  position: absolute;
  bottom: -10px;
  right: 10px;
  background: var(--bg-card);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-md);
  padding: 8px 14px;
  box-shadow: var(--shadow-md);
  text-align: center;
  display: flex;
  flex-direction: column;
}

.seal-year {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1;
  color: var(--charcoal-brown);
}

.seal-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--grey-olive);
}

/* --- Modular Bento Grid Architecture --- */
.bento-card, .glass-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: var(--transition-tactile);
  position: relative;
}

.bento-card:hover, .glass-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-medium);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.bento-card-alt {
  background: var(--bg-card-alt);
}

/* Dashed Divider Details */
.dashed-divider {
  border: none;
  border-top: 1px dashed var(--border-medium);
  margin: 1.5rem 0;
  width: 100%;
}

/* --- About Me Bento Grid --- */
.about-bento-grid {
  display: grid;
  grid-template-columns: 1.25fr 0.95fr;
  gap: 2rem;
  align-items: stretch;
}

.bento-card-inner {
  padding: 2.8rem;
  display: flex;
  flex-direction: column;
  height: 100%;
  box-sizing: border-box;
}

.bento-card-microhead {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--grey-olive);
  margin-bottom: 1.5rem;
}

.about-narrative-card h3 {
  font-size: 2.1rem;
  font-weight: 500;
  margin-bottom: 1.2rem;
  line-height: 1.2;
}

.about-narrative-card p {
  margin-bottom: 1.2rem;
  font-size: 1.05rem;
  color: var(--charcoal);
}

.pill-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
}

.atelier-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background: var(--bg-card-alt);
  border: 1px solid var(--border-light);
  color: var(--charcoal-brown);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  transition: var(--transition-fast);
}

.atelier-pill:hover {
  background: var(--tea-green);
  border-color: var(--border-medium);
  transform: translateY(-2px);
}

/* Stat & Credential Cards in Bento */
.stats-grid-2x2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.stat-item-box {
  display: flex;
  flex-direction: column;
}

.stat-serif-number {
  font-family: var(--font-heading);
  font-size: 2.8rem;
  font-weight: 600;
  line-height: 1;
  color: var(--charcoal-brown);
  margin-bottom: 4px;
}

.stat-serif-unit {
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--grey-olive);
}

.stat-sans-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--charcoal);
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

/* Specification rows with dashed borders */
.specs-list {
  display: flex;
  flex-direction: column;
  width: 100%;
}

.spec-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 10px 0;
  border-top: 1px dashed var(--border-medium);
}

.spec-row:first-child {
  border-top: none;
}

.spec-label {
  font-size: 0.82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--grey-olive);
}

.spec-value {
  font-size: 1.02rem;
  font-weight: 600;
  color: var(--charcoal-brown);
  text-align: right;
}

/* --- Education Bento Grid --- */
.education-bento-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.edu-bento-card {
  padding: 2.4rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
  box-sizing: border-box;
}

.edu-card-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}

.roman-numeral {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--charcoal-brown);
}

.date-pill {
  padding: 4px 12px;
  border-radius: var(--radius-full);
  background: rgba(202, 223, 158, 0.35);
  border: 1px solid rgba(49, 54, 40, 0.20);
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--charcoal-brown);
}

.edu-bento-card h3 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  line-height: 1.25;
}

.edu-institute {
  font-weight: 600;
  color: var(--charcoal-brown);
  font-size: 1rem;
  margin-bottom: 0.3rem;
}

.edu-subtext {
  font-size: 0.92rem;
  color: var(--charcoal);
}

/* --- Experience Practice Bento Cards --- */
.experience-bento-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.2rem;
}

.practice-bento-card {
  padding: 2.8rem;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
}

.practice-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1.8rem;
}

/* 52px Circular Icon Badge */
.practice-icon-badge {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: rgba(202, 223, 158, 0.35);
  border: 1.5px solid var(--charcoal-brown);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--charcoal-brown);
  flex-shrink: 0;
  transition: var(--transition-fast);
}

.practice-bento-card:hover .practice-icon-badge,
.skill-bento-card:hover .practice-icon-badge {
  background: var(--charcoal-brown);
  color: var(--tea-green);
  border-color: var(--charcoal-brown);
  transform: scale(1.05);
}

.practice-meta-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}

.practice-roman {
  font-family: var(--font-heading);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--grey-olive);
}

.practice-bento-card h3 {
  font-size: 1.75rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  line-height: 1.2;
}

.practice-company {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--charcoal-brown);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
}

.practice-company:hover {
  color: var(--charcoal);
}

.practice-matters-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  width: 100%;
  margin-top: 1rem;
}

.practice-matter-item {
  padding: 10px 0;
  border-top: 1px dashed var(--border-medium);
  font-size: 0.96rem;
  color: var(--charcoal);
  line-height: 1.6;
  position: relative;
  padding-left: 20px;
}

.practice-matter-item::before {
  content: '✦';
  position: absolute;
  left: 0;
  top: 10px;
  color: var(--grey-olive);
  font-size: 0.8rem;
}

/* --- Skills Bento Grid --- */
.skills-bento-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 2rem;
}

.skill-bento-card {
  padding: 2.4rem;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
}

.skills-bento-grid .skill-bento-card:nth-child(1),
.skills-bento-grid .skill-bento-card:nth-child(2),
.skills-bento-grid .skill-bento-card:nth-child(3) {
  grid-column: span 2;
}

.skills-bento-grid .skill-bento-card:nth-child(4) {
  grid-column: 2 / span 2;
}

.skills-bento-grid .skill-bento-card:nth-child(5) {
  grid-column: 4 / span 2;
}

.skill-card-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}

.skill-bento-card h3 {
  font-size: 1.45rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.skill-items-list {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.skill-pill {
  padding: 7px 15px;
  border-radius: var(--radius-full);
  background: var(--bg-card-alt);
  border: 1px solid var(--border-light);
  color: var(--charcoal-brown);
  font-size: 0.88rem;
  font-weight: 500;
  transition: var(--transition-fast);
  cursor: default;
}

.skill-pill:hover {
  background: var(--tea-green);
  border-color: var(--charcoal-brown);
  color: var(--charcoal-brown);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

/* --- Certifications Bento Grid (Authentic Image Bento Cards) --- */
.certs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 2.4rem;
}

.cert-card {
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.cert-img-container {
  height: 220px;
  position: relative;
  overflow: hidden;
  background: var(--bg-secondary);
}

.cert-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.cert-card:hover .cert-img {
  transform: scale(1.04);
}

/* Dark bottom vignette gradient */
.cert-vignette {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg, transparent 0%, rgba(49, 54, 40, 0.88) 100%);
  pointer-events: none;
}

/* Frosted category tag pinned to corner */
.bento-frosted-tag {
  position: absolute;
  top: 15px;
  left: 15px;
  padding: 5px 12px;
  border-radius: var(--radius-full);
  background: rgba(247, 248, 244, 0.90);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(49, 54, 40, 0.18);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--charcoal-brown);
  box-shadow: var(--shadow-sm);
  z-index: 2;
}

.cert-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  background: rgba(49, 54, 40, 0.40);
  backdrop-filter: blur(4px);
  transition: var(--transition-fast);
  z-index: 3;
}

.cert-card:hover .cert-overlay {
  opacity: 1;
}

.cert-content {
  padding: 2.2rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  justify-content: space-between;
}

.cert-org-row {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--grey-olive);
  margin-bottom: 8px;
}

.cert-org-row a {
  color: inherit;
  text-decoration: none;
}

.cert-content h3 {
  font-size: 1.45rem;
  font-weight: 600;
  margin-bottom: 12px;
  line-height: 1.25;
}

.cert-date {
  font-size: 0.85rem;
  color: var(--grey-olive);
  font-weight: 500;
  padding-top: 12px;
  border-top: 1px dashed var(--border-medium);
}

/* --- Projects Bento Grid --- */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 2.4rem;
}

.project-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  height: 100%;
}

.proj-img-container {
  height: 220px;
  position: relative;
  overflow: hidden;
  background: var(--bg-secondary);
}

.proj-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.project-card:hover .proj-img {
  transform: scale(1.04);
}

.proj-overlay-glow {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg, transparent 0%, rgba(49, 54, 40, 0.88) 100%);
  pointer-events: none;
}

.proj-badge {
  position: absolute;
  top: 15px;
  right: 15px;
  padding: 5px 12px;
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  background: rgba(247, 248, 244, 0.90);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(49, 54, 40, 0.18);
  color: var(--charcoal-brown);
  box-shadow: var(--shadow-sm);
  z-index: 2;
}

.proj-content {
  padding: 2.2rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.proj-content h3 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 10px;
  line-height: 1.25;
}

.proj-desc {
  color: var(--charcoal);
  font-size: 0.98rem;
  line-height: 1.65;
  margin-bottom: 1.5rem;
  flex-grow: 1;
}

.proj-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 1.8rem;
  padding-bottom: 1.2rem;
  border-bottom: 1px dashed var(--border-medium);
}

.proj-tag {
  font-size: 0.76rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  background: var(--bg-card-alt);
  border: 1px solid var(--border-light);
  color: var(--charcoal);
}

.proj-actions {
  display: flex;
  gap: 0.8rem;
}

.proj-btn {
  flex: 1;
  padding: 8px 16px;
  font-size: 0.84rem;
  text-align: center;
  border-radius: var(--radius-full);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: var(--transition-fast);
  text-decoration: none;
}

.proj-btn-primary {
  background: var(--charcoal-brown);
  color: var(--text-inverse);
  border: 1px solid var(--charcoal-brown);
}

.proj-btn-primary:hover {
  background: var(--bg-dark-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.proj-btn-outline {
  background: transparent;
  color: var(--charcoal-brown);
  border: 1px solid var(--border-medium);
}

.proj-btn-outline:hover {
  background: var(--tea-green);
  border-color: var(--charcoal-brown);
  transform: translateY(-2px);
}

/* --- GitHub Activity Section --- */
.github-chart-card {
  padding: 2.5rem;
  margin-bottom: 2.4rem;
  overflow: hidden;
}

.github-chart-wrapper {
  width: 100%;
  overflow-x: auto;
  padding: 1rem 0;
  display: flex;
  justify-content: center;
}

.github-chart-wrapper img {
  max-width: 100%;
  min-width: 780px;
  height: auto;
}

.github-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
}

.github-stat-card {
  padding: 1.5rem;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

.github-stat-card img {
  width: 100%;
  height: auto;
  max-width: 420px;
  border-radius: var(--radius-md);
  transition: var(--transition-smooth);
}

.github-stat-card:hover img {
  transform: scale(1.02);
}

/* --- 3. Deep Forest Anchor Card (The "Dark Feature Box") --- */
.contact-anchor-card {
  background-color: var(--charcoal-brown);
  background-image: radial-gradient(circle at 90% 10%, rgba(202, 223, 158, 0.12) 0%, transparent 65%);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border-dark);
  box-shadow: var(--shadow-dark);
  padding: 4.5rem 3.5rem;
  position: relative;
  overflow: hidden;
  color: var(--text-inverse);
}

.pretitle-pill-inverse {
  background: rgba(202, 223, 158, 0.18);
  border-color: rgba(202, 223, 158, 0.35);
  color: var(--tea-green);
}

.pretitle-category-inverse {
  color: var(--ash-grey);
}

.contact-title-inverse {
  color: var(--text-inverse) !important;
}

.contact-title-inverse .header-italic {
  color: var(--tea-green) !important;
}

.contact-subtitle-inverse {
  color: var(--ash-grey) !important;
}

.contact-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 3.5rem;
  margin-top: 3rem;
  align-items: start;
}

.contact-info-block h3 {
  color: var(--text-inverse);
  font-size: 2.1rem;
  font-weight: 500;
  margin-bottom: 1rem;
}

.contact-info-block p {
  color: var(--ash-grey);
  font-size: 1.05rem;
  line-height: 1.7;
  margin-bottom: 2.5rem;
}

.contact-links {
  display: flex;
  flex-direction: column;
  gap: 1.4rem;
}

.contact-link-item {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  padding: 12px 0;
  border-top: 1px dashed rgba(202, 223, 158, 0.20);
}

.contact-link-item:first-child {
  border-top: none;
}

.contact-icon-box {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(202, 223, 158, 0.12);
  border: 1px solid rgba(202, 223, 158, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--tea-green);
  flex-shrink: 0;
  transition: var(--transition-fast);
}

.contact-link-item:hover .contact-icon-box {
  background: var(--tea-green);
  color: var(--charcoal-brown);
  transform: scale(1.08);
}

.contact-link-text {
  min-width: 0;
  overflow-wrap: anywhere;
}

.contact-link-text span {
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ash-grey);
  display: block;
}

.contact-link-text a {
  font-size: 1.08rem;
  font-weight: 600;
  color: var(--text-inverse);
  text-decoration: none;
  transition: var(--transition-fast);
}

.contact-link-text a:hover {
  color: var(--tea-green);
}

/* Contact Form on Deep Forest Surface */
.contact-form-card {
  background: var(--bg-dark-surface);
  border: 1px solid rgba(164, 172, 150, 0.22);
  border-radius: var(--radius-lg);
  padding: 3rem;
  box-shadow: var(--shadow-md);
}

.contact-form-card h3 {
  color: var(--text-inverse);
  font-size: 1.8rem;
  font-weight: 500;
  margin-bottom: 1.8rem;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.6rem;
}

.form-group {
  position: relative;
  display: flex;
  flex-direction: column;
}

.form-input {
  background: rgba(247, 248, 244, 0.06);
  border: 1px solid rgba(164, 172, 150, 0.25);
  border-radius: var(--radius-sm);
  padding: 1.1rem 1.2rem;
  font-size: 1rem;
  color: var(--text-inverse);
  outline: none;
  font-family: var(--font-body);
  transition: var(--transition-smooth);
}

.form-input:focus {
  border-color: var(--tea-green);
  background: rgba(247, 248, 244, 0.10);
  box-shadow: 0 0 0 3px rgba(202, 223, 158, 0.25);
}

.form-label {
  position: absolute;
  left: 1.2rem;
  top: 1.1rem;
  color: var(--ash-grey);
  font-size: 0.95rem;
  transition: var(--transition-smooth);
  pointer-events: none;
}

.form-input:focus ~ .form-label,
.form-input:not(:placeholder-shown) ~ .form-label {
  top: -10px;
  left: 10px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--tea-green);
  background: var(--bg-dark-surface);
  padding: 0 6px;
  border-radius: 4px;
}

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

.error-msg {
  font-size: 0.78rem;
  color: #fca5a5;
  margin-top: 5px;
  display: none;
}

.form-group.invalid .form-input {
  border-color: var(--accent-danger);
}

.form-group.invalid .error-msg {
  display: block;
}

.form-status {
  padding: 1rem;
  border-radius: var(--radius-sm);
  font-weight: 500;
  display: none;
  font-size: 0.95rem;
}

.form-status.success {
  display: block;
  background: rgba(49, 54, 40, 0.7);
  border: 1px solid var(--tea-green);
  color: var(--tea-green);
}

.form-status.error {
  display: block;
  background: rgba(158, 53, 41, 0.2);
  border: 1px solid var(--accent-danger);
  color: #fca5a5;
}

/* --- Footer --- */
footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-medium);
  padding: 3.5rem 0;
  text-align: center;
  position: relative;
  z-index: 10;
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.footer-socials {
  display: flex;
  gap: 1.2rem;
}

.social-icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border-medium);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--charcoal-brown);
  text-decoration: none;
  transition: var(--transition-smooth);
}

.social-icon:hover {
  background: var(--charcoal-brown);
  color: var(--tea-green);
  border-color: var(--charcoal-brown);
  transform: translateY(-3px);
  box-shadow: var(--shadow-sm);
}

.footer-copy {
  color: var(--grey-olive);
  font-size: 0.9rem;
  font-weight: 500;
}

/* --- Certificate Preview Modal --- */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(49, 54, 40, 0.85);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: var(--transition-smooth);
}

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

.modal-content {
  position: relative;
  max-width: 90%;
  max-height: 85%;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-dark);
  border: 1px solid var(--border-dark);
  background: var(--bg-card);
  transform: scale(0.95);
  transition: var(--transition-smooth);
}

.modal.active .modal-content {
  transform: scale(1);
}

.modal-img {
  display: block;
  max-width: 100%;
  max-height: 75vh;
  object-fit: contain;
}

.modal-close-btn {
  position: absolute;
  top: 15px;
  right: 15px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border-medium);
  color: var(--charcoal-brown);
  font-size: 1.4rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 2100;
  transition: var(--transition-fast);
}

.modal-close-btn:hover {
  background: var(--accent-danger);
  color: #fff;
  border-color: var(--accent-danger);
  transform: rotate(90deg);
}

/* --- Responsive Rules --- */
@media (max-width: 1024px) {
  .hero .container {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 3rem;
  }

  .hero-pretitle {
    justify-content: center;
  }

  .hero-title {
    font-size: 3.5rem;
  }

  .hero-typewriter-wrap {
    justify-content: center;
  }

  .hero-desc {
    margin: 0 auto 2.2rem auto;
    border-left: none;
    border-bottom: 2px solid var(--ash-grey);
    padding-left: 0;
    padding-bottom: 1.4rem;
  }

  .hero-buttons {
    justify-content: center;
  }

  .hero-image-wrapper {
    order: -1;
  }

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

  .education-bento-grid {
    grid-template-columns: 1fr;
  }

  .experience-bento-grid {
    grid-template-columns: 1fr;
  }

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

  .skills-bento-grid .skill-bento-card:nth-child(n) {
    grid-column: span 1;
  }

  .skills-bento-grid .skill-bento-card:nth-child(5) {
    grid-column: span 2;
  }

  .contact-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }
}

@media (max-width: 768px) {
  section {
    padding: 70px 0;
  }

  .hero {
    padding-top: 110px;
    padding-bottom: 60px;
  }

  .hero-title {
    font-size: 2.8rem;
  }

  .hero-title-italic {
    font-size: 1.5rem;
  }

  .section-header h2 {
    font-size: 2.3rem;
  }

  .hero-buttons {
    flex-direction: column;
    align-items: stretch;
    max-width: 320px;
    margin: 0 auto;
  }

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

  .mobile-menu-btn {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    background: var(--bg-card);
    border: 1px solid var(--border-medium);
    border-radius: var(--radius-sm);
    cursor: pointer;
    z-index: 1002;
  }

  .mobile-menu-btn span {
    display: block;
    width: 20px;
    height: 2px;
    background-color: var(--charcoal-brown);
    border-radius: 2px;
    transition: var(--transition-smooth);
  }

  .mobile-menu-btn.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }

  .mobile-menu-btn.active span:nth-child(2) {
    opacity: 0;
  }

  .mobile-menu-btn.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
  }

  .nav-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 80%;
    max-width: 340px;
    height: 100vh;
    background: var(--bg-primary);
    border-left: 1px solid var(--border-medium);
    box-shadow: var(--shadow-dark);
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    padding: 3rem 2rem;
    gap: 1.6rem;
    transition: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 1001;
  }

  .nav-menu.active {
    right: 0;
  }

  .nav-link {
    font-size: 1.15rem;
  }

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

  .skills-bento-grid .skill-bento-card:nth-child(n) {
    grid-column: span 1;
  }

  .contact-anchor-card {
    padding: 2.8rem 1.6rem;
    border-radius: var(--radius-lg);
  }

  .contact-form-card {
    padding: 2rem 1.4rem;
  }

  .bento-card-inner {
    padding: 2rem 1.4rem;
  }

  .edu-bento-card, .practice-bento-card, .skill-bento-card {
    padding: 2rem 1.4rem;
  }

  .stats-grid-2x2 {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
}

@media (max-width: 480px) {
  .hero-contour-wrap {
    width: 290px;
  }

  .hero-undulating-frame {
    width: 270px;
    height: 310px;
  }

  .hero-title {
    font-size: 2.2rem;
  }

  .hero-title-italic {
    font-size: 1.3rem;
  }

  .stat-serif-number {
    font-size: 2.3rem;
  }
}

/* --- Print Stylesheet --- */
@media print {
  html, body {
    background: #ffffff !important;
    color: #313628 !important;
    font-size: 11pt !important;
  }

  body::before,
  header,
  .hero-buttons,
  .mobile-menu-btn,
  .scroll-progress,
  .modal,
  .proj-btn,
  #contact-form button {
    display: none !important;
  }

  .bento-card, .glass-card, .contact-anchor-card, .contact-form-card {
    background: #ffffff !important;
    border: 1px solid #d1d5db !important;
    box-shadow: none !important;
    color: #313628 !important;
    page-break-inside: avoid;
  }

  .contact-anchor-card * {
    color: #313628 !important;
  }

  h1, h2, h3, h4 {
    color: #313628 !important;
  }
}
