* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  background-color: #000000;
  color: #ffffff;
  line-height: 1.6;
  overflow-x: hidden;
  transition: background-color 180ms ease, color 180ms ease;
}

html {
  scroll-behavior: smooth;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* =========================
   Navigation
========================= */

nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: rgba(0, 0, 0, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid #333;
  z-index: 1000;
  transition: all 0.3s ease;
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 70px;
  position: relative;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 40px;
}

.nav-links a {
  color: #ffffff;
  text-decoration: none;
  font-size: 16px;
  font-weight: 400;
  transition: all 0.3s ease;
  position: relative;
  padding: 5px 0;
}

.nav-links a::after {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background: #ffffff;
  transition: width 0.3s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: #cccccc;
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

.theme-toggle {
  align-items: center;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 50%;
  color: #ffffff;
  cursor: pointer;
  display: inline-flex;
  height: 36px;
  justify-content: center;
  padding: 0;
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  transition: background-color 180ms ease, border-color 180ms ease, color 180ms ease;
  width: 36px;
}

.theme-toggle:hover {
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.5);
}

.theme-toggle:focus-visible {
  outline: 2px solid #ffffff;
  outline-offset: 3px;
}

.theme-icon {
  fill: none;
  height: 17px;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
  width: 17px;
}

.theme-icon-moon {
  display: none;
}

/* =========================
   Sections
========================= */

section {
  min-height: 100vh;
  padding: 120px 0 80px;
  display: flex;
  align-items: center;
}

.section-title {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 50px;
  text-align: center;
  color: #ffffff;
}

/* =========================
   Home Section
========================= */

#home {
  text-align: left;
}

.hero h1 {
  font-size: 3.5rem;
  font-weight: 700;
  margin-bottom: 30px;
  color: #ffffff;
}

.subtitle {
  font-size: 1.2rem;
  color: #cccccc;
  margin-bottom: 50px;
  font-weight: 300;
}

.about-list {
  list-style: none;
  margin-bottom: 40px;
}

.about-list li {
  margin-bottom: 20px;
  padding-left: 30px;
  position: relative;
  font-size: 1.1rem;
  line-height: 1.8;
  color: #ffffff;
}

.about-list li::before {
  content: "▶";
  position: absolute;
  left: 0;
  color: #ffffff;
  font-size: 14px;
  top: 2px;
}

.contact-text {
  font-size: 1.1rem;
  margin-bottom: 30px;
  color: #cccccc;
}

/* =========================
   Social Links
========================= */

.social-links {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
}

.social-link {
  display: flex;
  align-items: center;
  text-decoration: none;
  color: #ffffff;
  font-weight: 500;
  transition: color 0.3s;
}

.social-link:hover {
  color: #00aaff;
}

.social-icon {
  width: 24px;
  height: 24px;
  margin-right: 6px;
  filter: invert(1);
  transition: transform 0.2s;
}

.social-link:hover .social-icon {
  transform: scale(1.1);
}

/* =========================
   Skills Section
========================= */

.skills-container {
  width: 100%;
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 40px;
  margin-top: 50px;
}

.skill-category {
  background: transparent;
  border: 1px solid #333;
  border-radius: 8px;
  padding: 40px;
  transition: all 0.3s ease;
}

.skill-category:hover {
  border-color: #ffffff;
  background: rgba(255, 255, 255, 0.05);
}

.skill-category h3 {
  color: #ffffff;
  font-size: 1.5rem;
  margin-bottom: 30px;
  display: flex;
  align-items: center;
  gap: 15px;
}

.category-icon {
  font-size: 1.5rem;
}

.skill-icon {
  width: 32px;
  height: 32px;
  border-radius: 4px;
}

.skill-name {
  font-size: 1.1rem;
  color: #ffffff;
}

.skills-list {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  white-space: nowrap;
  padding-bottom: 10px;
}

.skill-item {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 15px;
  border: 1px solid #333;
  border-radius: 5px;
  transition: all 0.3s ease;
  flex: 0 0 auto;
}

.skill-item:hover {
  border-color: #ffffff;
  background: rgba(255, 255, 255, 0.05);
}

/* =========================
   Selected / Projects Section
========================= */

#projects,
#selected-projects {
  width: 100%;
  align-items: flex-start;
  padding: 142px 0 96px;
}

#projects .container,
#selected-projects .container {
  width: 100%;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  align-items: stretch;
}

#projects .section-title {
  margin-bottom: 42px;
}

.project-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 100%;
  padding: 32px;
  background: rgba(255, 255, 255, 0.018);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 18px;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.2), 0 12px 32px rgba(0, 0, 0, 0.12);
  color: #ffffff;
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    border-color 180ms ease,
    background-color 180ms ease,
    opacity 500ms ease;
}

.project-card:hover {
  border-color: rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.04);
  box-shadow: 0 2px 3px rgba(0, 0, 0, 0.2), 0 16px 36px rgba(0, 0, 0, 0.18);
  transform: translateY(-3px);
}

.project-card:focus-within {
  border-color: rgba(255, 255, 255, 0.34);
}

