/* =============================================================
   MIJAL.DEV - PERSONAL PORTFOLIO
   External stylesheet for index.html
   -------------------------------------------------------------
   Sections in this file:
   01. Design tokens (colors, fonts, spacing)
   02. Base styles and typography
   03. Buttons and focus states
   04. Navbar
   05. Hero
   06. About
   07. Skills
   08. Projects
   09. Contact
   10. Footer
   11. Animations
   12. Responsive media queries
   ============================================================= */


/* =============================================================
   01. DESIGN TOKENS
   Custom properties keep colors and fonts in one place.
   Change a value here and it updates everywhere it is used.
   ============================================================= */
:root {
  /* Colors */
  --ink: #0d0709;
  --ink-soft: #140a0d;
  --line: rgba(255, 242, 244, 0.09);
  --line-strong: rgba(255, 242, 244, 0.16);
  --white: #fff6f7;
  --text: #d0c0c3;
  --muted: #9c858a;
  --accent: #ff4d5e;
  --accent-soft: rgba(255, 77, 94, 0.12);
  --success: #7ee2b8;

  /* Typography */
  --font-display: "Bricolage Grotesque", "Segoe UI", sans-serif;
  --font-body: "DM Sans", "Segoe UI", sans-serif;
  --font-serif: "Instrument Serif", Georgia, serif;
  --font-mono: "JetBrains Mono", "Consolas", monospace;

  /* Type scale */
  --text-2xs: 0.6875rem; /* 11px */
  --text-xs: 0.75rem;    /* 12px */
  --text-sm: 0.875rem;   /* 14px */
  --text-md: 1rem;       /* 16px */
  --text-lg: 1.125rem;   /* 18px */
  --text-xl: 1.25rem;    /* 20px */
  --text-2xl: 1.5rem;    /* 24px */

  /* Layout */
  --nav-height: 76px;
  --radius-lg: 20px;
  --radius-md: 16px;
  --radius-sm: 10px;
  --radius-tag: 6px;
  --shadow-lg: 0 24px 64px rgba(0, 0, 0, 0.4);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* A subtle film grain stops the dark background feeling flat.
   The SVG is drawn by the browser, so there is no extra image file. */
body::before {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  content: "";
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)' opacity='.7'/%3E%3C/svg%3E");
}

/* =============================================================
   02. BASE STYLES AND TYPOGRAPHY
   ============================================================= */
html {
  color-scheme: dark;
  scroll-behavior: smooth;
  /* Keeps anchored sections from hiding under the sticky navbar. */
  scroll-padding-top: calc(var(--nav-height) + 24px);
}

body {
  margin: 0;
  overflow-x: clip; /* Prevents accidental horizontal scrolling. */
  background: var(--ink);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

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

h1, h2, h3, h4 {
  color: var(--white);
  font-family: var(--font-display);
  font-weight: 600;
  text-wrap: balance;
}

p {
  text-wrap: pretty;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
}

::selection {
  background: var(--accent);
  color: var(--ink);
}

code {
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.85em;
}

.container {
  max-width: 1240px;
  padding-inline: 1.5rem;
}

/* Outer spacing for each content section (the hero has its own padding). */
.section {
  position: relative;
  z-index: 1;
  padding-block: clamp(5rem, 8vw, 7.5rem);
  border-top: 1px solid var(--line);
}

/* The mono label above headings, e.g. "/ About me". */
.section-label {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0 0 1.25rem;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  letter-spacing: 0;
  text-transform: none;
}

.section-label::after {
  width: 24px;
  height: 1px;
  content: "";
  background: var(--accent);
}

.section-title {
  margin: 0;
  color: var(--white);
  font-size: clamp(2.6rem, 5vw, 4.35rem);
  letter-spacing: -0.055em;
  line-height: 0.98;
}

/* Serif accent adds an editorial human touch to the display type. */
.section-title em {
  color: var(--accent);
  font-family: var(--font-serif);
  font-size: 1.1em;
  font-style: normal;
  font-weight: 400;
  letter-spacing: -0.01em;
}

.section-copy {
  max-width: 460px;
  margin: 1.5rem 0 0;
  color: var(--text);
  font-size: 1rem;
  line-height: 1.75;
}

/* Shared header layout for Skills and Projects. */
.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 3rem;
  margin-bottom: 3rem;
}

