/* ============================================================
   style.css — Divya Singh Personal Landing Page
   Aesthetic: Neo-Tokyo editorial / glassmorphism
   Fonts: Syne (display) + JetBrains Mono (accent)
   ============================================================ */


/* ── 1. CSS CUSTOM PROPERTIES (Design Tokens) ── */
:root {
  /* Dark theme (default) */
  --bg:           #080810;
  --bg-card:      rgba(11, 11, 28, 0.80);
  --border:       rgba(56, 217, 245, 0.14);
  --text:         #dde3f0;
  --text-muted:   #5a6380;
  --accent-1:     #38d9f5;   /* electric cyan   */
  --accent-2:     #a855f7;   /* violet          */
  --accent-3:     #f472b6;   /* pink            */
  --accent-4:     #facc15;   /* amber (Twitter) */
  --chip-bg:      rgba(56, 217, 245, 0.07);
  --chip-border:  rgba(56, 217, 245, 0.22);
  --mark-bg:      rgba(168, 85, 247, 0.16);
  --mark-color:   #c084fc;
  --shadow:       0 32px 80px rgba(0, 0, 0, 0.65);
  --card-blur:    blur(22px);
  --radius:       22px;
  --transition:   0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Light theme overrides */
[data-theme="light"] {
  --bg:           #eef2ff;
  --bg-card:      rgba(255, 255, 255, 0.72);
  --border:       rgba(99, 102, 241, 0.18);
  --text:         #1e1b4b;
  --text-muted:   #6366f1;
  --accent-1:     #4f46e5;
  --accent-2:     #7c3aed;
  --accent-3:     #db2777;
  --accent-4:     #d97706;
  --chip-bg:      rgba(79, 70, 229, 0.08);
  --chip-border:  rgba(79, 70, 229, 0.25);
  --mark-bg:      rgba(124, 58, 237, 0.12);
  --mark-color:   #7c3aed;
  --shadow:       0 24px 60px rgba(79, 70, 229, 0.12);
  --card-blur:    blur(18px);
}


/* ── 2. RESET & BASE ── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

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

body {
  font-family: 'Syne', sans-serif;
  background-color: var(--bg);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow-x: hidden;
  /* Smooth theme transition */
  transition: background-color 0.4s ease, color 0.4s ease;
}

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

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


/* ── 3. BACKGROUND CANVAS ── */
#grid-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  opacity: 0.45;
  pointer-events: none;
}


/* ── 4. THEME TOGGLE ── */
.theme-toggle {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 100;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--bg-card);
  backdrop-filter: var(--card-blur);
  color: var(--accent-1);
  font-size: 1rem;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: var(--transition);
  box-shadow: 0 0 0 0 transparent;
}

.theme-toggle:hover {
  border-color: var(--accent-1);
  box-shadow: 0 0 16px rgba(56, 217, 245, 0.35);
  transform: rotate(20deg);
}


/* ── 5. PAGE WRAPPER ── */
.page-wrapper {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 520px;
  padding: 32px 16px 48px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;

  /* Entrance animation */
  animation: fadeUp 0.8s cubic-bezier(0.22, 1, 0.36, 1) both;
}

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


/* ── 6. CARD (Glassmorphism) ── */
.card {
  position: relative;
  width: 100%;
  background: var(--bg-card);
  backdrop-filter: var(--card-blur);
  -webkit-backdrop-filter: var(--card-blur);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 48px 40px 44px;
  display: flex;
  flex-direction: column;
  gap: 36px;
  transition: background 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
}

/* Geometric corner decorations */
.corner {
  position: absolute;
  width: 12px;
  height: 12px;
  border-color: var(--accent-1);
  border-style: solid;
  opacity: 0.7;
  transition: opacity var(--transition);
}
.card:hover .corner { opacity: 1; }

.corner.tl { top: 10px; left: 10px;  border-width: 2px 0 0 2px; border-radius: 3px 0 0 0; }
.corner.tr { top: 10px; right: 10px; border-width: 2px 2px 0 0; border-radius: 0 3px 0 0; }
.corner.bl { bottom: 10px; left: 10px;  border-width: 0 0 2px 2px; border-radius: 0 0 0 3px; }
.corner.br { bottom: 10px; right: 10px; border-width: 0 2px 2px 0; border-radius: 0 0 3px 0; }


/* ── 7. HERO SECTION ── */
.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  text-align: center;
}

/* Avatar with animated glowing ring */
.avatar-ring {
  position: relative;
  width: 110px;
  height: 110px;
  border-radius: 50%;
  /* Rotating gradient ring */
  background: conic-gradient(
    from 0deg,
    var(--accent-1),
    var(--accent-2),
    var(--accent-3),
    var(--accent-1)
  );
  padding: 3px;
  animation: spinRing 6s linear infinite;
}

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

.avatar-wrap {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  overflow: hidden;
  background: var(--bg);
  /* Counter-rotate so avatar stays upright */
  animation: counterSpin 6s linear infinite;
}

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

.avatar {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

/* Name heading */
.name {
  font-family: 'Syne', sans-serif;
  font-size: clamp(1.9rem, 6vw, 2.6rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text);
  line-height: 1.1;
}

/* Tagline with typing effect */
.tagline {
  font-family: 'JetBrains Mono', monospace;
  font-size: clamp(0.7rem, 2.5vw, 0.85rem);
  font-weight: 400;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
  justify-content: center;
}

.bracket {
  color: var(--accent-1);
  font-weight: 500;
  font-size: 1.1em;
}

/* Blinking cursor for typing effect */
.cursor-blink {
  color: var(--accent-1);
  animation: blink 0.9s step-end infinite;
  font-weight: 300;
}
@keyframes blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0; }
}

