/* ============================================================
   MODERN PORTFOLIO - PROFESSIONAL DESIGN
   ============================================================ */

/* CSS Variables - Color Palette */
:root {
  /* Light Mode Colors */
  --bg-primary: #ffffff;
  --bg-secondary: #f8f9fa;
  --bg-tertiary: #f0f2f5;
  --text-primary: #1a1a1a;
  --text-secondary: #5a5a5a;
  --text-tertiary: #8a8a8a;
  --border-color: #e0e0e0;
  --border-light: #f0f0f0;
  
  /* Accent Colors */
  --accent-primary: #0066ff;
  --accent-secondary: #5a4fcf;
  --accent-hover: #0052cc;
  --accent-light: #e6f0ff;
  
  /* Status Colors */
  --success-color: #10b981;
  --error-color: #ef4444;
  --warning-color: #f59e0b;
  --info-color: #3b82f6;
  
  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
  --shadow-xl: 0 20px 50px -10px rgba(0, 0, 0, 0.1);
  
  /* Spacing */
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  
  /* Transitions */
  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 350ms cubic-bezier(0.4, 0, 0.2, 1);
}

html.dark-mode {
  /* Dark Mode Colors */
  --bg-primary: #0f0f0f;
  --bg-secondary: #1a1a1a;
  --bg-tertiary: #252525;
  --text-primary: #f5f5f5;
  --text-secondary: #d0d0d0;
  --text-tertiary: #8a8a8a;
  --border-color: #333333;
  --border-light: #2a2a2a;
  
  /* Accent Colors */
  --accent-primary: #4d94ff;
  --accent-secondary: #7c73d8;
  --accent-hover: #66a3ff;
  --accent-light: #1a2f4d;
  
  /* Status Colors */
  --success-color: #34d399;
  --error-color: #f87171;
  --warning-color: #fbbf24;
  --info-color: #60a5fa;
  
  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 10px 25px -5px rgba(0, 0, 0, 0.5);
  --shadow-xl: 0 20px 50px -10px rgba(0, 0, 0, 0.6);
}

/* ============================================================
   BASE STYLES
   ============================================================ */

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 60px;
}

body {
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  transition: background-color var(--transition-base), color var(--transition-base);
  overflow-x: hidden;
  position: relative;
}

#dna-bg-canvas,
#neural-network-canvas {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: 0;
  pointer-events: none;
  opacity: 0.95;
  top: 0;
  left: 0;
}

.site-header,
main,
.site-footer,
.mobile-nav {
  position: relative;
  z-index: 1;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

h1 { font-size: 3rem; }
h2 { font-size: 2.25rem; }
h3 { font-size: 1.875rem; }
h4 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }
h6 { font-size: 1rem; }

p {
  margin-bottom: 1rem;
  color: var(--text-secondary);
}

/* Links */
a {
  color: var(--accent-primary);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover, a:focus {
  color: var(--accent-hover);
  text-decoration: underline;
}

a:visited {
  color: var(--accent-secondary);
}

/* ============================================================
   LAYOUT & STRUCTURE
   ============================================================ */

.site-header {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  padding: 0.875rem 2rem;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-fast);
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.site-header .logo {
  font-size: 1.25rem;
  margin: 0;
  font-weight: 700;
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  white-space: nowrap;
}

main {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 3rem 2rem;
  background: var(--bg-primary);
  border: none;
}

/* Marquee - Hide but preserve */
.marquee-wrap {
  display: none !important;
}

.marquee-wrap marquee {
  display: none !important;
}

/* Nostalgia Bar - Hide but preserve */
.nostalgia-bar {
  display: none !important;
}

/* Section Structure */
.hero,
.section,
.section-alt,
.section-cta {
  margin-bottom: 4rem;
  padding: 0;
  background: transparent;
}

.section-table {
  width: 100% !important;
  border: none !important;
  background: transparent !important;
  padding: 0 !important;
  margin: 0 !important;
}

.section-table td {
  border: none !important;
  padding: 0 !important;
  background: transparent !important;
}

/* Section Headers */
.section-head,
.tile-section-head {
  margin-bottom: 2.5rem;
  padding: 0;
  text-align: center;
}

.section-title,
.tile-title {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: var(--text-primary);
  position: relative;
  display: inline-block;
}

.section-title::after {
  content: "";
  position: absolute;
  bottom: -8px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary));
  border-radius: var(--radius-md);
}

.section-desc,
.tile-section-desc {
  color: var(--text-secondary);
  font-size: 1.125rem;
  margin-top: 1rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* ============================================================
   HERO SECTION
   ============================================================ */

.hero {
  margin-bottom: 5rem;
  padding-top: 1rem;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
  margin-top: 2rem;
}

.hero-copy {
  animation: slideInUp 0.6s ease-out;
}

.eyebrow {
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent-primary);
  margin-bottom: 1rem;
}

