@import url('https://fonts.googleapis.com/css2?family=Chakra+Petch:wght@400;500;600;700;800;900&family=Space+Grotesk:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500;600;700&display=swap');

/* ═══════════════════════════════════════════════════════════════════
   DESIGN SYSTEM — bekirr.dev
   Premium Dark Developer Portfolio + Auth System
   ═══════════════════════════════════════════════════════════════════ */

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

:root {
  /* — Backgrounds — */
  --bg-black: #050507;
  --bg-surface: #0a0b0f;
  --bg-card: #111318;
  --bg-card-hover: #16181f;
  --bg-elevated: #1a1c24;
  --bg-input: #0e1015;

  /* — Accent — */
  --emerald: #1ED760;
  --emerald-hover: #22e868;
  --emerald-dark: #128a3c;
  --emerald-dim: rgba(30, 215, 96, 0.08);
  --emerald-glow: rgba(30, 215, 96, 0.15);

  /* — Text — */
  --text-primary: #f0f0f0;
  --text-secondary: #94a3b8;
  --text-muted: #4b5563;
  --text-inverse: #050507;

  /* — Borders — */
  --border: rgba(255, 255, 255, 0.06);
  --border-hover: rgba(255, 255, 255, 0.12);
  --border-active: var(--emerald);

  /* — Status — */
  --error: #ef4444;
  --error-dim: rgba(239, 68, 68, 0.1);
  --success: #1ED760;
  --success-dim: rgba(30, 215, 96, 0.1);

  /* — Typography — */
  --font-sans: 'Space Grotesk', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-display: 'Chakra Petch', var(--font-sans);
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

  /* — Spacing — */
  --section-pad: clamp(80px, 12vh, 140px);
  --container-width: 1200px;
  --container-pad: clamp(20px, 4vw, 40px);

  /* — Radii — */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-xl: 20px;
  --radius-full: 999px;

  /* — Shadows — */
  --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.3), 0 4px 20px rgba(0, 0, 0, 0.15);
  --shadow-elevated: 0 8px 40px rgba(0, 0, 0, 0.4);
  --shadow-glow: 0 0 30px rgba(30, 215, 96, 0.08);

  /* — Transitions — */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --duration-fast: 150ms;
  --duration-normal: 250ms;
  --duration-slow: 400ms;
}

html {
  background: var(--bg-black);
  color: var(--text-primary);
  font-family: var(--font-sans);
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  min-height: 100vh;
  background: var(--bg-black);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  font-size: 15px;
}

/* — Subtle dot grid background — */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 28px 28px;
  pointer-events: none;
}

/* — Subtle radial gradient overlay — */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  background: radial-gradient(ellipse 80% 50% at 50% 0%, rgba(30, 215, 96, 0.03) 0%, transparent 60%);
  pointer-events: none;
}

::selection {
  background: rgba(30, 215, 96, 0.25);
  color: var(--text-primary);
}

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

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

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

ul, ol {
  list-style: none;
}

/* ═══════════════════════════════════════════════════════════════════
   SCROLL PROGRESS BAR
   ═══════════════════════════════════════════════════════════════════ */
#scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 2px;
  width: 0%;
  background: var(--emerald);
  z-index: 10001;
  transition: none;
}

/* ═══════════════════════════════════════════════════════════════════
   CONTAINER
   ═══════════════════════════════════════════════════════════════════ */
.container {
  width: 100%;
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 var(--container-pad);
}


/* ═══════════════════════════════════════════════════════════════════
   NAVBAR
   ═══════════════════════════════════════════════════════════════════ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(5, 5, 7, 0.85);
  backdrop-filter: blur(20px) saturate(1.2);
  -webkit-backdrop-filter: blur(20px) saturate(1.2);
  border-bottom: 1px solid var(--border);
  transition: background var(--duration-normal) ease, box-shadow var(--duration-normal) ease;
}

.navbar.scrolled {
  background: rgba(5, 5, 7, 0.95);
  box-shadow: 0 1px 20px rgba(0, 0, 0, 0.3);
}

.navbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.navbar-brand {
  display: flex;
  align-items: center;
  gap: 3px;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 20px;
  letter-spacing: -0.5px;
  text-transform: uppercase;
  color: var(--text-primary);
  text-decoration: none;
  z-index: 2;
}

.navbar-brand .accent {
  color: var(--emerald);
}

.navbar-links {
  display: flex;
  align-items: center;
  gap: 8px;
}

.navbar-links a {
  padding: 6px 14px;
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  transition: color var(--duration-fast) ease, background var(--duration-fast) ease;
  letter-spacing: 0.2px;
}

.navbar-links a:hover,
.navbar-links a.active {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.04);
}

.navbar-auth {
  display: flex;
  align-items: center;
  gap: 10px;
  z-index: 2;
}

/* Mobile hamburger */
.navbar-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  cursor: pointer;
  z-index: 2;
}

