/* ==========================================================================
   REEM — Portfolio
   Aesthetic: dark editorial luxury × security-tech details
   ========================================================================== */

/* ------------------------------ Tokens ---------------------------------- */
:root {
  --font-head: "Alexandria", "IBM Plex Sans Arabic", system-ui, sans-serif;
  --font-body: "IBM Plex Sans Arabic", "Alexandria", system-ui, sans-serif;
  --font-mono: "Space Grotesk", "IBM Plex Sans Arabic", monospace;

  --bg: #07080a;
  --bg-soft: #0a0c10;
  --surface: #0e1015;
  --surface-2: #13161c;
  --surface-3: #181c23;
  --text: #f4f0e8;
  --text-soft: #d1cbc0;
  --muted: #918e87;
  --line: rgba(255, 255, 255, 0.08);
  --line-2: rgba(255, 255, 255, 0.14);

  --gold: #d6b489;
  --gold-2: #b78952;
  --gold-3: #f0d9b8;
  --gold-glow: rgba(214, 180, 137, 0.14);
  --green: #7ed6b0;
  --green-soft: rgba(126, 214, 176, 0.09);
  --danger: #f08e84;

  --grad-gold: linear-gradient(135deg, var(--gold-3) 0%, var(--gold) 42%, var(--gold-2) 100%);
  --grad-text: linear-gradient(100deg, var(--gold-3), var(--gold) 45%, var(--gold-2) 80%, var(--gold-3));
  --glow: 0 24px 70px -30px rgba(214, 180, 137, 0.4);

  --radius: 24px;
  --radius-sm: 16px;
  --container: 1240px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --header-h: 84px;
}

html[data-theme="light"] {
  --bg: #f6f2ea;
  --bg-soft: #efe9de;
  --surface: #fffdf9;
  --surface-2: #f6f0e5;
  --surface-3: #ece3d4;
  --text: #17130e;
  --text-soft: #3f382e;
  --muted: #746c5f;
  --line: rgba(23, 19, 14, 0.1);
  --line-2: rgba(23, 19, 14, 0.17);

  --gold: #a9783d;
  --gold-2: #855823;
  --gold-3: #c79a5b;
  --gold-glow: rgba(169, 120, 61, 0.11);
  --green: #1f8a66;
  --green-soft: rgba(31, 138, 102, 0.08);
  --grad-text: linear-gradient(100deg, #b9853f, #8a5a25 45%, #c79a5b 85%);
  --glow: 0 24px 70px -34px rgba(120, 82, 35, 0.32);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 100px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  color: var(--text);
  background-color: var(--bg);
  background-image:
    radial-gradient(ellipse 60% 38% at 82% -4%, rgba(214, 180, 137, 0.055), transparent 62%),
    radial-gradient(ellipse 50% 30% at 8% 22%, rgba(126, 214, 176, 0.025), transparent 70%);
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color 0.45s ease, color 0.45s ease;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 9997;
  pointer-events: none;
  opacity: 0.028;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.6'/%3E%3C/svg%3E");
}

body.menu-open,
body.modal-open {
  overflow: hidden;
}

img {
  display: block;
  max-width: 100%;
}

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

button,
input,
textarea,
select {
  font: inherit;
  color: inherit;
}

button {
  background: none;
  border: 0;
  cursor: pointer;
}

ul,
ol {
  list-style: none;
}

::selection {
  background: var(--gold);
  color: #171006;
}

:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
  border-radius: 4px;
}

::-webkit-scrollbar {
  width: 10px;
}

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

::-webkit-scrollbar-thumb {
  background: var(--surface-3);
  border-radius: 20px;
  border: 2px solid var(--bg);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--gold-2);
}

.container {
  width: 100%;
  max-width: calc(var(--container) + 96px);
  margin-inline: auto;
  padding-inline: clamp(20px, 4vw, 48px);
}

.svg-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.icon {
  width: 1em;
  height: 1em;
  display: inline-block;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.skip-link {
  position: fixed;
  top: -100px;
  inset-inline-start: 20px;
  z-index: 10000;
  padding: 12px 20px;
  background: var(--gold);
  color: #171006;
  border-radius: 0 0 10px 10px;
  font-weight: 600;
  transition: top 0.25s ease;
}

.skip-link:focus {
  top: 0;
}

.grad-text {
  background: var(--grad-text);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
  animation: shimmerText 9s ease-in-out infinite;
}

/* ---------------------------- Buttons ----------------------------------- */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 54px;
  padding: 0 26px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: 0.94rem;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  overflow: hidden;
  cursor: pointer;
  transition:
    transform 0.4s var(--ease),
    box-shadow 0.4s var(--ease),
    background-color 0.3s ease,
    border-color 0.3s ease,
    color 0.3s ease;
}

.btn .icon {
  font-size: 18px;
  transition: transform 0.4s var(--ease);
}

.btn-primary {
  background: var(--grad-gold);
  color: #1b1309;
  box-shadow: 0 18px 38px -18px rgba(214, 180, 137, 0.65);
}

.btn-primary::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 20%, rgba(255, 255, 255, 0.5) 50%, transparent 80%);
  transform: translateX(-140%);
  transition: transform 0.75s var(--ease);
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 24px 52px -18px rgba(214, 180, 137, 0.72);
}

.btn-primary:hover::after {
  transform: translateX(140%);
}

.btn-primary:hover .icon {
  transform: translate(2px, -2px);
}

.btn-outline {
  background: transparent;
  border-color: var(--line-2);
  color: var(--text);
}

.btn-outline:hover {
  background: var(--gold-glow);
  border-color: var(--gold);
  transform: translateY(-3px);
}

.btn-sm {
  min-height: 46px;
  padding: 0 20px;
  font-size: 0.84rem;
}

.icon-btn {
  position: relative;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--surface);
  color: var(--text-soft);
  transition: border-color 0.3s ease, color 0.3s ease, background 0.3s ease, transform 0.3s ease;
}

.icon-btn .icon {
  font-size: 18px;
}

.icon-btn:hover {
  border-color: var(--gold);
  color: var(--gold);
  transform: translateY(-2px);
}

/* ----------------------------- Preloader -------------------------------- */
.preloader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  background: #07080a;
  transition: opacity 0.7s ease, visibility 0.7s ease;
}

.preloader.loaded {
  opacity: 0;
  visibility: hidden;
}

.preloader-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
}

.preloader-mark {
  width: 78px;
  height: 78px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(214, 180, 137, 0.4);
  border-radius: 50%;
  font-family: var(--font-head);
  font-size: 32px;
  font-weight: 700;
  color: #d6b489;
  background: radial-gradient(circle at 30% 20%, rgba(214, 180, 137, 0.18), transparent 70%);
  animation: preloaderPulse 1.8s ease-in-out infinite;
}

.preloader-bar {
  width: 150px;
  height: 2px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  overflow: hidden;
}

.preloader-bar span {
  display: block;
  width: 0;
  height: 100%;
  background: #d6b489;
  animation: preloaderBar 1.25s var(--ease) forwards;
}

.preloader p {
  font-family: var(--font-mono);
  font-size: 0.58rem;
  letter-spacing: 0.3em;
  color: rgba(244, 240, 232, 0.55);
}

.preloader p span {
  color: #d6b489;
}

