/* ==========================================================================
   Seungwan Ha · HCI Portfolio — Pure CSS Stylesheet
   ========================================================================== */

:root {
  --font-display: 'Satoshi', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-sans: 'Satoshi', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'Satoshi', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-serif-hero: 'Satoshi', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-serif-body: 'Satoshi', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  --sky: #4fa7e8;
  --sky-dark: #3888cc;
  --sky-darker: #2d76b3;
  --sky-deep: #246399;
  --sky-ink: #256ea8;
  --sky-link: #3b8fd2;

  --slate-50: #f8fafc;
  --slate-100: #f1f5f9;
  --slate-200: #e2e8f0;
  --slate-300: #cbd5e1;
  --slate-400: #94a3b8;
  --slate-500: #64748b;
  --slate-600: #475569;
  --slate-700: #334155;
  --slate-800: #1e293b;
  --slate-900: #0f172a;

  --emerald-50: #ecfdf5;
  --emerald-500: #10b981;
  --emerald-600: #059669;
  --emerald-800: #065f46;

  --rose-50: #fff1f2;
  --rose-200: #fecdd3;
  --rose-600: #e11d48;
  --rose-700: #be123c;

  --amber-50: #fffbeb;
  --amber-200: #fde68a;
  --amber-500: #f59e0b;
  --amber-600: #d97706;
  --amber-700: #b45309;
  --amber-800: #92400e;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background-color: #fafafc;
  color: var(--slate-900);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent;
  line-height: 1.5;
}

h1, h2, h3, h4, p, ul, blockquote {
  margin: 0;
}

ul {
  padding: 0;
  list-style: none;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  background: none;
  border: none;
  padding: 0;
}

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

::selection {
  background: var(--sky);
  color: #ffffff;
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.3);
  border-radius: 9999px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(148, 163, 184, 0.5);
}

/* Icons */
.icon-xs { width: 10px; height: 10px; display: block; flex-shrink: 0; }
.icon-sm { width: 14px; height: 14px; display: block; flex-shrink: 0; }
.icon-md { width: 16px; height: 16px; display: block; flex-shrink: 0; }
.icon-lg { width: 20px; height: 20px; display: block; flex-shrink: 0; }
.icon-xl { width: 32px; height: 32px; display: block; flex-shrink: 0; }

/* Backgrounds */
.bg-stephane-grid {
  background-color: #4fa7e8;
  background-image:
    linear-gradient(to right, rgba(255, 255, 255, 0.14) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.14) 1px, transparent 1px);
  background-size: 36px 36px;
}

.bg-white-grid {
  background-color: #ffffff;
}

.font-serif-hero { font-family: var(--font-serif-hero); }
.font-mono { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.font-sans { font-family: var(--font-sans); }

/* App Shell */
.app-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.app-main {
  flex: 1;
  background-color: #ffffff;
}

.section-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 40px 16px;
}

@media (min-width: 640px) {
  .section-container {
    padding: 64px 24px;
  }
}

.section-divider-bottom {
  border-bottom: 1px solid rgba(226, 232, 240, 0.8);
}

.section-divider-top {
  border-top: 1px solid rgba(226, 232, 240, 0.8);
  margin-top: 48px;
}

/* ==========================================================================
   TopBar
   ========================================================================== */
.topbar-wrapper {
  position: sticky;
  top: 0;
  z-index: 40;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.topbar-wrapper.is-hidden {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  opacity: 0;
  transform: translateY(-100%);
  pointer-events: none;
}

.topbar {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(226, 232, 240, 0.8);
  padding: 10px 16px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  font-family: var(--font-mono);
  color: var(--slate-900);
  user-select: none;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

@media (min-width: 640px) {
  .topbar {
    padding: 10px 32px;
  }
}

.brand-link {
  display: flex;
  align-items: baseline;
  gap: 4px;
  transition: opacity 0.2s;
  flex-shrink: 0;
}
.brand-link:hover { opacity: 0.85; }

.brand-first {
  font-family: var(--font-serif-hero);
  font-size: 18px;
  font-weight: 400;
  color: var(--slate-900);
  letter-spacing: -0.025em;
}

.brand-last {
  font-family: var(--font-serif-hero);
  font-size: 18px;
  font-weight: 400;
  font-style: italic;
  color: var(--slate-700);
  letter-spacing: -0.025em;
}

@media (min-width: 640px) {
  .brand-first,
  .brand-last {
    font-size: 20px;
  }
}

.brand-candle {
  display: inline-block;
  transform: translateY(2px);
  margin: 0 2px;
}

.topbar-nav {
  display: none;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  letter-spacing: 0.05em;
}

@media (min-width: 768px) {
  .topbar-nav {
    display: flex;
  }
}

.nav-pill {
  padding: 4px 12px;
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-transform: uppercase;
  white-space: nowrap;
  cursor: pointer;
  color: var(--slate-600);
  transition: all 0.2s ease;
}

.nav-pill:hover {
  color: var(--slate-900);
  background: var(--slate-100);
}

.nav-pill.is-active {
  background: var(--sky);
  color: #ffffff;
  font-weight: 700;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}

.nav-pill-code {
  width: 14px;
  height: 14px;
  border-radius: 9999px;
  border: 1px solid var(--slate-400);
  color: var(--slate-600);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 8px;
  line-height: 1;
}

.nav-pill.is-active .nav-pill-code {
  border-color: #ffffff;
  color: #ffffff;
}

.topbar-contact-btn {
  padding: 4px 14px;
  font-size: 11px;
  font-weight: 700;
  color: #ffffff;
  background: var(--sky);
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  cursor: pointer;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
  transition: background 0.2s, transform 0.15s;
}
.topbar-contact-btn:hover { background: var(--sky-dark); }
.topbar-contact-btn:active { transform: scale(0.95); }

.topbar-contact-code {
  width: 14px;
  height: 14px;
  border-radius: 9999px;
  border: 1px solid #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 8px;
  line-height: 1;
}

/* ==========================================================================
   Mobile Bottom Tab Bar
   ========================================================================== */
.bottom-tab-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 40;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  border-top: 1px solid var(--slate-200);
  padding-bottom: env(safe-area-inset-bottom, 0px);
  font-family: var(--font-mono);
  color: var(--slate-800);
  box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.06);
}