.navbar-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: transform var(--duration-normal) var(--ease-out), opacity var(--duration-fast) ease;
}

.navbar-toggle.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.navbar-toggle.active span:nth-child(2) {
  opacity: 0;
}

.navbar-toggle.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}


/* ═══════════════════════════════════════════════════════════════════
   BUTTONS
   ═══════════════════════════════════════════════════════════════════ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 22px;
  border-radius: var(--radius-md);
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: all var(--duration-normal) var(--ease-out);
  border: 1px solid transparent;
  letter-spacing: 0.3px;
  white-space: nowrap;
  line-height: 1;
}

.btn-primary {
  background: var(--emerald);
  color: var(--text-inverse);
  border-color: var(--emerald);
}

.btn-primary:hover {
  background: var(--emerald-hover);
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(30, 215, 96, 0.2);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-secondary {
  background: transparent;
  color: var(--text-secondary);
  border-color: var(--border-hover);
}

.btn-secondary:hover {
  color: var(--text-primary);
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.03);
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  padding: 8px 16px;
}

.btn-ghost:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.04);
}

.btn-danger {
  background: transparent;
  color: var(--error);
  border-color: rgba(239, 68, 68, 0.2);
}

.btn-danger:hover {
  background: var(--error-dim);
}

.btn-sm {
  padding: 7px 16px;
  font-size: 12px;
}

.btn-lg {
  padding: 14px 32px;
  font-size: 15px;
  border-radius: var(--radius-lg);
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

/* ═══════════════════════════════════════════════════════════════════
   USER NAV (Authenticated State)
   ═══════════════════════════════════════════════════════════════════ */
.user-nav {
  display: flex;
  align-items: center;
  gap: 12px;
}

.user-nav-avatar {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  background: var(--emerald-dim);
  border: 1.5px solid rgba(30, 215, 96, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 13px;
  color: var(--emerald);
  cursor: pointer;
  transition: border-color var(--duration-fast) ease;
}

.user-nav-avatar:hover {
  border-color: var(--emerald);
}

.user-nav-name {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
}


/* ═══════════════════════════════════════════════════════════════════
   SECTIONS (Common)
   ═══════════════════════════════════════════════════════════════════ */
.section {
  position: relative;
  padding: var(--section-pad) 0;
  z-index: 1;
}

.section-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  color: var(--emerald);
  letter-spacing: 1.5px;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.section-label::before {
  content: "";
  display: inline-block;
  width: 20px;
  height: 1px;
  background: var(--emerald);
  opacity: 0.5;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.5px;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.section-subtitle {
  font-size: clamp(0.9rem, 1.5vw, 1.05rem);
  color: var(--text-secondary);
  max-width: 560px;
  line-height: 1.7;
}


/* ═══════════════════════════════════════════════════════════════════
   HERO
   ═══════════════════════════════════════════════════════════════════ */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 64px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.hero-content {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 14px;
  background: var(--emerald-dim);
  border: 1px solid rgba(30, 215, 96, 0.15);
  border-radius: var(--radius-full);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  color: var(--emerald);
  letter-spacing: 0.5px;
  width: fit-content;
}

.hero-badge .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--emerald);
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 3.8rem);
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: -1.5px;
}

.hero-title .accent {
  color: var(--emerald);
}

.hero-description {
  font-size: clamp(0.95rem, 1.4vw, 1.1rem);
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 480px;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 4px;
  flex-wrap: wrap;
}

/* Developer Card */
.hero-visual {
  display: flex;
  justify-content: center;
}