/* ------------------------------ Header ---------------------------------- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 120;
  transition: background 0.4s ease, border-color 0.4s ease, backdrop-filter 0.4s ease;
  border-bottom: 1px solid transparent;
}

.site-header.is-scrolled {
  background: rgba(7, 8, 10, 0.72);
  border-bottom-color: var(--line);
  backdrop-filter: blur(22px);
  -webkit-backdrop-filter: blur(22px);
}

html[data-theme="light"] .site-header.is-scrolled {
  background: rgba(246, 242, 234, 0.8);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  flex-shrink: 0;
}

.brand-mark {
  position: relative;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line-2);
  border-radius: 50%;
  font-family: var(--font-head);
  font-size: 19px;
  font-weight: 700;
  color: var(--gold);
  background: radial-gradient(circle at 32% 22%, var(--gold-glow), transparent 70%);
  transition: border-color 0.35s ease, transform 0.5s var(--ease), box-shadow 0.35s ease;
}

.brand-mark::after {
  content: "";
  position: absolute;
  inset: 4px;
  border-radius: 50%;
  border: 1px dashed rgba(214, 180, 137, 0.24);
}

.brand:hover .brand-mark {
  border-color: var(--gold);
  transform: rotate(-8deg);
  box-shadow: 0 0 22px -4px var(--gold-glow);
}

.brand-text strong {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.45;
  letter-spacing: -0.01em;
}

.brand-text small {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.52rem;
  letter-spacing: 0.18em;
  color: var(--muted);
  line-height: 1.4;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(14px, 2.2vw, 32px);
}

.nav-links a {
  position: relative;
  padding: 7px 0;
  font-size: 0.86rem;
  color: var(--muted);
  transition: color 0.3s ease;
}

.nav-links a::after {
  content: "";
  position: absolute;
  bottom: 0;
  inset-inline-start: 0;
  width: 0;
  height: 1px;
  background: var(--gold);
  transition: width 0.4s var(--ease);
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text);
}

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

.header-actions {
  display: flex;
  align-items: center;
  gap: 9px;
  flex-shrink: 0;
}

.theme-toggle .icon-moon {
  display: none;
}

.theme-toggle .icon-sun {
  display: block;
}

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

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

.menu-toggle {
  display: none;
}

.menu-toggle .icon-close {
  display: none;
}

.menu-toggle[aria-expanded="true"] .icon-open {
  display: none;
}

.menu-toggle[aria-expanded="true"] .icon-close {
  display: block;
}

/* --------------------------- Mobile menu -------------------------------- */
.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 110;
  padding: calc(var(--header-h) + 24px) 24px 32px;
  background:
    radial-gradient(ellipse 70% 50% at 70% 0%, rgba(214, 180, 137, 0.08), transparent 70%),
    var(--bg);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.45s ease, visibility 0.45s ease;
  overflow-y: auto;
}

.mobile-menu.open {
  opacity: 1;
  visibility: visible;
}

.mobile-menu-inner {
  max-width: 560px;
  margin-inline: auto;
  display: flex;
  flex-direction: column;
  min-height: 100%;
}

.mobile-kicker {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.25em;
  color: var(--gold);
  margin-bottom: 18px;
}

.mobile-menu nav {
  display: flex;
  flex-direction: column;
}

.mobile-menu nav a {
  display: flex;
  align-items: baseline;
  gap: 14px;
  padding: 15px 0;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-head);
  font-size: clamp(1.7rem, 7vw, 2.5rem);
  font-weight: 500;
  line-height: 1.4;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s var(--ease), color 0.3s ease;
}

.mobile-menu nav a span {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--gold);
}

.mobile-menu nav a:hover {
  color: var(--gold);
}

.mobile-menu.open nav a {
  opacity: 1;
  transform: none;
}

.mobile-menu.open nav a:nth-child(1) { transition-delay: 0.06s; }
.mobile-menu.open nav a:nth-child(2) { transition-delay: 0.1s; }
.mobile-menu.open nav a:nth-child(3) { transition-delay: 0.14s; }
.mobile-menu.open nav a:nth-child(4) { transition-delay: 0.18s; }
.mobile-menu.open nav a:nth-child(5) { transition-delay: 0.22s; }
.mobile-menu.open nav a:nth-child(6) { transition-delay: 0.26s; }

.mobile-menu-foot {
  margin-top: auto;
  padding-top: 32px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.mobile-menu-foot .btn {
  width: 100%;
}

.social-row {
  display: flex;
  align-items: center;
  gap: 9px;
}

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

.social-row a .icon {
  font-size: 17px;
}

.social-row a:hover {
  color: var(--gold);
  border-color: var(--gold);
  background: var(--gold-glow);
  transform: translateY(-2px);
}

/* ---------------------- Scroll progress & cursor ------------------------ */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  z-index: 130;
  background: transparent;
  pointer-events: none;
}

.scroll-progress span {
  display: block;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, var(--gold-2), var(--gold-3), var(--gold));
  transform: scaleX(0);
  transform-origin: right center;
  transition: transform 0.1s linear;
}

.cursor-glow {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 1;
  width: 520px;
  height: 520px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(214, 180, 137, 0.1) 0%, transparent 66%);
  transform: translate(-50%, -50%);
  pointer-events: none;
  opacity: 0;
  mix-blend-mode: screen;
  transition: opacity 0.5s ease;
}

.cursor-glow.on {
  opacity: 1;
}

/* ----------------------------- Reveal ----------------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition:
    opacity 0.9s var(--ease),
    transform 0.9s var(--ease);
  transition-delay: var(--d, 0s);
}

.reveal.in {
  opacity: 1;
  transform: none;
}

/* ---------------------------- Keyframes --------------------------------- */
@keyframes shimmerText {
  0%, 100% { background-position: 0% center; }
  50% { background-position: 100% center; }
}

@keyframes preloaderBar {
  to { width: 100%; }
}

@keyframes preloaderPulse {
  0%, 100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(214, 180, 137, 0.18); }
  50% { transform: scale(1.04); box-shadow: 0 0 40px 4px rgba(214, 180, 137, 0.12); }
}

/* ------------------------------- Hero ----------------------------------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding: calc(var(--header-h) + 56px) 0 88px;
  overflow: clip;
}

.hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.grid-lines {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, var(--line) 1px, transparent 1px),
    linear-gradient(to bottom, var(--line) 1px, transparent 1px);
  background-size: 72px 72px;
  opacity: 0.42;
  mask-image: radial-gradient(ellipse 70% 65% at 55% 35%, #000 20%, transparent 78%);
  -webkit-mask-image: radial-gradient(ellipse 70% 65% at 55% 35%, #000 20%, transparent 78%);
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.55;
  animation: orbFloat 18s ease-in-out infinite alternate;
}

.orb-1 {
  width: 480px;
  height: 480px;
  top: -180px;
  inset-inline-end: 4%;
  background: radial-gradient(circle, rgba(214, 180, 137, 0.23), transparent 68%);
}

.orb-2 {
  width: 420px;
  height: 420px;
  bottom: -200px;
  inset-inline-start: 8%;
  background: radial-gradient(circle, rgba(126, 214, 176, 0.1), transparent 68%);
  animation-delay: -7s;
}

.orb-3 {
  width: 260px;
  height: 260px;
  top: 38%;
  inset-inline-start: 42%;
  background: radial-gradient(circle, rgba(214, 180, 137, 0.12), transparent 70%);
  animation-delay: -12s;
}

.hero-inner {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1.06fr 0.94fr;
  align-items: center;
  gap: clamp(40px, 5vw, 76px);
}

.hero-copy {
  position: relative;
  z-index: 2;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 7px 13px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text-soft);
  font-size: 0.74rem;
  line-height: 1.4;
  margin-bottom: 24px;
}

.status-dot {
  position: relative;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
  flex-shrink: 0;
}

.status-dot::after {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 1px solid var(--green);
  animation: ping 2.2s ease-out infinite;
}

.hero-title {
  font-family: var(--font-head);
  font-size: clamp(3.4rem, 7.1vw, 6.5rem);
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: -0.035em;
  text-wrap: balance;
}

.title-line {
  display: block;
}

.hero-title .accent {
  background: var(--grad-text);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
  animation: shimmerText 9s ease-in-out infinite;
  padding-bottom: 0.06em;
}

.title-dot {
  -webkit-text-fill-color: var(--gold);
  color: var(--gold);
}

.hero-tagline {
  margin-top: 26px;
  font-size: clamp(0.98rem, 1.65vw, 1.24rem);
  font-weight: 500;
  color: var(--text-soft);
  letter-spacing: 0.005em;
}

.hero-tagline .sep {
  color: var(--gold);
  margin-inline: 4px;
  font-weight: 400;
}

.hero-desc {
  max-width: 570px;
  margin-top: 16px;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.95;
}

.hero-desc strong {
  color: var(--text-soft);
  font-weight: 500;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}

.cv-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 20px;
  padding-bottom: 4px;
  border-bottom: 1px dashed var(--line-2);
  color: var(--muted);
  font-size: 0.79rem;
  transition: color 0.3s ease, border-color 0.3s ease;
}

.cv-link .icon {
  font-size: 15px;
  color: var(--gold);
}

.cv-link span {
  font-family: var(--font-mono);
  font-size: 0.55rem;
  letter-spacing: 0.12em;
  color: var(--gold);
  border: 1px solid var(--line-2);
  border-radius: 4px;
  padding: 1px 5px;
}

.cv-link:hover {
  color: var(--gold);
  border-color: var(--gold);
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(4, auto);
  justify-content: start;
  gap: clamp(22px, 3.2vw, 46px);
  margin-top: 44px;
  padding-top: 26px;
  border-top: 1px solid var(--line);
}

.stat strong {
  display: flex;
  align-items: baseline;
  gap: 2px;
  font-family: var(--font-head);
  font-size: 1.72rem;
  font-weight: 600;
  line-height: 1;
  color: var(--text);
}

.stat sup {
  font-size: 0.72rem;
  color: var(--gold);
  top: -0.4em;
  position: relative;
}

.stat > span {
  display: block;
  margin-top: 7px;
  font-size: 0.68rem;
  color: var(--muted);
  line-height: 1.5;
}

/* --------------------------- Hero visual -------------------------------- */
.hero-visual {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 590px;
  perspective: 1200px;
}