@media (min-width: 768px) {
  .bottom-tab-bar {
    display: none;
  }
}

.bottom-tab-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  align-items: center;
  height: 56px;
  max-width: 512px;
  margin: 0 auto;
  padding: 0 4px;
}

.bottom-tab-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  min-width: 44px;
  padding: 4px 0;
  color: var(--slate-500);
  cursor: pointer;
  user-select: none;
  transition: color 0.2s;
}

.bottom-tab-btn.is-active {
  color: var(--sky-dark);
  font-weight: 700;
}

.bottom-tab-icon-wrap {
  position: relative;
}

.bottom-tab-dot {
  position: absolute;
  bottom: -4px;
  left: 50%;
  transform: translateX(-50%);
  width: 6px;
  height: 6px;
  border-radius: 9999px;
  background: var(--sky-dark);
}

.bottom-tab-label {
  font-size: 9px;
  letter-spacing: 0.05em;
  margin-top: 4px;
  white-space: nowrap;
  text-transform: uppercase;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero-section {
  position: relative;
  width: 100%;
  height: 100vh;
  min-height: 640px;
  color: #ffffff;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  user-select: none;
}

.hero-sparkle {
  position: absolute;
  pointer-events: none;
  transition: transform 0.7s ease-out;
}

.hero-header {
  position: relative;
  z-index: 20;
  padding: 20px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.9);
}

@media (min-width: 640px) {
  .hero-header {
    padding: 20px 40px;
    font-size: 11px;
  }
}

.hero-header-group {
  display: flex;
  align-items: center;
  gap: 24px;
}

.hero-nav-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  text-transform: uppercase;
  cursor: pointer;
  transition: opacity 0.2s, color 0.2s;
}
.hero-nav-btn:hover { color: #ffffff; }

.hero-nav-circle {
  width: 16px;
  height: 16px;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 9px;
  line-height: 1;
}

.hero-center {
  position: relative;
  z-index: 10;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.hero-wordmark {
  display: flex;
  align-items: baseline;
  justify-content: center;
  flex-wrap: wrap;
  user-select: none;
}

.hero-name-first,
.hero-name-last {
  font-family: var(--font-serif-hero);
  font-size: 3rem;
  line-height: 0.85;
  font-weight: 400;
  color: #ffffff;
}

.hero-name-first { letter-spacing: -0.03em; }
.hero-name-last { font-style: italic; letter-spacing: -0.025em; }

@media (min-width: 640px) {
  .hero-name-first, .hero-name-last { font-size: 4.5rem; }
}
@media (min-width: 768px) {
  .hero-name-first, .hero-name-last { font-size: 6rem; }
}
@media (min-width: 1024px) {
  .hero-name-first, .hero-name-last { font-size: 9.5rem; }
}
@media (min-width: 1280px) {
  .hero-name-first, .hero-name-last { font-size: 11.5rem; }
}

.hero-candle {
  margin: 0 8px;
  align-self: center;
  transform: translateY(8px);
}
@media (min-width: 640px) {
  .hero-candle { margin: 0 16px; transform: translateY(12px); }
}
@media (min-width: 768px) {
  .hero-candle { margin: 0 24px; transform: translateY(20px); }
}

.hero-subtitle {
  margin-top: 40px;
  text-align: center;
  color: rgba(255, 255, 255, 0.95);
  font-family: var(--font-serif-body);
  font-size: 12px;
  line-height: 1.625;
  letter-spacing: 0.025em;
  max-width: 768px;
  padding: 0 16px;
}

@media (min-width: 640px) {
  .hero-subtitle { margin-top: 56px; font-size: 14px; }
}
@media (min-width: 768px) {
  .hero-subtitle { margin-top: 80px; font-size: 16px; }
}
@media (min-width: 1024px) {
  .hero-subtitle { margin-top: 96px; }
}

.hero-subtitle-line {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}
@media (min-width: 640px) {
  .hero-subtitle-line {
    gap: 10px;
    flex-wrap: nowrap;
    white-space: nowrap;
  }
}

.hero-dot {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  opacity: 0.8;
}

.hero-location {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.8);
  font-family: var(--font-mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-top: 8px;
}
@media (min-width: 640px) {
  .hero-location { font-size: 12px; margin-top: 10px; }
}

.hero-footer {
  position: relative;
  z-index: 20;
  padding-bottom: 20px;
  text-align: center;
}

.hero-explore-btn {
  font-size: 10px;
  font-family: var(--font-mono);
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.8);
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: color 0.2s;
}
.hero-explore-btn:hover { color: #ffffff; }

@keyframes bounce-y {
  0%, 100% { transform: translateY(-25%); }
  50% { transform: translateY(0); }
}
.animate-bounce {
  display: inline-block;
  animation: bounce-y 1s infinite;
}

/* ==========================================================================
   Shared Cards, Headings, Pills
   ========================================================================== */
.section-h1 {
  font-family: var(--font-serif-hero);
  font-size: 30px;
  color: var(--slate-900);
  letter-spacing: -0.025em;
  font-weight: 400;
}
@media (min-width: 640px) { .section-h1 { font-size: 36px; } }
@media (min-width: 768px) { .section-h1 { font-size: 48px; } }

.section-h2 {
  font-family: var(--font-serif-hero);
  font-size: 30px;
  color: var(--slate-900);
  font-weight: 400;
  letter-spacing: -0.025em;
}
@media (min-width: 640px) { .section-h2 { font-size: 36px; } }
@media (min-width: 768px) { .section-h2 { font-size: 48px; } }

.section-sub {
  color: var(--slate-600);
  font-size: 12px;
  font-family: var(--font-sans);
  max-width: 768px;
  margin-top: 8px;
  line-height: 1.625;
}
@media (min-width: 640px) { .section-sub { font-size: 14px; } }

.card-white {
  background: #ffffff;
  color: var(--slate-900);
  border-radius: 28px;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.06);
  border: 1px solid rgba(226, 232, 240, 0.8);
}

/* ==========================================================================
   Introduction Section
   ========================================================================== */
.intro-card {
  position: relative;
  padding: 24px;
  overflow: hidden;
}
@media (min-width: 640px) { .intro-card { padding: 32px; } }
@media (min-width: 768px) { .intro-card { padding: 40px; } }

.intro-corner-cross {
  position: absolute;
  top: 16px;
  right: 16px;
  pointer-events: none;
  opacity: 0.8;
}

.intro-stack {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.intro-header {
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(226, 232, 240, 0.8);
}

.intro-name {
  font-family: var(--font-serif-hero);
  font-size: 20px;
  font-weight: 700;
  color: var(--slate-900);
  letter-spacing: -0.025em;
}
@media (min-width: 640px) { .intro-name { font-size: 24px; } }

.intro-loc {
  font-size: 12px;
  color: var(--slate-500);
  font-family: var(--font-mono);
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 4px;
}
@media (min-width: 640px) { .intro-loc { font-size: 14px; } }

.intro-badge {
  font-size: 11px;
  font-family: var(--font-mono);
  color: var(--slate-400);
  background: var(--slate-50);
  padding: 4px 10px;
  border-radius: 6px;
  border: 1px solid rgba(226, 232, 240, 0.6);
}

.intro-prose {
  display: flex;
  flex-direction: column;
  gap: 16px;
  font-size: 16px;
  color: var(--slate-700);
  line-height: 1.625;
  max-width: 1024px;
}
@media (min-width: 640px) { .intro-prose { font-size: 18px; } }

.intro-domains {
  padding-top: 16px;
  border-top: 1px solid rgba(226, 232, 240, 0.8);
  width: 100%;
}

.intro-domains-label {
  font-size: 10px;
  font-family: var(--font-mono);
  color: var(--slate-400);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 10px;
}

.intro-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 12px;
}
@media (min-width: 640px) { .intro-pills { font-size: 14px; } }

.domain-pill {
  padding: 6px 14px;
  border-radius: 9999px;
  background: var(--slate-100);
  color: var(--slate-700);
  font-weight: 500;
  border: 1px solid var(--slate-200);
}

.domain-pill--primary {
  background: #f1f5f9;
  color: #314158;
  border-color: rgba(79, 167, 232, 0.2);
}

/* ==========================================================================
   News & Field Dispatches
   ========================================================================== */
.news-section {
  max-width: 1280px;
  margin: 0 auto;
  padding: 32px 16px;
}
@media (min-width: 640px) { .news-section { padding: 48px 24px; } }

.news-header {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
}
@media (min-width: 640px) {
  .news-header {
    flex-direction: row;
    align-items: center;
  }
}

.news-title {
  font-family: var(--font-serif-hero);
  font-size: 30px;
  color: var(--slate-900);
  font-weight: 400;
  letter-spacing: -0.025em;
}
@media (min-width: 640px) { .news-title { font-size: 36px; } }
@media (min-width: 768px) { .news-title { font-size: 48px; } }

.segmented-control {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  background: var(--slate-100);
  border-radius: 9999px;
  border: 1px solid rgba(226, 232, 240, 0.8);
  font-family: var(--font-mono);
  font-size: 11px;
  align-self: flex-start;
}
@media (min-width: 640px) { .segmented-control { align-self: auto; } }

.segmented-btn {
  padding: 4px 12px;
  font-size: 11px;
  font-weight: 700;
  border-radius: 9999px;
  color: var(--slate-600);
  cursor: pointer;
  transition: color 0.15s, background 0.15s;
}
.segmented-btn:hover { color: var(--slate-900); }
.segmented-btn.is-active {
  background: #ffffff;
  color: var(--slate-900);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}

.news-list-card {
  background: #ffffff;
  color: var(--slate-900);
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.05);
  border: 1px solid rgba(226, 232, 240, 0.8);
}