.dev-card {
  width: 100%;
  max-width: 380px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  position: relative;
  overflow: hidden;
  transition: border-color var(--duration-normal) ease, transform var(--duration-normal) var(--ease-out);
}

.dev-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-2px);
}

.dev-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--emerald), transparent);
  opacity: 0.6;
}

.dev-card-header {
  display: flex;
  align-items: center;
  gap: 14px;
}

.dev-card-avatar {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  border: 2px solid rgba(30, 215, 96, 0.2);
  overflow: hidden;
  flex-shrink: 0;
}

.dev-card-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.dev-card-info h3 {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.3px;
}

.dev-card-info p {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 2px;
}

.dev-card-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  background: var(--emerald-dim);
  border: 1px solid rgba(30, 215, 96, 0.12);
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 600;
  color: var(--emerald);
}

.dev-card-status .status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--emerald);
  animation: pulse-dot 2s ease-in-out infinite;
}

.dev-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag {
  padding: 5px 11px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  font-family: var(--font-mono);
  letter-spacing: 0.3px;
  transition: color var(--duration-fast) ease, border-color var(--duration-fast) ease;
}

.tag:hover {
  color: var(--text-secondary);
  border-color: var(--border-hover);
}


/* ═══════════════════════════════════════════════════════════════════
   ABOUT
   ═══════════════════════════════════════════════════════════════════ */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start;
}

.about-text {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.about-text p {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.8;
}

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

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  transition: border-color var(--duration-normal) ease;
}

.stat-card:hover {
  border-color: var(--border-hover);
}

.stat-value {
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 900;
  color: var(--emerald);
  letter-spacing: -1px;
  line-height: 1;
}

.stat-label {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 6px;
}


/* ═══════════════════════════════════════════════════════════════════
   SKILLS
   ═══════════════════════════════════════════════════════════════════ */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 40px;
}

.skill-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: border-color var(--duration-normal) ease, transform var(--duration-normal) var(--ease-out);
}

.skill-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-2px);
}

.skill-card-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  background: var(--emerald-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
}

.skill-card h3 {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.2px;
}

.skill-card-items {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.skill-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.skill-item-name {
  font-size: 13px;
  color: var(--text-secondary);
}

.skill-item-bar {
  width: 80px;
  height: 3px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.skill-item-fill {
  height: 100%;
  background: var(--emerald);
  border-radius: var(--radius-full);
  transition: width 1s var(--ease-out);
  width: 0;
}


/* ═══════════════════════════════════════════════════════════════════
   PROJECTS
   ═══════════════════════════════════════════════════════════════════ */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-top: 40px;
}

.project-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: border-color var(--duration-normal) ease, transform var(--duration-normal) var(--ease-out);
  position: relative;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
}

.project-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-2px);
}

.project-card-number {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  color: var(--emerald);
  letter-spacing: 1px;
}

.project-card h3 {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.3px;
}

.project-card p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.7;
}

.project-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: auto;
}

.project-card-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--emerald);
  margin-top: auto;
  transition: gap var(--duration-normal) ease;
}

.project-card:hover .project-card-link {
  gap: 10px;
}

.project-card-featured {
  grid-column: span 2;
}


/* ═══════════════════════════════════════════════════════════════════
   CONTACT
   ═══════════════════════════════════════════════════════════════════ */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  margin-top: 40px;
  align-items: start;
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.contact-info p {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.7;
}

.contact-link-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: border-color var(--duration-normal) ease;
  text-decoration: none;
  color: inherit;
}

.contact-link-item:hover {
  border-color: var(--border-hover);
}

.contact-link-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  background: var(--emerald-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}

.contact-link-text h4 {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.contact-link-text p {
  font-size: 13px;
  color: var(--text-muted);
}


/* ═══════════════════════════════════════════════════════════════════
   FORM STYLES (Contact Form + Auth Forms)
   ═══════════════════════════════════════════════════════════════════ */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
}

.form-input {
  width: 100%;
  padding: 12px 16px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 14px;
  transition: border-color var(--duration-fast) ease, box-shadow var(--duration-fast) ease;
  outline: none;
}

.form-input::placeholder {
  color: var(--text-muted);
}

.form-input:focus {
  border-color: var(--emerald);
  box-shadow: 0 0 0 3px rgba(30, 215, 96, 0.08);
}

