@font-face {
  font-family: "Figtree";
  src: url("/assets/font/figtree-latin.woff2") format("woff2-variations");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --font-sans: "Figtree", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --color-bg: #ffffff;
  --color-surface: #f5f5f5;
  --color-raised: #ffffff;
  --color-ink: #000000;
  --color-muted: #707070;
  --color-subtle: #a0a0a0;
  --color-border: #e5e5e5;
  --color-line: #d0d0d0;
  --color-accent: #9b8afb;

  --radius-xs: 4px;
  --radius-panel: 8px;
  --radius-card: 10px;
  --radius-pill: 100px;

  --space-1: 2px;
  --space-2: 4px;
  --space-3: 6px;
  --space-4: 8px;
  --space-5: 10px;
  --space-6: 12px;
  --space-7: 16px;
  --space-8: 20px;
  --space-9: 24px;
  --space-10: 32px;
  --space-11: 56px;

  --text-2xs: 11px;
  --text-xs: 12px;
  --text-sm: 13px;
  --text-base: 14px;
  --text-md: 15px;
  --text-lg: 17px;
  --text-xl: 24px;
  --text-2xl: 34px;

  --leading-none: 1;
  --leading-display: 1.1;
  --leading-tight: 1.2;
  --leading-snug: 1.35;
  --leading-normal: 1.55;

  --gap-card: var(--space-5);
  --gap-list: var(--space-4);
  --gap-row: var(--space-6);
  --gap-tight: var(--space-3);
  --pad-card: var(--space-8);
  --pad-panel: var(--space-7);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  border: 0;
  outline: 0;
}

html {
  height: 100%;
  overflow-x: hidden;
  max-width: 100vw;
}

body {
  margin: 0;
  padding: var(--space-5);
  min-height: 100vh;
  min-height: 100dvh;
  max-width: 100vw;
  overflow-x: hidden;
  background-color: var(--color-bg);
  color: var(--color-ink);
  font-family: var(--font-sans);
  font-size: var(--text-base);
  font-weight: 500;
  letter-spacing: -0.01em;
  line-height: var(--leading-snug);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
}

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

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

.container {
  width: 100%;
  max-width: 400px;
  min-width: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: var(--gap-card);
  margin: 0 auto;
}

.card {
  background-color: var(--color-surface);
  border-radius: var(--radius-card);
  overflow: hidden;
  flex-shrink: 0;
  min-width: 0;
  max-width: 100%;
}

.btn {
  border-radius: var(--radius-pill);
  flex: none;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
  width: fit-content;
  height: 30px;
  padding: 0 var(--space-6);
  display: inline-flex;
  position: relative;
  overflow: hidden;
  font-size: var(--text-sm);
  font-weight: 500;
  line-height: var(--leading-none);
  letter-spacing: -0.01em;
  cursor: pointer;
  user-select: none;
  transition: opacity 0.15s ease, transform 0.15s ease;
}

.btn:hover {
  opacity: 0.9;
}

.btn:active {
  transform: scale(0.98);
}

.btn-white {
  background-color: var(--color-raised);
  color: var(--color-ink);
  padding: 0 var(--space-6) 0 var(--space-5);
  gap: var(--gap-tight);
}

.btn-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  display: block;
}

.tg-plane {
  transform-box: fill-box;
  transform-origin: center;
  will-change: transform, opacity;
}

.btn-white:hover .tg-plane {
  animation: tgFly 0.85s cubic-bezier(0.25, 0.9, 0.25, 1);
}

@keyframes tgFly {
  0% {
    transform: translate(0, 0);
    opacity: 1;
  }

  38% {
    transform: translate(140%, -140%);
    opacity: 0;
  }

  39% {
    transform: translate(-120%, 120%);
    opacity: 0;
  }

  65% {
    opacity: 1;
  }

  100% {
    transform: translate(0, 0);
    opacity: 1;
  }
}

.btn-purple {
  background-color: var(--color-accent);
  color: var(--color-ink);
  padding: 0 var(--space-6);
  transition: opacity 0.25s ease, transform 0.25s ease, padding 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-purple:hover {
  padding: 0 var(--space-5) 0 var(--space-6);
}

.btn-arrow {
  width: 0;
  height: 12px;
  opacity: 0;
  margin-left: 0;
  transform: translate(-3px, 3px) scale(0.6);
  transition: width 0.4s cubic-bezier(0.16, 1, 0.3, 1),
    margin-left 0.4s cubic-bezier(0.16, 1, 0.3, 1),
    opacity 0.35s ease,
    transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-block;
  flex-shrink: 0;
  pointer-events: none;
}

.btn-purple:hover .btn-arrow {
  width: 14px;
  opacity: 1;
  margin-left: var(--space-1);
  transform: translate(0, 0) scale(1);
}

.card-nav {
  padding: var(--space-6) var(--space-7);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.btn-back {
  background-color: var(--color-raised);
  color: var(--color-ink);
  height: 30px;
  padding: 0 var(--space-6) 0 var(--space-5);
  border-radius: var(--radius-pill);
  font-size: var(--text-sm);
  font-weight: 500;
  letter-spacing: -0.01em;
  display: inline-flex;
  align-items: center;
  gap: var(--gap-tight);
  cursor: pointer;
  user-select: none;
  transition: opacity 0.15s ease, transform 0.15s ease;
}

.btn-back:hover {
  opacity: 0.9;
}

.btn-back:active {
  transform: scale(0.98);
}

.btn-back-arrow {
  width: 12px;
  height: 12px;
  flex-shrink: 0;
  display: block;
}

.nav-tag {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-muted);
  letter-spacing: -0.01em;
  line-height: var(--leading-none);
}

.card-header {
  padding: var(--space-9) var(--pad-card);
  display: flex;
  flex-direction: column;
  gap: var(--gap-row);
}

.article-title {
  font-size: var(--text-xl);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: var(--leading-tight);
  color: var(--color-ink);
}

.article-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--gap-list);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-muted);
  letter-spacing: -0.01em;
  line-height: var(--leading-snug);
}

.meta-dot {
  color: var(--color-subtle);
  user-select: none;
}

.card-more {
  padding: var(--pad-card);
  display: flex;
  flex-direction: column;
  gap: var(--gap-card);
}

.col-title {
  font-size: var(--text-base);
  font-weight: 600;
  color: var(--color-ink);
  letter-spacing: -0.01em;
  line-height: var(--leading-tight);
}

.writing-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--gap-list);
}

.writing-item {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--gap-row);
}

.writing-item a {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-muted);
  letter-spacing: -0.01em;
  line-height: var(--leading-snug);
  transition: color 0.15s ease;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
}

.writing-item a:hover {
  color: var(--color-ink);
}

.writing-date {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-subtle);
  flex-shrink: 0;
  line-height: var(--leading-snug);
}

.card-time {
  padding: var(--space-10) var(--pad-card);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.time-display {
  font-size: var(--text-xl);
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: var(--leading-tight);
  color: var(--color-ink);
}

.card-footer {
  padding: var(--space-7) var(--pad-card);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-muted);
}

.footer-link {
  color: var(--color-muted);
  transition: color 0.15s ease;
}

.footer-link:hover {
  color: var(--color-ink);
}