.news-row {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 8px;
  padding: 16px 20px;
  transition: background 0.15s;
}
.news-row:hover {
  background: rgba(248, 250, 252, 0.8);
}
@media (min-width: 640px) {
  .news-row {
    flex-direction: row;
    align-items: center;
  }
}

.news-row-main {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  flex: 1;
}

.news-date {
  font-size: 12px;
  font-family: var(--font-mono);
  color: var(--slate-500);
  flex-shrink: 0;
  width: 96px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.news-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-family: var(--font-mono);
  padding: 2px 10px;
  border-radius: 9999px;
  background: var(--slate-100);
  color: var(--slate-700);
  flex-shrink: 0;
  border: 1px solid var(--slate-200);
}

.news-item-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--slate-900);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.news-loc {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--slate-500);
  font-family: var(--font-mono);
  flex-shrink: 0;
  padding-left: 32px;
}
@media (min-width: 640px) { .news-loc { padding-left: 0; } }

.news-expand-wrap {
  margin-top: 16px;
  display: flex;
  justify-content: center;
}

.outline-pill-btn {
  padding: 10px 20px;
  border-radius: 9999px;
  font-size: 12px;
  font-weight: 700;
  font-family: var(--font-mono);
  color: var(--slate-800);
  background: #ffffff;
  border: 1px solid var(--slate-300);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.2s;
}
.outline-pill-btn:hover {
  background: var(--slate-50);
  border-color: var(--slate-400);
}

/* ==========================================================================
   Selected Research (ProjectsList)
   ========================================================================== */
.projects-header {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 32px;
}
@media (min-width: 640px) {
  .projects-header {
    flex-direction: row;
    align-items: flex-end;
  }
}

.filter-pills-row {
  display: flex;
  align-items: center;
  gap: 6px;
  overflow-x: auto;
  max-width: 100%;
  flex-shrink: 0;
  padding-bottom: 4px;
  font-family: var(--font-mono);
  font-size: 12px;
}

.filter-pill-btn {
  padding: 4px 12px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  white-space: nowrap;
  border-radius: 9999px;
  border: 1px solid var(--slate-200);
  background: var(--slate-100);
  color: var(--slate-700);
  cursor: pointer;
  transition: all 0.15s;
}
.filter-pill-btn:hover { background: rgba(226, 232, 240, 0.7); }
.filter-pill-btn.is-active {
  background: var(--sky);
  color: #ffffff;
  border-color: var(--sky);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}