.section-head .section-copy {
  max-width: 360px;
  margin-bottom: 0.5rem;
}

/* Skip link: hidden until it receives keyboard focus. */
.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 2000;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-sm);
  background: var(--white);
  color: var(--ink);
  font-weight: 600;
  transform: translateY(-160%);
  transition: transform 0.25s var(--ease);
}

.skip-link:focus {
  transform: translateY(0);
}

/* =============================================================
   03. BUTTONS AND FOCUS STATES
   Bootstrap's .btn base class is kept; .btn-accent only restyles it.
   ============================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 600;
  line-height: 1.2;
  transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.btn-lg {
  padding: 0.875rem 1.5rem;
  font-size: 0.9375rem;
}

.btn-accent {
  border: 1px solid transparent;
  background: var(--accent);
  color: #190608;
  box-shadow: none;
}

.btn-accent:hover,
.btn-accent:focus-visible {
  background: #ff6675;
  color: #190608;
  transform: none;
  box-shadow: none;
}

.btn-ghost {
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--white);
  backdrop-filter: none;
}

.btn-ghost:hover,
.btn-ghost:focus-visible {
  border-color: rgba(255, 242, 244, 0.28);
  background: rgba(255, 255, 255, 0.04);
  color: var(--white);
  transform: none;
}

.btn:focus-visible,
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* All Lucide SVG icons share a small default size. */
.lucide {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  stroke-width: 1.8;
}

/* =============================================================
   04. NAVBAR
   position: sticky keeps the header visible while scrolling.
   ============================================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1030;
  border-bottom: 1px solid transparent;
  background: rgba(13, 7, 9, 0.94);
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

/* JavaScript adds .is-scrolled after 20px of scrolling. */
.site-header.is-scrolled {
  border-bottom-color: var(--line);
  background: var(--ink);
  box-shadow: none;
}

.navbar {
  min-height: var(--nav-height);
}

.navbar-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0;
  color: var(--white);
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.navbar-brand:hover {
  color: var(--white);
}

.brand-mark {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border-radius: 8px;
  background: var(--accent);
  color: #190608;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: -0.05em;
  box-shadow: none;
}

.brand-dot {
  color: var(--accent);
}

.navbar-nav {
  gap: 0.125rem;
}

.navbar-nav .nav-link {
  position: relative;
  padding: 0.5rem 0.75rem !important;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0;
  transition: color 0.2s ease;
}

/* The small line under each link grows from left to right on hover. */
.navbar-nav .nav-link::after {
  position: absolute;
  right: 0.75rem;
  bottom: 0.25rem;
  left: 0.75rem;
  height: 1px;
  content: "";
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s var(--ease);
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
  color: var(--white);
}

.navbar-nav .nav-link:hover::after,
.navbar-nav .nav-link.active::after {
  transform: scaleX(1);
}

.navbar-toggler {
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  padding: 0.5rem;
}

.navbar-toggler:focus {
  box-shadow: 0 0 0 2px rgba(255, 77, 94, 0.25);
}

.navbar-toggler-icon {
  width: 1.3em;
  height: 1.3em;
}

/* =============================================================
   05. HERO
   ============================================================= */
#hero {
  position: relative;
  display: flex;
  min-height: calc(100svh - var(--nav-height));
  align-items: center;
  overflow: clip;
  padding-block: 6rem 3.5rem;
  background: var(--ink);
}