.form-input.error {
  border-color: var(--error);
  box-shadow: 0 0 0 3px var(--error-dim);
}

textarea.form-input {
  resize: vertical;
  min-height: 120px;
}

.form-error {
  font-size: 12px;
  color: var(--error);
  display: none;
}

.form-error.visible {
  display: block;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 18px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
}

.contact-form .form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}


/* ═══════════════════════════════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════════════════════════════ */
.footer {
  border-top: 1px solid var(--border);
  padding: 40px 0;
  position: relative;
  z-index: 1;
  background: var(--bg-black);
}

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

.footer-brand {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.3px;
}

.footer-brand .accent {
  color: var(--emerald);
}

.footer-links {
  display: flex;
  align-items: center;
  gap: 20px;
}

.footer-links a {
  font-size: 13px;
  color: var(--text-muted);
  transition: color var(--duration-fast) ease;
}

.footer-links a:hover {
  color: var(--text-secondary);
}

.footer-copy {
  font-size: 12px;
  color: var(--text-muted);
}


/* ═══════════════════════════════════════════════════════════════════
   AUTH MODAL
   ═══════════════════════════════════════════════════════════════════ */
.auth-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--duration-normal) ease, visibility var(--duration-normal) ease;
}

.auth-overlay.active {
  opacity: 1;
  visibility: visible;
}

.auth-modal {
  width: 100%;
  max-width: 420px;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 36px;
  position: relative;
  transform: translateY(20px) scale(0.96);
  transition: transform var(--duration-slow) var(--ease-out);
  margin: 20px;
}

.auth-overlay.active .auth-modal {
  transform: translateY(0) scale(1);
}

.auth-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 18px;
  transition: color var(--duration-fast) ease, background var(--duration-fast) ease;
}

.auth-modal-close:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.04);
}

.auth-modal-header {
  margin-bottom: 28px;
}

.auth-modal-header h2 {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 6px;
  letter-spacing: -0.5px;
}

.auth-modal-header p {
  font-size: 14px;
  color: var(--text-secondary);
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.auth-form .btn {
  width: 100%;
  margin-top: 4px;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 4px 0;
}

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

.auth-divider span {
  font-size: 12px;
  color: var(--text-muted);
}

.auth-switch {
  text-align: center;
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 4px;
}

.auth-switch button {
  color: var(--emerald);
  font-weight: 600;
  font-size: 13px;
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  padding: 0;
  transition: opacity var(--duration-fast) ease;
}

.auth-switch button:hover {
  opacity: 0.8;
}

.auth-message {
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  display: none;
}

.auth-message.error {
  background: var(--error-dim);
  border: 1px solid rgba(239, 68, 68, 0.2);
  color: var(--error);
  display: block;
}

.auth-message.success {
  background: var(--success-dim);
  border: 1px solid rgba(30, 215, 96, 0.2);
  color: var(--success);
  display: block;
}

.password-wrapper {
  position: relative;
}

.password-toggle {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 14px;
  padding: 4px;
  cursor: pointer;
  background: none;
  border: none;
  transition: color var(--duration-fast) ease;
}

.password-toggle:hover {
  color: var(--text-secondary);
}


/* ═══════════════════════════════════════════════════════════════════
   DASHBOARD (Protected Area)
   ═══════════════════════════════════════════════════════════════════ */
.dashboard-view {
  display: none;
  min-height: 100vh;
  padding-top: 64px;
}

.dashboard-view.active {
  display: block;
}

.portfolio-view {
  display: block;
}

.portfolio-view.hidden {
  display: none;
}

.dashboard-header {
  padding: 40px 0 32px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 32px;
}

.dashboard-welcome {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.dashboard-welcome h1 {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 800;
  letter-spacing: -0.5px;
}

.dashboard-welcome h1 .accent {
  color: var(--emerald);
}

.dashboard-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  padding-bottom: var(--section-pad);
}

.dashboard-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.dashboard-card h3 {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
  letter-spacing: -0.2px;
}

.dashboard-card-full {
  grid-column: span 2;
}

.profile-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}

.profile-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.profile-row-label {
  font-size: 13px;
  color: var(--text-muted);
}

.profile-row-value {
  font-size: 14px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
}