.projects-list {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.study-card {
  padding: 24px;
  background: #ffffff;
  color: var(--slate-900);
  border-radius: 28px;
  box-shadow: 0 10px 35px rgba(0, 0, 0, 0.05);
  border: 1px solid rgba(226, 232, 240, 0.8);
  transition: box-shadow 0.2s;
}
.study-card:hover {
  box-shadow: 0 15px 45px rgba(0, 0, 0, 0.08);
}
@media (min-width: 640px) { .study-card { padding: 32px; } }

.study-title {
  font-family: var(--font-serif-hero);
  font-size: 20px;
  font-weight: 700;
  color: var(--slate-900);
  letter-spacing: -0.025em;
}
@media (min-width: 640px) { .study-title { font-size: 24px; } }

.study-subtitle {
  font-size: 12px;
  color: var(--slate-600);
  line-height: 1.625;
  margin-top: 4px;
}
@media (min-width: 640px) { .study-subtitle { font-size: 14px; } }

.study-abstract-section {
  margin-top: 16px;
  padding-top: 14px;
}

.abstract-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 10px;
  font-family: var(--font-mono);
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--sky-ink);
  background: rgba(79, 167, 232, 0.1);
  padding: 2px 10px;
  border-radius: 9999px;
  border: 1px solid rgba(79, 167, 232, 0.2);
  margin-bottom: 8px;
}

.dot-blue-sm {
  width: 6px;
  height: 6px;
  border-radius: 9999px;
  background: var(--sky-dark);
}

.dot-blue-md {
  width: 8px;
  height: 8px;
  border-radius: 9999px;
  background: var(--sky-dark);
}

.study-abstract-box {
  padding: 16px;
  background: rgba(248, 250, 252, 0.9);
  border-radius: 16px;
  border: 1px solid var(--slate-100);
  color: var(--slate-700);
  font-size: 12px;
  line-height: 1.625;
}
@media (min-width: 640px) {
  .study-abstract-box { padding: 20px; font-size: 14px; }
}

.study-action-row {
  margin-top: 20px;
  padding-top: 12px;
  display: flex;
  justify-content: flex-end;
}

.primary-pill-btn {
  padding: 6px 16px;
  font-size: 12px;
  font-weight: 700;
  font-family: var(--font-mono);
  color: #ffffff;
  background: var(--sky);
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
  transition: background 0.2s;
}
.primary-pill-btn:hover { background: var(--sky-dark); }

/* ==========================================================================
   Case Study Full Page
   ========================================================================== */
.case-study-page {
  min-height: 100vh;
  max-width: 1024px;
  margin: 0 auto;
  padding: 32px 16px;
  color: var(--slate-900);
}
@media (min-width: 640px) { .case-study-page { padding: 48px 24px; } }

.case-back-bar {
  margin-bottom: 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.case-back-btn {
  padding: 8px 16px;
  border-radius: 9999px;
  background: #ffffff;
  color: var(--slate-800);
  border: 1px solid rgba(226, 232, 240, 0.8);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: background 0.15s;
}
.case-back-btn:hover { background: var(--slate-50); }

.case-spec-badge {
  display: none;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 9999px;
  background: rgba(79, 167, 232, 0.15);
  color: var(--sky-deep);
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
}
@media (min-width: 640px) { .case-spec-badge { display: inline-flex; } }

.case-article-card {
  background: #ffffff;
  border-radius: 28px;
  box-shadow: 0 15px 45px rgba(0, 0, 0, 0.06);
  border: 1px solid rgba(226, 232, 240, 0.8);
  overflow: hidden;
}

.case-hero-header {
  padding: 24px;
  border-bottom: 1px solid var(--slate-100);
  display: flex;
  flex-direction: column;
  gap: 16px;
}
@media (min-width: 640px) { .case-hero-header { padding: 40px; } }

.case-meta-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-family: var(--font-mono);
  color: var(--slate-500);
}

.case-domain { font-weight: 700; color: var(--sky-ink); text-transform: uppercase; }

.case-h1 {
  font-family: var(--font-serif-hero);
  font-size: 30px;
  font-weight: 400;
  color: var(--slate-900);
  letter-spacing: -0.025em;
  line-height: 1.2;
}
@media (min-width: 640px) { .case-h1 { font-size: 36px; } }
@media (min-width: 768px) { .case-h1 { font-size: 48px; } }

.case-subtitle {
  font-size: 14px;
  color: var(--slate-600);
  line-height: 1.625;
  max-width: 768px;
}
@media (min-width: 640px) { .case-subtitle { font-size: 16px; } }

.case-takeaway {
  margin-top: 8px;
  padding: 20px;
  background: rgba(79, 167, 232, 0.1);
  border-radius: 16px;
  border: 1px solid rgba(79, 167, 232, 0.2);
}
@media (min-width: 640px) { .case-takeaway { padding: 24px; } }

.case-takeaway-label {
  font-size: 10px;
  font-family: var(--font-mono);
  font-weight: 700;
  text-transform: uppercase;
  color: var(--sky-deep);
  margin-bottom: 6px;
}

.case-takeaway-text {
  font-family: var(--font-serif-hero);
  color: var(--slate-900);
  font-size: 18px;
}
@media (min-width: 640px) { .case-takeaway-text { font-size: 20px; } }

.case-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 40px;
  color: var(--slate-800);
  font-size: 14px;
  line-height: 1.625;
}
@media (min-width: 640px) { .case-body { padding: 40px; } }

.case-section {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.case-h2 {
  font-family: var(--font-serif-hero);
  font-size: 20px;
  font-weight: 400;
  color: var(--slate-900);
  border-bottom: 1px solid var(--slate-100);
  padding-bottom: 8px;
}
@media (min-width: 640px) { .case-h2 { font-size: 24px; } }

.case-prose {
  color: var(--slate-600);
  font-size: 14px;
  line-height: 1.625;
}
@media (min-width: 640px) { .case-prose { font-size: 16px; } }

.case-rq-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 12px;
  color: var(--slate-700);
}
@media (min-width: 640px) { .case-rq-list { font-size: 14px; } }