.hero-title {
  font-size: 3.5rem;
  line-height: 1.1;
  margin-bottom: 1.5rem;
  color: var(--text-primary);
}

.hero-title .line {
  display: block;
}

.hero-title .line.accent {
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-lead {
  font-size: 1.25rem;
  color: var(--text-secondary);
  margin-bottom: 2rem;
  line-height: 1.8;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}

.hero-card-wrap {
  animation: slideInRight 0.6s ease-out;
}

.hero-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  padding: 2rem;
  box-shadow: var(--shadow-lg);
  transition: all var(--transition-base);
  transform: translateZ(0);
}

.hero-card:hover {
  box-shadow: var(--shadow-xl);
  transform: translateY(-8px);
}

.hero-card-inner {
  text-align: center;
}

.hero-name {
  font-size: 1.75rem;
  margin-bottom: 0.5rem;
}

.hero-role {
  color: var(--accent-primary);
  font-weight: 600;
  margin-bottom: 1.5rem;
}

.hero-meta {
  list-style: none;
  margin-bottom: 1.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border-color);
}

.hero-meta li {
  margin-bottom: 0.75rem;
  color: var(--text-secondary);
}

.hero-meta .label {
  font-weight: 600;
  color: var(--text-primary);
}

.hero-links {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* Reveal Animation */
.reveal {
  opacity: 1;
  animation: fadeIn 0.6s ease-out;
}

/* ============================================================
   NAVIGATION
   ============================================================ */

.nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
  flex: 1 1 auto;
  min-width: 0;
}

.nav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 0.875rem;
  background: transparent;
  color: var(--text-primary);
  border: none;
  border-radius: var(--radius-md);
  font-weight: 500;
  font-size: 0.9rem;
  transition: all var(--transition-fast);
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
}

.nav a:hover {
  background: var(--bg-tertiary);
  color: var(--accent-primary);
  text-decoration: none;
}

.nav a:visited {
  color: var(--text-primary);
}

.nav a:active {
  background: var(--accent-light);
  color: var(--accent-primary);
}

.nav a.nav-cta {
  background: var(--accent-primary);
  color: white;
  font-weight: 600;
  padding: 0.5rem 1rem;
}

.nav a.nav-cta:hover {
  background: var(--accent-hover);
  text-decoration: none;
}

.menu-toggle {
  display: none;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.chips span {
  display: inline-flex;
  align-items: center;
  padding: 0.3rem 0.65rem;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent-light) 65%, var(--bg-secondary));
  border: 1px solid color-mix(in srgb, var(--accent-primary) 28%, var(--border-color));
  color: var(--accent-primary);
  font-size: 0.78rem;
  font-weight: 600;
}

.subtle {
  color: var(--text-tertiary);
}

/* ============================================================
   BUTTONS & INTERACTIVE ELEMENTS
   ============================================================ */

.btn,
.filter-btn,
.cert-card__cta,
.project-link,
.link-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 1.75rem;
  background: var(--accent-primary);
  color: white;
  border: none;
  border-radius: var(--radius-lg);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
  text-decoration: none;
  white-space: nowrap;
}

.btn:hover,
.filter-btn:hover,
.cert-card__cta:hover,
.project-link:hover,
.link-pill:hover {
  background: var(--accent-hover);
  color: white;
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
  text-decoration: none;
}

.btn:active,
.filter-btn:active,
.cert-card__cta:active,
.project-link:active,
.link-pill:active {
  transform: translateY(0);
  box-shadow: var(--shadow-sm);
}

.btn:disabled,
.filter-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-primary {
  background: var(--accent-primary);
}

.btn-primary:hover {
  background: var(--accent-hover);
}

.btn-ghost {
  background: var(--bg-tertiary);
  color: var(--text-primary);
  border: 2px solid var(--accent-primary);
}

.btn-ghost:hover {
  background: var(--accent-light);
  color: var(--accent-primary);
}

.filter-btn.active {
  background: var(--accent-primary);
  color: white;
}

.cert-toolbar {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6rem;
  margin: 0 auto 1.6rem;
  max-width: 900px;
}

.cert-toolbar .filter-btn {
  padding: 0.5rem 0.9rem;
  border-radius: 999px;
  border: 1px solid var(--border-color);
  background: color-mix(in srgb, var(--bg-secondary) 78%, transparent);
  color: var(--text-secondary);
  font-size: 0.86rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  box-shadow: none;
  transform: none;
}

.cert-toolbar .filter-btn:hover {
  color: var(--text-primary);
  border-color: color-mix(in srgb, var(--accent-primary) 45%, var(--border-color));
  background: color-mix(in srgb, var(--accent-light) 45%, var(--bg-secondary));
}