.project-card h3 {
  color: #ffffff;
  font-size: 1.35rem;
  font-weight: 650;
  letter-spacing: -0.02em;
  line-height: 1.22;
  margin-bottom: 10px;
}

.project-meta {
  color: #8f8f8f;
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  margin: 0 0 26px;
}

.project-description {
  max-inline-size: 35ch;
  color: #c7c7c7;
  font-size: 0.95rem;
  line-height: 1.72;
  margin: 0;
}

.project-tech {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin: 26px 0 0;
}

.tech-tag {
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 6px;
  color: #cfcfcf;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  line-height: 1;
  padding: 6px 8px;
  transition: border-color 180ms ease, background-color 180ms ease, color 180ms ease;
}

.project-card:hover .tech-tag {
  background: rgba(255, 255, 255, 0.065);
  border-color: rgba(255, 255, 255, 0.17);
  color: #e0e0e0;
}

.project-links {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 22px;
  margin-top: auto;
  padding-top: 30px;
}

.project-link {
  align-items: center;
  color: #dedede;
  display: inline-flex;
  font-size: 0.9rem;
  font-weight: 600;
  gap: 7px;
  min-height: 44px;
  padding: 8px 0;
  text-decoration: none;
  transition: color 180ms ease;
}

.project-link:hover {
  color: #ffffff;
}

.project-link:focus-visible {
  border-radius: 4px;
  outline: 2px solid #ffffff;
  outline-offset: 4px;
}

.project-link-arrow {
  display: inline-block;
  transition: transform 180ms ease;
}

.project-link:hover .project-link-arrow,
.project-link:focus-visible .project-link-arrow {
  transform: translateX(3px);
}

.reveal-ready .project-card[data-reveal] {
  opacity: 0;
  transform: translateY(10px);
}

.reveal-ready .project-card[data-reveal].is-revealed {
  opacity: 1;
  transform: translateY(0);
  transition-delay: var(--reveal-delay, 0ms);
}

@media (hover: hover) {
  .reveal-ready .project-card[data-reveal].is-revealed:hover {
    transform: translateY(-3px);
  }
}

/* =========================
   Achievements
========================= */

.achievements-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 50px;
}

.achievement-card {
  background: transparent;
  border: 1px solid #333;
  border-radius: 8px;
  padding: 30px;
  text-align: center;
  transition: all 0.3s ease;
}

.achievement-card:hover {
  border-color: #ffffff;
  background: rgba(255, 255, 255, 0.05);
}

.achievement-icon {
  font-size: 3rem;
  margin-bottom: 20px;
}

.achievement-card h3 {
  color: #ffffff;
  font-size: 1.4rem;
  margin-bottom: 15px;
}

.achievement-description {
  color: #cccccc;
  line-height: 1.6;
  margin-bottom: 15px;
}

.achievement-date {
  color: #999;
  font-size: 0.9rem;
}

/* =========================
   Resume
========================= */

#resume {
  align-items: flex-start;
  padding: 142px 0 96px;
  width: 100%;
}

#resume .container {
  width: 100%;
}

.resume-content {
  max-width: 760px;
  margin: 0 auto;
}

#resume .section-title {
  margin-bottom: 42px;
  text-align: center;
}

.resume-preview {
  align-items: start;
  background: rgba(255, 255, 255, 0.018);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 18px;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.2), 0 12px 32px rgba(0, 0, 0, 0.12);
  display: grid;
  gap: 0 20px;
  grid-template-columns: 52px minmax(0, 1fr);
  margin: 0;
  padding: 32px;
  text-align: left;
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    border-color 180ms ease,
    background-color 180ms ease;
}

.resume-preview:hover {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.28);
  box-shadow: 0 2px 3px rgba(0, 0, 0, 0.2), 0 16px 36px rgba(0, 0, 0, 0.18);
  transform: translateY(-3px);
}

.resume-icon {
  align-items: center;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 12px;
  color: #ffffff;
  display: inline-flex;
  height: 52px;
  justify-content: center;
  width: 52px;
}

.resume-icon svg {
  fill: none;
  height: 24px;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.6;
  width: 24px;
}

.resume-eyebrow {
  color: #8f8f8f;
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  margin: 3px 0 8px;
}

.resume-text {
  color: #c7c7c7;
  font-size: 1rem;
  line-height: 1.65;
  margin: 0;
  max-inline-size: 48ch;
}

.resume-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 22px;
  grid-column: 2;
  margin-top: 28px;
}

.resume-action {
  align-items: center;
  color: #dedede;
  display: inline-flex;
  font-size: 0.9rem;
  font-weight: 600;
  gap: 7px;
  min-height: 44px;
  padding: 8px 0;
  text-decoration: none;
  transition: color 180ms ease;
}

.resume-action span {
  display: inline-block;
  transition: transform 180ms ease;
}

.resume-action:hover {
  color: #ffffff;
}

.resume-action:hover span,
.resume-action:focus-visible span {
  transform: translateX(3px);
}

.resume-action:focus-visible {
  border-radius: 4px;
  outline: 2px solid #ffffff;
  outline-offset: 4px;
}