.case-rq-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.case-methods-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-family: var(--font-mono);
  color: var(--slate-700);
}

.case-method-chip {
  padding: 4px 12px;
  border-radius: 9999px;
  background: var(--slate-100);
  border: 1px solid rgba(226, 232, 240, 0.7);
  text-transform: uppercase;
  font-size: 11px;
}

.case-cohort-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  padding-top: 8px;
  font-family: var(--font-mono);
}
@media (min-width: 640px) { .case-cohort-grid { grid-template-columns: 1fr 1fr; } }

.case-table-wrap {
  border: 1px solid rgba(226, 232, 240, 0.8);
  border-radius: 16px;
  overflow-x: auto;
  background: #ffffff;
}

.case-table {
  width: 100%;
  text-align: left;
  font-size: 12px;
  font-family: var(--font-mono);
  border-collapse: collapse;
}
@media (min-width: 640px) { .case-table { font-size: 14px; } }

.case-table thead {
  background: rgba(241, 245, 249, 0.8);
  color: var(--slate-700);
  border-bottom: 1px solid var(--slate-200);
}

.case-table th,
.case-table td {
  padding: 12px 16px;
}

.case-table tbody tr + tr {
  border-top: 1px solid var(--slate-100);
}

.case-table tbody tr:hover {
  background: rgba(248, 250, 252, 0.6);
}

.case-footer-strip {
  padding: 24px;
  border-top: 1px solid var(--slate-100);
  background: rgba(248, 250, 252, 0.6);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
@media (min-width: 640px) { .case-footer-strip { padding: 24px 40px; } }

/* ==========================================================================
   Interactive Prototypes (Pomodoro + Todo List)
   ========================================================================== */
.proto-tabs-row {
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  max-width: 100%;
  margin-bottom: 24px;
  padding-bottom: 8px;
  font-family: var(--font-mono);
  font-size: 12px;
}

.proto-tab-btn {
  padding: 8px 16px;
  border-radius: 9999px;
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  background: var(--slate-100);
  color: var(--slate-700);
  border: 1px solid rgba(226, 232, 240, 0.8);
  transition: all 0.2s;
}
.proto-tab-btn:hover { background: rgba(226, 232, 240, 0.7); }
.proto-tab-btn.is-active {
  background: var(--sky);
  color: #ffffff;
  border-color: var(--sky);
  font-weight: 700;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}

.proto-card-shell {
  background: #ffffff;
  color: var(--slate-900);
  border-radius: 28px;
  box-shadow: 0 15px 45px rgba(0, 0, 0, 0.06);
  border: 1px solid rgba(226, 232, 240, 0.8);
  overflow: hidden;
}

/* Shared Prototype Inner Card & Header Lockup (Exact alignment across tabs) */
.proto-inner {
  width: 100%;
  background: #ffffff;
  color: var(--slate-900);
  padding: 24px;
  font-family: var(--font-sans);
}
@media (min-width: 640px) {
  .proto-inner { padding: 32px; }
}

.proto-header {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--slate-100);
}
@media (min-width: 640px) {
  .proto-header--sm-row {
    flex-direction: row;
    align-items: center;
  }
}
@media (min-width: 1024px) {
  .proto-header--lg-row {
    flex-direction: row;
    align-items: center;
  }
}

.proto-title-wrap {
  flex-shrink: 0;
}

.proto-title-lockup {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 38px;
}

.proto-icon-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  border-radius: 8px;
  background: #f0f9ff;
  color: var(--sky);
  border: 1px solid #e0f2fe;
}

.proto-h3 {
  font-family: var(--font-serif-hero);
  font-size: 20px;
  font-weight: 400;
  color: var(--slate-900);
  letter-spacing: -0.025em;
  line-height: 1.375;
}
@media (min-width: 640px) {
  .proto-h3 { font-size: 24px; }
}

/* Pomodoro */
.pomodoro-presets {
  display: flex;
  align-items: center;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 4px;
  font-family: var(--font-mono);
  font-size: 12px;
  min-width: 0;
}

.preset-pill {
  padding: 4px 10px;
  border-radius: 9999px;
  font-size: 11px;
  background: var(--slate-100);
  color: var(--slate-700);
  border: 1px solid rgba(226, 232, 240, 0.8);
  text-transform: uppercase;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.15s;
}
.preset-pill:hover { background: var(--slate-200); }

.pomodoro-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  margin-top: 32px;
  align-items: center;
}
@media (min-width: 1024px) {
  .pomodoro-grid {
    grid-template-columns: 1fr 1fr;
    gap: 48px;
  }
}

.pomodoro-dial-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.mode-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  background: var(--slate-100);
  border-radius: 9999px;
  border: 1px solid rgba(226, 232, 240, 0.8);
  font-family: var(--font-mono);
  font-size: 12px;
  margin-bottom: 32px;
}

.mode-tab {
  padding: 6px 14px;
  border-radius: 9999px;
  font-weight: 700;
  color: var(--slate-500);
  cursor: pointer;
  transition: all 0.2s;
}
.mode-tab:hover { color: var(--slate-900); }
.mode-tab.is-active {
  background: #ffffff;
  color: var(--slate-900);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}
.mode-tab.is-active-short { color: var(--emerald-800); }
.mode-tab.is-active-long { color: var(--sky-deep); }

.timer-gauge {
  position: relative;
  width: 256px;
  height: 256px;
  display: flex;
  align-items: center;
  justify-content: center;
}
@media (min-width: 640px) {
  .timer-gauge { width: 288px; height: 288px; }
}

.timer-svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.timer-center-display {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.timer-mode-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--slate-400);
}

