/* Fonts */
@font-face { font-family: 'Manrope'; font-weight: 400; font-style: normal; font-display: swap; src: url('/static/fonts/manrope-400.woff2') format('woff2'), url('/static/fonts/manrope-400.ttf') format('truetype'); }
@font-face { font-family: 'Manrope'; font-weight: 600; font-style: normal; font-display: swap; src: url('/static/fonts/manrope-700.woff2') format('woff2'), url('/static/fonts/manrope-700.ttf') format('truetype'); }
@font-face { font-family: 'Manrope'; font-weight: 700; font-style: normal; font-display: swap; src: url('/static/fonts/manrope-700.woff2') format('woff2'), url('/static/fonts/manrope-700.ttf') format('truetype'); }
@font-face { font-family: 'Manrope'; font-weight: 800; font-style: normal; font-display: swap; src: url('/static/fonts/manrope-700.woff2') format('woff2'), url('/static/fonts/manrope-700.ttf') format('truetype'); }

/* Reset & base */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility; }
body { font-family: 'Manrope', system-ui, -apple-system, sans-serif; font-size: 1rem; line-height: 1.7; color: #202124; background: #fff; font-feature-settings: "kern" 1, "liga" 1; }
a { color: #4285f4; text-decoration: none; }
a:hover { text-decoration: underline; }

/* Utilities */
.min-h-screen { min-height: 100vh; }
.flex { display: flex; }
.flex-1 { flex: 1; }
.flex-col { flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1rem; }
.gap-6 { gap: 1.5rem; }
.gap-8 { gap: 2rem; }
.w-full { width: 100%; }
.max-w-6xl { max-width: 72rem; }
.max-w-3xl { max-width: 48rem; }
.max-w-none { max-width: none; }
.mx-auto { margin-left: auto; margin-right: auto; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.py-3 { padding-top: 0.75rem; padding-bottom: 0.75rem; }
.py-4 { padding-top: 1rem; padding-bottom: 1rem; }
.py-8 { padding-top: 2rem; padding-bottom: 2rem; }
.px-2 { padding-left: 0.5rem; padding-right: 0.5rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 0.75rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-10 { margin-bottom: 2.5rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 0.75rem; }
.mt-8 { margin-top: 2rem; }
.mt-12 { margin-top: 3rem; }
.pb-6 { padding-bottom: 1.5rem; }
.pb-8 { padding-bottom: 2rem; }
.p-2 { padding: 0.5rem; }
.py-1 { padding-top: 0.25rem; padding-bottom: 0.25rem; }
.space-y-1 > * + * { margin-top: 0.25rem; }
.space-y-2 > * + * { margin-top: 0.5rem; }
.space-y-8 > * + * { margin-top: 2rem; }
.block { display: block; }
.inline-block { display: inline-block; }
.hidden { display: none; }
.text-center { text-align: center; }
.no-underline { text-decoration: none; }

/* Typography */
/* Escala tipográfica: 1rem base (16px) × ratio 1.25 (Major Third) */
/* xs: 0.8rem (13px) — meta, labels                                */
/* sm: 0.875rem (14px) — secundario, captions                     */
/* base: 1rem (16px) — texto normal, excerpts, párrafos            */
/* lg: 1.125rem (18px) — prosa de lectura                          */
/* xl: 1.25rem (20px) — subtítulos, h4                             */
/* 2xl: 1.5rem (24px) — h3, títulos de sección                    */
/* 3xl: 2rem (32px) — h2, títulos de post                          */
/* 4xl: 2.5rem (40px) — h1, hero                                   */
.text-xs { font-size: 0.8rem; }
.text-sm { font-size: 0.875rem; }
.text-lg { font-size: 1.125rem; }
.text-xl { font-size: 1.25rem; }
.text-2xl { font-size: 1.5rem; }
.text-3xl { font-size: 2rem; }
.text-4xl { font-size: 2.5rem; }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }
.uppercase { text-transform: uppercase; }
.tracking-wide { letter-spacing: 0.05em; }
.leading-tight { line-height: 1.25; }
.leading-relaxed { line-height: 1.75; }

/* Colors */
.bg-white { background-color: #fff; }
.bg-gray-100 { background-color: #f1f3f4; }
.text-white { color: #fff; }
.text-gray-400 { color: #6d7175; }
.text-gray-500 { color: #545960; }
.text-gray-600 { color: #3c4043; }
.text-gray-700 { color: #202124; }
.text-gray-900 { color: #202124; }
.text-blue-600 { color: #4285f4; }
.bg-blue-600 { background-color: #4285f4; }
.border-gray-100 { border-color: #e8eaed; }
.border-gray-200 { border-color: #dadce0; }
.border-gray-300 { border-color: #dadce0; }
.border-b { border-bottom: 1px solid #dadce0; }
.border-t { border-top: 1px solid #dadce0; }
.rounded { border-radius: 0.25rem; }

/* Hover */
.hover\:text-blue-600:hover { color: #4285f4; }
.hover\:underline:hover { text-decoration: underline; }
.hover\:bg-blue-50:hover { background-color: #e8f0fe; }
.hover\:bg-blue-700:hover { background-color: #3367d6; }

/* Focus */
.focus\:outline-none:focus { outline: none; }
.focus\:border-blue-500:focus { border-color: #4285f4; }

/* Grid */
.grid { display: grid; }
.grid-cols-1 { grid-template-columns: 1fr; }

/* Prose (basic content styling) */
.prose { font-size: 1.0625rem; line-height: 1.8; }
.prose h1 { font-size: 2rem; font-weight: 800; margin-top: 2em; margin-bottom: 0.5em; color: #202124; }
.prose h2 { font-size: 1.5rem; font-weight: 700; margin-top: 1.75em; margin-bottom: 0.5em; color: #202124; }
.prose h3 { font-size: 1.25rem; font-weight: 700; margin-top: 1.5em; margin-bottom: 0.5em; color: #202124; }
.prose h4 { font-size: 1.125rem; font-weight: 600; margin-top: 1.25em; margin-bottom: 0.5em; color: #202124; }
.prose p { margin-bottom: 1em; }
.prose ul, .prose ol { margin-bottom: 1em; padding-left: 1.5em; }
.prose li { margin-bottom: 0.25em; }
.prose pre { background: #f6f8fa; border: 1px solid #e8eaed; border-left: 3px solid #4285f4; padding: 1rem 1.25rem; border-radius: 0.375rem; overflow-x: auto; margin-bottom: 1.5em; font-size: 0.875rem; line-height: 1.65; }
.prose code { font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace; font-size: 0.9em; }
.prose p code, .prose li code { background: #eef1f5; padding: 0.15em 0.4em; border-radius: 0.25rem; font-size: 0.875em; color: #d93025; }
.prose table { width: 100%; border-collapse: collapse; margin-bottom: 1em; }
.prose th, .prose td { padding: 0.5rem 0.75rem; border: 1px solid #dadce0; text-align: left; }
.prose th { background: #f8f9fa; font-weight: 600; }
.prose a { color: #4285f4; }
.prose img { max-width: 100%; height: auto; border-radius: 0.5rem; display: block; margin-left: auto; margin-right: auto; }
.prose blockquote { border-left: 3px solid #dadce0; padding-left: 1rem; color: #5f6368; margin-bottom: 1em; }
.prose del { color: #6d7175; }
.prose input[type="checkbox"] { margin-right: 0.5em; }

/* Forms */
input[type="text"] { font-family: inherit; }
button { font-family: inherit; cursor: pointer; border: none; }

/* Responsive */
@media (min-width: 768px) {
  .md\:flex { display: flex; }
  .md\:hidden { display: none; }
}

@media (min-width: 1024px) {
  .lg\:grid-cols-\[1fr_280px\] { grid-template-columns: 1fr 280px; }
}

/* Post hero */
.post-hero {
  position: relative;
  border-radius: 0.75rem;
  overflow: hidden;
  margin-bottom: 2rem;
  min-height: 400px;
  display: flex;
  align-items: flex-end;
}
.post-hero__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.post-hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    transparent 30%,
    rgba(0, 0, 0, 0.15) 45%,
    rgba(0, 0, 0, 0.55) 65%,
    rgba(0, 0, 0, 0.8) 100%
  );
}
.post-hero__content {
  position: relative;
  z-index: 1;
  padding: 2rem;
  width: 100%;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
}
.post-hero__title {
  font-size: 2rem; /* matches .prose h1 */
  font-weight: 800;
  color: #fff;
  line-height: 1.2;
  margin-bottom: 0.75rem;
}
.post-hero__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem; /* meta: text-sm */
  color: rgba(255, 255, 255, 0.85);
}
.post-hero__author,
.post-hero__link {
  color: #fff;
  text-decoration: none;
  font-weight: 600;
}
.post-hero__author:hover,
.post-hero__link:hover {
  text-decoration: underline;
}
.post-hero__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
  margin-top: 0.75rem;
}
.post-hero__tag {
  font-size: 0.75rem;
  padding: 0.2rem 0.625rem;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  color: #fff;
  border-radius: 1rem;
  text-decoration: none;
  font-weight: 500;
  border: 1px solid rgba(255, 255, 255, 0.25);
  transition: background 0.2s;
}
.post-hero__tag:hover {
  background: rgba(255, 255, 255, 0.35);
  text-decoration: none;
}

@media (min-width: 768px) {
  .post-hero { min-height: 480px; }
  .post-hero__title { font-size: 2.5rem; } /* h1 hero desktop */
  .post-hero__content { padding: 2.5rem; }
}

/* Post navigation */
.post-nav {
  display: flex;
  justify-content: space-between;
  gap: 2rem;
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid #dadce0;
}
.post-nav__prev, .post-nav__next { max-width: 45%; }
.post-nav__next { text-align: right; margin-left: auto; }
.post-nav__label { display: block; font-size: 0.8rem; color: #6d7175; margin-bottom: 0.25rem; }
.post-nav__link { font-size: 0.875rem; font-weight: 600; color: #4285f4; text-decoration: none; line-height: 1.3; }
.post-nav__link:hover { text-decoration: underline; }

@media (max-width: 640px) {
  .post-nav { flex-direction: column; gap: 1.5rem; }
  .post-nav__prev, .post-nav__next { max-width: 100%; text-align: left; margin-left: 0; }
}

/* Sidebar */
.sidebar--separated ul { list-style: none; padding-left: 0; }

/* Sidebar separator */
@media (min-width: 1024px) {
  .sidebar--separated { border-left: 1px solid #dadce0; padding-left: 2rem; }
}

/* Error pages */
.error-page { display: flex; align-items: center; justify-content: center; min-height: 60vh; padding: 2rem 1rem; }
.error-page__container { text-align: center; max-width: 480px; }
.error-page__illustration { margin-bottom: 2rem; }
.error-page__code { font-size: 8rem; font-weight: 800; line-height: 1; color: #dadce0; letter-spacing: -0.04em; }
.error-page__line { width: 64px; height: 4px; margin: 1.5rem auto 0; background-color: #4285f4; border-radius: 2px; }
.error-page__title { font-size: 1.5rem; font-weight: 700; color: #202124; margin: 0 0 0.75rem; }
.error-page__message { font-size: 1rem; line-height: 1.6; color: #5f6368; margin: 0 0 2rem; }
.error-page__actions { display: flex; align-items: center; justify-content: center; gap: 1.5rem; }
.error-page__button { display: inline-block; padding: 0.625rem 1.5rem; font-size: 0.875rem; font-weight: 600; color: #fff; background-color: #4285f4; border-radius: 4px; }
.error-page__button:hover { background-color: #3367d6; text-decoration: none; }
.error-page__link { font-size: 0.875rem; font-weight: 600; color: #4285f4; }

/* Post list thumbnails */
.post-list__item { display: flex; flex-direction: column; gap: 0.75rem; margin-bottom: 1.5rem; padding-bottom: 1.5rem; border-bottom: 1px solid #f1f3f4; }
.post-list__thumb { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 0.375rem; display: block; }
.post-list__body { flex: 1 1 0%; min-width: 0; }
@media (min-width: 640px) {
  .post-list__item { flex-direction: row; gap: 1rem; align-items: flex-start; }
  .post-list__thumb { width: 9rem; height: 9rem; aspect-ratio: auto; flex-shrink: 0; }
}

/* Post hero (home) */
.post-hero__media { display: block; margin-bottom: 1rem; }
.post-hero__image { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 0.5rem; display: block; }

/* Preview banner */
.preview-banner { position: sticky; top: 0; z-index: 10; margin-bottom: 1.5rem; padding: 0.75rem 1rem; background: #fef7e0; border: 1px solid #f9ab00; border-radius: 0.375rem; color: #3c4043; font-size: 0.875rem; font-weight: 600; }