.download-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: #ffffff;
  color: #000000;
  text-decoration: none;
  padding: 15px 30px;
  border-radius: 5px;
  font-weight: 600;
  font-size: 1.1rem;
  transition: all 0.3s ease;
  margin: 0 10px;
  border: 1px solid #ffffff;
}

.download-btn:hover {
  background: transparent;
  color: #ffffff;
}

/* =========================
   Contact
========================= */

.contact-content {
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
}

.contact-form {
  background: transparent;
  border: 1px solid #333;
  border-radius: 8px;
  padding: 40px;
  margin-top: 40px;
}

.form-group {
  margin-bottom: 25px;
  text-align: left;
}

.form-group label {
  display: block;
  color: #ffffff;
  margin-bottom: 8px;
  font-weight: 500;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 12px 16px;
  background: transparent;
  border: 1px solid #333;
  border-radius: 5px;
  color: #ffffff;
  font-size: 16px;
  transition: all 0.3s ease;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: #666;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #ffffff;
}

.form-group textarea {
  resize: vertical;
  min-height: 120px;
}

.submit-btn {
  background: #ffffff;
  color: #000000;
  border: 1px solid #ffffff;
  padding: 15px 40px;
  border-radius: 5px;
  font-weight: 600;
  font-size: 1.1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  width: 100%;
}

.submit-btn:hover {
  background: transparent;
  color: #ffffff;
}

/* =========================
   Responsive - Tablet
========================= */

@media (max-width: 900px) {
  .projects-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
  }
}

/* =========================
   Responsive - 768px
========================= */

@media (max-width: 768px) {
  .hero h1 {
    font-size: 2.5rem;
  }
  .section-title {
    font-size: 2.5rem;
  }
  .nav-links {
    gap: 20px;
  }
  .nav-links a {
    font-size: 14px;
  }
  .about-list li {
    font-size: 1rem;
  }
  .social-links {
    gap: 15px;
  }
  .social-link {
    font-size: 14px;
    padding: 10px 16px;
  }
  .skills-grid,
  .achievements-grid {
    grid-template-columns: 1fr;
  }
  .skills-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  }
  .project-card {
    padding: 28px;
  }
}

/* =========================
   Responsive - Mobile
========================= */

@media (max-width: 600px) {
  .projects-grid {
    grid-template-columns: 1fr;
  }
  .project-card {
    padding: 24px;
  }
  .resume-preview {
    gap: 16px;
    grid-template-columns: 1fr;
    padding: 24px;
  }
  .resume-buttons {
    grid-column: 1;
    margin-top: 4px;
  }
}

/* =========================
   Small Mobile
========================= */