.timer-digits {
  font-family: var(--font-serif-hero);
  font-size: 50px;
  color: var(--slate-900);
  letter-spacing: -0.025em;
  font-weight: 400;
  margin-top: 0;
  margin-bottom: 5px;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.timer-sub-duration {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-family: var(--font-mono);
  color: var(--slate-500);
  margin-top: 5px;
}

.timer-controls {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 32px;
}

.icon-circle-btn {
  padding: 12px;
  border-radius: 9999px;
  border: 1px solid var(--slate-200);
  background: var(--slate-50);
  color: var(--slate-600);
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.icon-circle-btn:hover { background: var(--slate-100); color: var(--slate-900); }

.start-routine-btn {
  padding: 12px 32px;
  border-radius: 9999px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #ffffff;
  background: var(--sky-dark);
  box-shadow: 0 4px 12px rgba(56, 136, 204, 0.2);
  cursor: pointer;
  transition: background 0.15s;
}
.start-routine-btn:hover { background: var(--sky-darker); }
.start-routine-btn.is-running {
  background: var(--amber-600);
  box-shadow: 0 4px 12px rgba(217, 119, 6, 0.2);
}
.start-routine-btn.is-running:hover { background: var(--amber-700); }

.pomodoro-right-col {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.intent-box {
  padding: 20px;
  background: rgba(248, 250, 252, 0.8);
  border-radius: 24px;
  border: 1px solid rgba(226, 232, 240, 0.8);
  display: flex;
  flex-direction: column;
  gap: 14px;
}
@media (min-width: 640px) { .intent-box { padding: 24px; } }

.intent-form {
  display: flex;
  gap: 8px;
}

.text-input-sm {
  flex: 1;
  padding: 8px 14px;
  font-size: 12px;
  background: #ffffff;
  border-radius: 12px;
  border: 1px solid var(--slate-200);
  font-family: var(--font-sans);
  color: var(--slate-800);
  outline: none;
}
.text-input-sm:focus {
  border-color: var(--sky);
  box-shadow: 0 0 0 2px rgba(79, 167, 232, 0.25);
}

.add-btn-sm {
  padding: 8px 16px;
  font-size: 12px;
  font-family: var(--font-mono);
  font-weight: 700;
  background: var(--sky-dark);
  color: #ffffff;
  border-radius: 12px;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.15s, opacity 0.15s;
}
.add-btn-sm:hover { background: var(--sky-darker); }
.add-btn-sm:disabled { opacity: 0.4; cursor: not-allowed; }

.intent-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding-top: 4px;
}

.intent-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 12px;
  font-size: 12px;
  border: 1px solid var(--slate-200);
  background: rgba(255, 255, 255, 0.7);
  color: var(--slate-700);
  cursor: pointer;
  user-select: none;
  transition: all 0.15s;
}
.intent-chip:hover { background: #ffffff; border-color: var(--slate-300); }
.intent-chip.is-selected {
  background: #ffffff;
  color: var(--slate-900);
  border-color: var(--sky-dark);
  font-weight: 600;
  box-shadow: 0 0 0 1px rgba(56, 136, 204, 0.3);
}

.chip-del-btn {
  margin-left: 4px;
  color: var(--slate-400);
  padding: 2px;
  border-radius: 9999px;
  cursor: pointer;
}
.chip-del-btn:hover { color: var(--rose-600); }

.metrics-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  font-family: var(--font-mono);
  font-size: 12px;
}

.metric-subcard {
  padding: 16px;
  background: rgba(248, 250, 252, 0.8);
  border-radius: 20px;
  border: 1px solid rgba(226, 232, 240, 0.8);
}

.cycle-dots {
  display: flex;
  align-items: center;
  gap: 4px;
}

.cycle-dot {
  width: 14px;
  height: 14px;
  border-radius: 9999px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 9px;
  background: var(--slate-200);
  color: var(--slate-400);
}
.cycle-dot.is-done {
  background: var(--sky-dark);
  color: #ffffff;
}

.duration-customizer {
  padding: 16px 20px;
  background: #ffffff;
  border-radius: 20px;
  border: 1px solid rgba(226, 232, 240, 0.8);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-family: var(--font-mono);
  font-size: 12px;
}

.stepper-btn {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  background: var(--slate-100);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: var(--slate-700);
  cursor: pointer;
}
.stepper-btn:hover { background: var(--slate-200); }

/* ==========================================================================
   To-Do List Routine
   ========================================================================== */
.progress-pill {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--slate-50);
  border: 1px solid rgba(226, 232, 240, 0.7);
  border-radius: 16px;
  padding: 8px 16px;
  align-self: flex-start;
  font-family: var(--font-mono);
  font-size: 12px;
}
@media (min-width: 640px) { .progress-pill { align-self: auto; } }

.progress-track {
  width: 80px;
  background: var(--slate-200);
  border-radius: 9999px;
  height: 8px;
  overflow: hidden;
}

.progress-fill {
  background: var(--sky);
  height: 100%;
  border-radius: 9999px;
  transition: width 0.3s ease;
}

.todo-form-card {
  margin-top: 24px;
  background: rgba(248, 250, 252, 0.7);
  border: 1px solid rgba(226, 232, 240, 0.8);
  border-radius: 16px;
  padding: 16px;
}
@media (min-width: 640px) { .todo-form-card { padding: 20px; } }