/* Faint architectural grid, faded out with a mask. */
#hero::before {
  position: absolute;
  inset: 0;
  content: "";
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 72px 72px;
  -webkit-mask-image: radial-gradient(ellipse at 70% 45%, #000 0%, transparent 70%);
  mask-image: radial-gradient(ellipse at 70% 45%, #000 0%, transparent 70%);
  opacity: 0.4;
  pointer-events: none;
}

.hero-container {
  position: relative;
  z-index: 1;
}

.hero-copy .eyebrow,
.hero-title,
.hero-role,
.hero-lede,
.hero-actions,
.hero-meta {
  animation: fade-up 0.85s var(--ease) both;
}

.hero-title {
  animation-delay: 0.08s;
}

.hero-role {
  animation-delay: 0.14s;
}

.hero-lede {
  animation-delay: 0.2s;
}

.hero-actions {
  animation-delay: 0.27s;
}

.hero-meta {
  animation-delay: 0.34s;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0;
  text-transform: none;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 4px rgba(126, 226, 184, 0.08);
  animation: pulse-dot 2.8s ease-in-out infinite;
}

.hero-title {
  margin: 1.25rem 0 1rem;
  color: var(--white);
  font-size: clamp(4.8rem, 10.8vw, 9rem);
  font-weight: 600;
  letter-spacing: -0.075em;
  line-height: 0.82;
}

.hero-title .accent {
  display: inline-block;
  color: var(--accent);
}

.hero-role {
  margin: 0 0 1.5rem;
  color: var(--text);
  font-family: var(--font-mono);
  font-size: clamp(0.75rem, 1.3vw, 0.8125rem);
  letter-spacing: 0;
  line-height: 1.8;
}

.role-divider {
  margin-inline: 0.5rem;
  color: var(--accent);
}

.hero-lede {
  max-width: 555px;
  margin: 0;
  color: var(--text);
  font-size: clamp(1rem, 1.4vw, 1.0625rem);
  line-height: 1.75;
}

.hero-actions {
  margin-top: 2rem;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 2rem;
  margin: 2.5rem 0 0;
  padding: 1.25rem 0 0;
  border-top: 1px solid var(--line);
  list-style: none;
}

.hero-meta li {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.hero-meta span {
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  letter-spacing: 0;
  text-transform: none;
}

.hero-meta strong {
  color: #f0e4e6;
  font-size: 0.8125rem;
  font-weight: 500;
}

/* ----- Hero visual: the student developer ID card ----- */
/* From Uiverse.io by Cornerstone-04 - https://uiverse.io/Cornerstone-04/moody-treefrog-55
   MIT License, Copyright (c) Cornerstone-04 (Cornerstone Ephraim) */
.hero-visual {
  position: relative;
  width: 100%;
  max-width: 384px;
  margin-inline: auto;
  padding-block: 1rem;
  perspective: 900px;
  animation: fade-up 1s 0.2s var(--ease) both;
}

/* A dashed technical frame behind the card adds depth without clutter. */
.hero-visual::before {
  position: absolute;
  inset: -1.25rem -1rem;
  border: 1px dashed rgba(255, 255, 255, 0.08);
  border-radius: 32px;
  content: "";
  transform: rotate(3deg);
  pointer-events: none;
}

.id-card {
  --tilt-x: 0deg;
  --tilt-y: 0deg;
  --glare-x: 50%;
  --glare-y: 50%;
  position: relative;
  width: 100%;
  padding: 0.75rem;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 24px;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.02) 60%);
  box-shadow: var(--shadow-lg);
  transform: rotate(-2.2deg) rotateX(var(--tilt-x)) rotateY(var(--tilt-y));
  transform-style: preserve-3d;
  will-change: transform;
  transition: transform 0.5s var(--ease), border-color 0.3s ease;
}

/* Cursor-driven parallax tilt. JavaScript writes --tilt-x/--tilt-y from the
   pointer position, and --glare-x/--glare-y move a soft light across the
   card. Touch screens keep the static card. */