.visual-glow {
  position: absolute;
  width: 430px;
  height: 430px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(214, 180, 137, 0.2), transparent 65%);
  filter: blur(50px);
  animation: breathe 7s ease-in-out infinite;
}

.orbit {
  position: absolute;
  width: 505px;
  height: 505px;
  border: 1px solid var(--line);
  border-radius: 50%;
  animation: spin 26s linear infinite;
}

.orbit span {
  position: absolute;
  top: -4px;
  left: 50%;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 16px 3px var(--gold-glow);
}

.orbit-a::before {
  content: "";
  position: absolute;
  inset: 34px;
  border: 1px dashed var(--line);
  border-radius: 50%;
}

.orbit-b {
  width: 420px;
  height: 420px;
  border-style: dashed;
  animation-direction: reverse;
  animation-duration: 18s;
  opacity: 0.7;
}

.orbit-b span {
  top: auto;
  bottom: 18%;
  left: 7%;
  width: 5px;
  height: 5px;
  background: var(--green);
  box-shadow: 0 0 12px 2px var(--green-soft);
}

.id-card {
  position: relative;
  z-index: 3;
  width: min(100%, 424px);
  padding: 21px;
  border: 1px solid rgba(214, 180, 137, 0.22);
  border-radius: 28px;
  background:
    linear-gradient(160deg, rgba(24, 27, 34, 0.94), rgba(10, 12, 16, 0.97));
  box-shadow:
    0 45px 100px -32px rgba(0, 0, 0, 0.9),
    inset 0 1px 0 rgba(255, 255, 255, 0.055);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  transform-style: preserve-3d;
  will-change: transform;
  transition: transform 0.18s ease-out, border-color 0.4s ease, box-shadow 0.4s ease;
}

.id-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 16%;
  right: 16%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  opacity: 0.75;
}

.id-card:hover {
  border-color: rgba(214, 180, 137, 0.42);
  box-shadow:
    0 50px 120px -30px rgba(0, 0, 0, 0.95),
    0 0 60px -20px var(--gold-glow),
    inset 0 1px 0 rgba(255, 255, 255, 0.07);
}

.id-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.id-brand {
  display: flex;
  align-items: center;
  gap: 9px;
}

.id-mono {
  width: 33px;
  height: 33px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(214, 180, 137, 0.35);
  border-radius: 50%;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--gold);
  background: rgba(214, 180, 137, 0.08);
}

.id-brand strong {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  line-height: 1.45;
}

.id-brand small {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.45rem;
  letter-spacing: 0.14em;
  color: var(--muted);
  line-height: 1.4;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 8px;
  border: 1px solid rgba(126, 214, 176, 0.3);
  border-radius: 999px;
  background: rgba(126, 214, 176, 0.07);
  font-family: var(--font-mono);
  font-size: 0.46rem;
  letter-spacing: 0.14em;
  color: var(--green);
  white-space: nowrap;
}

.status-pill i {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--green);
  animation: blink 2s ease-in-out infinite;
}

.id-main {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 24px;
}

.avatar-wrap {
  position: relative;
  flex-shrink: 0;
  width: 86px;
  height: 86px;
}

.avatar-ring {
  position: absolute;
  inset: -6px;
  border: 1px dashed rgba(214, 180, 137, 0.34);
  border-radius: 50%;
  animation: spin 18s linear infinite;
}

.avatar {
  width: 86px;
  height: 86px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(214, 180, 137, 0.42);
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 25%, rgba(240, 217, 184, 0.3), transparent 58%),
    linear-gradient(145deg, #2a2117, #0f1115);
  font-family: var(--font-head);
  font-size: 36px;
  font-weight: 600;
  color: var(--gold-3);
  box-shadow: inset 0 0 24px rgba(214, 180, 137, 0.12);
}

.avatar-dot {
  position: absolute;
  bottom: 6px;
  right: 10px;
  width: 11px;
  height: 11px;
  border: 2px solid #11141a;
  border-radius: 50%;
  background: var(--green);
}

.id-info h2 {
  font-family: var(--font-head);
  font-size: 1.08rem;
  font-weight: 600;
  line-height: 1.4;
}

.id-info p {
  margin-top: 2px;
  font-family: var(--font-mono);
  font-size: 0.58rem;
  letter-spacing: 0.12em;
  color: var(--gold);
}

.id-location {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 7px;
  font-size: 0.64rem;
  color: var(--muted);
}

.id-location .icon {
  font-size: 12px;
  color: var(--green);
}

.id-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 20px;
}

.id-tags span {
  padding: 4px 7px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.035);
  font-family: var(--font-mono);
  font-size: 0.46rem;
  letter-spacing: 0.09em;
  color: var(--text-soft);
}

.id-gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 5px;
  margin-top: 16px;
  border-radius: 12px;
  overflow: hidden;
}

.mini-shot {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #0a0c10;
}

.mini-shot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.8) brightness(0.82);
  transition: transform 0.7s var(--ease), filter 0.5s ease;
}

.mini-shot span {
  position: absolute;
  bottom: 5px;
  inset-inline-start: 5px;
  padding: 1px 4px;
  border-radius: 3px;
  background: rgba(3, 4, 6, 0.64);
  backdrop-filter: blur(4px);
  font-family: var(--font-mono);
  font-size: 0.38rem;
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.85);
}

.mini-shot:hover img {
  transform: scale(1.12);
  filter: saturate(1) brightness(1);
}

.mini-shot:focus-visible {
  outline-offset: -2px;
}

.id-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 16px;
  padding-top: 13px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.id-code {
  font-family: var(--font-mono);
  font-size: 0.45rem;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.id-arrow {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  color: var(--gold);
  transition: background 0.3s ease, border-color 0.3s ease, transform 0.3s ease;
}

.id-arrow .icon {
  font-size: 14px;
}

.id-arrow:hover {
  background: var(--gold-glow);
  border-color: var(--gold);
  transform: rotate(-45deg);
}

.float-chip {
  position: absolute;
  z-index: 4;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 13px;
  border: 1px solid var(--line-2);
  border-radius: 14px;
  background: rgba(14, 16, 21, 0.82);
  box-shadow: 0 18px 40px -20px rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  animation: floatY 6s ease-in-out infinite;
}

.float-chip strong {
  font-family: var(--font-head);
  font-size: 1.15rem;
  font-weight: 600;
  line-height: 1;
  color: var(--text);
}

.float-chip > span {
  font-size: 0.56rem;
  line-height: 1.2;
  color: var(--muted);
}

.chip-age {
  top: 7%;
  left: -2%;
  animation-delay: -1s;
}

.chip-projects {
  right: -3%;
  bottom: 13%;
  animation-delay: -3s;
}

.chip-security {
  top: 44%;
  right: -5%;
  gap: 7px;
  animation-delay: -4.5s;
}

.chip-security > span:last-child {
  font-family: var(--font-mono);
  font-size: 0.46rem;
  letter-spacing: 0.08em;
  line-height: 1.4;
  color: var(--gold);
}

.chip-icon {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(214, 180, 137, 0.25);
  border-radius: 8px;
  background: var(--gold-glow);
  color: var(--gold);
}

.chip-icon .icon {
  font-size: 14px;
}

.scroll-cue {
  position: absolute;
  bottom: 26px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  z-index: 3;
}

.scroll-cue i {
  position: relative;
  width: 1px;
  height: 42px;
  background: var(--line-2);
  overflow: hidden;
}

.scroll-cue i::after {
  content: "";
  position: absolute;
  top: -50%;
  left: 0;
  width: 100%;
  height: 50%;
  background: var(--gold);
  animation: scrollLine 2s var(--ease) infinite;
}

/* ----------------------------- Marquee ---------------------------------- */
.marquee {
  position: relative;
  padding: 16px 0;
  border-block: 1px solid var(--line);
  background: var(--bg-soft);
  overflow: hidden;
}

.marquee-track {
  display: flex;
  align-items: center;
  gap: 30px;
  width: max-content;
  animation: marquee 34s linear infinite;
}

.marquee:hover .marquee-track {
  animation-play-state: paused;
}

.marquee-track span {
  font-family: var(--font-head);
  font-size: 0.92rem;
  font-weight: 400;
  color: var(--text-soft);
  white-space: nowrap;
}

.marquee-track i {
  font-style: normal;
  font-size: 0.62rem;
  color: var(--gold);
}

/* ---------------------------- Sections ---------------------------------- */
.section {
  position: relative;
  padding: clamp(80px, 9vw, 128px) 0;
  scroll-margin-top: 80px;
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 40px;
  margin-bottom: clamp(36px, 5vw, 64px);
}

.section-heading {
  display: flex;
  align-items: flex-start;
  gap: 18px;
}

.section-num {
  flex-shrink: 0;
  margin-top: 9px;
  padding: 6px 9px;
  border: 1px solid var(--line-2);
  border-radius: 7px;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  line-height: 1;
  color: var(--gold);
}

.kicker {
  font-family: var(--font-mono);
  font-size: 0.63rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 9px;
}

.section h2 {
  font-family: var(--font-head);
  font-size: clamp(2rem, 4.1vw, 3.5rem);
  font-weight: 600;
  line-height: 1.28;
  letter-spacing: -0.025em;
  text-wrap: balance;
}

.section-desc {
  max-width: 340px;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.9;
  text-align: start;
  padding-bottom: 4px;
}

/* ------------------------------ About ----------------------------------- */
.about-grid {
  display: grid;
  grid-template-columns: 1.06fr 0.94fr;
  gap: clamp(36px, 5.2vw, 76px);
  align-items: start;
}

.about-lead {
  font-family: var(--font-head);
  font-size: clamp(1.45rem, 2.5vw, 2rem);
  font-weight: 500;
  line-height: 1.6;
  color: var(--text);
}

.about-lead span {
  background: var(--grad-text);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}

.about-text {
  max-width: 580px;
  margin-top: 20px;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 2;
}

.about-info {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 26px;
  margin-top: 32px;
  border-top: 1px solid var(--line);
}

.info-item {
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}

.info-item span {
  display: block;
  font-size: 0.65rem;
  color: var(--muted);
  margin-bottom: 3px;
}

.info-item strong {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-soft);
}