/* Status badge ("Open to opportunities") */
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  color: var(--accent-1);
  background: rgba(56, 217, 245, 0.08);
  border: 1px solid rgba(56, 217, 245, 0.22);
  border-radius: 100px;
  padding: 6px 14px;
  margin-top: 4px;
}

/* Pulsing green dot */
.pulse-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.5);
  animation: pulseGlow 2s ease-out infinite;
  flex-shrink: 0;
}
@keyframes pulseGlow {
  0%   { box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.6); }
  70%  { box-shadow: 0 0 0 8px rgba(74, 222, 128, 0); }
  100% { box-shadow: 0 0 0 0 rgba(74, 222, 128, 0); }
}


/* ── 8. SECTION LABEL ── */
.section-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  color: var(--accent-2);
  margin-bottom: 16px;
  text-transform: uppercase;
}


/* ── 9. SOCIAL SECTION ── */
.social-section {
  display: flex;
  flex-direction: column;
}

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

/* Social button base */
.social-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 18px;
  border-radius: 12px;
  font-family: 'Syne', sans-serif;
  font-size: 0.88rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: var(--transition);
}

/* The arrow that slides in on hover */
.btn-arrow {
  margin-left: auto;
  font-size: 0.9rem;
  opacity: 0;
  transform: translate(-4px, 4px);
  transition: var(--transition);
}

/* Icon sizing */
.social-btn i {
  font-size: 1.05rem;
  flex-shrink: 0;
  transition: transform var(--transition);
}

/* Generic hover: lift + glow border */
.social-btn:hover {
  transform: translateY(-3px);
}
.social-btn:hover .btn-arrow {
  opacity: 1;
  transform: translate(0, 0);
}
.social-btn:hover i {
  transform: scale(1.15);
}

/* Ripple-like pseudo-element glow */
.social-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity var(--transition);
  border-radius: inherit;
}
.social-btn:hover::before { opacity: 1; }

/* ── Per-platform accent colors ── */

/* GitHub */
.social-btn.github:hover {
  border-color: #e2e8f0;
  box-shadow: 0 0 20px rgba(226, 232, 240, 0.18);
  color: #e2e8f0;
}
.social-btn.github::before {
  background: radial-gradient(circle at top left, rgba(226, 232, 240, 0.06), transparent 70%);
}

/* LinkedIn */
.social-btn.linkedin:hover {
  border-color: #0ea5e9;
  box-shadow: 0 0 20px rgba(14, 165, 233, 0.25);
  color: #38bdf8;
}
.social-btn.linkedin::before {
  background: radial-gradient(circle at top left, rgba(14, 165, 233, 0.08), transparent 70%);
}

/* Instagram */
.social-btn.instagram:hover {
  border-color: #f472b6;
  box-shadow: 0 0 20px rgba(244, 114, 182, 0.25);
  color: #f9a8d4;
}
.social-btn.instagram::before {
  background: radial-gradient(circle at top left, rgba(244, 114, 182, 0.08), transparent 70%);
}

/* Twitter / X */
.social-btn.twitter:hover {
  border-color: #94a3b8;
  box-shadow: 0 0 20px rgba(148, 163, 184, 0.2);
  color: #cbd5e1;
}
.social-btn.twitter::before {
  background: radial-gradient(circle at top left, rgba(148, 163, 184, 0.06), transparent 70%);
}


/* ── 10. DIVIDER ── */
.divider {
  display: flex;
  align-items: center;
  gap: 14px;
  color: var(--text-muted);
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.65rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.divider::before,
.divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}


/* ── 11. ABOUT SECTION ── */
.about-section {
  display: flex;
  flex-direction: column;
}

.about-text {
  font-family: 'Syne', sans-serif;
  font-size: 0.92rem;
  line-height: 1.8;
  color: var(--text);
  opacity: 0.88;
}

/* Keyword highlight */
mark {
  background: var(--mark-bg);
  color: var(--mark-color);
  padding: 1px 5px;
  border-radius: 4px;
  font-weight: 600;
}

/* Skill chips row */
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
}

.chip {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  color: var(--accent-1);
  background: var(--chip-bg);
  border: 1px solid var(--chip-border);
  border-radius: 100px;
  padding: 5px 12px;
  cursor: default;
  transition: var(--transition);
}

.chip:hover {
  background: rgba(56, 217, 245, 0.14);
  box-shadow: 0 0 10px rgba(56, 217, 245, 0.2);
  transform: translateY(-1px);
}


/* ── 12. FOOTER ── */
.footer {
  margin-top: 24px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  text-align: center;
}

.heart {
  display: inline-block;
  animation: heartbeat 1.4s ease-in-out infinite;
}

@keyframes heartbeat {
  0%, 100% { transform: scale(1); }
  14%       { transform: scale(1.25); }
  28%       { transform: scale(1); }
  42%       { transform: scale(1.15); }
  56%       { transform: scale(1); }
}


/* ── 13. RESPONSIVE (Mobile) ── */
@media (max-width: 480px) {
  .card {
    padding: 36px 24px 36px;
    gap: 28px;
  }

  .social-grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .social-btn {
    padding: 12px 13px;
    font-size: 0.82rem;
    gap: 8px;
  }

  /* Hide arrow text on small screens to save space */
  .btn-arrow { display: none; }
}

@media (max-width: 360px) {
  .social-grid {
    grid-template-columns: 1fr;
  }
}


/* ── 14. STAGGERED ENTRANCE (children of card) ── */
.hero,
.social-section,
.divider,
.about-section {
  animation: fadeUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.hero           { animation-delay: 0.10s; }
.social-section { animation-delay: 0.22s; }
.divider        { animation-delay: 0.32s; }
.about-section  { animation-delay: 0.40s; }