@media (hover: hover) and (pointer: fine) {
  .hero-visual:hover .id-card {
    border-color: rgba(255, 77, 94, 0.3);
    transform: rotate(-2.2deg) rotateX(var(--tilt-x)) rotateY(var(--tilt-y));
  }

  .id-card.is-tilting {
    transition: transform 0.08s linear, border-color 0.3s ease;
  }

  .id-card::after {
    position: absolute;
    inset: 0;
    z-index: 2;
    border-radius: inherit;
    background: radial-gradient(360px circle at var(--glare-x) var(--glare-y), rgba(255, 255, 255, 0.06), transparent 62%);
    content: "";
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
  }

  .hero-visual:hover .id-card::after {
    opacity: 1;
  }
}

.id-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.25rem 0.5rem 0.75rem;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  letter-spacing: 0;
}

.id-dots {
  display: flex;
  gap: 4px;
}

.id-dots span {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--line-strong);
}

.id-dots span:first-child {
  background: var(--accent);
}

.id-photo {
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-radius: 16px;
  background: #1c0e11;
}

.id-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Absolute positioning places these labels over the image. */
.id-photo::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(180deg, transparent 48%, rgba(10, 6, 7, 0.72));
  pointer-events: none;
}

.photo-chip {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  z-index: 1;
  padding: 0.25rem 0.5rem;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-tag);
  background: rgba(13, 7, 9, 0.72);
  color: var(--white);
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  letter-spacing: 0;
  backdrop-filter: none;
}

.photo-label {
  position: absolute;
  bottom: 0.75rem;
  left: 0.75rem;
  z-index: 1;
  color: rgba(255, 255, 255, 0.72);
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  letter-spacing: 0;
}

.id-body {
  padding: 0.75rem 0.5rem 0.25rem;
}

.id-kicker {
  margin: 0 0 0.25rem;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  letter-spacing: 0;
  text-transform: none;
}

.id-name {
  margin: 0;
  color: var(--white);
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.id-role {
  margin: 0.25rem 0 0;
  color: var(--muted);
  font-size: 0.8125rem;
  line-height: 1.55;
}

.id-meta {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--line);
}

.id-meta-label {
  display: block;
  margin-bottom: 0.25rem;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  letter-spacing: 0;
}

.id-meta strong {
  color: #ede1e3;
  font-size: 0.8125rem;
  font-weight: 500;
}

/* A decorative barcode made only with CSS. */
.id-barcode {
  width: 80px;
  height: 28px;
  border-radius: 2px;
  background: repeating-linear-gradient(
    90deg,
    rgba(255, 255, 255, 0.7) 0 1px,
    transparent 1px 3px,
    rgba(255, 255, 255, 0.7) 3px 5px,
    transparent 5px 8px
  );
  opacity: 0.5;
}

.scroll-cue {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: clamp(2rem, 4vw, 3rem);
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  letter-spacing: 0;
  text-transform: none;
  transition: color 0.2s ease;
}

.scroll-cue:hover {
  color: var(--white);
}

.scroll-cue span {
  width: 32px;
  height: 1px;
  background: var(--accent);
  opacity: 0.5;
}

/* =============================================================
   06. ABOUT
   ============================================================= */
#about {
  background: var(--ink);
}

.sticky-heading {
  position: sticky;
  top: calc(var(--nav-height) + 2.5rem);
}

.about-signoff {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 2rem;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0;
}

.signoff-line {
  width: 32px;
  height: 1px;
  background: var(--accent);
}

.about-content > p {
  max-width: 630px;
  margin: 0 0 1.25rem;
  color: var(--text);
  line-height: 1.8;
}

.about-content .about-lede {
  margin-bottom: 1.25rem;
  color: #f4e9eb;
  font-size: clamp(1.25rem, 2vw, 1.375rem);
  line-height: 1.55;
  letter-spacing: -0.01em;
}

/* CSS GRID: two equal columns for the fact cards.
   The third card spans both columns using grid-column: 1 / -1. */
.facts-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin: 2rem 0 1.5rem;
}

