/* =====================================================================
   IYAJ UDDIN PAROSH — PORTFOLIO STYLES
   Plain CSS, organised by section. Colors and spacing come from the
   CSS variables in :root below, so the whole theme can be tweaked
   from one place.
===================================================================== */

/* ---------------------------------------------------------------------
   1. VARIABLES & RESET
--------------------------------------------------------------------- */
:root {
  /* Brand colors */
  --bg: #0b1120;
  --bg-soft: #0f172a;
  --primary: #38bdf8;
  --secondary: #8b5cf6;
  --accent: #10b981;

  /* Text colors */
  --text: #e2e8f0;
  --text-muted: #94a3b8;

  /* Glass / card surfaces */
  --glass-bg: rgba(148, 163, 184, 0.06);
  --glass-border: rgba(148, 163, 184, 0.14);

  /* Fonts */
  --font-display: "Space Grotesk", sans-serif;
  --font-body: "Inter", sans-serif;
  --font-mono: "JetBrains Mono", monospace;

  /* Layout */
  --container-width: 1140px;
  --radius: 16px;
  --transition: all 0.3s ease;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.65;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.2;
  color: #ffffff;
}

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

ul {
  list-style: none;
}

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

.container {
  width: 90%;
  max-width: var(--container-width);
  margin: 0 auto;
}

/* Respect users who prefer less motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

/* Custom scrollbar (purely visual) */
::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: #1e293b; border-radius: 8px; }
::-webkit-scrollbar-thumb:hover { background: #334155; }

/* ---------------------------------------------------------------------
   2. REUSABLE HELPERS (glass cards, gradient text, buttons, tags)
--------------------------------------------------------------------- */
.glass {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: var(--radius);
}

.gradient-text {
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--primary);
  opacity: 0.85;
  margin-bottom: 0.75rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 24px;
  border-radius: 12px;
  font-weight: 500;
  font-size: 0.95rem;
  cursor: pointer;
  transition: var(--transition);
  border: 1px solid transparent;
}

.btn-primary {
  background: var(--primary);
  color: var(--bg);
  box-shadow: 0 0 30px rgba(56, 189, 248, 0.25);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 40px rgba(56, 189, 248, 0.4);
}

.btn-outline {
  border-color: var(--glass-border);
  color: var(--text);
}

.btn-outline:hover {
  border-color: var(--primary);
  background: rgba(56, 189, 248, 0.08);
  transform: translateY(-2px);
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.tag {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  padding: 6px 12px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--glass-border);
  color: var(--text-muted);
  transition: var(--transition);
}

.tag:hover {
  color: var(--primary);
  border-color: rgba(56, 189, 248, 0.4);
}

.tag-accent {
  color: var(--accent);
  border-color: rgba(16, 185, 129, 0.3);
}

/* Grid layouts used across several sections */
.grid {
  display: grid;
  gap: 24px;
}
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-5 { grid-template-columns: repeat(5, 1fr); }

@media (max-width: 900px) {
  .grid-3, .grid-4, .grid-5 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .grid-2, .grid-3, .grid-4, .grid-5 { grid-template-columns: 1fr; }
}

/* Generic card used in Focus / Skills / Projects / Goals etc. */
.card {
  padding: 28px;
  transition: var(--transition);
}

.card:hover {
  transform: translateY(-6px);
  border-color: rgba(56, 189, 248, 0.35);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3);
}

.card-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  color: var(--primary);
  background: rgba(56, 189, 248, 0.1);
  margin-bottom: 16px;
}

.card h3 {
  font-size: 1.05rem;
  margin-bottom: 10px;
}

.card h3 i {
  color: var(--primary);
  margin-right: 8px;
}

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

/* ---------------------------------------------------------------------
   3. PAGE LOADER
--------------------------------------------------------------------- */
#page-loader {
  position: fixed;
  inset: 0;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

#page-loader.loaded {
  opacity: 0;
  visibility: hidden;
}

.loader-mark {
  font-family: var(--font-mono);
  font-size: 1.5rem;
  color: var(--primary);
  border: 2px solid var(--primary);
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: pulse 1.1s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.12); opacity: 0.6; }
}

/* ---------------------------------------------------------------------
   4. SCROLL PROGRESS BAR
--------------------------------------------------------------------- */
#scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0%;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  z-index: 1001;
  transition: width 0.1s ease-out;
}