.cert-toolbar .filter-btn.active {
  color: #ffffff;
  border-color: transparent;
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
  box-shadow: 0 10px 26px -14px color-mix(in srgb, var(--accent-primary) 80%, transparent);
}

.cert-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.2rem;
}

/* ============================================================
   CARDS & TILES
   ============================================================ */

.card,
.tile-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

.card:hover,
.tile-card:hover {
  border-color: var(--accent-primary);
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

.tile-card__glow,
.tile-card__shine {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 0;
  transition: opacity var(--transition-base);
}

.tile-card:hover .tile-card__glow {
  opacity: 0.1;
  background: radial-gradient(circle at center, var(--accent-primary), transparent);
}

.tile-card:hover .tile-card__shine {
  opacity: 0.05;
  background: linear-gradient(135deg, transparent, white);
}

.tile-card__inner {
  position: relative;
  z-index: 1;
}

/* Grid Layouts */
.tile-grid,
.tile-stack,
.grid-3,
.grid-2,
.grid-1 {
  display: grid;
  gap: 2rem;
  margin-top: 2rem;
}

.grid-3 { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(400px, 1fr)); }
.grid-1 { grid-template-columns: 1fr; }
.tile-grid { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.tile-stack { grid-template-columns: 1fr; }

.about-grid,
.project-grid,
.blog-grid,
.edu-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.2rem;
}

.skills-bento {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.skill-block.wide {
  grid-column: span 2;
}

.lang-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 0.9rem;
}

/* About Cards */
.about-card {
  text-align: center;
}

.about-card h3 {
  margin-bottom: 1rem;
}

.about-card.stat-card {
  padding: 2rem;
}

.stat-value {
  display: block;
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--accent-primary);
  margin-bottom: 0.5rem;
}

.stat-label {
  display: block;
  font-size: 0.95rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
}

/* Experience Cards */
.exp-card {
  border-left: 4px solid var(--accent-primary);
}

.exp-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1rem;
}

.exp-head h3 {
  margin: 0;
}

.exp-role {
  color: var(--accent-primary);
  font-weight: 600;
  margin: 0.25rem 0 0;
}

.badge {
  display: inline-block;
  padding: 0.4rem 0.75rem;
  background: var(--accent-light);
  color: var(--accent-primary);
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 600;
  white-space: nowrap;
}

.exp-meta {
  color: var(--text-tertiary);
  font-size: 0.95rem;
  margin-bottom: 1rem;
}

.exp-list {
  list-style: none;
  padding: 0;
}

.exp-list li {
  padding: 0.5rem 0;
  padding-left: 1.5rem;
  position: relative;
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.exp-list li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--accent-primary);
  font-weight: bold;
}

.exp-list li.timeline-item {
  color: var(--accent-primary);
  font-weight: 600;
}

.exp-list li.timeline-item::before {
  content: "●";
  color: var(--accent-primary);
}

/* Education Cards */
.edu-card {
  border-top: 3px solid var(--accent-primary);
}

.edu-icon {
  display: inline-block;
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.edu-degree {
  color: var(--accent-primary);
  font-weight: 600;
  margin: 0.5rem 0;
}

.edu-meta {
  color: var(--text-tertiary);
  font-size: 0.95rem;
  margin: 0.5rem 0;
}

.edu-coursework {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border-color);
}

/* Project Cards */
.project-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  border: 1px solid color-mix(in srgb, var(--border-color) 78%, transparent);
  background: linear-gradient(145deg, color-mix(in srgb, var(--bg-secondary) 84%, transparent), var(--bg-tertiary));
}

.project-card .tile-card__inner--flush-top {
  display: flex;
  flex-direction: column;
  gap: 0.95rem;
  height: 100%;
}

.project-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem;
}

.project-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 52px;
  height: 30px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-primary);
  background: color-mix(in srgb, var(--accent-light) 70%, var(--bg-secondary));
  border: 1px solid color-mix(in srgb, var(--accent-primary) 26%, var(--border-color));
}

.project-card h3 {
  margin: 0;
  font-size: 1.2rem;
}

.project-card p {
  margin: 0;
  color: var(--text-secondary);
  line-height: 1.75;
}

.project-head {
  margin-bottom: 1rem;
}

.project-title {
  margin: 0 0 0.5rem;
}

.project-meta {
  color: var(--text-tertiary);
  font-size: 0.9rem;
}