.info-item strong.available {
  color: var(--green);
}

.info-item strong.available i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--green);
  animation: blink 2s ease-in-out infinite;
}

.about-quote {
  display: flex;
  align-items: flex-start;
  gap: 13px;
  margin-top: 28px;
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-inline-start: 2px solid var(--gold);
  border-radius: 12px;
  background: var(--surface);
}

.about-quote .icon {
  font-size: 22px;
  color: var(--gold);
  opacity: 0.65;
  margin-top: 2px;
}

.about-quote p {
  font-size: 0.9rem;
  color: var(--text-soft);
  line-height: 1.8;
}

.about-visual {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.terminal {
  direction: ltr;
  text-align: left;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 18px;
  background: #0a0c0f;
  overflow: hidden;
  box-shadow: 0 34px 80px -36px rgba(0, 0, 0, 0.9);
  font-family: var(--font-mono);
}

.terminal-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  height: 42px;
  padding: 0 15px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  background: rgba(255, 255, 255, 0.022);
}

.terminal-dots {
  display: flex;
  gap: 5px;
}

.terminal-dots i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #3a3f47;
}

.terminal-dots i:first-child { background: #5b4640; }
.terminal-dots i:nth-child(2) { background: #5d543c; }
.terminal-dots i:nth-child(3) { background: #3f5548; }

.terminal-bar > span {
  font-size: 0.55rem;
  letter-spacing: 0.08em;
  color: #7d828c;
}

.terminal-bar > .icon {
  font-size: 13px;
  color: #7d828c;
}

.terminal-body {
  padding: 18px 20px 22px;
  font-size: 0.74rem;
  line-height: 1.95;
  color: #c9d1d9;
  overflow-x: auto;
}

.terminal-body p {
  white-space: nowrap;
}

.terminal-body .out {
  color: #8b949e;
}

.terminal-body pre.out {
  margin: 0;
  white-space: pre;
  font-family: var(--font-mono);
}

.prompt {
  color: #d6b489;
  font-weight: 600;
}

.cmd {
  color: #f0f6fc;
}

.key {
  color: #7ee0c2;
}

.str {
  color: #e3b778;
}

.num {
  color: #9ecbff;
}

.terminal-body .success {
  color: #7ee0b0;
}

.terminal-cursor {
  display: flex;
  align-items: center;
  gap: 7px;
}

.cursor-blink {
  display: inline-block;
  width: 7px;
  height: 14px;
  background: #d6b489;
  animation: blink 1.1s step-end infinite;
}

.education-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
  transition: transform 0.4s var(--ease), border-color 0.4s ease;
}

.education-card:hover {
  transform: translateY(-3px);
  border-color: var(--gold);
}

.edu-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  border: 1px solid var(--line-2);
  border-radius: 12px;
  background: var(--gold-glow);
  color: var(--gold);
}

.edu-icon .icon {
  font-size: 20px;
}

.edu-label {
  font-family: var(--font-mono);
  font-size: 0.5rem;
  letter-spacing: 0.15em;
  color: var(--gold);
}

.education-card h3 {
  margin-top: 2px;
  font-family: var(--font-head);
  font-size: 0.88rem;
  font-weight: 500;
  line-height: 1.5;
}

.education-card p {
  font-size: 0.66rem;
  color: var(--muted);
}

.edu-year {
  margin-inline-start: auto;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  color: var(--gold);
}

.principles {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-top: 56px;
}

.principle {
  position: relative;
  padding: 25px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface);
  overflow: hidden;
  transition: transform 0.45s var(--ease), border-color 0.4s ease, background 0.4s ease;
}

.principle::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 70% at 50% 0%, var(--gold-glow), transparent 70%);
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.principle:hover {
  transform: translateY(-4px);
  border-color: var(--line-2);
}

.principle:hover::after {
  opacity: 1;
}

.principle-num {
  position: absolute;
  top: 20px;
  inset-inline-end: 22px;
  font-family: var(--font-mono);
  font-size: 0.58rem;
  color: var(--muted);
}

.principle-icon {
  position: relative;
  z-index: 1;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line-2);
  border-radius: 11px;
  background: var(--gold-glow);
  color: var(--gold);
}

.principle-icon .icon {
  font-size: 19px;
}

.principle h3 {
  position: relative;
  z-index: 1;
  margin-top: 17px;
  font-family: var(--font-head);
  font-size: 1rem;
  font-weight: 500;
}

.principle p {
  position: relative;
  z-index: 1;
  margin-top: 7px;
  font-size: 0.79rem;
  line-height: 1.85;
  color: var(--muted);
}

/* ---------------------------- Keyframes 2 ------------------------------- */
@keyframes orbFloat {
  0% { transform: translate3d(0, 0, 0) scale(1); }
  100% { transform: translate3d(26px, -32px, 0) scale(1.08); }
}

@keyframes ping {
  0% { transform: scale(0.7); opacity: 0.9; }
  80%, 100% { transform: scale(1.9); opacity: 0; }
}

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

@keyframes breathe {
  0%, 100% { transform: scale(0.94); opacity: 0.7; }
  50% { transform: scale(1.06); opacity: 1; }
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

@keyframes floatY {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-11px); }
}

@keyframes scrollLine {
  0% { top: -50%; }
  100% { top: 110%; }
}

@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ----------------------------- Projects --------------------------------- */
.projects {
  background:
    radial-gradient(ellipse 60% 40% at 78% 10%, rgba(214, 180, 137, 0.04), transparent 65%),
    var(--bg-soft);
  border-block: 1px solid var(--line);
}

.projects-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 26px;
}

.filters {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
}

.filter-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.4;
  transition: color 0.3s ease, border-color 0.3s ease, background 0.3s ease, transform 0.3s ease;
}

.filter-btn .count {
  font-family: var(--font-mono);
  font-size: 0.55rem;
  padding: 1px 5px;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--muted);
  transition: background 0.3s ease, color 0.3s ease;
}

.filter-btn:hover {
  color: var(--text);
  border-color: var(--line-2);
  transform: translateY(-1px);
}

.filter-btn.active {
  background: var(--gold);
  border-color: var(--gold);
  color: #1b1309;
}

.filter-btn.active .count {
  background: rgba(0, 0, 0, 0.16);
  color: #1b1309;
}

.projects-count {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  color: var(--muted);
  white-space: nowrap;
}

.projects-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
}