@media (max-width: 480px) {
  .hero h1 {
    font-size: 2rem;
  }
  .section-title {
    font-size: 2rem;
  }
  .nav-links {
    gap: 12px;
  }
  .nav-links a {
    font-size: 13px;
  }
  .nav-container {
    justify-content: flex-start;
    padding: 0 15px;
  }
  .theme-toggle {
    right: 15px;
  }
  .social-links {
    flex-direction: column;
    align-items: flex-start;
  }
  .contact-form {
    padding: 20px;
  }
  .skill-category {
    padding: 25px;
  }
  .container {
    padding: 0 15px;
  }
  .projects-grid {
    gap: 20px;
  }
  .project-card h3 {
    font-size: 1.3rem;
  }
  .project-meta {
    margin-bottom: 22px;
  }
  .project-tech {
    margin-top: 22px;
  }
  .project-links {
    padding-top: 24px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

/* Education */
.education-entry {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 20px;
  padding: 24px 0;
  border-top: 1px solid #e7e5e4;
}
.education-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid #d6d3d1;
  border-radius: 50%;
  color: #44403c;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .04em;
}
.education-mark img { width: 34px; height: 34px; object-fit: contain; border-radius: 50%; }
.education-copy h3 { margin: 0 0 7px; font-size: 1.05rem; color: #1c1917; }
.education-meta { margin: 3px 0; color: #78716c; font-size: .92rem; }
.education-copy ul { margin: 12px 0 0; padding-left: 18px; color: #57534e; }
.education-copy li { margin: 4px 0; }
html[data-theme="dark"] .education-entry { border-color: #3a3532; }
html[data-theme="dark"] .education-mark { border-color: #57534e; color: #e7e5e4; }
html[data-theme="dark"] .education-copy h3 { color: #fff; }
html[data-theme="dark"] .education-meta, html[data-theme="dark"] .education-copy ul { color: #d6d3d1; }
@media (max-width: 600px) { .education-entry { grid-template-columns: 1fr; gap: 12px; } }

/* Blog */
.blog-intro { max-width: 620px; margin-bottom: 24px; }
.blog-featured { max-width: 760px; padding: 22px 0 24px; border-top: 1px solid #e7e5e4; border-bottom: 1px solid #e7e5e4; }
.blog-featured-top, .blog-footer { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.blog-label { color: #78716c; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; }
.blog-featured h3 { margin: 12px 0 8px; font-size: 1.22rem; line-height: 1.35; }
.blog-featured h3 a { color: #1c1917; }
.blog-featured h3 a:hover { color: #2563eb; }
.blog-featured p { max-width: 680px; color: #78716c; line-height: 1.7; }
.blog-tags { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 16px; }
.blog-tags span { padding: 4px 8px; border-radius: 5px; background: #f5f5f4; color: #78716c; font-size: 12px; }
.blog-footer { max-width: 760px; padding-top: 18px; color: #78716c; font-size: 14px; }
html[data-theme="dark"] .blog-featured { border-color: #3a3532; }
html[data-theme="dark"] .blog-featured h3 a { color: #fff; }
html[data-theme="dark"] .blog-featured p, html[data-theme="dark"] .blog-footer { color: #d6d3d1; }
html[data-theme="dark"] .blog-tags span { background: #292524; color: #d6d3d1; }
@media (max-width: 600px) { .blog-featured-top, .blog-footer { align-items: flex-start; flex-direction: column; gap: 8px; } }

/* Strict monochrome theme */
:root { --accent: #111; --accent-soft: #f2f2f2; --surface: #fff; --line: #e5e5e5; --muted: #666; }
.theme-toggle { display: none; }
.theme-toggle { display: none !important; }
.section-title::after { display: none; }
strong { color: #2563eb; }
#home strong { color: #2563eb; }
body { background: #fff; color: #111; }
body::before { display: none; }
nav { background: rgba(255,255,255,.96); border-color: #e5e5e5; }
.nav-links a, .subtitle, .project-meta, .education-meta, .blog-featured p, .blog-footer, .card-kicker { color: #666; }
.nav-links a:hover, .nav-links a.active { color: #111; background: #f2f2f2; }
.nav-links a.active { color: #111; }
a, .social-link, .project-link, .text-link { color: #111; }
a:hover, .social-link:hover, .project-link:hover, .text-link:hover, .blog-featured h3 a:hover { color: #555; }
.scroll-progress span { background: #111; }
.section-title::after { background: #111; }
.project-card, .education-entry, .blog-featured, .resume-preview { background: #fff; border-color: #e5e5e5; box-shadow: 0 8px 24px rgba(0,0,0,.045); }
.project-card:hover, .blog-featured:hover { border-color: #999; box-shadow: 0 14px 36px rgba(0,0,0,.1); }
.tech-tag, .blog-tags span { background: #f2f2f2; color: #666; }
.education-mark { background: #fff; border-color: #ccc; }
.hero h1, .section-title, .project-card h3, .education-copy h3, .about-list li, .resume-text { color: #111; }

html[data-theme="dark"] body { background: #000; color: #fff; }
html[data-theme="dark"] nav { background: rgba(0,0,0,.96); border-color: #2b2b2b; }
html[data-theme="dark"] .nav-links a, html[data-theme="dark"] .subtitle, html[data-theme="dark"] .project-meta, html[data-theme="dark"] .education-meta, html[data-theme="dark"] .blog-featured p, html[data-theme="dark"] .blog-footer, html[data-theme="dark"] .card-kicker { color: #aaa; }
html[data-theme="dark"] .nav-links a:hover, html[data-theme="dark"] .nav-links a.active { color: #fff; background: #1a1a1a; }
html[data-theme="dark"] a, html[data-theme="dark"] .social-link, html[data-theme="dark"] .project-link, html[data-theme="dark"] .text-link, html[data-theme="dark"] .blog-featured h3 a { color: #fff; }
html[data-theme="dark"] a:hover, html[data-theme="dark"] .social-link:hover, html[data-theme="dark"] .project-link:hover, html[data-theme="dark"] .text-link:hover { color: #ccc; }
html[data-theme="dark"] .scroll-progress span, html[data-theme="dark"] .section-title::after { background: #fff; }
html[data-theme="dark"] .project-card, html[data-theme="dark"] .education-entry, html[data-theme="dark"] .blog-featured, html[data-theme="dark"] .resume-preview { background: #111; border-color: #2b2b2b; box-shadow: 0 8px 24px rgba(0,0,0,.35); }
html[data-theme="dark"] .project-card:hover, html[data-theme="dark"] .blog-featured:hover { border-color: #666; }
html[data-theme="dark"] .tech-tag, html[data-theme="dark"] .blog-tags span { background: #1a1a1a; color: #aaa; }
html[data-theme="dark"] .education-mark { background: #111; border-color: #555; }
html[data-theme="dark"] .hero h1, html[data-theme="dark"] .section-title, html[data-theme="dark"] .project-card h3, html[data-theme="dark"] .education-copy h3, html[data-theme="dark"] .about-list li, html[data-theme="dark"] .resume-text { color: #fff; }
.nav-links a::after, .section-title::after { display: none !important; content: none !important; }
.section-title { text-align: center !important; }
#hackathons .hackathon-list, #hackathons .hackathon-entry { margin-left: auto !important; margin-right: auto !important; text-align: center !important; }
#hackathons .hackathon-entry h3, #hackathons .hackathon-entry .text-link { text-align: center !important; margin-left: auto !important; margin-right: auto !important; }
#hackathons .hackathon-image { display: block !important; margin-left: auto !important; margin-right: auto !important; }
#hackathons .hackathon-entry { background: transparent !important; box-shadow: none !important; }
#hackathons .hackathon-entry { border: 0 !important; border-radius: 0 !important; padding: 0 !important; }
.site-footer { width: min(100% - 40px, 980px); margin: 0 auto; padding: 24px 0 30px; display: flex; justify-content: center; gap: 24px; border-top: 1px solid #e5e5e5; color: #666; font-size: 13px; }
html[data-theme="dark"] .site-footer { border-color: #2b2b2b; color: #aaa; }
/* Keep every secondary section on the same centered content axis. */
#education .container > *, #projects .container > *, #blog .container > *, #resume .container > *, #manifesto .container > * { margin-left: auto !important; margin-right: auto !important; }
#education .education-entry, #blog .blog-intro, #blog .blog-featured, #blog .blog-footer, #resume .resume-content, #manifesto .about-section { width: min(100%, 820px); }
#projects .projects-grid { width: 100%; }
.contact-section { text-align: left; }
.leadership-grid { width: min(100%, 820px); display: grid; grid-template-columns: 1fr; gap: 16px; margin: 0 auto; }
.leadership-entry { width: min(100%, 820px); margin: 0 auto; padding: 24px 0; border-top: 1px solid #e5e5e5; }
.leadership-grid .leadership-entry { position: relative; width: auto; margin: 0; padding: 26px 28px; border: 1px solid #e5e5e5; border-radius: 16px; background: linear-gradient(135deg, #fff 0%, #fafafa 100%); box-shadow: 0 8px 24px rgba(0,0,0,.045); overflow: hidden; transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease; }
.leadership-grid .leadership-entry::before { display: none; }
.leadership-grid .leadership-entry:hover { transform: translateY(-4px); border-color: #aaa; box-shadow: 0 16px 34px rgba(0,0,0,.1); }
.leadership-grid .leadership-entry ul { margin-bottom: 0; }
.leadership-top { display: flex; justify-content: space-between; align-items: baseline; gap: 18px; }
.leadership-top h3 { margin: 0; color: #111; font-size: 1.12rem; }
.leadership-top span { color: #666; font-size: .9rem; }
.leadership-entry ul { margin: 14px 0 0; padding-left: 20px; color: #666; line-height: 1.7; }
html[data-theme="dark"] .leadership-entry { border-color: #2b2b2b; }
html[data-theme="dark"] .leadership-grid .leadership-entry { background: #111; }
html[data-theme="dark"] .leadership-top h3 { color: #fff; }
html[data-theme="dark"] .leadership-top span, html[data-theme="dark"] .leadership-entry ul { color: #aaa; }
@media (max-width: 650px) { .leadership-grid { grid-template-columns: 1fr; } .leadership-top { align-items: flex-start; flex-direction: column; gap: 5px; } }

/* Unified visual system */
:root { --card-border: #e5e5e5; --card-bg: #fff; --card-radius: 16px; --card-shadow: 0 8px 24px rgba(0,0,0,.05); }
.project-card, .education-entry, .blog-featured, .hackathon-entry, .leadership-grid .leadership-entry, .resume-preview, .contact-panel { background: var(--card-bg); border: 1px solid var(--card-border); border-radius: var(--card-radius); box-shadow: var(--card-shadow); }
.project-card, .education-entry, .blog-featured, .hackathon-entry, .leadership-grid .leadership-entry, .resume-preview { padding: 26px; }
.project-card:hover, .blog-featured:hover, .leadership-grid .leadership-entry:hover { border-color: #aaa; box-shadow: 0 14px 32px rgba(0,0,0,.09); }
.education-entry, .blog-featured, .hackathon-entry, .leadership-grid .leadership-entry, .resume-preview { border-top: 1px solid var(--card-border); }
.project-card, .education-entry, .blog-featured, .hackathon-entry, .leadership-grid .leadership-entry, .resume-preview { margin-top: 0; }
.projects-grid { gap: 16px; }
.blog-featured + .blog-featured { margin-top: 16px; }
.hackathon-entry { width: 100%; }
html[data-theme="dark"] { --card-border: #2b2b2b; --card-bg: #111; --card-shadow: 0 8px 24px rgba(0,0,0,.3); }
html[data-theme="dark"] .project-card, html[data-theme="dark"] .education-entry, html[data-theme="dark"] .blog-featured, html[data-theme="dark"] .hackathon-entry, html[data-theme="dark"] .leadership-grid .leadership-entry, html[data-theme="dark"] .resume-preview, html[data-theme="dark"] .contact-panel { border-color: var(--card-border); background: var(--card-bg); box-shadow: var(--card-shadow); }
@media (max-width: 600px) { .project-card, .education-entry, .blog-featured, .hackathon-entry, .leadership-grid .leadership-entry, .resume-preview { padding: 20px; } }
.hackathon-list { width: min(100%, 820px); }
.hackathon-entry { padding: 26px 0 30px; border-bottom: 1px solid #e5e5e5; text-align: center; }
.hackathon-entry:first-child { border-top: 1px solid #e5e5e5; }
.hackathon-entry-top { display: flex; justify-content: space-between; gap: 16px; }
.hackathon-entry h3 { margin: 0 0 18px; font-size: 1.16rem; }
.hackathon-entry h3 a { color: #2563eb; }
.hackathon-entry h3 a:hover { color: #111; }
.hackathon-entry p { max-width: 760px; margin: 7px 0; color: #666; line-height: 1.7; }
.hackathon-meta { font-size: .9rem; }
.hackathon-result { color: #111 !important; font-weight: 650; }
.hackathon-gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; max-width: 820px; margin: 0 auto 18px; }
.hackathon-image { display: block; width: 100%; height: 220px; margin: 0; object-fit: cover; object-position: center; border: 1px solid #e5e5e5; border-radius: 12px; }
.hackathon-image:first-child { grid-column: auto; height: 220px; }
.hackathon-image { cursor: zoom-in; }
.image-lightbox { position: fixed; inset: 0; z-index: 3000; display: grid; place-items: center; padding: 32px; background: rgba(0,0,0,.88); cursor: zoom-out; }
.image-lightbox img { max-width: min(94vw, 1200px); max-height: 90vh; object-fit: contain; border-radius: 8px; box-shadow: 0 20px 80px rgba(0,0,0,.45); }
.image-lightbox button { position: fixed; border: 0; background: transparent; color: #fff; cursor: pointer; line-height: 1; }
.lightbox-close { top: 18px; right: 24px; font-size: 38px; }
.lightbox-prev, .lightbox-next { top: 50%; transform: translateY(-50%); padding: 20px; font-size: 52px; }
.lightbox-prev { left: 18px; }
.lightbox-next { right: 18px; }
.lightbox-count { position: fixed; bottom: 18px; left: 0; right: 0; text-align: center; color: #fff; font-size: 14px; }
.hackathon-entry .text-link { display: inline-flex; justify-content: center; }
html[data-theme="dark"] .hackathon-entry { border-color: #2b2b2b; }
html[data-theme="dark"] .hackathon-entry h3 a { color: #fff; }
html[data-theme="dark"] .hackathon-entry h3 a:hover { color: #ccc; }
html[data-theme="dark"] .hackathon-entry p { color: #aaa; }
html[data-theme="dark"] .hackathon-result { color: #fff !important; }
html[data-theme="dark"] .hackathon-image { border-color: #2b2b2b; }
@media (max-width: 600px) { .hackathon-entry-top { align-items: flex-start; flex-direction: column; gap: 6px; } }
@media (max-width: 600px) { .hackathon-gallery { grid-template-columns: 1fr; } .hackathon-image, .hackathon-image:first-child { grid-column: auto; height: auto; max-height: none; } }
.contact-panel { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(260px, .8fr); gap: 42px; padding: 34px; border: 1px solid #e5e5e5; border-radius: 20px; background: #fff; box-shadow: 0 16px 40px rgba(0,0,0,.06); }
.contact-eyebrow { margin: 0 0 12px; color: #666; font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; }
.contact-copy .section-title { margin-bottom: 16px; text-align: left !important; }
.contact-lede { max-width: 520px; margin: 0 0 24px; color: #666; }
.contact-primary { display: flex; align-items: center; flex-wrap: wrap; gap: 14px; }
.contact-primary > a { color: #111; font-size: 1rem; font-weight: 650; }
.contact-primary > a span { color: #666; }
.copy-email { border: 1px solid #ccc; border-radius: 999px; background: #f2f2f2; color: #111; cursor: pointer; font: inherit; font-size: 12px; padding: 8px 13px; }
.copy-email:hover { border-color: #777; background: #fff; }
.contact-grid { display: grid; grid-template-columns: 1fr; align-content: center; gap: 12px; }
.contact-grid a { display: flex; flex-direction: column; gap: 7px; padding: 17px; border: 1px solid #e5e5e5; border-radius: 12px; color: #111; text-decoration: none; transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease; }
.contact-grid a:hover { transform: translateX(4px); border-color: #999; box-shadow: 0 8px 20px rgba(0,0,0,.07); }
.contact-grid span { color: #666; font-size: 12px; }
.contact-grid strong { color: #111; font-size: 13px; overflow-wrap: anywhere; }
.contact-grid b { color: #666; font-weight: 500; }
html[data-theme="dark"] .contact-panel { border-color: #2b2b2b; background: #111; }
html[data-theme="dark"] .contact-lede, html[data-theme="dark"] .contact-eyebrow { color: #aaa; }
html[data-theme="dark"] .contact-primary > a, html[data-theme="dark"] .contact-grid a { color: #fff; }
html[data-theme="dark"] .contact-grid a { border-color: #2b2b2b; background: #111; }
html[data-theme="dark"] .contact-grid a:hover { border-color: #666; }
html[data-theme="dark"] .contact-grid span { color: #aaa; }
html[data-theme="dark"] .contact-grid strong { color: #fff; }
html[data-theme="dark"] .copy-email { border-color: #555; background: #1a1a1a; color: #fff; }
@media (max-width: 700px) { .contact-panel { grid-template-columns: 1fr; gap: 26px; padding: 24px; } }

/* Shared page alignment and rhythm */
section { min-height: auto; padding: 96px 0 72px; display: block; }
section:first-of-type { padding-top: 130px; }
.container { width: min(100% - 40px, 980px); max-width: 980px; margin: 0 auto; padding: 0; }
.section-title { width: 100%; margin: 0 0 34px; text-align: left; line-height: 1.15; }
.about-section, .resume-content, .blog-intro, .blog-featured, .blog-footer, .education-entry { margin-left: 0 !important; margin-right: 0 !important; }
.about-section { max-width: 820px !important; text-align: left !important; }
.about-list { max-width: 820px; }
.projects-grid { width: 100%; margin-top: 0; }
.project-card { min-height: 100%; }
.resume-preview { margin-left: 0; margin-right: 0; }
#manifesto .about-section { max-width: 820px !important; }
#manifesto .about-section > .subtitle { text-align: left !important; margin-top: 0 !important; }
.social-links { justify-content: flex-start !important; }
@media (max-width: 768px) {
  section { padding: 76px 0 54px; }
  section:first-of-type { padding-top: 108px; }
  .container { width: min(100% - 30px, 980px); }
  .section-title { margin-bottom: 26px; }
}

/* Premium interaction layer */
:root {
  --accent: #2563eb;
  --accent-soft: rgba(37, 99, 235, .1);
  --surface: rgba(255,255,255,.72);
  --shadow: 0 18px 50px rgba(28,25,23,.08);
}
body { background: radial-gradient(circle at 85% 4%, rgba(219,234,254,.34), transparent 28rem), #fff; }
nav { box-shadow: 0 1px 0 rgba(28,25,23,.04); }
.scroll-progress { position: fixed; inset: 0 0 auto; height: 3px; z-index: 2000; background: transparent; }
.scroll-progress span { display: block; width: 0; height: 100%; background: linear-gradient(90deg, #2563eb, #60a5fa); transition: width .1s linear; }
.nav-links a { transition: color .2s ease, background .2s ease, transform .2s ease; }
.nav-links a:hover { transform: translateX(2px); }
.nav-links a.active { color: var(--accent); background: var(--accent-soft); }
.hero h1 { font-size: clamp(2.4rem, 5vw, 4.2rem); line-height: 1.05; letter-spacing: -.055em; max-width: 760px; }
.subtitle { max-width: 70ch; }
.section-title { font-size: clamp(1.7rem, 3vw, 2.35rem); letter-spacing: -.04em; }
.section-title::after { content: ''; display: block; width: 34px; height: 3px; margin-top: 14px; border-radius: 99px; background: var(--accent); }
.projects-grid { gap: 22px; }
.project-card { padding: 26px; border: 1px solid #e7e5e4; border-radius: 16px; background: var(--surface); box-shadow: 0 1px 0 rgba(28,25,23,.02); transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease; }
.project-card:hover { transform: translateY(-6px); border-color: #bfdbfe; box-shadow: var(--shadow); }
.project-card h3 { font-size: 1.2rem; }
.education-entry, .blog-featured, .resume-preview { border-radius: 16px; background: var(--surface); box-shadow: 0 1px 0 rgba(28,25,23,.02); }
.education-entry { padding: 26px; border: 1px solid #e7e5e4; }
.education-mark { background: #fff; box-shadow: 0 4px 15px rgba(28,25,23,.08); }
.blog-featured { padding: 28px; border: 1px solid #e7e5e4; transition: transform .25s ease, box-shadow .25s ease; }
.blog-featured:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.resume-preview { border: 1px solid #e7e5e4; }
.reveal-item { opacity: 0; transform: translateY(18px); transition: opacity .65s ease, transform .65s ease; }
.reveal-item.is-visible { opacity: 1; transform: translateY(0); }
html[data-theme="dark"] body { background: radial-gradient(circle at 85% 4%, rgba(30,64,175,.16), transparent 28rem), #181615; }
html[data-theme="dark"] .project-card, html[data-theme="dark"] .education-entry, html[data-theme="dark"] .blog-featured, html[data-theme="dark"] .resume-preview { background: rgba(41,37,36,.72); border-color: #44403c; }
html[data-theme="dark"] .project-card:hover { border-color: #1d4ed8; }
html[data-theme="dark"] .education-mark { background: #292524; }
@media (prefers-reduced-motion: reduce) { .reveal-item { opacity: 1; transform: none; transition: none; } }


/* =========================
   Light Theme
========================= */

html[data-theme="light"] {
  color-scheme: light;
}

html[data-theme="light"] body {
  background-color: #f5f5f7;
  color: #1d1d1f;
}

html[data-theme="light"] nav {
  background: rgba(245, 245, 247, 0.92);
  border-bottom-color: #d2d2d7;
}

html[data-theme="light"] .nav-links a {
  color: #1d1d1f;
}

html[data-theme="light"] .nav-links a:hover,
html[data-theme="light"] .nav-links a.active {
  color: #6e6e73;
}

html[data-theme="light"] .nav-links a::after {
  background: #1d1d1f;
}

html[data-theme="light"] .theme-toggle {
  border-color: #c7c7cc;
  color: #1d1d1f;
}

html[data-theme="light"] .theme-toggle:hover {
  background: rgba(29, 29, 31, 0.06);
  border-color: #8e8e93;
}

html[data-theme="light"] .theme-toggle:focus-visible,
html[data-theme="light"] .project-link:focus-visible {
  outline-color: #1d1d1f;
}

html[data-theme="light"] .theme-icon-sun {
  display: none;
}

html[data-theme="light"] .theme-icon-moon {
  display: block;
}

html[data-theme="light"] .section-title,
html[data-theme="light"] .hero h1,
html[data-theme="light"] .about-list li,
html[data-theme="light"] .skill-category h3,
html[data-theme="light"] .skill-name,
html[data-theme="light"] .project-card,
html[data-theme="light"] .project-card h3,
html[data-theme="light"] .achievement-card h3,
html[data-theme="light"] .resume-icon,
html[data-theme="light"] .form-group label {
  color: #1d1d1f;
}

html[data-theme="light"] .about-list li::before {
  color: #1d1d1f;
}

html[data-theme="light"] .subtitle,
html[data-theme="light"] .contact-text,
html[data-theme="light"] .project-description,
html[data-theme="light"] .achievement-description,
html[data-theme="light"] .resume-text {
  color: #515154;
}

html[data-theme="light"] .social-link {
  color: #1d1d1f;
}

html[data-theme="light"] .social-link:hover {
  color: #0071e3;
}

html[data-theme="light"] .social-icon {
  filter: invert(0);
}

html[data-theme="light"] .skill-category,
html[data-theme="light"] .skill-item,
html[data-theme="light"] .achievement-card,
html[data-theme="light"] .contact-form {
  background: rgba(255, 255, 255, 0.6);
  border-color: #d2d2d7;
}

html[data-theme="light"] .skill-category:hover,
html[data-theme="light"] .skill-item:hover,
html[data-theme="light"] .achievement-card:hover {
  background: #ffffff;
  border-color: #8e8e93;
}

html[data-theme="light"] .project-card {
  background: rgba(255, 255, 255, 0.72);
  border-color: #d2d2d7;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.03), 0 12px 32px rgba(0, 0, 0, 0.05);
}

html[data-theme="light"] .project-card:hover,
html[data-theme="light"] .project-card:focus-within {
  background: #ffffff;
  border-color: #a1a1a6;
  box-shadow: 0 2px 3px rgba(0, 0, 0, 0.04), 0 16px 36px rgba(0, 0, 0, 0.08);
}

html[data-theme="light"] .resume-preview {
  background: rgba(255, 255, 255, 0.6);
  border-color: #d2d2d7;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.03), 0 12px 32px rgba(0, 0, 0, 0.05);
}

html[data-theme="light"] .resume-preview:hover {
  background: #ffffff;
  border-color: #a1a1a6;
  box-shadow: 0 2px 3px rgba(0, 0, 0, 0.04), 0 16px 36px rgba(0, 0, 0, 0.08);
}

html[data-theme="light"] .resume-icon {
  background: #f5f5f7;
  border-color: #d2d2d7;
  color: #1d1d1f;
}

html[data-theme="light"] .resume-eyebrow {
  color: #6e6e73;
}

html[data-theme="light"] .resume-action {
  color: #424245;
}

html[data-theme="light"] .resume-action:hover {
  color: #000000;
}

html[data-theme="light"] .resume-action:focus-visible {
  outline-color: #1d1d1f;
}

html[data-theme="light"] .project-meta,
html[data-theme="light"] .achievement-date {
  color: #6e6e73;
}

html[data-theme="light"] .tech-tag {
  background: #f5f5f7;
  border-color: #d2d2d7;
  color: #515154;
}

html[data-theme="light"] .project-card:hover .tech-tag {
  background: #ffffff;
  border-color: #b8b8bd;
  color: #1d1d1f;
}

html[data-theme="light"] .project-link {
  color: #424245;
}

html[data-theme="light"] .project-link:hover {
  color: #000000;
}

html[data-theme="light"] .download-btn,
html[data-theme="light"] .submit-btn {
  background: #1d1d1f;
  border-color: #1d1d1f;
  color: #ffffff;
}

html[data-theme="light"] .download-btn:hover,
html[data-theme="light"] .submit-btn:hover {
  background: transparent;
  color: #1d1d1f;
}

html[data-theme="light"] .form-group input,
html[data-theme="light"] .form-group textarea {
  background: #ffffff;
  border-color: #c7c7cc;
  color: #1d1d1f;
}

html[data-theme="light"] .form-group input::placeholder,
html[data-theme="light"] .form-group textarea::placeholder {
  color: #86868b;
}

html[data-theme="light"] .form-group input:focus,
html[data-theme="light"] .form-group textarea:focus {
  border-color: #1d1d1f;
}