/* ---------------------------------------------------------------------
   5. NAVBAR
--------------------------------------------------------------------- */
#navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  padding: 16px 0;
  background: rgba(11, 17, 32, 0.7);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: var(--transition);
}

#navbar.scrolled {
  border-bottom-color: var(--glass-border);
  padding: 10px 0;
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.15rem;
  color: #ffffff;
}

.logo i {
  color: var(--primary);
}

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

.nav-links {
  display: flex;
  gap: 6px;
}

.nav-link {
  font-size: 0.85rem;
  padding: 8px 12px;
  border-radius: 8px;
  color: var(--text-muted);
  transition: var(--transition);
}

.nav-link:hover {
  color: var(--primary);
}

.nav-link.active {
  color: var(--primary);
  background: rgba(56, 189, 248, 0.08);
}

#mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  color: var(--text);
  font-size: 1.4rem;
  cursor: pointer;
}

/* Mobile navigation */
@media (max-width: 900px) {
  .nav-links {
    position: fixed;
    top: 64px;
    right: 0;
    width: 70%;
    max-width: 320px;
    height: calc(100vh - 64px);
    background: var(--bg-soft);
    border-left: 1px solid var(--glass-border);
    flex-direction: column;
    padding: 24px;
    gap: 4px;
    transform: translateX(100%);
    transition: transform 0.35s ease;
  }

  .nav-links.open {
    transform: translateX(0);
  }

  .nav-link {
    padding: 14px 12px;
    width: 100%;
  }

  #mobile-menu-btn {
    display: block;
  }
}

/* ---------------------------------------------------------------------
   6. HERO
--------------------------------------------------------------------- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 90px;
  overflow: hidden;
}

#network-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  opacity: 0.5;
}

.hero-glow {
  position: absolute;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  filter: blur(110px);
  z-index: 0;
  pointer-events: none;
}

.hero-glow-1 {
  background: rgba(56, 189, 248, 0.22);
  top: -80px;
  left: -80px;
}

.hero-glow-2 {
  background: rgba(139, 92, 246, 0.2);
  bottom: -100px;
  right: -60px;
}

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

.hero-text {
  max-width: 720px;
}

.hero-name {
  font-size: clamp(2.2rem, 5vw, 3.4rem);
  margin-bottom: 12px;
}

.hero-role {
  font-family: var(--font-mono);
  font-size: 0.95rem;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.dot-sep {
  color: var(--accent);
  margin: 0 4px;
}

.typing-line {
  font-family: var(--font-mono);
  font-size: 1.05rem;
  color: var(--primary);
  min-height: 1.6em;
  margin-bottom: 20px;
}

.cursor {
  display: inline-block;
  margin-left: 2px;
  animation: blink 1s step-end infinite;
  color: var(--accent);
}

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

.hero-desc {
  color: var(--text-muted);
  max-width: 560px;
  margin-bottom: 32px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 40px;
}

.hero-stats {
  display: flex;
  gap: 40px;
  flex-wrap: wrap;
}

.hero-stat {
  display: flex;
  flex-direction: column;
}

.stat-number {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 700;
  color: #ffffff;
}

.stat-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.scroll-cue {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  color: var(--text-muted);
  font-size: 1.1rem;
  animation: floatDown 1.8s ease-in-out infinite;
  z-index: 1;
}

@keyframes floatDown {
  0%, 100% { transform: translate(-50%, 0); }
  50% { transform: translate(-50%, 8px); }
}

/* ---------------------------------------------------------------------
   7. GENERIC SECTION LAYOUT
--------------------------------------------------------------------- */
.section {
  padding: 110px 0;
}

.section-heading {
  margin-bottom: 48px;
}

.section-heading h2 {
  font-size: clamp(1.8rem, 3.5vw, 2.4rem);
}

.section-intro {
  color: var(--text-muted);
  max-width: 620px;
  margin-bottom: 36px;
}

/* ---------------------------------------------------------------------
   8. ABOUT
--------------------------------------------------------------------- */
.about-card {
  padding: 36px;
}

.about-card p {
  color: var(--text-muted);
  margin-bottom: 16px;
}

.about-card p:last-child {
  margin-bottom: 0;
}

.about-card strong {
  color: var(--primary);
  font-weight: 600;
}