.project-body {
  flex: 1;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.project-tags {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 1.5rem;
}

.project-tag {
  display: inline-block;
  padding: 0.35rem 0.75rem;
  background: var(--accent-light);
  color: var(--accent-primary);
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 500;
}

.project-links {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.project-card .project-link {
  padding: 0.52rem 0.9rem;
  border-radius: 999px;
  font-size: 0.82rem;
}

/* Blog Cards */
.blog-card {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.blog-header {
  margin-bottom: 1rem;
}

.blog-title {
  margin: 0 0 0.5rem;
  line-height: 1.3;
}

.blog-meta {
  display: flex;
  gap: 1rem;
  font-size: 0.9rem;
  color: var(--text-tertiary);
  margin-bottom: 1rem;
}

.blog-body {
  flex: 1;
  color: var(--text-secondary);
  margin-bottom: 1rem;
  line-height: 1.7;
}

.blog-excerpt {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.blog-tags {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.blog-tag {
  display: inline-block;
  padding: 0.3rem 0.6rem;
  background: var(--bg-tertiary);
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
}

/* Certification Cards */
.cert-card {
  text-align: left;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: linear-gradient(
    140deg,
    rgba(255, 255, 255, 0.12),
    rgba(255, 255, 255, 0.08)
  );
  backdrop-filter: blur(30px);
  -webkit-backdrop-filter: blur(30px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.35),
    0 8px 32px rgba(15, 23, 42, 0.35);
  position: relative;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), transform 0.1s ease;
  transform-style: preserve-3d;
}

.cert-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(120% 100% at 0% 0%, rgba(255, 255, 255, 0.26), transparent 48%);
}

.cert-card:hover::before {
  background: radial-gradient(120% 100% at 0% 0%, rgba(255, 255, 255, 0.34), transparent 58%);
}

.cert-card:hover {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.26),
    0 24px 48px -32px rgba(0, 102, 255, 0.35);
}

.cert-card__title {
  font-size: 1.25rem;
  margin: 0 0 0.65rem;
  color: var(--text-primary);
}

.cert-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
  display: block;
}

.cert-card__issuer {
  color: var(--accent-primary);
  font-weight: 700;
  margin: 0.4rem 0;
  font-size: 0.95rem;
}

.cert-card__date {
  color: var(--text-tertiary);
  font-size: 0.85rem;
  margin: 0.5rem 0;
}

.cert-card__id {
  color: var(--text-secondary);
  font-size: 0.8rem;
  font-family: monospace;
  margin: 0.75rem 0 1rem;
  padding: 0.45rem 0.55rem;
  background: color-mix(in srgb, var(--bg-primary) 65%, transparent);
  border-radius: 0.45rem;
  border: 1px solid color-mix(in srgb, var(--border-color) 72%, transparent);
  word-break: break-all;
}

.cert-card__cta {
  margin-top: 1rem;
}

/* Language Cards */
.lang-card {
  text-align: center;
}

.lang-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.lang-proficiency {
  display: flex;
  gap: 0.3rem;
  justify-content: center;
  margin-top: 0.75rem;
}

.lang-star {
  color: #fbbf24;
  font-size: 1.2rem;
}

.lang-star.empty {
  color: var(--border-color);
}

/* CTA Card */
.cta-card {
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
  color: white;
  text-align: center;
  border: none;
  padding: 2.5rem;
}

.cta-card h3 {
  color: white;
  margin-bottom: 1rem;
}

.cta-card p {
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 1.5rem;
}

.cta-card .btn {
  background: white;
  color: var(--accent-primary);
}

.cta-card .btn:hover {
  background: var(--bg-secondary);
}

/* ============================================================
   FORMS & INPUTS
   ============================================================ */

.contact-form,
form {
  display: grid;
  gap: 1.5rem;
  margin-top: 2rem;
}

.contact-panel {
  display: grid;
  grid-template-columns: minmax(280px, 0.9fr) minmax(340px, 1.1fr);
  gap: 1.2rem;
  align-items: stretch;
}

.contact-panel__info,
.contact-panel__form-wrap {
  border: 1px solid color-mix(in srgb, var(--border-color) 80%, transparent);
  border-radius: 1rem;
  padding: 1.2rem;
  background: linear-gradient(150deg, color-mix(in srgb, var(--bg-secondary) 86%, transparent), var(--bg-tertiary));
  box-shadow: var(--shadow-sm);
}

.contact-panel__info .cta-card__heading {
  margin-bottom: 0.8rem;
  font-size: 1.35rem;
}

.contact-meta {
  margin-top: 1rem;
  padding-top: 0.9rem;
  border-top: 1px dashed var(--border-color);
}

.contact-meta p {
  margin: 0;
  font-size: 0.95rem;
}

.contact-field > span {
  display: inline-block;
  margin-bottom: 0.2rem;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  color: var(--text-primary);
}

.contact-actions {
  display: flex;
  justify-content: flex-end;
}

.contact-field,
.form-group {
  display: grid;
  gap: 0.5rem;
}

label {
  font-weight: 600;
  color: var(--text-primary);
  font-size: 0.95rem;
}

input[type="text"],
input[type="email"],
input[type="number"],
input[type="tel"],
input[type="url"],
input[type="date"],
textarea,
select {
  width: 100%;
  padding: 0.875rem 1rem;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-family: inherit;
  font-size: 1rem;
  transition: all var(--transition-fast);
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px var(--accent-light);
}

textarea {
  resize: vertical;
  min-height: 120px;
}

.contact-submit,
button[type="submit"] {
  padding: 1rem 2rem;
  background: var(--accent-primary);
  color: white;
  border: none;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.contact-submit:hover,
button[type="submit"]:hover {
  background: var(--accent-hover);
  color: white;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.contact-status {
  padding: 0.78rem 0.92rem;
  border-radius: 0.72rem;
  border: 1px solid var(--border-color);
  background: color-mix(in srgb, var(--bg-secondary) 80%, transparent);
  font-size: 0.9rem;
}

.contact-status.is-success {
  border-color: color-mix(in srgb, var(--success-color) 40%, var(--border-color));
  color: var(--success-color);
}

.contact-status.is-error {
  border-color: color-mix(in srgb, var(--error-color) 40%, var(--border-color));
  color: var(--error-color);
}

/* ============================================================
   COMMENTS SECTION
   ============================================================ */

.comment-item {
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border-color);
  border-radius: 0;
  padding: 1.5rem 0;
  margin-bottom: 0;
  animation: slideInRight 0.3s ease;
}

.comment-item:last-child {
  border-bottom: none;
}

.comment-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 0.75rem;
  gap: 1rem;
  flex-wrap: wrap;
}

.comment-author-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.comment-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 700;
  font-size: 0.85rem;
  flex-shrink: 0;
  flex-basis: 36px;
}

