/**
 * Estilos para página de post (post.php)
 * Antes estavam inline na view - movidos para arquivo separado para cache e manutenibilidade
 */

/* Container principal do conteúdo do post */
.post-content {
    max-width: 100%;
}

.post-content ul {
    list-style-type: disc !important;
    padding-left: 1.5rem !important;
    margin-top: 1rem;
    margin-bottom: 1rem;
}

.post-content li {
    margin: 0.5rem 0;
    line-height: 1.7;
}

/* Parágrafos do post */
.post-paragraph {
    text-align: justify;
    margin-bottom: 1.5rem;
    line-height: 1.7;
}

/* Responsivo: alinhamento à esquerda em mobile */
@media (max-width: 768px) {
    .post-paragraph {
        text-align: left;
        margin-bottom: 1.25rem;
    }
}

/* Tipografia do conteúdo (prose do Tailwind Typography) */
.prose {
    color: #1f2937;
    /* gray-800 */
}

.prose h1,
.prose h2,
.prose h3,
.prose h4 {
    color: #111827;
    /* gray-900 */
    font-weight: 700;
    line-height: 1.25;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.prose h1 {
    font-size: 2.25rem;
}

/* text-4xl */
.prose h2 {
    font-size: 1.875rem;
}

/* text-3xl */
.prose h3 {
    font-size: 1.5rem;
}

/* text-2xl */
.prose h4 {
    font-size: 1.25rem;
}

/* text-xl */

.prose p {
    margin-bottom: 1.25rem;
    line-height: 1.75;
}

.prose a {
    color: #4f46e5;
    /* indigo-600 */
    text-decoration: underline;
    text-underline-offset: 2px;
}

.prose a:hover {
    color: #4338ca;
    /* indigo-700 */
}

.prose code {
    background-color: #f3f4f6;
    /* gray-100 */
    padding: 0.125rem 0.375rem;
    border-radius: 0.25rem;
    font-size: 0.875em;
    color: #dc2626;
    /* red-600 */
}

.prose pre {
    background-color: #1f2937;
    /* gray-900 */
    color: #e5e7eb;
    /* gray-200 */
    padding: 1.5rem;
    border-radius: 0.5rem;
    overflow-x: auto;
    margin: 1.5rem 0;
}

.prose pre code {
    background: none;
    padding: 0;
    color: inherit;
    font-size: 0.875rem;
    line-height: 1.7;
}

.prose blockquote {
    border-left: 4px solid #4f46e5;
    /* indigo-500 */
    padding-left: 1.5rem;
    margin: 1.5rem 0;
    font-style: italic;
    color: #4b5563;
    /* gray-600 */
}

.prose ul,
.prose ol {
    margin: 1.25rem 0;
    padding-left: 1.5rem;
}

.prose ul {
    list-style-type: disc;
}

.prose ol {
    list-style-type: decimal;
}

.prose li {
    margin: 0.5rem 0;
    line-height: 1.7;
}

.prose li::marker {
    color: #6b7280;
    /* gray-500 */
}

.prose img {
    border-radius: 0.5rem;
    margin: 1.5rem 0;
    max-width: 100%;
    height: auto;
}

.prose table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
    font-size: 0.875rem;
}

.prose th,
.prose td {
    border: 1px solid #e5e7eb;
    /* gray-200 */
    padding: 0.75rem 1rem;
    text-align: left;
}

.prose th {
    background-color: #f9fafb;
    /* gray-50 */
    font-weight: 600;
}

.prose tr:nth-child(even) td {
    background-color: #f9fafb;
    /* gray-50 */
}

.prose hr {
    border: none;
    border-top: 1px solid #e5e7eb;
    /* gray-200 */
    margin: 2rem 0;
}

/* Scroll suave para anchor links */
html {
    scroll-behavior: smooth;
}

/* Focus visible para acessibilidade */
:focus-visible {
    outline: 2px solid #4f46e5;
    /* indigo-600 */
    outline-offset: 2px;
}

/* Skip link (para acessibilidade) */
.skip-link {
    position: absolute;
    top: -100%;
    left: 50%;
    transform: translateX(-50%);
    background: #4f46e5;
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    z-index: 100;
    text-decoration: none;
    font-weight: 600;
}

.skip-link:focus {
    top: 1rem;
}

/* Animação suave para hover em cards */
.post-card {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.post-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
}

/* Breadcrumbs */
[itemscope][itemtype="https://schema.org/BreadcrumbList"] a {
    transition: color 0.15s ease;
}

/* Tags */
[aria-label="Tags do artigo"] a {
    transition: all 0.15s ease;
}

/* Botões de compartilhamento */
[aria-label^="Compartilhar"] {
    transition: all 0.15s ease;
}

/* Autor box */
[class*="author"] {
    transition: opacity 0.2s ease;
}

/* Navegação prev/next */
[rel="prev"],
[rel="next"] {
    transition: all 0.15s ease;
}

/* Print styles */
@media print {

    header,
    footer,
    nav,
    [aria-label="Compartilhar"],
    .skip-link,
    [rel="prev"],
    [rel="next"] {
        display: none !important;
    }

    main {
        max-width: none !important;
        padding: 0 !important;
    }

    .post-content {
        font-size: 12pt;
        line-height: 1.5;
    }

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

    .prose a[href^="http"]::after {
        content: " (" attr(href) ")";
        font-size: 0.8em;
        color: #666;
    }

    .prose img {
        page-break-inside: avoid;
    }

    .prose blockquote,
    .prose pre {
        page-break-inside: avoid;
    }
}

/* Highlight.js / Prism.js compatibility (se usar syntax highlighting) */
.hljs {
    background: #1f2937 !important;
    color: #e5e7eb !important;
    padding: 1.5rem !important;
    border-radius: 0.5rem !important;
}

.hljs-keyword {
    color: #c084fc;
}

/* purple-400 */
.hljs-string {
    color: #86efac;
}

/* green-300 */
.hljs-number {
    color: #fcd34d;
}

/* yellow-300 */
.hljs-comment {
    color: #9ca3af;
}

/* gray-400 */
.hljs-function {
    color: #60a5fa;
}

/* blue-400 */
.hljs-title {
    color: #f472b6;
}

/* pink-400 */