.session-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 600;
  background: var(--success-dim);
  color: var(--success);
  border: 1px solid rgba(30, 215, 96, 0.15);
}

.session-badge .dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--success);
  animation: pulse-dot 2s ease-in-out infinite;
}


/* ═══════════════════════════════════════════════════════════════════
   TOAST NOTIFICATIONS
   ═══════════════════════════════════════════════════════════════════ */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toast {
  padding: 14px 20px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-size: 13px;
  color: var(--text-primary);
  box-shadow: var(--shadow-elevated);
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 280px;
  max-width: 400px;
  transform: translateX(120%);
  transition: transform var(--duration-slow) var(--ease-out);
}

.toast.visible {
  transform: translateX(0);
}

.toast.success {
  border-color: rgba(30, 215, 96, 0.2);
}

.toast.error {
  border-color: rgba(239, 68, 68, 0.2);
}

.toast-icon {
  font-size: 16px;
  flex-shrink: 0;
}


/* ═══════════════════════════════════════════════════════════════════
   LOADING SPINNER
   ═══════════════════════════════════════════════════════════════════ */
.spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.15);
  border-top-color: var(--emerald);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

.spinner-dark {
  border-color: rgba(0, 0, 0, 0.15);
  border-top-color: var(--text-inverse);
}

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

.btn .spinner {
  width: 14px;
  height: 14px;
}

.page-loader {
  position: fixed;
  inset: 0;
  z-index: 10002;
  background: var(--bg-black);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity var(--duration-slow) ease;
}

.page-loader.hidden {
  opacity: 0;
  pointer-events: none;
}


/* ═══════════════════════════════════════════════════════════════════
   SCROLL REVEAL ANIMATIONS
   ═══════════════════════════════════════════════════════════════════ */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 80ms; }
.reveal-delay-2 { transition-delay: 160ms; }
.reveal-delay-3 { transition-delay: 240ms; }
.reveal-delay-4 { transition-delay: 320ms; }
.reveal-delay-5 { transition-delay: 400ms; }


/* ═══════════════════════════════════════════════════════════════════
   RESPONSIVE — TABLET (max-width: 900px)
   ═══════════════════════════════════════════════════════════════════ */
@media (max-width: 900px) {
  .navbar-links {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(5, 5, 7, 0.97);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    flex-direction: column;
    justify-content: center;
    gap: 8px;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    transition: opacity var(--duration-normal) ease, visibility var(--duration-normal) ease;
    z-index: 1;
  }

  .navbar-links.open {
    opacity: 1;
    visibility: visible;
  }

  .navbar-links a {
    font-size: 18px;
    padding: 12px 20px;
  }

  .navbar-toggle {
    display: flex;
  }

  .hero-grid {
    grid-template-columns: 1fr;
    gap: 40px;
    text-align: center;
  }

  .hero-content {
    align-items: center;
  }

  .hero-actions {
    justify-content: center;
  }

  .about-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .skills-grid {
    grid-template-columns: 1fr 1fr;
  }

  .projects-grid {
    grid-template-columns: 1fr;
  }

  .project-card-featured {
    grid-column: span 1;
  }

  .contact-grid {
    grid-template-columns: 1fr;
  }

  .contact-form .form-row {
    grid-template-columns: 1fr;
  }

  .dashboard-grid {
    grid-template-columns: 1fr;
  }

  .dashboard-card-full {
    grid-column: span 1;
  }

  .footer-inner {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }
}


/* ═══════════════════════════════════════════════════════════════════
   RESPONSIVE — MOBILE (max-width: 600px)
   ═══════════════════════════════════════════════════════════════════ */
@media (max-width: 600px) {
  .hero {
    min-height: auto;
    padding-top: 100px;
    padding-bottom: 60px;
  }

  .skills-grid {
    grid-template-columns: 1fr;
  }

  .about-stats {
    grid-template-columns: 1fr 1fr;
  }

  .dev-card {
    max-width: 100%;
  }

  .hero-actions {
    flex-direction: column;
    width: 100%;
  }

  .hero-actions .btn {
    width: 100%;
  }

  .auth-modal {
    padding: 28px 24px;
  }

  .toast-container {
    left: 16px;
    right: 16px;
    bottom: 16px;
  }

  .toast {
    min-width: auto;
    max-width: 100%;
  }
}