.project-card {
  position: relative;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--surface);
  overflow: hidden;
  transition:
    transform 0.5s var(--ease),
    border-color 0.4s ease,
    box-shadow 0.5s ease;
}

.project-card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background: radial-gradient(500px circle at var(--px, 50%) var(--py, 0%), rgba(214, 180, 137, 0.09), transparent 55%);
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.project-card:hover {
  transform: translateY(-6px);
  border-color: rgba(214, 180, 137, 0.34);
  box-shadow: 0 34px 80px -38px rgba(0, 0, 0, 0.75);
}

.project-card:hover::before {
  opacity: 1;
}

.project-card.is-filtered {
  display: none;
}

.project-card.entering {
  animation: cardIn 0.55s var(--ease) both;
}

.project-media {
  position: relative;
  z-index: 1;
  margin: 10px 10px 0;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: var(--surface-2);
  overflow: hidden;
}

.browser-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 33px;
  padding: 0 11px;
  border-bottom: 1px solid var(--line);
  background: var(--surface-2);
}

.browser-dots {
  display: flex;
  gap: 4px;
  flex-shrink: 0;
}

.browser-dots i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--line-2);
}

.browser-url {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  height: 19px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--bg);
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 0.42rem;
  letter-spacing: 0.03em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.browser-url .icon {
  font-size: 8px;
  color: var(--green);
}

.browser-bar > .icon {
  font-size: 11px;
  color: var(--muted);
  flex-shrink: 0;
}

.project-image {
  position: relative;
  aspect-ratio: 16 / 9.4;
  overflow: hidden;
}

.project-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  transition: transform 0.9s var(--ease), filter 0.6s ease;
}

.project-card:hover .project-image img {
  transform: scale(1.045);
}

.project-image::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(4, 5, 7, 0.36), transparent 45%);
  pointer-events: none;
}

.project-index {
  position: absolute;
  top: 10px;
  inset-inline-start: 10px;
  z-index: 2;
  padding: 3px 6px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 4px;
  background: rgba(4, 5, 7, 0.55);
  backdrop-filter: blur(6px);
  font-family: var(--font-mono);
  font-size: 0.46rem;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.86);
}

.project-open {
  position: absolute;
  top: 9px;
  inset-inline-end: 9px;
  z-index: 2;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 50%;
  background: rgba(4, 5, 7, 0.5);
  backdrop-filter: blur(6px);
  color: #fff;
  opacity: 0;
  transform: translateY(-4px);
  transition: opacity 0.35s ease, transform 0.35s var(--ease), background 0.3s ease;
}

.project-open .icon {
  font-size: 12px;
}

.project-card:hover .project-open {
  opacity: 1;
  transform: none;
}

.project-open:hover {
  background: var(--gold);
  color: #1b1309;
  border-color: var(--gold);
}

.project-body {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 20px 23px 22px;
}

.project-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.project-category {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.66rem;
  color: var(--gold);
}

.project-category::before {
  content: "";
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--gold);
}

.project-year {
  font-family: var(--font-mono);
  font-size: 0.55rem;
  color: var(--muted);
}

.project-body h3 {
  margin-top: 8px;
  font-family: var(--font-head);
  font-size: clamp(1.08rem, 1.5vw, 1.3rem);
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: -0.01em;
}

.project-body > p {
  margin-top: 6px;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.85;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 14px;
}

.project-tags span {
  padding: 3px 7px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--bg-soft);
  font-family: var(--font-mono);
  font-size: 0.47rem;
  letter-spacing: 0.03em;
  color: var(--muted);
  transition: border-color 0.3s ease, color 0.3s ease;
}

.project-card:hover .project-tags span {
  border-color: var(--line-2);
  color: var(--text-soft);
}

.project-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 18px;
  padding-top: 15px;
  border-top: 1px solid var(--line);
}

.project-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0;
  color: var(--text-soft);
  font-family: var(--font-body);
  font-size: 0.76rem;
  font-weight: 500;
  transition: color 0.3s ease, gap 0.3s ease;
}

.project-link .icon {
  font-size: 14px;
  transition: transform 0.35s var(--ease);
}

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

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

.project-link.primary:hover .icon {
  transform: translate(2px, -2px);
}

.project-link:not(.primary):hover .icon {
  transform: translateX(-3px);
}

.project-card.entering {
  animation-fill-mode: both;
}

.projects-cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 26px;
  margin-top: 46px;
  padding: 26px 30px;
  border: 1px dashed var(--line-2);
  border-radius: 18px;
  background: var(--surface);
}

.projects-cta h3 {
  margin-top: 4px;
  font-family: var(--font-head);
  font-size: 1.14rem;
  font-weight: 500;
}

/* ------------------------------ Skills ---------------------------------- */
.skills-layout {
  display: grid;
  grid-template-columns: 1.06fr 0.94fr;
  gap: clamp(36px, 5vw, 70px);
  align-items: start;
}

.skill {
  margin-bottom: 18px;
}

.skill-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.skill-head > span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.84rem;
  color: var(--text-soft);
}

.skill-head .icon {
  font-size: 15px;
  color: var(--gold);
}

.skill-head em {
  font-family: var(--font-mono);
  font-style: normal;
  font-size: 0.64rem;
  color: var(--gold);
}

.skill-track {
  position: relative;
  height: 6px;
  margin-top: 8px;
  border-radius: 999px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  overflow: hidden;
}

.skill-track > span {
  position: relative;
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--gold-2), var(--gold), var(--gold-3));
  transition: width 1.4s var(--ease);
  overflow: hidden;
}

.skill-track > span::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.55), transparent);
  transform: translateX(-100%);
  animation: barShine 3.4s ease-in-out infinite;
}

.skills-bars.in .skill-track > span {
  width: var(--level);
}

.skills-side {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.toolkit {
  padding: 23px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface);
}

.toolkit h3 {
  margin-top: 3px;
  font-family: var(--font-head);
  font-size: 1.08rem;
  font-weight: 500;
}

.tool-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
  margin-top: 16px;
}

.tool {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 9px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--bg-soft);
  font-size: 0.73rem;
  color: var(--text-soft);
  transition: border-color 0.3s ease, transform 0.3s ease, background 0.3s ease;
}

.tool i {
  width: 29px;
  height: 23px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--gold-glow);
  font-family: var(--font-mono);
  font-style: normal;
  font-size: 0.48rem;
  letter-spacing: 0.02em;
  color: var(--gold);
}

.tool:hover {
  border-color: var(--gold);
  transform: translateX(-2px);
}

.skill-focus {
  padding: 23px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background:
    radial-gradient(ellipse 80% 100% at 100% 0%, var(--gold-glow), transparent 70%),
    var(--surface);
}

.skill-focus-head {
  display: flex;
  align-items: center;
  gap: 12px;
}

.icon-box {
  width: 41px;
  height: 41px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  border: 1px solid var(--line-2);
  border-radius: 11px;
  background: var(--gold-glow);
  color: var(--gold);
}

.icon-box .icon {
  font-size: 19px;
}

.skill-focus h3 {
  font-family: var(--font-head);
  font-size: 1rem;
  font-weight: 500;
}

.skill-focus p {
  margin-top: 12px;
  color: var(--muted);
  font-size: 0.79rem;
  line-height: 1.9;
}

.focus-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 14px;
}

.focus-tags span {
  padding: 3px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.5rem;
  color: var(--muted);
}

.learning-note {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 14px 16px;
  border: 1px dashed var(--line-2);
  border-radius: 13px;
}

.learning-note .pulse {
  margin-top: 7px;
}

.learning-note p {
  font-size: 0.76rem;
  line-height: 1.8;
  color: var(--muted);
}

.learning-note strong {
  color: var(--text-soft);
  font-weight: 500;
}

.pulse {
  position: relative;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
  flex-shrink: 0;
}

.pulse::after {
  content: "";
  position: absolute;
  inset: -4px;
  border: 1px solid var(--green);
  border-radius: 50%;
  animation: ping 2.4s ease-out infinite;
}

/* ------------------------------ Journey --------------------------------- */
.journey {
  background:
    radial-gradient(ellipse 50% 40% at 15% 20%, rgba(126, 214, 176, 0.035), transparent 65%),
    var(--bg-soft);
  border-block: 1px solid var(--line);
}

.journey-grid {
  display: grid;
  grid-template-columns: 1.12fr 0.88fr;
  gap: clamp(36px, 5vw, 70px);
  align-items: start;
}

.timeline {
  position: relative;
  padding-inline-start: 34px;
  border-inline-start: 1px solid var(--line-2);
  margin-inline-start: 6px;
}

