/* MyTimeline — folha de estilos estática (substitui o Tailwind via CDN).
   Cobre exatamente as classes utilitárias usadas nas views, geradas manualmente
   a partir da paleta definida antes em tailwind-config.js, para eliminar o
   download + compilação em tempo de execução do Play CDN (lento e gera FOUC). */

/* ---------- Reset básico (equivalente ao Preflight do Tailwind) ---------- */
*, *::before, *::after {
  box-sizing: border-box;
  border-width: 0;
  border-style: solid;
  border-color: currentColor;
}
html {
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
}
body { margin: 0; }
h1, h2, h3, h4 { font-size: inherit; font-weight: inherit; margin: 0; }
p { margin: 0; }
a { color: inherit; text-decoration: inherit; }
button, input, textarea, select { font: inherit; color: inherit; margin: 0; padding: 0; background-color: transparent; }
button { cursor: pointer; text-transform: none; }
img, svg { display: block; max-width: 100%; height: auto; }
::placeholder { color: #94a3b8; opacity: 1; }

/* ---------- Layout / display ---------- */
.block { display: block; }
.inline-block { display: inline-block; }
.inline { display: inline; }
.inline-flex { display: inline-flex; }
.flex { display: flex; }
.grid { display: grid; }

.flex-col { flex-direction: column; }
.flex-1 { flex: 1 1 0%; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.shrink-0 { flex-shrink: 0; }
.group { }

.relative { position: relative; }
.absolute { position: absolute; }
.sticky { position: sticky; }
.inset-y-0 { top: 0; bottom: 0; }
.top-0 { top: 0; }
.right-0 { right: 0; }
.z-30 { z-index: 30; }

.overflow-hidden { overflow: hidden; }
.object-cover { object-fit: cover; }
.cursor-pointer { cursor: pointer; }

/* ---------- Tamanhos ---------- */
.h-5 { height: 1.25rem; }
.h-8 { height: 2rem; }
.h-16 { height: 4rem; }
.h-24 { height: 6rem; }
.h-28 { height: 7rem; }
.h-32 { height: 8rem; }
.h-40 { height: 10rem; }
.h-full { height: 100%; }
.w-8 { width: 2rem; }
.w-full { width: 100%; }
.min-w-5 { min-width: 1.25rem; }
.max-w-md { max-width: 28rem; }
.max-w-xl { max-width: 36rem; }
.max-w-2xl { max-width: 42rem; }
.max-w-5xl { max-width: 64rem; }
.max-h-48 { max-height: 12rem; }
.max-h-96 { max-height: 24rem; }

/* ---------- Espaçamento ---------- */
.mx-auto { margin-left: auto; margin-right: auto; }
.ml-auto { margin-left: auto; }
.ml-1 { margin-left: 0.25rem; }
.ml-2 { margin-left: 0.5rem; }
.mt-0\.5 { margin-top: 0.125rem; }
.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 0.75rem; }
.mt-4 { margin-top: 1rem; }
.mt-6 { margin-top: 1.5rem; }
.mt-8 { margin-top: 2rem; }
.mb-1 { margin-bottom: 0.25rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.-mb-px { margin-bottom: -1px; }

.p-2 { padding: 0.5rem; }
.p-4 { padding: 1rem; }
.p-5 { padding: 1.25rem; }
.p-6 { padding: 1.5rem; }
.px-1 { padding-left: 0.25rem; padding-right: 0.25rem; }
.px-2 { padding-left: 0.5rem; padding-right: 0.5rem; }
.px-3 { padding-left: 0.75rem; padding-right: 0.75rem; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.py-0\.5 { padding-top: 0.125rem; padding-bottom: 0.125rem; }
.py-1\.5 { padding-top: 0.375rem; padding-bottom: 0.375rem; }
.py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.py-2\.5 { padding-top: 0.625rem; padding-bottom: 0.625rem; }
.py-3 { padding-top: 0.75rem; padding-bottom: 0.75rem; }
.py-6 { padding-top: 1.5rem; padding-bottom: 1.5rem; }
.py-8 { padding-top: 2rem; padding-bottom: 2rem; }
.py-16 { padding-top: 4rem; padding-bottom: 4rem; }
.py-20 { padding-top: 5rem; padding-bottom: 5rem; }
.pr-3 { padding-right: 0.75rem; }
.pr-10 { padding-right: 2.5rem; }

.gap-1 { gap: 0.25rem; }
.gap-1\.5 { gap: 0.375rem; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 0.75rem; }
.gap-5 { gap: 1.25rem; }

.space-y-3 > * + * { margin-top: 0.75rem; }
.space-y-4 > * + * { margin-top: 1rem; }

/* ---------- Tipografia ---------- */
.text-xs { font-size: 0.75rem; line-height: 1rem; }
.text-sm { font-size: 0.875rem; line-height: 1.25rem; }
.text-lg { font-size: 1.125rem; line-height: 1.75rem; }
.text-2xl { font-size: 1.5rem; line-height: 2rem; }
.text-3xl { font-size: 1.875rem; line-height: 2.25rem; }
.text-6xl { font-size: 3.75rem; line-height: 1; }
.font-normal { font-weight: 400; }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }
.text-center { text-align: center; }
.uppercase { text-transform: uppercase; }
.tracking-wide { letter-spacing: 0.025em; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.whitespace-pre-line { white-space: pre-line; }

/* ---------- Bordas / raio ---------- */
.border { border-width: 1px; }
.border-b { border-bottom-width: 1px; }
.border-b-2 { border-bottom-width: 2px; }
.border-t { border-top-width: 1px; }
.border-dashed { border-style: dashed; }
.rounded { border-radius: 0.25rem; }
.rounded-lg { border-radius: 0.5rem; }
.rounded-xl { border-radius: 0.75rem; }
.rounded-2xl { border-radius: 1rem; }
.rounded-full { border-radius: 9999px; }

/* ---------- Sombra / transição ---------- */
.shadow-sm { box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05); }
.hover\:shadow-md:hover { box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1); }
.transition { transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; }

/* ---------- Gradiente (usado na capa das timelines) ---------- */
.bg-gradient-to-br { background-image: linear-gradient(to bottom right, var(--tw-gradient-stops)); }
.from-brand-500 { --tw-gradient-from: #3b74f4; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, rgb(59 116 244 / 0)); }
.to-brand-700 { --tw-gradient-to: #1f45c9; }

/* ---------- Foco (ring) ---------- */
.focus\:ring-2:focus {
  outline: none;
  --tw-ring-shadow: 0 0 0 2px var(--tw-ring-color, #3b74f4);
  box-shadow: var(--tw-ring-shadow);
}
.focus\:ring-brand-500:focus { --tw-ring-color: #3b74f4; }
.focus\:border-brand-500:focus { border-color: #3b74f4; }

/* ---------- Paleta: slate ---------- */
.bg-slate-50 { background-color: #f8fafc; }
.bg-slate-100 { background-color: #f1f5f9; }
.hover\:bg-slate-50:hover { background-color: #f8fafc; }
.hover\:bg-slate-100:hover { background-color: #f1f5f9; }
.text-slate-400 { color: #94a3b8; }
.text-slate-500 { color: #64748b; }
.text-slate-600 { color: #475569; }
.text-slate-700 { color: #334155; }
.text-slate-800 { color: #1e293b; }
.text-slate-900 { color: #0f172a; }
.hover\:text-slate-600:hover { color: #475569; }
.hover\:text-slate-700:hover { color: #334155; }
.border-slate-100 { border-color: #f1f5f9; }
.border-slate-200 { border-color: #e2e8f0; }
.border-slate-300 { border-color: #cbd5e1; }

/* ---------- Paleta: brand ---------- */
.bg-brand-600 { background-color: #2557e8; }
.hover\:bg-brand-700:hover { background-color: #1f45c9; }
.text-brand-600 { color: #2557e8; }
.text-brand-700 { color: #1f45c9; }
.hover\:text-brand-600:hover { color: #2557e8; }
.group:hover .group-hover\:text-brand-600 { color: #2557e8; }
.border-brand-600 { border-color: #2557e8; }

/* ---------- Paleta: emerald ---------- */
.bg-emerald-50 { background-color: #ecfdf5; }
.bg-emerald-600 { background-color: #059669; }
.hover\:bg-emerald-700:hover { background-color: #047857; }
.text-emerald-700 { color: #047857; }

/* ---------- Paleta: red ---------- */
.text-red-500 { color: #ef4444; }
.text-red-600 { color: #dc2626; }
.hover\:text-red-600:hover { color: #dc2626; }
.hover\:text-red-700:hover { color: #b91c1c; }

/* ---------- Paleta: amber ---------- */
.bg-amber-50 { background-color: #fffbeb; }
.bg-amber-500 { background-color: #f59e0b; }
.text-amber-700 { color: #b45309; }
.hover\:bg-amber-100:hover { background-color: #fef3c7; }

/* ---------- Paleta: rose (curtida) ---------- */
.bg-rose-50 { background-color: #fff1f2; }
.border-rose-200 { border-color: #fecdd3; }
.text-rose-600 { color: #e11d48; }

/* ---------- Paleta: branco / transparente ---------- */
.bg-white { background-color: #ffffff; }
.text-white { color: #ffffff; }
.border-transparent { border-color: transparent; }
.hover\:underline:hover { text-decoration: underline; }

/* ---------- Inputs de arquivo (file:) ---------- */
.file\:mr-3::file-selector-button { margin-right: 0.75rem; }
.file\:px-3::file-selector-button { padding-left: 0.75rem; padding-right: 0.75rem; }
.file\:px-4::file-selector-button { padding-left: 1rem; padding-right: 1rem; }
.file\:py-2::file-selector-button { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.file\:rounded-lg::file-selector-button { border-radius: 0.5rem; }
.file\:border-0::file-selector-button { border-width: 0; }
.file\:bg-brand-50::file-selector-button { background-color: #eef4ff; }
.file\:text-brand-700::file-selector-button { color: #1f45c9; }
.file\:font-medium::file-selector-button { font-weight: 500; }
.hover\:file\:bg-brand-100:hover::file-selector-button { background-color: #dbe7fe; }
.file\:mr-3::-webkit-file-upload-button { margin-right: 0.75rem; }
.file\:px-3::-webkit-file-upload-button { padding-left: 0.75rem; padding-right: 0.75rem; }
.file\:px-4::-webkit-file-upload-button { padding-left: 1rem; padding-right: 1rem; }
.file\:py-2::-webkit-file-upload-button { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.file\:rounded-lg::-webkit-file-upload-button { border-radius: 0.5rem; }
.file\:border-0::-webkit-file-upload-button { border-width: 0; }
.file\:bg-brand-50::-webkit-file-upload-button { background-color: #eef4ff; }
.file\:text-brand-700::-webkit-file-upload-button { color: #1f45c9; }
.hover\:file\:bg-brand-100:hover::-webkit-file-upload-button { background-color: #dbe7fe; }

/* ---------- Responsivo ---------- */
@media (min-width: 640px) {
  .sm\:gap-4 { gap: 1rem; }
  .sm\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sm\:h-56 { height: 14rem; }
  .sm\:px-6 { padding-left: 1.5rem; padding-right: 1.5rem; }
}
@media (min-width: 1024px) {
  .lg\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* ---------- Componentes específicos do app (linha do tempo, curtidas) ---------- */
.timeline {
  position: relative;
  padding-left: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.timeline::before {
  content: '';
  position: absolute;
  top: 0.5rem;
  bottom: 0.5rem;
  left: 0.3125rem;
  width: 2px;
  background: linear-gradient(to bottom, #93b9fd, #dbe7fe);
}

.timeline-item {
  position: relative;
  display: flex;
  align-items: flex-start;
}

.timeline-dot {
  position: absolute;
  left: -1.5rem;
  top: 1.5rem;
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 9999px;
  background: #2557e8;
  border: 3px solid #eef4ff;
  box-shadow: 0 0 0 2px #2557e8;
}

.timeline-item > div {
  width: 100%;
}

.like-btn[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
}

.like-btn:not([disabled]) {
  cursor: pointer;
}

.like-btn.liking .like-icon {
  animation: like-pop 0.3s ease;
}

@keyframes like-pop {
  0%   { transform: scale(1); }
  40%  { transform: scale(1.4); }
  100% { transform: scale(1); }
}