.fact-card {
  position: relative;
  overflow: hidden;
  padding: 1.5rem; /* Box model: content + padding + border */
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.025);
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.fact-card:hover {
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.035);
}

.fact-icon {
  display: grid;
  width: 20px;
  height: 20px;
  margin-bottom: 0.75rem;
  place-items: center;
  color: var(--muted);
}

.fact-icon .lucide {
  width: 18px;
  height: 18px;
}

.fact-label {
  margin: 0 0 0.375rem;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  letter-spacing: 0;
  text-transform: none;
}

.fact-title {
  margin: 0 0 0.5rem;
  color: var(--white);
  font-size: var(--text-lg);
  letter-spacing: -0.01em;
  line-height: 1.3;
}

.fact-text {
  margin: 0;
  color: var(--muted);
  font-size: var(--text-sm);
  line-height: 1.65;
}

.fact-card--wide {
  display: flex;
  grid-column: 1 / -1;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.fact-wide-content {
  max-width: 480px;
}

.fact-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
  margin: 0.75rem 0 0;
  padding: 0;
  list-style: none;
}

.fact-tags li {
  padding: 0.25rem 0.5rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-tag);
  background: rgba(255, 255, 255, 0.03);
  color: #cbbcc0;
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  letter-spacing: 0;
  line-height: 1.5;
}

.field-notes {
  padding: 1.25rem 1.5rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.02);
}

.field-notes-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0;
  text-transform: none;
}

.field-notes-head .lucide {
  width: 16px;
  height: 16px;
  color: var(--muted);
}

.field-notes ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.field-notes li {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 0.75rem;
  align-items: start;
  padding: 0.75rem 0;
  border-top: 1px solid var(--line);
  color: #d4c4c7;
  font-size: 0.8125rem;
  line-height: 1.55;
}

.field-notes li:first-child {
  margin-top: 0.5rem;
}

.note-state {
  display: inline-flex;
  width: fit-content;
  padding: 0.125rem 0.375rem;
  border: 1px solid var(--line);
  border-radius: 4px;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  letter-spacing: 0;
  line-height: 1.4;
}

.note-state--active {
  border-color: rgba(255, 77, 94, 0.25);
  background: transparent;
  color: var(--accent);
}

/* =============================================================
   07. SKILLS
   ============================================================= */
#skills {
  background: var(--ink-soft);
}

.skill-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.025);
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.skill-card:hover {
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.035);
  box-shadow: none;
  transform: none;
}

.skill-card .card-body {
  display: flex;
  height: 100%;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1.5rem;
}

.skill-top {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 1rem;
  margin-bottom: 0.5rem;
}

.skill-icon {
  display: grid;
  width: 20px;
  height: 20px;
  place-items: center;
  border: 0;
  border-radius: 0;
  background: none;
  color: var(--muted);
  transition: color 0.2s ease;
}

.skill-icon .lucide {
  width: 20px;
  height: 20px;
}

.skill-card:hover .skill-icon {
  background: none;
  box-shadow: none;
  color: var(--accent);
}

.skill-name {
  margin: 0;
  color: var(--white);
  font-size: 1.1875rem;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.skill-desc {
  margin: 0;
  color: var(--muted);
  font-size: var(--text-sm);
  line-height: 1.65;
}

/* The shared tag list sits a little tighter inside a skill card. */
.skill-card .fact-tags {
  margin-top: 0.25rem;
}

.learning-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  margin-top: 2rem;
  padding: 1rem 1.25rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0;
}

.learning-strip-title {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text);
}

.learning-strip-title .lucide {
  width: 15px;
  height: 15px;
  color: var(--muted);
}

.learning-strip p {
  margin: 0;
}

.learning-strip strong {
  color: #ece0e2;
  font-weight: 500;
}

/* =============================================================
   08. PROJECTS
   ============================================================= */
#projects {
  background: var(--ink);
}