.timeline-item {
  position: relative;
  padding-bottom: 18px;
}

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

.timeline-dot {
  position: absolute;
  top: 7px;
  inset-inline-start: -40px;
  width: 11px;
  height: 11px;
  border: 2px solid var(--bg-soft);
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 0 1px var(--gold-2), 0 0 15px 1px var(--gold-glow);
}

.timeline-year {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.58rem;
  letter-spacing: 0.1em;
  color: var(--gold);
}

.timeline-card {
  position: relative;
  margin-top: 8px;
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  transition: transform 0.4s var(--ease), border-color 0.4s ease;
}

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

.timeline-tag {
  font-family: var(--font-mono);
  font-size: 0.46rem;
  letter-spacing: 0.16em;
  color: var(--muted);
}

.timeline-card h3 {
  margin-top: 3px;
  font-family: var(--font-head);
  font-size: 0.98rem;
  font-weight: 500;
  line-height: 1.55;
}

.timeline-card p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.77rem;
  line-height: 1.85;
}

.timeline-meta {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 10px;
  font-size: 0.62rem;
  color: var(--gold);
}

.timeline-meta .icon {
  font-size: 12px;
}

.timeline-item.next .timeline-card {
  border-style: dashed;
  background:
    radial-gradient(ellipse 90% 100% at 100% 0%, var(--gold-glow), transparent 70%),
    var(--surface);
}

.timeline-item.next .timeline-dot {
  background: var(--green);
  box-shadow: 0 0 0 1px var(--green), 0 0 15px 1px var(--green-soft);
}

.journey-aside {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.quote-card {
  position: relative;
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface);
  overflow: hidden;
}

.quote-mark {
  font-size: 29px;
  color: var(--gold);
  opacity: 0.55;
}

.quote-card p {
  margin-top: 12px;
  font-family: var(--font-head);
  font-size: 1.05rem;
  font-weight: 400;
  line-height: 1.8;
  color: var(--text-soft);
}

.quote-card > span {
  display: block;
  margin-top: 12px;
  font-size: 0.68rem;
  color: var(--muted);
}

.quote-line {
  width: 44px;
  height: 1px;
  margin-top: 16px;
  background: linear-gradient(90deg, var(--gold), transparent);
}

.journey-cta {
  padding: 26px;
  border: 1px solid rgba(214, 180, 137, 0.24);
  border-radius: 18px;
  background:
    radial-gradient(ellipse 80% 100% at 100% 0%, var(--gold-glow), transparent 65%),
    var(--surface);
}

.journey-cta h3 {
  margin-top: 4px;
  font-family: var(--font-head);
  font-size: 1.16rem;
  font-weight: 500;
  line-height: 1.6;
}

.journey-cta p {
  margin-top: 7px;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.85;
}

.journey-cta .btn {
  margin-top: 18px;
  width: 100%;
}

/* ---------------------------- Keyframes 3 ------------------------------- */
@keyframes cardIn {
  from { opacity: 0; transform: translateY(18px) scale(0.985); }
  to { opacity: 1; transform: none; }
}

@keyframes barShine {
  0%, 55% { transform: translateX(-100%); }
  85%, 100% { transform: translateX(160%); }
}

/* ------------------------------ Contact --------------------------------- */
.contact {
  position: relative;
  overflow: clip;
}

.contact-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.orb-contact-1 {
  width: 500px;
  height: 500px;
  top: -120px;
  inset-inline-start: -120px;
  background: radial-gradient(circle, rgba(214, 180, 137, 0.12), transparent 68%);
  filter: blur(100px);
  opacity: 0.8;
}

.orb-contact-2 {
  width: 440px;
  height: 440px;
  bottom: -180px;
  inset-inline-end: -80px;
  background: radial-gradient(circle, rgba(126, 214, 176, 0.07), transparent 68%);
  filter: blur(100px);
  opacity: 0.8;
}

.contact-head {
  position: relative;
  z-index: 1;
}

.contact-shell {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.24fr 0.76fr;
  gap: clamp(28px, 4vw, 54px);
  padding: clamp(22px, 3.6vw, 42px);
  border: 1px solid var(--line);
  border-radius: 28px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.038), rgba(255, 255, 255, 0.012));
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: 0 40px 100px -50px rgba(0, 0, 0, 0.7);
  overflow: hidden;
}

.contact-shell::before {
  content: "";
  position: absolute;
  top: 0;
  inset-inline-start: 12%;
  width: 30%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  opacity: 0.6;
}

html[data-theme="light"] .contact-shell {
  background: rgba(255, 253, 249, 0.72);
}

.contact-form-head h3 {
  font-family: var(--font-head);
  font-size: 1.35rem;
  font-weight: 500;
}

.contact-form-head p {
  margin-top: 4px;
  font-size: 0.78rem;
  color: var(--muted);
}

.contact-form {
  margin-top: 22px;
}

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

.field {
  margin-bottom: 13px;
}

.field label {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-bottom: 6px;
  font-size: 0.72rem;
  color: var(--text-soft);
}

.field label span {
  color: var(--gold);
}

.field input,
.field textarea,
.field select {
  width: 100%;
  min-height: 48px;
  padding: 12px 13px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: var(--bg-soft);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 0.82rem;
  transition: border-color 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
}

.field input::placeholder,
.field textarea::placeholder {
  color: var(--muted);
  opacity: 0.72;
}

.field input:focus,
.field textarea:focus,
.field select:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px var(--gold-glow);
}

.field textarea {
  min-height: 118px;
  resize: vertical;
  line-height: 1.8;
}

.field input.invalid,
.field textarea.invalid {
  border-color: var(--danger);
  box-shadow: 0 0 0 3px rgba(240, 142, 132, 0.08);
  animation: fieldShake 0.35s ease;
}

.select-wrap {
  position: relative;
}

.select-wrap select {
  appearance: none;
  -webkit-appearance: none;
  padding-inline-end: 38px;
  cursor: pointer;
}

.select-wrap > .icon {
  position: absolute;
  top: 50%;
  inset-inline-end: 14px;
  transform: translateY(-50%);
  font-size: 14px;
  color: var(--muted);
  pointer-events: none;
}

.form-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 3px;
}

.form-note {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--muted);
  font-size: 0.65rem;
}

.form-note .icon {
  font-size: 12px;
  color: var(--green);
}

.contact-side {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.contact-availability {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 14px 15px;
  margin-bottom: 2px;
  border: 1px solid rgba(126, 214, 176, 0.24);
  border-radius: 13px;
  background: var(--green-soft);
}

.contact-availability strong {
  display: block;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text);
}

.contact-availability div > span {
  display: block;
  font-size: 0.63rem;
  color: var(--muted);
}

.contact-card {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: var(--surface);
  transition: border-color 0.35s ease, transform 0.35s var(--ease), background 0.35s ease;
}

.contact-card:hover {
  border-color: var(--gold);
  background: var(--gold-glow);
  transform: translateX(-3px);
}

.contact-card-main {
  display: flex;
  align-items: center;
  gap: 11px;
  flex: 1;
  min-width: 0;
}

.contact-icon {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  border: 1px solid var(--line-2);
  border-radius: 10px;
  background: var(--gold-glow);
  color: var(--gold);
}

.contact-icon .icon {
  font-size: 17px;
}

.contact-icon.whatsapp {
  color: var(--green);
  background: var(--green-soft);
  border-color: rgba(126, 214, 176, 0.22);
}

.contact-card > div {
  min-width: 0;
}

.contact-card div > span {
  display: block;
  font-size: 0.6rem;
  color: var(--muted);
}

.contact-card div > strong {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.71rem;
  font-weight: 500;
  color: var(--text-soft);
  margin-top: 1px;
  overflow-wrap: anywhere;
}

.contact-arrow {
  margin-inline-start: auto;
  font-size: 13px;
  color: var(--muted);
  flex-shrink: 0;
  transition: color 0.3s ease, transform 0.3s ease;
}

.contact-card:hover .contact-arrow {
  color: var(--gold);
  transform: translate(2px, -2px);
}

.copy-btn {
  margin-inline-start: auto;
  width: 31px;
  height: 31px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  border: 1px solid var(--line-2);
  border-radius: 50%;
  color: var(--muted);
  transition: color 0.3s ease, border-color 0.3s ease, background 0.3s ease;
}

.copy-btn .icon {
  font-size: 13px;
}

.copy-btn:hover {
  color: var(--gold);
  border-color: var(--gold);
  background: var(--gold-glow);
}