.todo-form-row {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
@media (min-width: 640px) { .todo-form-row { flex-direction: row; } }

.todo-input {
  flex: 1;
  background: #ffffff;
  border: 1px solid var(--slate-200);
  border-radius: 12px;
  padding: 10px 16px;
  font-size: 14px;
  color: var(--slate-800);
  outline: none;
}
.todo-input:focus {
  border-color: var(--sky);
  box-shadow: 0 0 0 2px rgba(79, 167, 232, 0.25);
}

.todo-controls-group {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
@media (min-width: 640px) { .todo-controls-group { flex-wrap: nowrap; } }

.priority-box {
  display: flex;
  align-items: center;
  background: #ffffff;
  border: 1px solid var(--slate-200);
  border-radius: 12px;
  padding: 4px;
  font-size: 12px;
  font-family: var(--font-mono);
}

.priority-btn {
  padding: 4px 10px;
  border-radius: 8px;
  color: var(--slate-500);
  cursor: pointer;
}
.priority-btn:hover { color: var(--slate-700); }
.priority-btn.is-high {
  background: var(--rose-50);
  color: var(--rose-700);
  font-weight: 700;
  border: 1px solid var(--rose-200);
}
.priority-btn.is-routine {
  background: #f0f9ff;
  color: #0284c7;
  font-weight: 700;
  border: 1px solid #bae6fd;
}
.priority-btn.is-low {
  background: rgba(226, 232, 240, 0.7);
  color: var(--slate-700);
  font-weight: 700;
}

.duration-box {
  display: flex;
  align-items: center;
  gap: 4px;
  background: #ffffff;
  border: 1px solid var(--slate-200);
  border-radius: 12px;
  padding: 4px 10px;
  font-size: 12px;
  font-family: var(--font-mono);
  color: var(--slate-600);
}

.duration-box.is-custom {
  border-color: var(--sky);
  gap: 6px;
}

.duration-select {
  background: transparent;
  border: none;
  font-size: 12px;
  font-family: var(--font-mono);
  color: var(--slate-700);
  outline: none;
  cursor: pointer;
}

.duration-number-input {
  width: 48px;
  background: var(--slate-50);
  border: 1px solid var(--slate-200);
  border-radius: 4px;
  padding: 2px 4px;
  font-size: 12px;
  font-family: var(--font-mono);
  text-align: center;
  font-weight: 700;
  outline: none;
}
.duration-number-input:focus { border-color: var(--sky); }

.todo-add-btn {
  background: var(--sky);
  color: #ffffff;
  font-size: 12px;
  font-family: var(--font-mono);
  padding: 10px 16px;
  border-radius: 12px;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: background 0.15s, opacity 0.15s;
}
.todo-add-btn:hover { background: #3d96d7; }
.todo-add-btn:disabled { opacity: 0.4; cursor: not-allowed; }

.todo-filter-strip {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 12px;
  margin-top: 24px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--slate-100);
  font-family: var(--font-mono);
  font-size: 12px;
}
@media (min-width: 640px) {
  .todo-filter-strip { flex-direction: row; align-items: center; }
}

.todo-filter-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
  background: rgba(241, 245, 249, 0.8);
  padding: 4px;
  border-radius: 12px;
}

.todo-filter-tab {
  padding: 4px 12px;
  border-radius: 8px;
  color: var(--slate-500);
  cursor: pointer;
}
.todo-filter-tab:hover { color: var(--slate-700); }
.todo-filter-tab.is-active {
  background: #ffffff;
  color: var(--slate-900);
  font-weight: 700;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.todo-list {
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.todo-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid var(--slate-200);
  background: #ffffff;
  color: var(--slate-800);
  transition: all 0.15s;
}
@media (min-width: 640px) { .todo-item { padding: 16px; } }
.todo-item:hover {
  border-color: var(--slate-300);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}
.todo-item.is-completed {
  background: rgba(248, 250, 252, 0.6);
  border-color: rgba(226, 232, 240, 0.6);
  color: var(--slate-400);
}

.todo-checkbox {
  width: 20px;
  height: 20px;
  border-radius: 6px;
  border: 2px solid var(--slate-300);
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  cursor: pointer;
}
.todo-checkbox:hover { border-color: var(--sky); }
.todo-checkbox.is-checked {
  background: var(--sky);
  border: 1px solid var(--sky);
  color: #ffffff;
}

.todo-title {
  font-size: 14px;
  line-height: 1.375;
  cursor: pointer;
  user-select: none;
}
.todo-title.is-completed {
  text-decoration: line-through;
  color: var(--slate-400);
}

.todo-summary-grid {
  margin-top: 32px;
  padding-top: 20px;
  border-top: 1px solid var(--slate-100);
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  font-family: var(--font-mono);
  text-align: center;
}
@media (min-width: 640px) {
  .todo-summary-grid { grid-template-columns: repeat(4, 1fr); }
}

.todo-stat-box {
  padding: 12px;
  background: rgba(248, 250, 252, 0.8);
  border-radius: 12px;
  border: 1px solid rgba(226, 232, 240, 0.6);
}

/* ==========================================================================
   Previous Prototypes Section
   ========================================================================== */
.prev-header-row {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
}
@media (min-width: 640px) {
  .prev-header-row { flex-direction: row; align-items: flex-end; }
}

.prev-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}
@media (min-width: 768px) { .prev-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .prev-grid { grid-template-columns: repeat(3, 1fr); } }

.proto-archive-card {
  padding: 20px;
  background: #ffffff;
  border-radius: 24px;
  box-shadow: 0 10px 35px rgba(0, 0, 0, 0.05);
  border: 1px solid rgba(226, 232, 240, 0.8);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: var(--slate-900);
  transition: transform 0.2s, box-shadow 0.2s;
}
.proto-archive-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 15px 45px rgba(0, 0, 0, 0.08);
}
@media (min-width: 640px) { .proto-archive-card { padding: 24px; } }

.spec-badge {
  padding: 2px 8px;
  border-radius: 9999px;
  background: rgba(79, 167, 232, 0.15);
  color: var(--sky-deep);
  font-weight: 700;
}

.cat-badge {
  padding: 2px 8px;
  border-radius: 9999px;
  font-size: 9px;
  text-transform: uppercase;
  font-weight: 700;
  border: 1px solid rgba(226, 232, 240, 0.6);
  background: var(--slate-100);
  color: var(--slate-600);
  cursor: pointer;
  transition: all 0.15s;
}
.cat-badge:hover {
  background: rgba(79, 167, 232, 0.15);
  color: var(--sky-deep);
  border-color: rgba(79, 167, 232, 0.3);
}
.cat-badge.is-active {
  background: var(--sky);
  color: #ffffff;
  border-color: var(--sky);
}

.media-placeholder-btn {
  width: 100%;
  padding: 16px 12px;
  border-radius: 16px;
  border: 1px dashed var(--slate-300);
  background: rgba(248, 250, 252, 0.5);
  color: var(--slate-500);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
  font-family: var(--font-mono);
  font-size: 12px;
  transition: all 0.15s;
}
.media-placeholder-btn:hover {
  border-color: var(--sky);
  background: rgba(240, 249, 255, 0.4);
  color: var(--sky-deep);
}

.media-box {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(226, 232, 240, 0.8);
  background: var(--slate-900);
}