.project-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: #13090b;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.project-card:hover {
  border-color: var(--line-strong);
  box-shadow: none;
  transform: none;
}

.project-media {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: #1a0d10;
}

.project-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.project-body {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1.5rem;
}

.project-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  letter-spacing: 0;
  text-transform: none;
}

.project-title {
  margin: 0;
  color: var(--white);
  font-size: 1.375rem;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.project-desc {
  flex: 1 1 auto;
  margin: 0;
  color: var(--text);
  font-size: var(--text-sm);
  line-height: 1.7;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.project-tags li {
  padding: 0.25rem 0.5rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-tag);
  background: rgba(255, 255, 255, 0.025);
  color: #cbbcc0;
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  letter-spacing: 0;
  line-height: 1.5;
}

.project-link {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 0.375rem;
  margin-top: 0.25rem;
  color: var(--accent);
  font-family: var(--font-body);
  font-size: 0.8125rem;
  letter-spacing: 0;
  transition: color 0.2s ease;
}

.project-link .lucide {
  width: 14px;
  height: 14px;
}

.project-link:hover {
  gap: 0.375rem;
  color: var(--white);
}

/* =============================================================
   09. CONTACT
   ============================================================= */
#contact {
  overflow: clip;
  background: var(--ink-soft);
}

.contact-list {
  /* CSS GRID again: a tidy stack of contact details with one gap rule. */
  display: grid;
  gap: 1rem;
  margin: 2rem 0 0;
  padding: 0;
  list-style: none;
}

.contact-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}

.contact-icon {
  display: grid;
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
}

.contact-icon .lucide {
  width: 16px;
  height: 16px;
}

.contact-label {
  display: block;
  margin-bottom: 0.125rem;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  letter-spacing: 0;
  text-transform: none;
}

.contact-list a,
.contact-list strong {
  color: #f4e9eb;
  font-size: var(--text-sm);
  font-weight: 500;
  word-break: break-word;
}

.contact-list a {
  border-bottom: 1px solid var(--line-strong);
  transition: border-color 0.2s ease, color 0.2s ease;
}

.contact-list a:hover {
  border-color: var(--accent);
  color: var(--white);
}

.contact-aside {
  max-width: 390px;
  margin: 1.75rem 0 0;
  padding-top: 1.25rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.8125rem;
  line-height: 1.6;
}

.contact-panel {
  padding: clamp(1.5rem, 3.5vw, 2.5rem);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.025);
  box-shadow: none;
  backdrop-filter: none;
}

.contact-intro {
  display: flex;
  flex-direction: column;
}

.contact-intro .contact-aside {
  margin-top: auto;
}

.contact-panel-head {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0;
  white-space: nowrap;
}

.contact-panel-head::after {
  flex: 1 1 auto;
  height: 1px;
  background: var(--line);
  content: "";
}

.contact-feature {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.25rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: rgba(13, 7, 9, 0.35);
  color: #f4e9eb;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.contact-feature:hover {
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.04);
}

.contact-feature-icon {
  display: grid;
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--accent);
}

.contact-feature-icon .lucide {
  width: 18px;
  height: 18px;
}

.contact-feature-copy {
  display: grid;
  min-width: 0;
  gap: 0.125rem;
}

.contact-feature-copy strong {
  color: var(--white);
  font-size: clamp(0.9375rem, 2vw, 1.0625rem);
  font-weight: 500;
  overflow-wrap: break-word;
}

.contact-feature > .lucide {
  width: 18px;
  height: 18px;
  margin-left: auto;
  color: var(--muted);
  transition: color 0.2s ease, transform 0.2s var(--ease);
}

.contact-feature:hover > .lucide {
  color: var(--accent);
  transform: translate(2px, -2px);
}

.contact-list--grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.125rem 1.5rem;
  margin: 1.5rem 0 0;
  padding: 1.5rem 0 0;
  border-top: 1px solid var(--line);
}

/* =============================================================
   10. FOOTER
   ============================================================= */