.comment-author {
  font-weight: 600;
  color: var(--text-primary);
  font-size: 0.9rem;
}

.comment-author-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
}

.comment-date {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.comment-owner {
  background: transparent;
  color: var(--text-secondary);
  padding: 0;
  border-radius: 0;
  font-size: 0.8rem;
  font-weight: 500;
  text-transform: none;
  margin-left: auto;
}

.comment-body {
  color: var(--text-primary);
  line-height: 1.6;
  margin-bottom: 0.75rem;
  font-size: 0.9rem;
  word-wrap: break-word;
  overflow-wrap: break-word;
  margin-left: 3rem;
}

.comment-actions {
  display: flex;
  gap: 1.5rem;
  align-items: center;
  flex-wrap: wrap;
  margin-left: 3rem;
  margin-top: 0.5rem;
}

.comment-vote {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.comment-vote-like,
.comment-vote-dislike,
.comment-reply,
.comment-delete {
  background: none;
  border: none;
  padding: 0.3rem 0.6rem;
  border-radius: 0;
  cursor: pointer;
  font-size: 0.8rem;
  color: var(--text-secondary);
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  text-decoration: none;
}

.comment-vote-like:hover,
.comment-vote-dislike:hover,
.comment-reply:hover {
  background: none;
  color: var(--text-primary);
  border-color: transparent;
  text-decoration: underline;
}

.comment-vote-like.voted,
.comment-vote-dislike.voted {
  background: none;
  color: var(--accent-primary);
  border-color: transparent;
}

.comment-delete {
  margin-left: 0;
}

.comment-delete:hover {
  background: none;
  color: var(--text-primary);
  border-color: transparent;
  text-decoration: underline;
}


/* ============================================================
   FOOTER
   ============================================================ */

.site-footer {
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%) !important;
  border: 1px solid #dbe4f0;
  border-top: 5px solid #3b82f6;
  padding: 2.5rem 2rem;
  margin: 4rem 0 0;
  font-size: 0.95rem;
  color: #666666;
  text-align: center;
  display: block;
  visibility: visible;
  width: 100%;
  box-sizing: border-box;
  position: relative;
  z-index: 5;
  clear: both;
  box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.04);
  border-radius: 0;
  overflow: hidden;
}

html.dark-mode .site-footer {
  background: var(--bg-secondary) !important;
  border-top-color: var(--border-color);
  color: var(--text-secondary);
}

.footer-clocks {
  max-width: 1280px;
  margin: 0 auto 1.5rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

.footer-clock-panel,
.footer-currency-panel {
  background: color-mix(in srgb, var(--bg-tertiary) 72%, transparent);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1rem 1rem 1.1rem;
  text-align: center;
  box-shadow: var(--shadow-sm);
}

.footer-clock-panel h4,
.footer-currency-panel h4 {
  font-size: 0.78rem;
  margin: 0 0 0.8rem;
  color: var(--accent-primary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 700;
}

.clock-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 0.6rem;
}

.clock-pill {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  align-items: center;
  justify-content: center;
  min-height: 64px;
  border: 1px solid var(--border-color);
  background: var(--bg-primary);
  border-radius: 0.8rem;
  padding: 0.5rem;
}

.clock-pill span {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-tertiary);
  font-weight: 700;
}

