/* ============================================================
   Aisha Maged Portfolio — Static CSS
   Mobile-first · Dark default · 5 accent themes · RTL-aware
   ============================================================ */

/* ---------- Variables ---------- */
:root,
.dark {
  --radius: 1rem;
  --brand: #9b5cff;
  --brand-2: #ec4899;
  --brand-muted: #c4b5fd;
  --brand-soft: rgba(155, 92, 255, 0.14);
  --brand-glow: rgba(155, 92, 255, 0.45);

  --bg: #07060f;
  --bg-2: #050410;
  --surface: rgba(255, 255, 255, 0.04);
  --surface-2: rgba(255, 255, 255, 0.06);
  --surface-glass: rgba(15, 12, 30, 0.55);
  --hairline: rgba(255, 255, 255, 0.08);
  --hairline-2: rgba(255, 255, 255, 0.12);

  --text: #ffffff;
  --text-2: #d5d0e8;
  --text-muted: #9a8fbf;

  --star: rgba(255, 255, 255, 0.75);
  --grid: rgba(155, 92, 255, 0.07);
  --shadow: 0 8px 40px -8px rgba(0, 0, 0, 0.5);
}

.light {
  --bg: #f5f3ff;
  --bg-2: #ede9fe;
  --surface: rgba(124, 58, 237, 0.05);
  --surface-2: rgba(124, 58, 237, 0.08);
  --surface-glass: rgba(255, 255, 255, 0.7);
  --hairline: rgba(124, 58, 237, 0.12);
  --hairline-2: rgba(124, 58, 237, 0.2);
  --text: #2e1065;
  --text-2: #4a3a6a;
  --text-muted: #6b5a8a;
  --brand: #7c3aed;
  --brand-muted: #6d28d9;
  --brand-soft: rgba(124, 58, 237, 0.1);
  --brand-glow: rgba(124, 58, 237, 0.3);
  --star: rgba(80, 60, 130, 0.35);
  --grid: rgba(124, 58, 237, 0.05);
  --shadow: 0 8px 30px -8px rgba(124, 58, 237, 0.15);
}