.contact-social {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 4px;
  padding-top: 13px;
  border-top: 1px solid var(--line);
}

.contact-social > span {
  font-size: 0.68rem;
  color: var(--muted);
}

/* ------------------------------ Footer ---------------------------------- */
.site-footer {
  position: relative;
  border-top: 1px solid var(--line);
  background: var(--bg);
  overflow: hidden;
}

.site-footer::before {
  content: "";
  position: absolute;
  bottom: -200px;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 300px;
  background: radial-gradient(ellipse, rgba(214, 180, 137, 0.09), transparent 70%);
  filter: blur(60px);
  pointer-events: none;
}

.footer-inner {
  position: relative;
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: clamp(32px, 6vw, 80px);
  padding-top: 52px;
  padding-bottom: 44px;
}

.footer-brand p {
  max-width: 340px;
  margin-top: 16px;
  font-size: 0.78rem;
  line-height: 1.9;
  color: var(--muted);
}

.footer-brand .social-row {
  margin-top: 18px;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.footer-links h3 {
  margin-bottom: 12px;
  font-family: var(--font-head);
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text);
}

.footer-links a {
  display: block;
  padding: 3px 0;
  font-size: 0.73rem;
  color: var(--muted);
  transition: color 0.3s ease, transform 0.3s ease;
}

.footer-links a:hover {
  color: var(--gold);
  transform: translateX(-2px);
}

.footer-location {
  display: block;
  margin-top: 8px;
  font-size: 0.66rem;
  color: var(--muted);
  opacity: 0.8;
}

.footer-bottom {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  padding-top: 18px;
  padding-bottom: 22px;
  border-top: 1px solid var(--line);
}

.footer-bottom p {
  font-size: 0.68rem;
  color: var(--muted);
}

.footer-made span {
  color: var(--gold);
  margin-inline: 3px;
}

.footer-top {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.68rem;
  color: var(--text-soft);
  transition: color 0.3s ease;
}

.footer-top .icon {
  font-size: 12px;
}

.footer-top:hover {
  color: var(--gold);
}

/* ------------------------------- Modal ---------------------------------- */
.modal {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: grid;
  place-items: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease, visibility 0.35s ease;
}

.modal.open {
  opacity: 1;
  visibility: visible;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 4, 6, 0.82);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.modal-panel {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  width: min(100%, 940px);
  max-height: 91vh;
  border: 1px solid var(--line-2);
  border-radius: 22px;
  background: var(--surface);
  box-shadow: 0 60px 140px -50px rgba(0, 0, 0, 0.9);
  overflow: hidden auto;
  transform: translateY(22px) scale(0.985);
  transition: transform 0.45s var(--ease);
}

.modal.open .modal-panel {
  transform: none;
}

.modal-close {
  position: absolute;
  top: 13px;
  inset-inline-end: 13px;
  z-index: 5;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  background: rgba(4, 5, 7, 0.55);
  backdrop-filter: blur(8px);
  color: #fff;
  transition: background 0.3s ease, transform 0.3s ease;
}

.modal-close .icon {
  font-size: 17px;
}

.modal-close:hover {
  background: var(--gold);
  color: #1b1309;
  transform: rotate(90deg);
}

.modal-media {
  position: relative;
  min-height: 100%;
  background: var(--surface-2);
}

.modal-media img {
  width: 100%;
  height: 100%;
  min-height: 260px;
  object-fit: cover;
  object-position: top center;
}

.modal-badge {
  position: absolute;
  bottom: 14px;
  inset-inline-start: 14px;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(4, 5, 7, 0.7);
  backdrop-filter: blur(8px);
  font-size: 0.62rem;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.modal-body {
  padding: clamp(24px, 3vw, 34px);
}

.modal-body h3 {
  font-family: var(--font-head);
  font-size: clamp(1.2rem, 2vw, 1.55rem);
  font-weight: 500;
  line-height: 1.45;
}

.modal-desc {
  margin-top: 9px;
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.95;
}

.modal-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 16px;
  padding: 13px 0;
  border-block: 1px solid var(--line);
}

.meta-item span {
  display: block;
  font-size: 0.58rem;
  color: var(--muted);
}

.meta-item strong {
  display: block;
  margin-top: 1px;
  font-size: 0.74rem;
  font-weight: 500;
  color: var(--text-soft);
}

.modal-block {
  margin-top: 16px;
}

.modal-block h4 {
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--text);
}

.modal-highlights {
  margin-top: 9px;
}

.modal-highlights li {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  margin-bottom: 6px;
  font-size: 0.74rem;
  line-height: 1.7;
  color: var(--muted);
}

.modal-highlights .icon {
  font-size: 12px;
  color: var(--green);
  margin-top: 4px;
}

.modal-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 16px;
}

.modal-tags span {
  padding: 3px 7px;
  border: 1px solid var(--line);
  border-radius: 5px;
  font-family: var(--font-mono);
  font-size: 0.48rem;
  color: var(--muted);
}

.modal-actions {
  display: flex;
  gap: 9px;
  margin-top: 22px;
}

.modal-actions .btn {
  flex: 1;
  min-height: 47px;
  font-size: 0.8rem;
  padding: 0 16px;
}

/* --------------------------- Utilities UI ------------------------------- */
.back-to-top {
  position: fixed;
  bottom: 22px;
  inset-inline-end: 22px;
  z-index: 80;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line-2);
  border-radius: 50%;
  background: var(--surface);
  color: var(--text-soft);
  box-shadow: 0 14px 34px -16px rgba(0, 0, 0, 0.7);
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity 0.35s ease, visibility 0.35s ease, transform 0.35s var(--ease), color 0.3s ease, border-color 0.3s ease;
}

.back-to-top .icon {
  font-size: 17px;
}

.back-to-top.show {
  opacity: 1;
  visibility: visible;
  transform: none;
}

.back-to-top:hover {
  color: var(--gold);
  border-color: var(--gold);
  transform: translateY(-3px);
}

.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  z-index: 400;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 11px 18px 11px 14px;
  border: 1px solid var(--line-2);
  border-radius: 999px;
  background: var(--surface-2);
  box-shadow: 0 24px 60px -24px rgba(0, 0, 0, 0.8);
  color: var(--text);
  font-size: 0.73rem;
  opacity: 0;
  visibility: hidden;
  transform: translate(-50%, 16px);
  transition: opacity 0.35s ease, visibility 0.35s ease, transform 0.35s var(--ease);
  max-width: calc(100vw - 40px);
}

.toast.show {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
}

.toast-icon {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--green-soft);
  color: var(--green);
}

.toast-icon .icon {
  font-size: 12px;
}

/* ---------------------------- Light theme ------------------------------- */
html[data-theme="light"] body {
  background-image:
    radial-gradient(ellipse 60% 38% at 82% -4%, rgba(169, 120, 61, 0.08), transparent 62%),
    radial-gradient(ellipse 50% 30% at 8% 22%, rgba(31, 138, 102, 0.04), transparent 70%);
}

html[data-theme="light"] .orb-1 {
  background: radial-gradient(circle, rgba(169, 120, 61, 0.15), transparent 68%);
}

