/* Base */
:root {
  --bg: #0b0d10;
  --text: #eef2f6;
  --muted: #b7c0cc;
  --accent: #5ad6ff;
  --accent-2: #a07cff;
  --card: rgba(255, 255, 255, 0.06);
  --border: rgba(255, 255, 255, 0.18);
  --glass: rgba(255, 255, 255, 0.08);
  --shadow: rgba(0, 0, 0, 0.45);
}

* { box-sizing: border-box; }

html, body {
  padding: 0;
  margin: 0;
  background: radial-gradient(1200px 800px at 10% 10%, #0f1220 0%, var(--bg) 55%),
              radial-gradient(900px 600px at 90% 20%, #0f1422 0%, #0b0d10 60%);
  color: var(--text);
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, 'Helvetica Neue', Arial, 'Noto Sans', 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', 'Noto Color Emoji', sans-serif;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.page {
  max-width: 980px;
  padding: 6vh 20px 12vh;
  margin: 0 auto;
}

/* Background ornaments */
.background { position: fixed; inset: 0; overflow: hidden; pointer-events: none; }
.blob {
  position: absolute;
  filter: blur(60px);
  opacity: 0.55;
  transform: translateZ(0);
}
.blob-1 { width: 520px; height: 520px; left: -120px; top: -120px; background: radial-gradient(circle at 30% 30%, #5ad6ff, transparent 60%); }
.blob-2 { width: 480px; height: 480px; right: -140px; top: 80px; background: radial-gradient(circle at 70% 40%, #a07cff, transparent 60%); }
.blob-3 { width: 560px; height: 560px; left: 40%; bottom: -200px; background: radial-gradient(circle at 50% 50%, #34e0a1, transparent 60%); opacity: .35; }
.grain {
  position: absolute; inset: -100px; background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="140" height="140" viewBox="0 0 140 140"><filter id="n"><feTurbulence type="fractalNoise" baseFrequency="0.65" numOctaves="3" stitchTiles="stitch"/></filter><rect width="100%" height="100%" filter="url(%23n)" opacity="0.05"/></svg>');
  mix-blend-mode: overlay;
}

/* Cards */
.glass-card {
  background: linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.04));
  border: 1px solid var(--border);
  border-radius: 18px;
  backdrop-filter: saturate(160%) blur(18px);
  -webkit-backdrop-filter: saturate(160%) blur(18px);
  box-shadow: 0 8px 24px var(--shadow), inset 0 1px 0 rgba(255,255,255,0.08);
}

.header .identity {
  padding: 28px 28px 26px;
  position: relative;
}

.name {
  font-family: 'Sora', 'Inter', system-ui, sans-serif;
  font-size: clamp(28px, 5vw, 46px);
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 0 0 8px 0;
}

.tagline {
  margin: 0 0 8px 0;
  color: var(--muted);
  font-weight: 500;
}

.location { margin: 0; opacity: .9; }

.divider {
  height: 1px;
  width: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.22), transparent);
  margin: 28px 0 18px;
}

/* Header hero with avatar */
.hero {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 18px;
  align-items: center;
}

.avatar-wrap { position: relative; display: inline-block; }

/* Full-avatar animated glow when talking */
.avatar { position: relative; display: block; }
.avatar-base { position: relative; z-index: 1; }
.avatar-alt {
  position: absolute;
  left: 0; top: 0; right: 0; bottom: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  border-radius: 18px;
  opacity: 0;
  z-index: 1;
  transition: opacity .35s ease;
  border: 1px solid var(--border);
}

.avatar-wrap.talking .avatar-alt { opacity: 1; }
.avatar-wrap.talking .avatar-base { opacity: 0; transition: opacity .35s ease; }

.avatar-wrap::before,
.avatar-wrap::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 18px;
  pointer-events: none;
  opacity: 0;
  z-index: 2;
  transition: opacity .25s ease;
}

/* Outer halo */
.avatar-wrap::before {
  inset: -6%;
  border-radius: 22px;
  background: radial-gradient(70% 70% at 50% 50%, rgba(90,214,255,0.28), rgba(160,124,255,0.18) 50%, transparent 72%);
  filter: blur(18px) saturate(140%);
}

/* On-image gradient sweep */
.avatar-wrap::after {
  background:
    radial-gradient(120% 120% at -10% -10%, rgba(90,214,255,0.28) 0%, transparent 45%),
    radial-gradient(120% 120% at 110% 110%, rgba(160,124,255,0.28) 0%, transparent 45%),
    linear-gradient(135deg, rgba(255,255,255,0.16) 0%, rgba(255,255,255,0.0) 40%, rgba(255,255,255,0.16) 60%, rgba(255,255,255,0.0) 100%);
  mix-blend-mode: screen;
  filter: saturate(140%);
  background-size: 140% 140%, 140% 140%, 220% 220%;
  background-position: 0% 0%, 100% 100%, 0% 0%;
}

.avatar-wrap.talking::before,
.avatar-wrap.talking::after { opacity: 1; }

@media (prefers-reduced-motion: no-preference) {
  .avatar-wrap.talking::after { animation: sweepGlow 3s ease-in-out infinite; }
  .avatar-wrap.talking::before { animation: haloPulse 2.6s ease-in-out infinite; }
}

@keyframes sweepGlow {
  0%   { background-position: 0% 0%, 100% 100%,   0%   0%; }
  50%  { background-position: 30% 30%, 70%  70%, 100% 100%; }
  100% { background-position: 0% 0%, 100% 100%, 200% 200%; }
}

@keyframes haloPulse {
  0%, 100% { transform: scale(0.98); opacity: .75; }
  50%      { transform: scale(1.02); opacity: 1; }
}

.avatar {
  width: clamp(144px, 28vw, 220px);
  height: clamp(144px, 28vw, 220px);
  border-radius: 18px;
  object-fit: cover;
  border: 1px solid var(--border);
  box-shadow: 0 8px 22px var(--shadow), inset 0 1px 0 rgba(255,255,255,0.08);
  background: linear-gradient(180deg, rgba(255,255,255,0.06), rgba(255,255,255,0.03));
}

.hero-text { min-width: 0; }

/* Top-right LinkedIn button */
.identity-actions {
  position: absolute;
  right: 16px;
  top: 16px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 14px;
  letter-spacing: 0.02em;
  color: #0b0d10;
  background: linear-gradient(180deg, #e7f6ff, #c8eaff);
  border: 1px solid rgba(255,255,255,0.6);
  box-shadow: 0 6px 18px rgba(90, 214, 255, 0.35);
  transition: transform .16s ease, box-shadow .2s ease, background .2s ease;
}

.btn:hover { transform: translateY(-1px); box-shadow: 0 10px 26px rgba(90,214,255,.45); }
.btn:active { transform: translateY(0); box-shadow: 0 4px 14px rgba(90,214,255,.35); }

.linkedin-btn { background: linear-gradient(180deg, #e7f3ff, #cfe2ff); box-shadow: 0 6px 18px rgba(160,124,255,0.28); }
.linkedin-btn:hover { box-shadow: 0 10px 26px rgba(160,124,255,0.4); }

@media (max-width: 480px) {
  .identity-actions { position: static; margin-bottom: 10px; }
  .hero { grid-template-columns: 1fr; }
  .avatar { width: 176px; height: 176px; }
}

/* Speak button overlay */
.speak-btn {
  position: absolute;
  left: 50%;
  bottom: -12px;
  transform: translateX(-50%);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.02em;
  color: #e8edf5;
  background: linear-gradient(180deg, rgba(22,26,34,0.82), rgba(12,16,23,0.78));
  border: 1px solid rgba(255,255,255,0.14);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.06), 0 8px 22px rgba(0,0,0,0.45);
  backdrop-filter: saturate(150%) blur(10px);
  -webkit-backdrop-filter: saturate(150%) blur(10px);
  cursor: pointer;
  transition: transform .16s ease, box-shadow .2s ease, background .2s ease;
  z-index: 3;
  /* progress ring variable: 0..1 */
  --progress: 0;
  overflow: hidden;
}

/* In-button progress fill */
.speak-btn::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.22), rgba(255,255,255,0.12))
    left/ calc(var(--progress) * 100%) 100% no-repeat;
  mix-blend-mode: screen;
  opacity: .85;
  z-index: 0;
}

/* Ensure button contents are above the fill */
.speak-btn .bars,
.speak-btn .label { position: relative; z-index: 1; }

.speak-btn:hover { transform: translateX(-50%) translateY(-1px); box-shadow: inset 0 1px 0 rgba(255,255,255,0.08), 0 14px 28px rgba(0,0,0,0.55), 0 0 0 2px rgba(160,124,255,0.2); }
.speak-btn:active { transform: translateX(-50%) translateY(0); box-shadow: inset 0 1px 0 rgba(255,255,255,0.06), 0 6px 16px rgba(0,0,0,0.5), 0 0 0 2px rgba(90,214,255,0.18); }

.speak-btn .bars { display: inline-flex; align-items: flex-end; gap: 3px; height: 12px; }
.speak-btn .bars i { width: 2px; height: 6px; background: #cfe2ff; border-radius: 2px; opacity: .95; }

@media (prefers-reduced-motion: no-preference) {
  .speak-btn.playing .bars i:nth-child(1) { animation: bar 0.6s ease-in-out infinite; }
  .speak-btn.playing .bars i:nth-child(2) { animation: bar 0.6s ease-in-out .15s infinite; }
  .speak-btn.playing .bars i:nth-child(3) { animation: bar 0.6s ease-in-out .3s infinite; }
}

@keyframes bar {
  0%, 100% { height: 4px; }
  50% { height: 12px; }
}

.section-title {
  font-family: 'Sora', 'Inter', system-ui, sans-serif;
  font-size: clamp(16px, 2.6vw, 18px);
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #dbe6f7;
  margin: 0 0 12px 2px;
}

.content { padding: 20px 24px; }

.content p { margin: 0; color: #e8edf5; }

.skills,
.availability {
  display: grid;
  grid-template-columns: repeat(1, minmax(0, 1fr));
  gap: 10px 18px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.skills li,
.availability li { color: #e8edf5; }

.experience {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.exp-item { padding: 18px 24px; }

.exp-role {
  margin: 0 0 10px 0;
  font-size: 18px;
}

.exp-dates { color: var(--muted); font-weight: 500; }

.footer { opacity: .8; text-align: center; margin-top: 40px; }

/* Links and accents */
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-2); }

/* Responsive */
@media (min-width: 640px) {
  .skills, .availability { grid-template-columns: repeat(2, minmax(0,1fr)); }
}

@media (min-width: 900px) {
  .experience { grid-template-columns: 1fr 1fr; }
}

/* Motion preferences */
@media (prefers-reduced-motion: no-preference) {
  .blob-1 { animation: float1 22s ease-in-out infinite; }
  .blob-2 { animation: float2 26s ease-in-out infinite; }
  .blob-3 { animation: float3 28s ease-in-out infinite; }
}

@keyframes float1 {
  0% { transform: translate(0,0) scale(1); }
  50% { transform: translate(20px, -10px) scale(1.06); }
  100% { transform: translate(0,0) scale(1); }
}
@keyframes float2 {
  0% { transform: translate(0,0) scale(1); }
  50% { transform: translate(-16px, 14px) scale(1.08); }
  100% { transform: translate(0,0) scale(1); }
}
@keyframes float3 {
  0% { transform: translate(0,0) scale(1); }
  50% { transform: translate(12px, -20px) scale(1.05); }
  100% { transform: translate(0,0) scale(1); }
}