#site-footer {
  padding-block: 3.5rem 1.5rem;
  border-top: 1px solid var(--line);
  background: #0a0607;
}

.footer-top {
  display: grid;
  grid-template-columns: 1.6fr 0.8fr 0.9fr;
  gap: 3rem;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid var(--line);
}

.footer-brand p {
  max-width: 290px;
  margin: 1rem 0 0;
  color: var(--muted);
  font-size: var(--text-sm);
  line-height: 1.7;
}

.footer-heading {
  margin: 0 0 1rem;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0;
  text-transform: none;
}

.footer-nav ul {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-nav a {
  color: #d1c1c4;
  font-size: var(--text-sm);
  transition: color 0.2s ease;
}

.footer-nav a:hover {
  color: var(--accent);
}

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

.social-link {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--muted);
  transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.social-link .lucide {
  width: 16px;
  height: 16px;
}

.social-link:hover {
  border-color: var(--accent);
  background: var(--accent);
  color: var(--ink);
  transform: none;
}

.footer-mail {
  display: inline-block;
  margin-top: 1rem;
  color: #d3c3c6;
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  border-bottom: 1px solid var(--line);
  transition: color 0.2s ease, border-color 0.2s ease;
}

.footer-mail:hover {
  border-color: var(--accent);
  color: var(--white);
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 2rem;
  flex-wrap: wrap;
  padding-top: 1.5rem;
  color: var(--muted);
  font-size: var(--text-xs);
}

.footer-bottom p {
  margin: 0;
}

.back-to-top {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0;
  transition: color 0.2s ease;
}

.back-to-top .lucide {
  width: 13px;
  height: 13px;
}

.back-to-top:hover {
  gap: 0.375rem;
  color: var(--white);
}

/* =============================================================
   11. ANIMATIONS
   @keyframes define reusable motion; transitions handle hover states.
   ============================================================= */
@keyframes fade-up {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse-dot {
  0%, 100% {
    box-shadow: 0 0 0 4px rgba(126, 226, 184, 0.08);
    opacity: 1;
  }
  50% {
    box-shadow: 0 0 0 7px rgba(126, 226, 184, 0.02);
    opacity: 0.72;
  }
}

/* Scroll-reveal styles only apply when JavaScript is available.
   script.js adds the .js class to <html> immediately.
   The hidden state is in :not(.is-visible), so once an element is visible
   its normal hover transforms (on cards, for example) work again. */
.js .reveal {
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}

.js .reveal:not(.is-visible) {
  opacity: 0;
  transform: translateY(16px);
}

.reveal-delay-1 {
  transition-delay: 90ms;
}

.reveal-delay-2 {
  transition-delay: 180ms;
}

.reveal-delay-3 {
  transition-delay: 270ms;
}

/* =============================================================
   12. RESPONSIVE MEDIA QUERIES
   Bootstrap already handles the grid. These queries refine spacing
   and hide decoration when there is not enough room.
   ============================================================= */

/* Laptop */
@media (max-width: 1199.98px) {
  .hero-title {
    font-size: clamp(4.4rem, 10vw, 7.2rem);
  }

  .hero-visual::before {
    inset: -1rem -0.5rem;
  }
}

/* Tablet and below */
@media (max-width: 991.98px) {
  :root {
    --nav-height: 72px;
  }

  .navbar-collapse {
    margin-top: 0.75rem;
    padding: 0.75rem;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #13090b;
    box-shadow: none;
  }

  .navbar-nav {
    gap: 0;
  }

  .navbar-nav .nav-link {
    padding: 0.75rem !important;
    font-size: 0.8125rem;
  }

  .navbar-nav .nav-link::after {
    right: auto;
    left: 0.75rem;
    width: 24px;
  }

  .navbar .container {
    align-items: center;
  }

  #hero {
    min-height: auto;
    padding-top: 3.75rem;
  }

  .hero-title {
    font-size: clamp(4.8rem, 16vw, 8rem);
  }

  .hero-visual {
    max-width: 384px;
    margin-top: 1.5rem;
  }

  .hero-visual::before {
    inset: -1.25rem -1rem;
  }

  .sticky-heading {
    position: static;
  }

  .section-head {
    display: block;
    margin-bottom: 2.25rem;
  }

  .section-head .section-copy {
    max-width: 520px;
    margin-top: 1.25rem;
  }

  .about-content {
    margin-top: 0.5rem;
  }

  .section-title {
    font-size: clamp(2.6rem, 6.5vw, 3.7rem);
  }

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

  .footer-social {
    grid-column: 1 / -1;
  }
}

/* Small tablet / large phone */
@media (max-width: 767.98px) {
  .container {
    padding-inline: 1.25rem;
  }

  /* Bootstrap's g-5 gutters are wider than the phone container padding.
     Reducing the horizontal gutter keeps every row inside the viewport. */
  .row.g-5 {
    --bs-gutter-x: 1.75rem;
  }

  .section {
    padding-block: 4.5rem;
  }

  .hero-copy .eyebrow {
    font-size: var(--text-xs);
    letter-spacing: 0;
  }

  .hero-title {
    font-size: clamp(4.25rem, 19vw, 6.2rem);
  }

  .hero-role {
    font-size: var(--text-xs);
    line-height: 1.9;
  }

  .hero-lede {
    font-size: 1rem;
  }

  .hero-meta {
    gap: 1rem 1.5rem;
  }

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

  .fact-card--wide {
    grid-column: auto;
  }

  .field-notes li {
    grid-template-columns: 84px 1fr;
  }

  .learning-strip {
    display: block;
    line-height: 1.7;
  }

  .learning-strip p {
    margin-top: 0.5rem;
  }

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

  .footer-brand {
    grid-column: 1 / -1;
  }

  .footer-social {
    grid-column: auto;
  }

  .footer-bottom {
    justify-content: flex-start;
  }

  .back-to-top {
    width: 100%;
  }
}

/* Smartphone */
@media (max-width: 575.98px) {
  .container {
    padding-inline: 1.25rem;
  }

  .navbar-brand {
    font-size: 1rem;
  }

  .brand-mark {
    width: 32px;
    height: 32px;
  }

  .hero-actions {
    margin-top: 1.5rem;
  }

  .hero-actions .btn {
    flex: 1 1 100%;
  }

  .hero-meta {
    margin-top: 2rem;
    gap: 1rem 1.5rem;
  }

  .hero-meta li {
    min-width: 88px;
  }

  .hero-visual {
    max-width: 100%;
  }

  .hero-visual::before {
    display: none;
  }

  .id-card {
    transform: rotate(-1.2deg) rotateX(var(--tilt-x)) rotateY(var(--tilt-y));
  }

  .section-title {
    font-size: clamp(2.35rem, 10.5vw, 3rem);
  }

  .section-copy {
    font-size: 1rem;
  }

  .about-content .about-lede {
    font-size: 1.25rem;
  }

  .facts-grid {
    gap: 0.75rem;
    margin-top: 1.75rem;
  }

  .fact-card {
    padding: 1.25rem;
  }

  .field-notes {
    padding: 1.25rem;
  }

  .field-notes li {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }

  .contact-list a,
  .contact-list strong {
    font-size: var(--text-sm);
  }

  .contact-panel {
    padding: 1.25rem;
    border-radius: var(--radius-md);
  }

  .contact-feature {
    gap: 0.75rem;
    padding: 0.875rem 1rem;
  }

  .contact-feature-copy strong {
    font-size: 0.875rem;
  }

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

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

  .footer-social {
    grid-column: auto;
  }

  .footer-bottom {
    gap: 0.75rem;
  }

  .back-to-top {
    width: auto;
  }
}

/* Accessibility: stop decorative motion for visitors who ask for less. */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .js .reveal:not(.is-visible) {
    opacity: 1;
    transform: none;
  }
}