/* ---------------------------------------------------------------------
   9. EDUCATION (timeline)
--------------------------------------------------------------------- */
.timeline {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.timeline-item {
  padding: 26px 30px;
  border-left: 3px solid var(--primary);
}

.timeline-period {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--primary);
  margin-bottom: 8px;
}

.timeline-item h3 {
  font-size: 1.05rem;
  margin-bottom: 6px;
}

.timeline-place {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.timeline-place i {
  color: var(--secondary);
  margin-right: 6px;
}

.timeline-note {
  color: var(--accent);
  font-size: 0.9rem;
  margin-top: 4px;
}

/* ---------------------------------------------------------------------
   10. PROJECTS
--------------------------------------------------------------------- */
.project-card .card-icon {
  color: var(--secondary);
  background: rgba(139, 92, 246, 0.12);
}

.project-card-more {
  border-style: dashed;
  opacity: 0.85;
}

/* ---------------------------------------------------------------------
   11. RESEARCH INTERESTS
--------------------------------------------------------------------- */
.research-card {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.research-card .card-icon {
  margin-bottom: 14px;
}

.research-card h3 {
  margin-bottom: 0;
}

/* ---------------------------------------------------------------------
   12. LEARNING JOURNEY
--------------------------------------------------------------------- */
.learning-item {
  padding: 20px;
  text-align: center;
  font-size: 0.9rem;
  transition: var(--transition);
}

.learning-item i {
  color: var(--accent);
  margin-right: 8px;
}

.learning-item:hover {
  transform: translateY(-4px);
  border-color: rgba(16, 185, 129, 0.4);
}

/* ---------------------------------------------------------------------
   13. BOOKSHELF
--------------------------------------------------------------------- */
.bookshelf {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  align-items: flex-end;
  padding-bottom: 18px;
  position: relative;
}

.book {
  width: 120px;
  height: 170px;
  border-radius: 10px 10px 4px 4px;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.02));
  border: 1px solid var(--glass-border);
  border-top: 5px solid var(--book-color, var(--primary));
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 12px;
  padding: 16px 10px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.book i {
  font-size: 1.4rem;
  color: var(--book-color, var(--primary));
}

.book span {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.book:hover {
  transform: translateY(-10px) rotate(-2deg);
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.35);
}

.shelf-plank {
  width: 100%;
  height: 8px;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--primary), var(--secondary), var(--accent));
  opacity: 0.4;
  position: absolute;
  bottom: 0;
  left: 0;
}

/* ---------------------------------------------------------------------
   14. GOALS
--------------------------------------------------------------------- */
.goal-list li {
  color: var(--text-muted);
  padding: 10px 0;
  border-bottom: 1px solid var(--glass-border);
  font-size: 0.92rem;
}

.goal-list li:last-child {
  border-bottom: none;
}

/* ---------------------------------------------------------------------
   15. CONTACT
--------------------------------------------------------------------- */
.contact-card {
  padding: 40px;
}

.contact-intro {
  color: var(--text-muted);
  margin-bottom: 28px;
  max-width: 560px;
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

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

.contact-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  border-radius: 12px;
  border: 1px solid var(--glass-border);
  background: rgba(255, 255, 255, 0.02);
  color: var(--text);
  font-size: 0.9rem;
  transition: var(--transition);
}

.contact-item i {
  color: var(--primary);
  font-size: 1.1rem;
}

.contact-item:hover {
  border-color: rgba(56, 189, 248, 0.4);
  transform: translateY(-3px);
}

.contact-item-static:hover {
  transform: none;
  border-color: var(--glass-border);
}

/* ---------------------------------------------------------------------
   16. FOOTER
--------------------------------------------------------------------- */
#footer {
  border-top: 1px solid var(--glass-border);
  padding: 32px 0;
  text-align: center;
}

.footer-inner p {
  font-size: 0.9rem;
}

.footer-meta {
  color: var(--text-muted);
  font-size: 0.8rem;
  margin-top: 6px;
}

/* ---------------------------------------------------------------------
   17. BACK TO TOP BUTTON
--------------------------------------------------------------------- */
#back-to-top {
  position: fixed;
  bottom: 28px;
  right: 28px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: none;
  background: var(--primary);
  color: var(--bg);
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 20px rgba(56, 189, 248, 0.35);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: var(--transition);
  z-index: 900;
}

#back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

#back-to-top:hover {
  background: var(--secondary);
  color: #fff;
}