html[data-theme="light"] .id-card {
  background: linear-gradient(160deg, rgba(255, 253, 249, 0.98), rgba(240, 232, 218, 0.98));
  border-color: rgba(169, 120, 61, 0.32);
  box-shadow:
    0 45px 100px -38px rgba(93, 64, 28, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

html[data-theme="light"] .id-card:hover {
  box-shadow:
    0 50px 110px -36px rgba(93, 64, 28, 0.4),
    0 0 60px -20px rgba(169, 120, 61, 0.22);
}

html[data-theme="light"] .avatar {
  background:
    radial-gradient(circle at 32% 25%, rgba(255, 255, 255, 0.75), transparent 58%),
    linear-gradient(145deg, #e9dcc8, #cdb99a);
  color: #6d4a22;
  box-shadow: inset 0 0 24px rgba(120, 82, 35, 0.1);
}

html[data-theme="light"] .avatar-dot {
  border-color: #f8f3ea;
}

html[data-theme="light"] .id-tags span,
html[data-theme="light"] .id-bottom,
html[data-theme="light"] .id-card::before {
  border-color: rgba(23, 19, 14, 0.12);
}

html[data-theme="light"] .float-chip {
  background: rgba(255, 253, 249, 0.9);
  box-shadow: 0 18px 40px -22px rgba(93, 64, 28, 0.35);
}

html[data-theme="light"] .mini-shot img {
  filter: saturate(0.95) brightness(0.98);
}

html[data-theme="light"] .cursor-glow {
  background: radial-gradient(circle, rgba(169, 120, 61, 0.13) 0%, transparent 66%);
  mix-blend-mode: multiply;
}

html[data-theme="light"] .grid-lines {
  opacity: 0.5;
}

html[data-theme="light"] .project-card:hover {
  box-shadow: 0 34px 70px -44px rgba(93, 64, 28, 0.45);
}

html[data-theme="light"] .browser-url {
  background: #fff;
}

html[data-theme="light"] .filter-btn.active,
html[data-theme="light"] .btn-primary {
  color: #fffaf2;
}

html[data-theme="light"] .filter-btn.active .count {
  background: rgba(255, 255, 255, 0.24);
  color: #fffaf2;
}

html[data-theme="light"] .btn-primary::after {
  opacity: 0.65;
}

html[data-theme="light"] body::before {
  opacity: 0.035;
}

html[data-theme="light"] .terminal {
  background: #0b0d11;
}

html[data-theme="light"] .modal-backdrop {
  background: rgba(26, 20, 12, 0.55);
}

/* --------------------------- Responsive --------------------------------- */
@media (max-width: 1180px) {
  .nav-links {
    gap: 15px;
  }

  .header-cta {
    display: none;
  }

  .hero-title {
    font-size: clamp(3.2rem, 6.7vw, 5.4rem);
  }

  .orbit,
  .orbit-b {
    width: 440px;
    height: 440px;
  }

  .float-chip {
    transform: scale(0.92);
  }
}

@media (max-width: 1024px) {
  :root {
    --header-h: 76px;
  }

  .hero {
    min-height: auto;
    padding-top: calc(var(--header-h) + 72px);
    padding-bottom: 80px;
  }

  .hero-inner {
    grid-template-columns: 1fr;
    gap: 56px;
  }

  .hero-copy {
    max-width: 760px;
  }

  .hero-title {
    font-size: clamp(3.3rem, 9vw, 5.6rem);
  }

  .hero-desc {
    max-width: 620px;
  }

  .hero-visual {
    min-height: 520px;
    max-width: 560px;
    width: 100%;
    margin-inline: auto;
  }

  .scroll-cue {
    display: none;
  }

  .section-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 16px;
  }

  .section-desc {
    max-width: 540px;
    padding-inline-start: 46px;
  }

  .about-grid,
  .skills-layout,
  .journey-grid {
    grid-template-columns: 1fr;
    gap: 44px;
  }

  .about-visual {
    max-width: 620px;
    width: 100%;
  }

  .skills-side {
    max-width: 640px;
  }

  .journey-aside {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
  }

  .contact-shell {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .contact-side {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 9px;
  }

  .contact-availability,
  .contact-social {
    grid-column: 1 / -1;
  }

  .footer-inner {
    grid-template-columns: 1fr;
    gap: 36px;
  }
}

@media (max-width: 860px) {
  .nav-links {
    display: none;
  }

  .menu-toggle {
    display: grid;
  }

  .header-actions {
    margin-inline-start: auto;
  }

  .hero-stats {
    gap: 20px;
  }

  .principles {
    grid-template-columns: 1fr;
    margin-top: 40px;
  }

  .principle {
    padding: 22px;
  }

  .projects-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .project-body h3 {
    font-size: 1.2rem;
  }

  .project-body > p {
    font-size: 0.81rem;
  }

  .projects-cta {
    flex-direction: column;
    align-items: flex-start;
    padding: 24px;
  }

  .modal-panel {
    grid-template-columns: 1fr;
    max-height: 90vh;
  }

  .modal-media {
    aspect-ratio: 16 / 9;
    min-height: 0;
  }

  .modal-media img {
    min-height: 0;
  }

  .modal-body {
    padding: 24px;
  }
}

@media (max-width: 640px) {
  .container {
    padding-inline: 18px;
  }

  .hero {
    padding-top: calc(var(--header-h) + 44px);
    padding-bottom: 64px;
  }

  .hero-title {
    font-size: clamp(2.85rem, 13vw, 4rem);
    letter-spacing: -0.03em;
  }

  .eyebrow {
    font-size: 0.67rem;
    padding: 6px 11px;
    margin-bottom: 20px;
  }

  .hero-tagline {
    margin-top: 22px;
    font-size: 0.98rem;
    line-height: 1.9;
  }

  .hero-desc {
    font-size: 0.87rem;
    line-height: 1.9;
  }

  .hero-actions {
    gap: 9px;
    margin-top: 26px;
  }

  .hero-actions .btn {
    flex: 1;
    min-width: 140px;
    padding: 0 18px;
    font-size: 0.84rem;
    min-height: 50px;
  }

  .cv-link {
    font-size: 0.72rem;
    flex-wrap: wrap;
  }

  .hero-stats {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px 20px;
    margin-top: 34px;
    padding-top: 20px;
  }

  .stat strong {
    font-size: 1.5rem;
  }

  .hero-visual {
    min-height: 440px;
  }

  .id-card {
    width: min(100%, 380px);
    padding: 18px;
    border-radius: 22px;
  }

  .id-info h2 {
    font-size: 0.98rem;
  }

  .avatar-wrap,
  .avatar {
    width: 74px;
    height: 74px;
  }

  .avatar {
    font-size: 31px;
  }

  .orbit,
  .orbit-b {
    display: none;
  }

  .float-chip {
    padding: 7px 10px;
    transform: scale(0.86);
  }

  .chip-age {
    top: 2%;
    left: -1%;
  }

  .chip-projects {
    right: -1%;
    bottom: 5%;
  }

  .chip-security {
    top: 38%;
    right: -2%;
  }

  .section {
    padding: 68px 0;
  }

  .section-heading {
    gap: 12px;
  }

  .section-num {
    margin-top: 6px;
    font-size: 0.56rem;
    padding: 5px 7px;
  }

  .section h2 {
    font-size: clamp(1.75rem, 8vw, 2.4rem);
  }

  .section-desc {
    padding-inline-start: 0;
    font-size: 0.82rem;
  }

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

  .about-info .info-item {
    padding: 11px 0;
  }

  .about-lead {
    font-size: 1.35rem;
  }

  .about-text {
    font-size: 0.86rem;
  }

  .about-quote {
    padding: 15px 16px;
  }

  .terminal-body {
    padding: 16px;
    font-size: 0.66rem;
    line-height: 1.9;
  }

  .education-card {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .edu-year {
    margin-inline-start: 0;
  }

  .filters {
    flex-wrap: nowrap;
    overflow-x: auto;
    width: 100%;
    padding-bottom: 5px;
    scrollbar-width: none;
  }

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

  .filter-btn {
    flex-shrink: 0;
    font-size: 0.72rem;
    padding: 7px 11px;
  }

  .projects-count {
    display: none;
  }

  .project-media {
    margin: 8px 8px 0;
  }

  .project-body {
    padding: 18px;
  }

  .project-actions {
    margin-top: 16px;
  }

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

  .journey-aside {
    grid-template-columns: 1fr;
  }

  .timeline {
    padding-inline-start: 26px;
  }

  .timeline-dot {
    inset-inline-start: -32px;
  }

  .timeline-card {
    padding: 16px;
  }

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

  .contact-shell {
    border-radius: 22px;
    padding: 19px;
  }

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

  .contact-availability,
  .contact-social {
    grid-column: auto;
  }

  .form-foot {
    align-items: stretch;
    flex-direction: column;
  }

  .form-foot .btn {
    width: 100%;
  }

  .form-note {
    justify-content: center;
  }

  .footer-links {
    grid-template-columns: 1fr 1fr;
    gap: 26px;
  }

  .footer-bottom {
    justify-content: space-between;
  }

  .footer-made {
    display: none;
  }

  .modal {
    padding: 12px;
  }

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

  .modal-actions .btn {
    width: 100%;
  }

  .back-to-top {
    bottom: 16px;
    inset-inline-end: 16px;
    width: 40px;
    height: 40px;
  }

  .toast {
    bottom: 70px;
  }
}

@media (max-width: 400px) {
  .brand-text small {
    display: none;
  }

  .brand-text strong {
    font-size: 0.82rem;
  }

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

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

  .chip-security {
    display: none;
  }

  .float-chip {
    transform: scale(0.8);
  }

  .tool {
    font-size: 0.67rem;
  }
}

/* --------------------------- Reduced motion ----------------------------- */
@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;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }

  .cursor-glow {
    display: none;
  }

  .skill-track > span::after {
    display: none;
  }
}

@keyframes fieldShake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-4px); }
  75% { transform: translateX(4px); }
}