.media-aspect {
  width: 100%;
  aspect-ratio: 16 / 9;
  display: block;
  border: 0;
  object-fit: cover;
}

.media-overlay-actions {
  position: absolute;
  top: 8px;
  right: 8px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.media-overlay-btn {
  padding: 2px 8px;
  background: rgba(0, 0, 0, 0.7);
  color: #ffffff;
  font-size: 10px;
  font-family: var(--font-mono);
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
}
.media-overlay-btn:hover { background: #000000; }

.media-remove-btn {
  padding: 4px;
  background: rgba(0, 0, 0, 0.7);
  color: #ffffff;
  border-radius: 6px;
  cursor: pointer;
}
.media-remove-btn:hover { background: var(--rose-600); }

.media-editor-box {
  padding: 12px;
  background: var(--slate-50);
  border: 1px solid var(--sky);
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 12px;
  font-family: var(--font-mono);
}

/* ==========================================================================
   Research, Teaching, About Sections
   ========================================================================== */
.grid-3col {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}
@media (min-width: 768px) { .grid-3col { grid-template-columns: repeat(3, 1fr); } }

.grid-2col-sm {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
@media (min-width: 640px) { .grid-2col-sm { grid-template-columns: repeat(2, 1fr); } }

.theme-card {
  padding: 24px;
  background: #ffffff;
  color: var(--slate-900);
  border-radius: 24px;
  box-shadow: 0 10px 35px rgba(0, 0, 0, 0.04);
  border: 1px solid rgba(226, 232, 240, 0.8);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.2s, box-shadow 0.2s;
}
.theme-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 15px 45px rgba(0, 0, 0, 0.08);
}

.icon-circle-sky {
  width: 40px;
  height: 40px;
  border-radius: 9999px;
  background: rgba(79, 167, 232, 0.1);
  color: var(--sky-deep);
  display: flex;
  align-items: center;
  justify-content: center;
}

.pub-card {
  padding: 24px;
  background: #ffffff;
  color: var(--slate-900);
  border-radius: 24px;
  box-shadow: 0 10px 35px rgba(0, 0, 0, 0.04);
  border: 1px solid rgba(226, 232, 240, 0.8);
}

.pub-header-row {
  cursor: pointer;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.pub-toggle-btn {
  width: 32px;
  height: 32px;
  border-radius: 9999px;
  background: var(--slate-100);
  color: var(--slate-700);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  cursor: pointer;
}
.pub-toggle-btn:hover { background: var(--slate-200); }

.award-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 9999px;
  background: var(--amber-50);
  color: var(--amber-800);
  border: 1px solid rgba(253, 230, 138, 0.8);
  font-size: 12px;
  font-family: var(--font-mono);
  font-weight: 700;
  text-transform: uppercase;
}

.view-pub-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 16px;
  border-radius: 9999px;
  background: var(--sky);
  color: #ffffff;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  transition: background 0.15s;
}
.view-pub-btn:hover { background: var(--sky-dark); }

/* About Section */
.about-avatar {
  width: 80px;
  height: 80px;
  border-radius: 9999px;
  object-fit: cover;
  border: 2px solid #ffffff;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.12);
  outline: 2px solid rgba(79, 167, 232, 0.3);
  flex-shrink: 0;
}
@media (min-width: 640px) {
  .about-avatar { width: 96px; height: 96px; }
}

.soft-box {
  padding: 20px;
  background: rgba(248, 250, 252, 0.8);
  border-radius: 16px;
  border: 1px solid rgba(226, 232, 240, 0.6);
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  border-top: 1px solid var(--slate-200);
  background: #ffffff;
  backdrop-filter: blur(4px);
  padding: 40px 16px;
  font-size: 12px;
  color: var(--slate-600);
  margin-bottom: 56px;
  font-family: var(--font-mono);
}
@media (min-width: 768px) { .site-footer { margin-bottom: 0; } }

.footer-inner {
  max-width: 1152px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
@media (min-width: 640px) {
  .footer-inner { flex-direction: row; }
}

.footer-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  text-align: center;
}
@media (min-width: 640px) {
  .footer-brand { flex-direction: row; text-align: left; }
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 11px;
}

.footer-pill {
  padding: 6px 12px;
  border-radius: 9999px;
  background: var(--slate-100);
  border: 1px solid var(--slate-200);
  color: var(--slate-700);
}

.footer-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 9999px;
  background: var(--slate-100);
  border: 1px solid var(--slate-200);
  color: var(--slate-800);
  cursor: pointer;
  transition: all 0.15s;
}
.footer-btn:hover {
  background: var(--sky);
  color: #ffffff;
  border-color: var(--sky);
}

/* ==========================================================================
   Contact Modal
   ========================================================================== */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(15, 41, 66, 0.6);
  backdrop-filter: blur(10px);
}

.modal-card {
  width: 100%;
  max-width: 448px;
  background: #ffffff;
  color: var(--slate-900);
  border-radius: 28px;
  box-shadow: 0 25px 70px rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.9);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
@media (min-width: 640px) { .modal-card { padding: 28px; } }

.modal-submit-btn {
  width: 100%;
  padding: 10px;
  background: var(--sky-dark);
  color: #ffffff;
  font-weight: 700;
  font-size: 12px;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 9999px;
  font-family: var(--font-mono);
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(56, 136, 204, 0.25);
}
.modal-submit-btn:hover { background: var(--sky-darker); }

/* Utilities */
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.flex-center { display: flex; align-items: center; }
.gap-1-5 { gap: 6px; }
.gap-2 { gap: 8px; }
.gap-3 { gap: 12px; }
.text-mono { font-family: var(--font-mono); }
.text-sky-ink { color: var(--sky-ink); }
.text-sky-deep { color: var(--sky-deep); }
.text-sky-dark { color: var(--sky-dark); }
.text-slate-400 { color: var(--slate-400); }
.text-slate-500 { color: var(--slate-500); }
.text-slate-600 { color: var(--slate-600); }
.text-slate-700 { color: var(--slate-700); }
.text-slate-800 { color: var(--slate-800); }
.text-slate-900 { color: var(--slate-900); }
.text-emerald { color: var(--emerald-600); }
.hidden { display: none !important; }