.clock-pill strong {
  font-family: "JetBrains Mono", "Consolas", "Courier New", monospace;
  font-size: 1rem;
  color: var(--text-primary);
  font-weight: 700;
}

.footer-currency {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 0.6rem;
  padding: 0;
  background: transparent;
  border-radius: 0;
  border: none;
}

.currency-pair {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.45rem 0.65rem;
  background: var(--bg-primary);
  border-radius: 0.72rem;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.currency-symbol {
  display: block;
  font-weight: 700;
  color: var(--accent-primary);
  font-size: 0.9rem;
}

.currency-rate {
  display: block;
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
  color: var(--text-tertiary);
  font-size: 0.9rem;
}

.retro-note {
  margin: 0.4rem 0;
  font-size: 0.85rem;
  color: var(--text-tertiary);
}

.retro-note--joke {
  font-weight: 700;
  color: var(--text-primary);
}

.retro-links {
  margin: 1rem 0 0;
}

.retro-links a {
  margin: 0 0.5rem;
}

/* ============================================================
   ANIMATIONS
   ============================================================ */

@keyframes slideInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

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

/* ============================================================
   BLOG & COMMENTS STYLING - MEDIUM.COM INSPIRED
   ============================================================ */

.blog-detail {
  width: 100%;
  margin: 0;
  padding: 3rem 2rem;
  max-width: none;
}

.blog-detail__title {
  font-size: clamp(2.5rem, 8vw, 4rem);
  line-height: 1.2;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 1.5rem;
  letter-spacing: -0.02em;
  text-align: center;
}

.blog-detail__meta {
  display: flex;
  gap: 1.5rem;
  align-items: center;
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border-color);
  flex-wrap: wrap;
}

.blog-readtime,
.blog-author,
.blog-date {
  font-size: 0.95rem;
  color: var(--text-secondary);
}

.blog-author {
  font-weight: 600;
  color: var(--text-primary);
}

.blog-detail__content {
  font-size: 1.125rem;
  line-height: 1.85;
  color: var(--text-primary);
  word-wrap: break-word;
  overflow-wrap: break-word;
  max-width: 900px;
  margin: 0 auto;
}

.blog-detail__content p {
  margin-bottom: 1.5rem;
}

.blog-detail__content h2,
.blog-detail__content h3 {
  margin-top: 2rem;
  margin-bottom: 1rem;
  font-weight: 700;
  line-height: 1.3;
}

.blog-detail__content h2 {
  font-size: 1.8rem;
}

.blog-detail__content h3 {
  font-size: 1.4rem;
}

.blog-detail__content ul,
.blog-detail__content ol {
  margin-bottom: 1.5rem;
  padding-left: 2rem;
}

.blog-detail__content li {
  margin-bottom: 0.75rem;
}

.blog-detail__content code {
  background: var(--bg-secondary);
  padding: 0.2rem 0.4rem;
  border-radius: 0.25rem;
  font-family: 'Courier New', monospace;
  font-size: 0.95em;
  color: var(--accent-primary);
}

.blog-detail__content blockquote {
  border-left: 4px solid var(--accent-primary);
  padding-left: 1.5rem;
  margin: 1.5rem 0;
  font-style: italic;
  color: var(--text-secondary);
}

/* ============================================================
   COMMENTS SYSTEM STYLING
   ============================================================ */

.comments-section {
  max-width: 720px;
  margin: 3rem auto 0;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
}

.comments-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 2rem;
  color: var(--text-primary);
}

.comments-form {
  margin-bottom: 2.5rem;
  background: var(--bg-secondary);
  padding: 1.5rem;
  border-radius: 0.75rem;
  border: 1px solid var(--border-color);
}

.comments-grid {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 1rem;
}

.comments-row {
  display: flex;
  gap: 0.75rem;
}

.comments-row input,
.comments-row textarea {
  flex: 1;
}

.comments-row.full {
  grid-column: 1 / -1;
}

input.comment-field,
textarea.comment-field {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  background: var(--bg-primary);
  color: var(--text-primary);
  font-size: 0.95rem;
  font-family: inherit;
  transition: all 0.2s ease;
}

input.comment-field:focus,
textarea.comment-field:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.1);
}

textarea.comment-field {
  resize: vertical;
  min-height: 100px;
}

.comments-note {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 1rem;
}

.comments-status {
  padding: 0.75rem;
  border-radius: 0.5rem;
  font-size: 0.9rem;
  margin-bottom: 1rem;
  display: none;
}

.comments-status.ok {
  background: rgba(34, 197, 94, 0.1);
  color: #22c55e;
  border: 1px solid rgba(34, 197, 94, 0.2);
  display: block;
}

