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

/* =========================
   THEME VARIABLES
========================= */
:root {
  --bg: #f4f6f8;
  --text: #111;
  --muted: #666;
  --accent: #2563eb;

  --card-bg: rgba(255, 255, 255, 0.72);
  --border: rgba(0, 0, 0, 0.08);

  --blur: blur(18px);
  --radius: 16px;
}

[data-theme="dark"] {
  --bg: #0b0f19;
  --text: #f1f5f9;
  --muted: #9ca3af;
  --accent: #60a5fa;

  --card-bg: rgba(20, 25, 40, 0.65);
  --border: rgba(255, 255, 255, 0.12);
}

/* =========================
   BASE
========================= */
html,
body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100%;
}

body {
  line-height: 1.6;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* =========================
   WRAPPER / LAYOUT
========================= */
.wrapper {
  max-width: 1100px;
  margin: auto;
  padding: 32px 24px 48px;
}

.container {
  display: grid;
  gap: 28px;
}

/* =========================
   NAVIGATION
========================= */
nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 48px;
}

.nav-links a {
  margin-right: 18px;
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--muted);
}

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

.toggle {
  border: 1px solid var(--border);
  background: var(--card-bg);
  backdrop-filter: var(--blur);
  padding: 6px 12px;
  border-radius: 10px;
  cursor: pointer;
  font-size: 0.85rem;
}

/* =========================
   TYPOGRAPHY
========================= */
h1 {
  font-size: clamp(1.9rem, 3vw, 2.6rem);
  margin-bottom: 12px;
}

h2 {
  font-size: 1.2rem;
  margin-bottom: 8px;
}

p {
  color: var(--muted);
  margin-bottom: 14px;
}

strong {
  color: var(--text);
}

/* =========================
   CARDS (GLASS)
========================= */
.card {
  background: var(--card-bg);
  backdrop-filter: var(--blur);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
}

.glass {
  background: var(--card-bg);
  backdrop-filter: var(--blur);
}

/* =========================
   BUTTONS
========================= */
.btn {
  display: inline-block;
  margin-top: 14px;
  padding: 10px 16px;
  border-radius: 10px;
  background: var(--accent);
  color: #fff;
  font-weight: 500;
}

/* =========================
   TIMELINE (RESUME)
========================= */
.timeline {
  position: relative;
  margin-top: 36px;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 14px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--border);
}

.timeline-item {
  position: relative;
  padding-left: 48px;
  margin-bottom: 40px;
}

.timeline-dot {
  position: absolute;
  left: 6px;
  top: 18px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--accent);
}

.timeline-date {
  font-size: 0.85rem;
  color: var(--muted);
}

.role {
  font-weight: 600;
  margin: 6px 0;
}

.timeline ul {
  padding-left: 18px;
}

.timeline li {
  margin-bottom: 6px;
}

/* =========================
   PROJECTS GRID
========================= */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
  margin-top: 32px;
}

/* =========================
   PROJECT CARD
========================= */
.project-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 26px;
  border-radius: 18px;
  border: 1px solid var(--border);
  text-decoration: none;
  color: var(--text);
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease,
    border-color 0.25s ease;
}

.project-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
  border-color: var(--accent);
}

/* =========================
   ICON
========================= */
.project-icon {
  font-size: 2rem;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: var(--accent);
  color: white;
}

/* =========================
   TAG
========================= */
.project-tag {
  margin-top: auto;
  font-size: 0.8rem;
  color: var(--muted);
}
/* =========================
   ANIMATIONS
========================= */

/* Page load fade */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  animation: fadeUp 0.6s ease-out both;
}

/* Stagger helper */
.fade-delay-1 { animation-delay: 0.1s; }
.fade-delay-2 { animation-delay: 0.2s; }
.fade-delay-3 { animation-delay: 0.3s; }

/* Card hover */
.card {
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.08);
}

/* Glass glow (subtle) */
.glass:hover {
  border-color: var(--accent);
}

/* Button micro-interaction */
.btn {
  transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(0,0,0,0.15);
}

.btn:active {
  transform: translateY(0);
  box-shadow: none;
}

/* Nav underline animation */
.nav-links a {
  position: relative;
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 0%;
  height: 2px;
  background: var(--accent);
  transition: width 0.25s ease;
}

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