/* Accent themes */
[data-accent="purple"] { --brand:#9b5cff; --brand-2:#ec4899; --brand-muted:#c4b5fd; --brand-soft:rgba(155,92,255,.14); --brand-glow:rgba(155,92,255,.45); }
[data-accent="pink"]   { --brand:#ec4899; --brand-2:#f43f5e; --brand-muted:#f9a8d4; --brand-soft:rgba(236,72,153,.14); --brand-glow:rgba(236,72,153,.45); }
[data-accent="blue"]   { --brand:#38bdf8; --brand-2:#3b82f6; --brand-muted:#bae6fd; --brand-soft:rgba(56,189,248,.14); --brand-glow:rgba(56,189,248,.45); }
[data-accent="amber"]  { --brand:#f59e0b; --brand-2:#f97316; --brand-muted:#fcd34d; --brand-soft:rgba(245,158,11,.14); --brand-glow:rgba(245,158,11,.45); }
[data-accent="emerald"]{ --brand:#10b981; --brand-2:#059669; --brand-muted:#6ee7b7; --brand-soft:rgba(16,185,129,.14); --brand-glow:rgba(16,185,129,.45); }

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: "Cairo", system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  min-height: 100dvh;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  background-image:
    radial-gradient(ellipse 80% 50% at 50% -10%, var(--brand-glow), transparent 60%),
    radial-gradient(ellipse 60% 40% at 100% 100%, rgba(236, 72, 153, 0.08), transparent 60%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 100%);
  background-attachment: fixed;
  background-repeat: no-repeat;
  transition: background-color 0.4s ease, color 0.4s ease;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
svg { width: 1em; height: 1em; flex-shrink: 0; }
::selection { background: var(--brand); color: #fff; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--brand); border-radius: 999px; border: 2px solid transparent; background-clip: padding-box; }

/* ---------- Background ---------- */
.bg-layer { position: fixed; inset: 0; z-index: -10; overflow: hidden; pointer-events: none; }
.aurora { position: absolute; border-radius: 50%; filter: blur(120px); opacity: 0.2; animation: auroraShift 20s ease-in-out infinite; }
.aurora-1 { top: -25%; left: 50%; width: 60vmax; height: 60vmax; transform: translateX(-50%); background: var(--brand); opacity: 0.18; }
.aurora-2 { top: 33%; left: -25%; width: 40vmax; height: 40vmax; background: #ec4899; opacity: 0.10; animation-delay: -6s; }
.aurora-3 { bottom: 0; right: 0; width: 35vmax; height: 35vmax; background: #d946ef; opacity: 0.10; animation-delay: -12s; }
.dot-grid {
  position: absolute; inset: 0;
  background-image: radial-gradient(var(--grid) 1px, transparent 1px);
  background-size: 24px 24px;
  opacity: 0.5;
  -webkit-mask-image: linear-gradient(to bottom, black 60%, transparent 100%);
  mask-image: linear-gradient(to bottom, black 60%, transparent 100%);
}
#stars { position: absolute; inset: 0; width: 100%; height: 100%; }
.vignette { position: absolute; inset: 0; background: radial-gradient(ellipse at center, transparent 55%, rgba(0,0,0,0.5) 100%); }
.light .vignette { background: radial-gradient(ellipse at center, transparent 60%, rgba(124,58,237,0.05) 100%); }

@keyframes auroraShift {
  0%, 100% { transform: translate(0,0) rotate(0) scale(1); }
  33% { transform: translate(4%,-3%) rotate(8deg) scale(1.08); }
  66% { transform: translate(-3%,4%) rotate(-6deg) scale(0.95); }
}
.aurora-1 { animation-name: auroraShift1; }
@keyframes auroraShift1 {
  0%, 100% { transform: translateX(-50%) translate(0,0) scale(1); }
  50% { transform: translateX(-50%) translate(0,5%) scale(1.1); }
}

/* ---------- Scroll progress ---------- */
.scroll-progress {
  position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 100;
  background: linear-gradient(90deg, var(--brand), var(--brand-2), var(--brand));
  transform: scaleX(0); transform-origin: left;
  box-shadow: 0 0 12px var(--brand-glow);
  transition: transform 0.1s linear;
}

/* ---------- Custom cursor (desktop only) ---------- */
.cursor-dot, .cursor-ring {
  position: fixed; top: 0; left: 0; pointer-events: none; z-index: 9999;
  border-radius: 50%; transform: translate(-50%, -50%); will-change: transform;
}
.cursor-dot { width: 8px; height: 8px; background: var(--brand); transition: opacity 0.2s; }
.cursor-ring {
  width: 36px; height: 36px; border: 1.5px solid var(--brand);
  box-shadow: 0 0 20px var(--brand-glow);
  transition: width 0.25s, height 0.25s, border-color 0.25s;
}
body.cursor-hover .cursor-ring { width: 56px; height: 56px; border-color: var(--brand-2); }
body.cursor-hover .cursor-dot { opacity: 0; }
@media (hover: none), (pointer: coarse) {
  .cursor-dot, .cursor-ring { display: none !important; }
}

/* ---------- Top bar ---------- */
.topbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  padding: 0.75rem max(0.75rem, env(safe-area-inset-left));
  padding-top: max(0.75rem, env(safe-area-inset-top));
  transition: padding 0.4s ease;
}
.topbar.scrolled { padding-top: max(0.5rem, env(safe-area-inset-top)); }
.topbar-inner {
  max-width: 72rem; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between; gap: 0.75rem;
  padding: 0.5rem 0.75rem;
  border-radius: 1.25rem;
  border: 1px solid transparent;
  transition: all 0.4s ease;
}
.topbar.scrolled .topbar-inner {
  background: var(--surface-glass);
  backdrop-filter: blur(24px) saturate(160%);
  -webkit-backdrop-filter: blur(24px) saturate(160%);
  border-color: var(--hairline);
  box-shadow: var(--shadow);
}
.logo { display: flex; align-items: center; gap: 0.5rem; font-weight: 800; }
.logo-badge {
  width: 2.25rem; height: 2.25rem; display: grid; place-items: center;
  border-radius: 0.75rem; color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  box-shadow: 0 4px 16px var(--brand-glow);
  position: relative;
}
.logo-badge::after { content: ""; position: absolute; inset: 0; border-radius: inherit; box-shadow: inset 0 0 0 2px rgba(255,255,255,0.2); }
.logo-spark { font-size: 1rem; line-height: 1; }
.logo-text {
  font-size: 1.05rem; display: none;
  background: linear-gradient(120deg, #fff, var(--brand-muted), #fff);
  background-size: 200% 100%; -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  animation: textShine 6s linear infinite;
}
.light .logo-text { background: linear-gradient(120deg, #2e1065, var(--brand), #2e1065); background-size: 200% 100%; -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
@keyframes textShine { 0% { background-position: 0% 50%; } 100% { background-position: 200% 50%; } }

.topnav { display: none; align-items: center; gap: 0.25rem; }
.navlink {
  position: relative; padding: 0.5rem 0.9rem; border-radius: 999px;
  font-size: 0.875rem; font-weight: 500; color: var(--text-muted);
  transition: color 0.3s;
}
.navlink:hover { color: var(--text); }
.navlink.active { color: var(--text); }
.navlink.active::before {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit;
  background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--hairline-2);
}

.topbar-controls { display: flex; align-items: center; gap: 0.5rem; }
.lang-switch {
  display: none; align-items: center; gap: 0.125rem;
  padding: 0.125rem; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--hairline);
  backdrop-filter: blur(8px);
}
.lang-btn {
  display: flex; align-items: center; gap: 0.25rem;
  height: 2rem; padding: 0 0.625rem; border-radius: 999px;
  font-size: 0.75rem; font-weight: 700; color: var(--text-muted);
  transition: all 0.3s;
}
.lang-btn:hover { color: var(--text); }
.lang-btn.active {
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  color: #fff; box-shadow: 0 4px 16px var(--brand-glow);
}
.icon-btn {
  width: 2.5rem; height: 2.5rem; display: none; place-items: center;
  border-radius: 999px; border: 1px solid var(--hairline);
  background: var(--surface); color: var(--text);
  transition: all 0.3s;
}
.icon-btn:hover { border-color: var(--brand); color: var(--brand); box-shadow: 0 0 20px var(--brand-glow); }
.icon-btn svg { width: 1.125rem; height: 1.125rem; }
#themeToggle .icon-sun { display: none; }
body.light #themeToggle .icon-sun { display: block; }
body.light #themeToggle .icon-moon { display: none; }
.settings-btn { display: grid; }

/* Mobile: show settings + theme toggle, hide lang-switch (it's in drawer) but show compact on sm+ */
@media (min-width: 640px) {
  .topbar .lang-switch { display: flex; }
  .logo-text { display: inline; }
  #themeToggle { display: grid; }
}
@media (max-width: 639px) {
  .settings-btn { display: grid; }
}
/* The lang-switch INSIDE the drawer is always visible (regardless of viewport) */
.drawer .lang-switch { display: flex !important; }

/* Desktop: show topnav + accent picker */
@media (min-width: 1024px) {
  .topnav { display: flex; }
  .settings-btn { display: none; }
}

/* ---------- Accent picker (desktop left edge) ---------- */
.accent-picker {
  position: fixed; left: 0; top: 50%; transform: translateY(-50%);
  z-index: 40; display: none; flex-direction: column; gap: 0.5rem;
  padding: 0.5rem; border-radius: 0 1rem 1rem 0;
  background: var(--surface-glass); backdrop-filter: blur(16px);
  border: 1px solid var(--hairline); border-left: none;
}
.accent-dot {
  width: 1.25rem; height: 1.25rem; border-radius: 50%;
  background: var(--c); border: 2px solid transparent;
  transition: transform 0.3s;
}
.accent-dot:hover { transform: scale(1.3); }
.accent-dot.active { border-color: #fff; box-shadow: 0 0 12px var(--c); }
@media (min-width: 1024px) { .accent-picker { display: flex; } }

/* ---------- Settings drawer (mobile) ---------- */
.drawer-overlay {
  position: fixed; inset: 0; z-index: 60; background: rgba(0,0,0,0.5);
  opacity: 0; pointer-events: none; transition: opacity 0.3s;
}
.drawer-overlay.open { opacity: 1; pointer-events: auto; }
.drawer {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 61;
  background: var(--surface-glass); backdrop-filter: blur(24px) saturate(160%);
  border-top: 1px solid var(--hairline);
  border-radius: 1.5rem 1.5rem 0 0;
  padding: 0.5rem 1.25rem 2rem;
  transform: translateY(100%);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  max-height: 80vh; overflow-y: auto;
}
.drawer.open { transform: translateY(0); }
.drawer-handle { width: 100px; height: 4px; background: var(--hairline-2); border-radius: 999px; margin: 0.5rem auto 1rem; }
.drawer-title { text-align: center; font-size: 1.125rem; font-weight: 800; margin-bottom: 1.5rem; background: linear-gradient(120deg, var(--brand), var(--brand-2)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.drawer-section { display: flex; flex-direction: column; align-items: center; gap: 0.75rem; margin-bottom: 1.5rem; }
.drawer-label { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-muted); }
.theme-row { display: flex; gap: 0.5rem; }
.theme-pill {
  padding: 0.5rem 1rem; border-radius: 999px; font-size: 0.8125rem; font-weight: 600;
  border: 1px solid var(--hairline); background: var(--surface); color: var(--text-2);
  transition: all 0.3s;
}
.theme-pill.active { background: linear-gradient(135deg, var(--brand), var(--brand-2)); color: #fff; border-color: transparent; box-shadow: 0 4px 16px var(--brand-glow); }
.accent-row { display: flex; gap: 0.75rem; }
.accent-row .accent-dot { width: 2.25rem; height: 2.25rem; }
.accent-row .accent-dot.active { transform: scale(1.1); }

/* ---------- Layout ---------- */
main { flex: 1; }
.container { width: min(72rem, 92%); margin: 0 auto; }
.section { padding: 5rem 0; scroll-margin-top: 6rem; }
@media (min-width: 768px) { .section { padding: 7rem 0; } }

/* ---------- Section header ---------- */
.section-head { text-align: center; margin-bottom: 2.5rem; }
@media (min-width: 768px) { .section-head { margin-bottom: 3.5rem; } }
.section-eyebrow {
  display: inline-block; margin-bottom: 0.75rem;
  font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.2em;
  color: var(--brand);
}
.section-title {
  font-size: 2rem; font-weight: 800; line-height: 1.1;
  background: linear-gradient(120deg, var(--brand), var(--brand-2), var(--brand));
  background-size: 200% 100%; -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  animation: textShine 6s linear infinite;
}
@media (min-width: 768px) { .section-title { font-size: 3rem; } }
.section-sub { max-width: 36rem; margin: 0.75rem auto 0; font-size: 0.9375rem; color: var(--text-muted); }
@media (min-width: 768px) { .section-sub { font-size: 1rem; } }

/* ---------- Hero ---------- */
.hero {
  min-height: 100vh; min-height: 100dvh;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: 6rem 1rem 5rem; position: relative;
}
.hero-inner { max-width: 48rem; display: flex; flex-direction: column; align-items: center; }

.profile-wrap {
  position: relative; width: 9rem; height: 9rem; margin-bottom: 1.75rem;
  perspective: 1000px;
}
@media (min-width: 640px) { .profile-wrap { width: 12rem; height: 12rem; } }
@media (min-width: 768px) { .profile-wrap { width: 14rem; height: 14rem; } }
.profile-glow { position: absolute; inset: -1.5rem; border-radius: 50%; background: var(--brand); opacity: 0.25; filter: blur(40px); z-index: -1; }
.profile-ring-spin {
  position: absolute; inset: -0.75rem; border-radius: 50%; z-index: -1;
  border: 1px dashed var(--brand); opacity: 0.4; animation: spinSlow 24s linear infinite;
}
@keyframes spinSlow { to { transform: rotate(360deg); } }
.profile-pulse {
  position: absolute; inset: -0.25rem; border-radius: 50%; z-index: -1;
  border: 2px solid var(--brand); animation: pulseRing 3s ease-out infinite;
}
@keyframes pulseRing {
  0% { transform: scale(0.92); opacity: 0.7; }
  70%, 100% { transform: scale(1.15); opacity: 0; }
}
.profile-img-box {
  width: 100%; height: 100%; border-radius: 50%; overflow: hidden;
  border: 4px solid var(--brand-soft);
  box-shadow: 0 0 40px var(--brand-glow);
  transform-style: preserve-3d; transition: transform 0.2s ease-out;
}
.profile-img-box img { width: 100%; height: 100%; object-fit: cover; }
.profile-badge {
  position: absolute; top: -0.5rem; right: -0.5rem;
  width: 2.25rem; height: 2.25rem; display: grid; place-items: center;
  border-radius: 50%; color: #fff; font-size: 1rem;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
  animation: floatY 3s ease-in-out infinite;
}
@keyframes floatY { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }

.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.375rem 0.875rem; border-radius: 999px;
  border: 1px solid var(--hairline); background: var(--surface);
  backdrop-filter: blur(8px);
  font-size: 0.6875rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--text-muted); margin-bottom: 1rem;
}
@media (min-width: 640px) { .hero-eyebrow { font-size: 0.75rem; } }
.ping-dot { position: relative; width: 0.5rem; height: 0.5rem; }
.ping-dot::before { content: ""; position: absolute; inset: 0; border-radius: 50%; background: #34d399; animation: ping 1.5s cubic-bezier(0,0,0.2,1) infinite; }
.ping-dot::after { content: ""; position: absolute; inset: 0; border-radius: 50%; background: #34d399; }
@keyframes ping { 75%, 100% { transform: scale(2); opacity: 0; } }

.hero-name { font-size: 2.25rem; font-weight: 800; line-height: 1.1; }
@media (min-width: 640px) { .hero-name { font-size: 3rem; } }
@media (min-width: 768px) { .hero-name { font-size: 3.75rem; } }
.hero-hello { display: block; font-size: 1.125rem; font-weight: 500; color: var(--text-2); margin-bottom: 0.25rem; }
@media (min-width: 640px) { .hero-hello { font-size: 1.25rem; } }
.hero-fullname {
  display: block;
  background: linear-gradient(120deg, #fff 0%, var(--brand-muted) 50%, #fff 100%);
  background-size: 200% 100%; -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  animation: textShine 6s linear infinite;
  filter: drop-shadow(0 0 20px var(--brand-glow));
}
.light .hero-fullname { background: linear-gradient(120deg, #2e1065 0%, var(--brand) 50%, #2e1065 100%); background-size: 200% 100%; -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; filter: none; }

.hero-typing {
  margin-top: 1rem; min-height: 1.8em; display: flex; align-items: center; justify-content: center;
  font-size: 1.125rem; font-weight: 600; color: var(--brand-muted);
}
@media (min-width: 640px) { .hero-typing { font-size: 1.5rem; } }
.cursor-blink { display: inline-block; width: 2px; height: 1.1em; margin-left: 2px; background: var(--brand); animation: blink 1s step-end infinite; }
@keyframes blink { 50% { opacity: 0; } }

.hero-text { max-width: 36rem; margin: 1.25rem auto 0; font-size: 0.9375rem; color: var(--text-muted); }
@media (min-width: 640px) { .hero-text { font-size: 1rem; } }

.hero-chips { display: flex; flex-wrap: wrap; gap: 0.5rem; justify-content: center; margin-top: 1.25rem; }
.chip {
  display: inline-flex; align-items: center; gap: 0.375rem;
  padding: 0.25rem 0.75rem; border-radius: 999px;
  border: 1px solid var(--hairline); background: var(--surface);
  font-size: 0.75rem; font-weight: 500; color: var(--text-2);
}
.chip-green { border-color: rgba(52, 211, 153, 0.3); background: rgba(52, 211, 153, 0.1); color: #6ee7b7; }
.light .chip-green { color: #059669; }
.chip .dot { width: 0.5rem; height: 0.5rem; border-radius: 50%; background: #34d399; }
.chip .spark { color: var(--brand); }

.hero-cta { display: flex; flex-direction: column; gap: 0.75rem; margin-top: 1.75rem; width: 100%; align-items: stretch; }
@media (min-width: 640px) { .hero-cta { flex-direction: row; justify-content: center; width: auto; } }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  padding: 0.875rem 1.75rem; border-radius: 999px;
  font-size: 0.875rem; font-weight: 700; transition: all 0.3s;
  position: relative; overflow: hidden;
}
.btn svg { width: 1rem; height: 1rem; }
.btn-primary { color: #fff; background: linear-gradient(135deg, var(--brand), var(--brand-2)); box-shadow: 0 8px 30px var(--brand-glow); }
.btn-primary::before { content: ""; position: absolute; inset: 0; transform: translateX(-120%); background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent); transition: transform 0.7s; }
.btn-primary:hover::before { transform: translateX(120%); }
.btn-primary:hover { filter: brightness(1.1); box-shadow: 0 12px 40px var(--brand-glow); }
.btn-ghost { border: 1px solid var(--brand-soft); background: var(--surface); color: var(--text); backdrop-filter: blur(8px); }
.btn-ghost:hover { border-color: var(--brand); background: var(--brand-soft); }
.btn:active { transform: scale(0.96); }
.btn-whatsapp { color: #fff; background: linear-gradient(135deg, #22c55e, #16a34a); box-shadow: 0 8px 24px rgba(34,197,94,0.4); }

.socials { display: flex; gap: 0.625rem; justify-content: center; margin-top: 2rem; }
.socials a {
  width: 2.75rem; height: 2.75rem; display: grid; place-items: center;
  border-radius: 50%; border: 1px solid var(--hairline); background: var(--surface);
  color: var(--text-muted); transition: all 0.3s;
}
.socials a svg { width: 1.125rem; height: 1.125rem; }
.socials a:hover { transform: translateY(-4px); border-color: var(--brand); color: var(--brand); box-shadow: 0 8px 20px var(--brand-glow); }

.scroll-cue {
  position: absolute; bottom: 6rem; left: 50%; transform: translateX(-50%);
  display: none; flex-direction: column; align-items: center; gap: 0.25rem;
  color: var(--text-muted); font-size: 0.625rem; font-weight: 500; text-transform: uppercase; letter-spacing: 0.15em;
  transition: color 0.3s;
}
@media (min-width: 768px) { .scroll-cue { display: flex; bottom: 2rem; } }
.scroll-cue:hover { color: var(--brand); }
.scroll-cue svg { width: 1rem; height: 1rem; animation: floatY 1.6s ease-in-out infinite; }

/* ---------- About ---------- */
.about-grid { display: grid; gap: 2rem; }
@media (min-width: 1024px) { .about-grid { grid-template-columns: 1.1fr 0.9fr; gap: 3rem; } }
.about-text { font-size: 1rem; color: var(--text-2); }
@media (min-width: 768px) { .about-text { font-size: 1.125rem; } }
.about-cards { display: grid; gap: 0.75rem; margin-top: 1.75rem; }
@media (min-width: 640px) { .about-cards { grid-template-columns: repeat(3, 1fr); } }
.info-card {
  display: flex; flex-direction: column; gap: 0.5rem;
  padding: 1rem; border-radius: 1rem;
  border: 1px solid var(--hairline); background: var(--surface);
  backdrop-filter: blur(8px);
  transition: transform 0.4s, border-color 0.4s, box-shadow 0.4s;
}
.info-card:hover { transform: translateY(-4px); border-color: var(--brand); box-shadow: 0 12px 30px -8px var(--brand-glow); }
.info-icon {
  width: 2.5rem; height: 2.5rem; display: grid; place-items: center;
  border-radius: 0.75rem; background: var(--brand-soft); color: var(--brand);
}
.info-icon svg { width: 1.25rem; height: 1.25rem; }
.info-label { font-size: 0.6875rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-muted); }
.info-value { font-size: 0.875rem; font-weight: 700; color: var(--text); }

.hobbies { margin-top: 1.5rem; }
.hobbies-label { display: flex; align-items: center; gap: 0.375rem; font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-muted); margin-bottom: 0.75rem; }
.hobbies-label svg { width: 0.875rem; height: 0.875rem; color: #f472b6; fill: #f472b6; }
.hobbies-list { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.hobby-chip {
  display: inline-flex; align-items: center; gap: 0.375rem;
  padding: 0.375rem 0.75rem; border-radius: 999px;
  border: 1px solid var(--hairline); background: var(--surface);
  font-size: 0.75rem; font-weight: 500; color: var(--text-2);
  transition: all 0.3s;
}
.hobby-chip:hover { border-color: var(--brand); color: var(--brand); }
.hobby-chip span:first-child { color: var(--brand); }

.stats-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.75rem; }
@media (min-width: 768px) { .stats-grid { gap: 1rem; } }
.stat-card {
  position: relative; overflow: hidden;
  padding: 1.25rem; border-radius: 1rem;
  border: 1px solid var(--hairline);
  background: linear-gradient(135deg, var(--surface-2), transparent);
  backdrop-filter: blur(8px);
}
.stat-card::before { content: ""; position: absolute; top: -1.5rem; right: -1.5rem; width: 5rem; height: 5rem; border-radius: 50%; background: var(--brand-soft); filter: blur(20px); }
.stat-value {
  font-size: 1.875rem; font-weight: 800;
  background: linear-gradient(120deg, var(--brand), var(--brand-2));
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
@media (min-width: 768px) { .stat-value { font-size: 2.5rem; } }
.stat-label { font-size: 0.75rem; color: var(--text-muted); margin-top: 0.25rem; }
@media (min-width: 768px) { .stat-label { font-size: 0.875rem; } }

/* ---------- Skills ---------- */
.skills-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.75rem; }
@media (min-width: 640px) { .skills-grid { grid-template-columns: repeat(3, 1fr); gap: 1rem; } }
@media (min-width: 1024px) { .skills-grid { grid-template-columns: repeat(6, 1fr); } }
.skill-card {
  display: flex; flex-direction: column; align-items: center; gap: 0.75rem;
  padding: 1.25rem 1rem; text-align: center;
  border-radius: 1rem; border: 1px solid var(--hairline); background: var(--surface);
  backdrop-filter: blur(8px); position: relative; overflow: hidden;
  transition: transform 0.4s, border-color 0.4s, box-shadow 0.4s;
}
.skill-card:hover { transform: translateY(-4px); border-color: var(--skill-color); box-shadow: 0 12px 30px -8px var(--skill-color); }
.skill-card::before { content: ""; position: absolute; top: -2rem; left: 50%; transform: translateX(-50%); width: 4rem; height: 4rem; border-radius: 50%; background: var(--skill-color); opacity: 0; filter: blur(20px); transition: opacity 0.5s; }
.skill-card:hover::before { opacity: 0.5; }
.skill-icon {
  width: 3rem; height: 3rem; display: grid; place-items: center; border-radius: 1rem;
  background: color-mix(in srgb, var(--skill-color) 12%, transparent);
  color: var(--skill-color); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--skill-color) 25%, transparent);
  transition: transform 0.5s;
}
@media (min-width: 768px) { .skill-icon { width: 3.5rem; height: 3.5rem; } }
.skill-card:hover .skill-icon { transform: scale(1.1) rotate(-6deg); }
.skill-icon svg { width: 1.5rem; height: 1.5rem; }
@media (min-width: 768px) { .skill-icon svg { width: 1.75rem; height: 1.75rem; } }
.skill-name { font-size: 0.875rem; font-weight: 700; }
@media (min-width: 768px) { .skill-name { font-size: 1rem; } }
.skill-desc { font-size: 0.6875rem; color: var(--text-muted); line-height: 1.4; }
@media (min-width: 768px) { .skill-desc { font-size: 0.75rem; } }
.skill-bar-wrap { width: 100%; margin-top: auto; padding-top: 0.25rem; }
.skill-bar-meta { display: flex; justify-content: space-between; font-size: 0.625rem; font-weight: 600; color: var(--text-muted); margin-bottom: 0.25rem; }
.skill-bar-meta span:last-child { color: var(--skill-color); }
.skill-bar { height: 0.375rem; width: 100%; background: var(--hairline); border-radius: 999px; overflow: hidden; }
.skill-bar-fill { height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--skill-color), color-mix(in srgb, var(--skill-color) 60%, #000)); width: 0; transition: width 1s cubic-bezier(0.16, 1, 0.3, 1); }

/* ---------- Projects ---------- */
.projects-grid { display: grid; gap: 1rem; }
@media (min-width: 768px) { .projects-grid { grid-template-columns: repeat(2, 1fr); gap: 1.5rem; } }
@media (min-width: 1024px) { .projects-grid { grid-template-columns: repeat(3, 1fr); } }
.project-card {
  display: flex; flex-direction: column; overflow: hidden;
  border-radius: 1.5rem; border: 1px solid var(--hairline); background: var(--surface);
  backdrop-filter: blur(8px); position: relative;
  transition: transform 0.4s, border-color 0.4s, box-shadow 0.4s;
}
.project-card:hover { transform: translateY(-4px); border-color: var(--brand); box-shadow: 0 20px 50px -16px var(--brand-glow); }
.project-img { position: relative; aspect-ratio: 16/10; overflow: hidden; }
.project-img img { width: 100%; height: 100%; object-fit: cover; object-position: top; transition: transform 0.7s ease; }
.project-card:hover .project-img img { transform: scale(1.05); }
.project-img::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, var(--bg) 0%, transparent 60%); }
.project-badge {
  position: absolute; top: 0.75rem; right: 0.75rem; z-index: 2;
  display: inline-flex; align-items: center; gap: 0.25rem;
  padding: 0.25rem 0.625rem; border-radius: 999px;
  font-size: 0.6875rem; font-weight: 700; color: #fff;
  border: 1px solid rgba(255,255,255,0.2);
}
.project-badge svg { width: 0.75rem; height: 0.75rem; }
.project-badge.tone-brand { background: linear-gradient(135deg, #9b5cff, #d946ef); }
.project-badge.tone-amber { background: linear-gradient(135deg, #f59e0b, #f97316); }
.project-badge.tone-pink { background: linear-gradient(135deg, #ec4899, #f43f5e); }
.project-content { padding: 1.25rem; flex: 1; display: flex; flex-direction: column; }
.project-title { font-size: 1.125rem; font-weight: 700; }
@media (min-width: 768px) { .project-title { font-size: 1.25rem; } }
.project-text { margin-top: 0.5rem; font-size: 0.875rem; color: var(--text-muted); line-height: 1.6; }
.project-tags { display: flex; flex-wrap: wrap; gap: 0.375rem; margin-top: 1rem; }
.project-tag { padding: 0.25rem 0.625rem; border-radius: 999px; font-size: 0.6875rem; font-weight: 500; color: var(--text-muted); border: 1px solid var(--hairline); background: var(--surface); transition: all 0.3s; }
.project-tag:hover { border-color: var(--brand); color: var(--brand); }
.project-footer { display: flex; justify-content: space-between; align-items: center; margin-top: 1.25rem; padding-top: 1rem; border-top: 1px solid var(--hairline); font-size: 0.75rem; color: var(--text-muted); }
.project-more { display: inline-flex; align-items: center; gap: 0.25rem; font-weight: 700; color: var(--brand); opacity: 0; transition: opacity 0.3s; }
.project-card:hover .project-more { opacity: 1; }
.project-more svg { width: 0.875rem; height: 0.875rem; }

/* ---------- Education timeline ---------- */
.timeline { max-width: 48rem; margin: 0 auto; position: relative; }
.timeline::before { content: ""; position: absolute; left: 1.375rem; top: 1.5rem; bottom: 1.5rem; width: 1px; background: linear-gradient(to bottom, var(--brand), var(--brand-soft), transparent); }
@media (min-width: 640px) { .timeline::before { left: 1.625rem; } }
.edu-item { position: relative; padding-left: 3.5rem; margin-bottom: 1rem; }
@media (min-width: 640px) { .edu-item { padding-left: 4rem; } }
.edu-node {
  position: absolute; left: 0; top: 0;
  width: 2.75rem; height: 2.75rem; display: grid; place-items: center;
  border-radius: 1rem; color: var(--brand);
  background: var(--brand-soft); border: 1px solid var(--brand-soft);
  box-shadow: 0 0 20px var(--brand-glow);
}
@media (min-width: 640px) { .edu-node { width: 3.25rem; height: 3.25rem; } }
.edu-node svg { width: 1.25rem; height: 1.25rem; }
@media (min-width: 640px) { .edu-node svg { width: 1.5rem; height: 1.5rem; } }
.edu-node::after { content: ""; position: absolute; inset: 0; border-radius: inherit; border: 1px solid var(--brand); animation: pulseRing 2s ease-out infinite; }
.edu-card { padding: 1.25rem; border-radius: 1rem; border: 1px solid var(--hairline); background: var(--surface); backdrop-filter: blur(8px); transition: transform 0.4s, border-color 0.4s; }
.edu-card:hover { transform: translateY(-4px); border-color: var(--brand); }
.edu-year { display: inline-flex; align-items: center; gap: 0.25rem; padding: 0.25rem 0.625rem; border-radius: 999px; font-size: 0.6875rem; font-weight: 700; color: var(--brand); background: var(--brand-soft); }
.edu-school { margin-top: 0.75rem; font-size: 1.125rem; font-weight: 700; }
@media (min-width: 768px) { .edu-school { font-size: 1.25rem; } }
.edu-grade { margin-top: 0.25rem; font-size: 0.875rem; font-weight: 600; color: var(--brand-muted); }
.edu-desc { margin-top: 0.75rem; font-size: 0.875rem; color: var(--text-muted); }
.edu-achievements { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--hairline); }
.edu-achievement { display: inline-flex; align-items: center; gap: 0.25rem; padding: 0.25rem 0.625rem; border-radius: 999px; font-size: 0.6875rem; font-weight: 500; color: var(--text-muted); border: 1px solid var(--hairline); background: var(--surface); }
.edu-achievement svg { width: 0.75rem; height: 0.75rem; color: var(--brand); }

/* ---------- Contact ---------- */
.contact-grid { display: grid; gap: 0.75rem; }
@media (min-width: 640px) { .contact-grid { grid-template-columns: repeat(2, 1fr); gap: 1rem; } }
.contact-card {
  display: flex; align-items: center; gap: 1rem;
  padding: 1.25rem; border-radius: 1rem;
  border: 1px solid var(--hairline); background: var(--surface);
  backdrop-filter: blur(8px); position: relative; overflow: hidden;
  transition: transform 0.4s, border-color 0.4s, box-shadow 0.4s;
}
.contact-card:hover { transform: translateY(-4px); border-color: var(--contact-color); box-shadow: 0 12px 30px -8px var(--contact-color); }
.contact-icon {
  width: 3rem; height: 3rem; flex-shrink: 0; display: grid; place-items: center;
  border-radius: 1rem; color: var(--contact-color);
  background: color-mix(in srgb, var(--contact-color) 12%, transparent);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--contact-color) 25%, transparent);
  transition: transform 0.5s;
}
.contact-card:hover .contact-icon { transform: scale(1.1); }
.contact-icon svg { width: 1.5rem; height: 1.5rem; }
.contact-info { flex: 1; min-width: 0; }
.contact-label { font-size: 0.6875rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-muted); }
.contact-value { font-size: 0.875rem; font-weight: 700; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (min-width: 768px) { .contact-value { font-size: 1rem; } }
.copy-btn {
  width: 2.25rem; height: 2.25rem; flex-shrink: 0; display: grid; place-items: center;
  border-radius: 999px; border: 1px solid var(--hairline); background: var(--surface);
  color: var(--text-muted); transition: all 0.3s;
}
.copy-btn:hover { border-color: var(--brand); color: var(--brand); }
.copy-btn svg { width: 1rem; height: 1rem; }
.copy-btn.copied { color: #34d399; border-color: #34d399; }

.contact-cta {
  margin-top: 2rem; padding: 1.5rem; text-align: center;
  border-radius: 1.5rem; border: 1px solid var(--brand-soft);
  background: linear-gradient(135deg, var(--brand-soft), transparent, var(--brand-soft));
  display: flex; flex-direction: column; align-items: center; gap: 0.75rem;
}
@media (min-width: 768px) { .contact-cta { padding: 2rem; } }
.contact-cta svg { width: 1.75rem; height: 1.75rem; color: var(--brand); }
.contact-cta p { max-width: 28rem; font-size: 0.875rem; color: var(--text-muted); }
@media (min-width: 768px) { .contact-cta p { font-size: 1rem; } }
.contact-cta-btns { display: flex; flex-direction: column; gap: 0.5rem; }
@media (min-width: 640px) { .contact-cta-btns { flex-direction: row; } }

/* ---------- Footer ---------- */
.footer { margin-top: auto; border-top: 1px solid var(--hairline); background: var(--surface); backdrop-filter: blur(16px); }
.footer-inner { max-width: 72rem; margin: 0 auto; padding: 2.5rem 1rem 7rem; display: flex; flex-direction: column; align-items: center; gap: 1.5rem; text-align: center; }
@media (min-width: 1024px) { .footer-inner { padding-bottom: 3rem; } }
.footer-logo { display: flex; align-items: center; gap: 0.5rem; }
.footer-name { font-size: 1.25rem; font-weight: 800; background: linear-gradient(120deg, #fff, var(--brand-muted), #fff); background-size: 200% 100%; -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; animation: textShine 6s linear infinite; }
.light .footer-name { background: linear-gradient(120deg, #2e1065, var(--brand), #2e1065); background-size: 200% 100%; -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.footer-tagline { max-width: 28rem; font-size: 0.875rem; color: var(--text-muted); }
.footer-divider { height: 1px; width: 100%; max-width: 28rem; background: linear-gradient(90deg, transparent, var(--hairline-2), transparent); }
.footer-bottom { display: flex; flex-direction: column; gap: 0.75rem; font-size: 0.75rem; color: var(--text-muted); }
@media (min-width: 640px) { .footer-bottom { flex-direction: row; justify-content: space-between; width: 100%; max-width: 36rem; font-size: 0.875rem; } }
.footer-built { display: inline-flex; align-items: center; gap: 0.25rem; }
.footer-built::after { content: "❤"; color: #ec4899; }

/* ---------- Back to top ---------- */
.back-to-top {
  position: fixed; bottom: 6rem; right: 1rem; z-index: 45;
  width: 2.75rem; height: 2.75rem; display: grid; place-items: center;
  border-radius: 999px; border: 1px solid var(--hairline);
  background: var(--surface-glass); backdrop-filter: blur(16px); color: var(--text);
  opacity: 0; pointer-events: none; transform: translateY(10px);
  transition: all 0.3s;
}
@media (min-width: 1024px) { .back-to-top { bottom: 1.5rem; right: 1.5rem; } }
.back-to-top.visible { opacity: 1; pointer-events: auto; transform: translateY(0); }
.back-to-top:hover { border-color: var(--brand); color: var(--brand); box-shadow: 0 8px 24px var(--brand-glow); }
.back-to-top svg { width: 1.25rem; height: 1.25rem; transition: transform 0.3s; }
.back-to-top:hover svg { transform: translateY(-2px); }

/* ---------- Bottom nav (mobile) ---------- */
.bottomnav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
  display: flex; justify-content: space-between; gap: 0.125rem;
  margin: 0 auto 0.5rem; max-width: 28rem;
  padding: 0.375rem;
  border-radius: 1rem;
  background: rgba(10, 8, 20, 0.7); backdrop-filter: blur(24px) saturate(160%);
  border: 1px solid var(--hairline);
  margin-left: 0.75rem; margin-right: 0.75rem;
  padding-bottom: max(0.375rem, env(safe-area-inset-bottom));
}
@media (min-width: 1024px) { .bottomnav { display: none; } }
.bn-item {
  flex: 1; display: flex; flex-direction: column; align-items: center; gap: 0.125rem;
  padding: 0.375rem 0.25rem; border-radius: 0.75rem;
  font-size: 0.625rem; font-weight: 500; color: var(--text-muted);
  transition: color 0.3s; position: relative;
}
.bn-item svg { width: 1.125rem; height: 1.125rem; transition: transform 0.3s; }
.bn-item.active { color: var(--text); }
.bn-item.active svg { color: var(--brand); transform: scale(1.1); filter: drop-shadow(0 0 8px var(--brand-glow)); }
.bn-item.active::before { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; background: var(--brand-soft); box-shadow: inset 0 0 0 1px var(--brand-soft); }

/* ---------- Toast ---------- */
.toast {
  position: fixed; top: 1rem; left: 50%; transform: translateX(-50%) translateY(-100px);
  z-index: 200; padding: 0.75rem 1.25rem; border-radius: 999px;
  background: var(--surface-glass); backdrop-filter: blur(16px);
  border: 1px solid var(--hairline-2); color: var(--text);
  font-size: 0.875rem; font-weight: 600;
  box-shadow: 0 8px 30px rgba(0,0,0,0.3);
  opacity: 0; transition: all 0.3s; pointer-events: none;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---------- Reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.6s cubic-bezier(0.16,1,0.3,1), transform 0.6s cubic-bezier(0.16,1,0.3,1); }
.reveal.in { opacity: 1; transform: translateY(0); }

/* ---------- RTL ---------- */
[dir="rtl"] .scroll-cue { direction: ltr; }
[dir="rtl"] .project-badge { right: auto; left: 0.75rem; }
[dir="rtl"] .contact-card { flex-direction: row-reverse; text-align: right; }
[dir="rtl"] .contact-info { text-align: right; }
[dir="rtl"] .info-card { text-align: right; }
[dir="rtl"] .timeline::before { left: auto; right: 1.375rem; }
[dir="rtl"] .edu-item { padding-left: 0; padding-right: 3.5rem; }
@media (min-width: 640px) { [dir="rtl"] .edu-item { padding-right: 4rem; } }
[dir="rtl"] .edu-node { left: auto; right: 0; }
[dir="rtl"] .skill-card { direction: rtl; }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}