.comments-status.error {
  background: rgba(239, 68, 68, 0.1);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.2);
  display: block;
}

.btn-post-comment,
.btn-post-reply {
  background: var(--accent-primary);
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 600;
  cursor: pointer;
  font-size: 0.95rem;
  transition: all 0.2s ease;
  align-self: flex-start;
}

.btn-post-comment:hover,
.btn-post-reply:hover {
  background: var(--accent-dark);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 102, 255, 0.25);
}

.btn-post-comment:active,
.btn-post-reply:active {
  transform: translateY(0);
}

.comments-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.comment-item {
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border-color);
  border-radius: 0;
  padding: 1.5rem 0;
  margin-bottom: 0;
  animation: slideInRight 0.3s ease;
}

.comment-item:last-child {
  border-bottom: none;
}

.comment-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 0.75rem;
  gap: 1rem;
  flex-wrap: wrap;
}

.comment-author-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.comment-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 700;
  font-size: 0.85rem;
  flex-shrink: 0;
  flex-basis: 36px;
}

.comment-author {
  font-weight: 600;
  color: var(--text-primary);
  font-size: 0.9rem;
}

.comment-author-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
}

.comment-date {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.comment-owner {
  background: transparent;
  color: var(--text-secondary);
  padding: 0;
  border-radius: 0;
  font-size: 0.8rem;
  font-weight: 500;
  text-transform: none;
  margin-left: auto;
}

.comment-body {
  color: var(--text-primary);
  line-height: 1.6;
  margin-bottom: 0.75rem;
  font-size: 0.9rem;
  word-wrap: break-word;
  overflow-wrap: break-word;
  margin-left: 3rem;
}

.comment-actions {
  display: flex;
  gap: 0.8rem;
  align-items: center;
  flex-wrap: wrap;
  margin-left: 3rem;
  margin-top: 0.5rem;
}

.comment-vote {
  display: inline-flex;
  gap: 0.2rem;
  align-items: center;
}

.comment-vote-like,
.comment-vote-dislike,
.comment-reply,
.comment-delete {
  background: none;
  border: none;
  padding: 0.4rem 0.5rem;
  border-radius: 0.3rem;
  cursor: pointer;
  font-size: 1rem;
  color: var(--text-secondary);
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  line-height: 1;
  text-decoration: none;
}

.comment-vote-like:hover,
.comment-vote-dislike:hover,
.comment-reply:hover {
  background: var(--bg-secondary);
  color: var(--text-primary);
  border-color: transparent;
}

.comment-vote-like.voted,
.comment-vote-dislike.voted {
  color: var(--accent-primary);
  font-weight: 700;
}

.comment-vote-count {
  font-size: 0.75rem;
  margin-left: 0.2rem;
  color: var(--text-secondary);
}

.comment-delete {
  margin-left: auto;
  padding: 0.3rem 0.4rem;
}

.comment-delete:hover {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.05);
}

.comment-replies {
  margin-top: 0.5rem;
  padding-top: 0;
  border-top: none;
  list-style: none;
  padding-left: 0;
}

.comment-item.reply {
  margin-left: 2rem;
  padding-left: 1.5rem;
  border-left: 2px dotted var(--border-color);
  background: transparent;
  padding: 1rem 0 1rem 1.5rem;
  border-bottom: none;
}

.comment-item.reply.level-2 {
  margin-left: 4rem;
}

.comment-item.reply.level-3 {
  margin-left: 6rem;
}

.comment-item.reply.level-4 {
  margin-left: 8rem;
}

.reply-form-slot {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border-color);
}

.reply-form {
  background: var(--bg-tertiary);
  padding: 1rem;
  border-radius: 0.5rem;
  border: 1px solid var(--border-color);
  animation: slideInRight 0.2s ease;
}

.reply-form-content {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.reply-form textarea {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid var(--border-color);
  border-radius: 0.4rem;
  background: var(--bg-primary);
  color: var(--text-primary);
  font-size: 0.9rem;
  font-family: inherit;
  resize: vertical;
  min-height: 80px;
}

.reply-form textarea:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.1);
}

.reply-form-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: flex-end;
}

.reply-cancel {
  background: none;
  border: 1px solid var(--border-color);
  padding: 0.5rem 1rem;
  border-radius: 0.4rem;
  cursor: pointer;
  font-size: 0.9rem;
  color: var(--text-secondary);
  transition: all 0.2s ease;
}

.reply-cancel:hover {
  background: var(--bg-secondary);
  color: var(--text-primary);
}

/* ============================================================
   LANGUAGE CARDS ENHANCED
   ============================================================ */

.lang-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
  margin-bottom: 3rem;
}

.lang-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 0.75rem;
  padding: 1.5rem;
  text-align: center;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  overflow: hidden;
}

