@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&display=swap');

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

:root {
  --bg: #ffffff;
  --text-primary: #111111;
  --text-secondary: #737373;
  --border: #e5e7eb;
  --card-bg: #f9fafb;
  --nav-bg: rgba(255, 255, 255, 0.85);
  --badge-done-bg: #dcfce7;
  --badge-done-text: #166534;
  --badge-wip-bg: #fef9c3;
  --badge-wip-text: #854d0e;
}

[data-theme="dark"] {
  --bg: #0f0f0f;
  --text-primary: #ededed;
  --text-secondary: #737373;
  --border: #262626;
  --card-bg: #161616;
  --nav-bg: rgba(15, 15, 15, 0.85);
  --badge-done-bg: #14532d;
  --badge-done-text: #86efac;
  --badge-wip-bg: #422006;
  --badge-wip-text: #fde68a;
}

html {
  color-scheme: light;
}

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: var(--bg);
  color: var(--text-primary);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

/* ── Nav ── */
nav {
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  background-color: var(--nav-bg);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  max-width: 680px;
  margin: 0 auto;
  padding: 0 24px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.nav-logo {
  white-space: nowrap;
  flex-shrink: 0;
}

.nav-logo a {
  font-weight: 600;
  font-size: 15px;
  color: var(--text-primary);
  transition: opacity 0.15s;
}

.nav-logo a:hover {
  opacity: 0.7;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 20px;
  flex: 1;
  justify-content: flex-end;
}

.nav-links a {
  font-size: 14px;
  color: var(--text-secondary);
  transition: color 0.15s;
}

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

.nav-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.theme-toggle {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-secondary);
  padding: 4px;
  display: flex;
  align-items: center;
  transition: color 0.15s;
  line-height: 0;
}

.theme-toggle:hover {
  color: var(--text-primary);
}

.nav-hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-secondary);
  padding: 4px;
  align-items: center;
  transition: color 0.15s;
  line-height: 0;
}

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

/* ── Layout ── */
.container {
  max-width: 680px;
  margin: 0 auto;
  padding: 0 24px;
}

main {
  padding: 56px 0 96px;
}

/* ── Hero ── */
.hero {
  margin-bottom: 64px;
}

.hero h1 {
  font-size: 22px;
  font-weight: 600;
  margin-bottom: 12px;
  line-height: 1.4;
}

.hero p {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 520px;
}

/* ── Section ── */
.section {
  margin-bottom: 56px;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.section-title {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-secondary);
}

.section-link {
  font-size: 13px;
  color: var(--text-secondary);
  transition: color 0.15s;
}

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

/* ── Post list ── */
.post-list {
  list-style: none;
  border-top: 1px solid var(--border);
}

.post-item {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding: 13px 0;
  border-bottom: 1px solid var(--border);
}

.post-title {
  font-size: 14px;
  color: var(--text-primary);
  line-height: 1.5;
  flex: 1;
  transition: color 0.15s;
}

.post-title:hover {
  color: var(--text-secondary);
}

.post-date {
  font-size: 13px;
  color: var(--text-secondary);
  white-space: nowrap;
  flex-shrink: 0;
}

/* ── Page title ── */
.page-title {
  font-size: 24px;
  font-weight: 600;
  margin-bottom: 8px;
}

.page-subtitle {
  font-size: 15px;
  color: var(--text-secondary);
  margin-bottom: 48px;
  line-height: 1.6;
}

/* ── Project cards ── */
.project-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.project-card {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 20px 22px;
  background: var(--card-bg);
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.project-icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  overflow: hidden;
}

.project-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 8px;
}

.project-body {
  flex: 1;
  min-width: 0;
}

.project-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
  gap: 12px;
}

.project-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
}

.badge {
  font-size: 11px;
  font-weight: 500;
  padding: 2px 8px;
  border-radius: 99px;
  flex-shrink: 0;
}

.badge-done {
  background: var(--badge-done-bg);
  color: var(--badge-done-text);
}

.badge-wip {
  background: var(--badge-wip-bg);
  color: var(--badge-wip-text);
}

.project-desc {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.65;
  margin-bottom: 14px;
}

.project-links {
  display: flex;
  gap: 14px;
  font-size: 13px;
}

.project-links a {
  color: var(--text-secondary);
  transition: color 0.15s;
}

.project-links a:hover {
  color: var(--text-primary);
}

/* ── Progress bar ── */
.progress-wrap {
  margin-top: 14px;
}

.progress-meta {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.progress-bar {
  height: 3px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--text-secondary);
  border-radius: 2px;
  transition: width 0.4s ease;
}

/* ── Ideas ── */
.ideas-list {
  list-style: none;
  border-top: 1px solid var(--border);
}

.idea-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 0;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
  color: var(--text-secondary);
}

.idea-item::before {
  content: "→";
  color: var(--text-secondary);
  flex-shrink: 0;
  font-size: 13px;
}

/* ── About / Experience ── */
.about-bio {
  margin-bottom: 56px;
}

.about-bio p {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 14px;
}

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

.about-bio p a {
  color: var(--text-primary);
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 0.15s;
}

.about-bio p a:hover {
  color: var(--text-secondary);
}

.experience-list {
  display: flex;
  flex-direction: column;
  gap: 30px;
}

.exp-company {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.exp-meta {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.exp-desc {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.65;
}

.exp-desc a {
  color: var(--text-primary);
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 0.15s;
}

.exp-desc a:hover {
  color: var(--text-secondary);
}

/* ── Divider ── */
.divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 48px 0;
}

/* ── Footer ── */
footer {
  border-top: 1px solid var(--border);
  padding: 28px 0;
}

.footer-inner {
  max-width: 680px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.footer-socials {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.footer-socials a {
  font-size: 13px;
  color: var(--text-secondary);
  transition: color 0.15s;
}

.footer-socials a:hover {
  color: var(--text-primary);
}

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

/* ── Contact ── */
.contact-list {
  list-style: none;
  border-top: 1px solid var(--border);
}

.contact-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 0;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
}

.contact-label {
  color: var(--text-secondary);
}

.contact-item a {
  color: var(--text-primary);
  transition: color 0.15s;
}

.contact-item a:hover {
  color: var(--text-secondary);
}

.cal-embed {
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--border);
}

.cal-embed iframe {
  width: 100%;
  height: 1100px;
  display: block;
}

/* ── Buy Me a Coffee ── */
.bmc-link {
  display: inline-block;
  font-size: 16px;
  font-weight: 600;
  padding: 14px 28px;
  border-radius: 8px;
  background-color: #FFDD00;
  color: #000000;
  transition: opacity 0.15s;
}

.bmc-link:hover {
  opacity: 0.85;
}

/* ── Responsive ── */
@media (max-width: 560px) {
  .nav-hamburger {
    display: flex;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 56px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    background-color: var(--bg);
    border-bottom: 1px solid var(--border);
    padding: 12px 24px 20px;
    gap: 16px;
    z-index: 99;
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    font-size: 15px;
    display: block;
    width: 100%;
    padding: 2px 0;
  }

  .post-item {
    flex-direction: column;
    gap: 3px;
  }

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

  .footer-socials {
    justify-content: center;
    gap: 12px;
  }

  .cal-embed iframe {
    height: 750px;
  }
}