.lang-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(0, 102, 255, 0.1), transparent);
  transition: left 0.5s ease;
}

.lang-card:hover {
  border-color: var(--accent-primary);
  box-shadow: 0 8px 32px rgba(0, 102, 255, 0.15);
  transform: translateY(-4px);
}

.lang-card:hover::before {
  left: 100%;
}

.lang-name {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

.lang-level {
  display: inline-block;
  background: var(--accent-primary);
  color: white;
  padding: 0.35rem 0.75rem;
  border-radius: 0.25rem;
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.lang-info {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ============================================================
   HEADER & THEME TOGGLE FIXES
   ============================================================ */

.theme-toggle-nav {
  position: relative;
  z-index: 9999 !important;
  visibility: visible !important;
  opacity: 1 !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  background: #ffffff;
  border: 2px solid #e5e7eb;
  padding: 0;
  border-radius: 0.6rem;
  font-size: 1.4rem;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  flex: 0 0 auto;
}

.theme-toggle-nav:hover {
  background: #f3f4f6;
  border-color: #3b82f6;
  transform: scale(1.1);
  color: #3b82f6;
}

.theme-toggle-nav:active {
  transform: scale(0.95);
}

.theme-toggle-icon {
  display: block;
  transition: transform 0.3s ease;
  line-height: 1;
}

.theme-toggle-nav:hover .theme-toggle-icon {
  transform: rotate(20deg);
}

html.dark-mode .theme-toggle-nav {
  background: var(--bg-secondary);
  border-color: var(--border-color);
  color: var(--text-primary);
}

html.dark-mode .theme-toggle-nav:hover {
  background: var(--accent-primary);
  border-color: var(--accent-primary);
  color: white;
}

header {
  z-index: 100;
}

/* ============================================================
   RESPONSIVE DESIGN
   ============================================================ */

@media (max-width: 768px) {
  main {
    padding: 1.5rem 1rem;
  }

  .header-container {
    gap: 0.75rem;
  }

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

  h1 { font-size: 2rem; }
  h2 { font-size: 1.75rem; }
  h3 { font-size: 1.5rem; }

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

  .hero-actions {
    flex-direction: column;
  }

  .btn,
  .contact-submit {
    width: 100%;
    justify-content: center;
  }

  .grid-3,
  .grid-2 {
    grid-template-columns: 1fr;
  }

  .about-grid,
  .project-grid,
  .blog-grid,
  .edu-grid,
  .lang-row,
  .skills-bento {
    grid-template-columns: 1fr;
  }

  .skill-block.wide {
    grid-column: auto;
  }

  .nav {
    gap: 0.35rem;
    justify-content: flex-start;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .nav::-webkit-scrollbar {
    display: none;
  }

  .nav a {
    padding: 0.5rem 0.7rem;
    font-size: 0.82rem;
  }

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

  .footer-clocks {
    gap: 0.8rem;
  }

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

  .footer-currency {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .theme-toggle-nav {
    width: 32px;
    height: 32px;
    font-size: 1rem;
    margin-left: 0;
  }

  .site-header .logo {
    font-size: 1.1rem;
  }

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

  .contact-panel__info,
  .contact-panel__form-wrap {
    padding: 1rem;
  }
}

@media (max-width: 480px) {
  main {
    padding: 1rem;
  }

  h1 { font-size: 1.75rem; }
  h2 { font-size: 1.5rem; }
  h3 { font-size: 1.25rem; }

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

  .section-title::after {
    width: 40px;
    height: 3px;
  }

  .hero-card {
    padding: 1.5rem;
  }

  .tile-card {
    padding: 1.25rem;
  }

  input[type="text"],
  input[type="email"],
  textarea,
  select {
    padding: 0.75rem 0.875rem;
  }

  .logo-text {
    font-size: 1.2rem;
  }

  .site-header {
    padding: 0.72rem 0.65rem;
  }

  .site-header .logo {
    display: none;
  }

  .theme-toggle-nav {
    width: 30px;
    height: 30px;
    font-size: 0.92rem;
  }

  .cert-toolbar {
    justify-content: center;
    gap: 0.45rem;
  }

  .cert-toolbar .filter-btn {
    font-size: 0.8rem;
    padding: 0.45rem 0.72rem;
  }

  .clock-grid,
  .footer-currency {
    grid-template-columns: 1fr;
  }
}

/* ============================================================
   PRINT STYLES
   ============================================================ */

@media print {
  .theme-toggle,
  .marquee-wrap,
  .nostalgia-bar,
  .footer-clocks,
  .footer-currency {
    display: none !important;
  }

  body {
    background: white;
    color: black;
  }

  a {
    color: #0000ee;
    text-decoration: underline;
  }

  .card,
  .tile-card {
    page-break-inside: avoid;
  }
}
