/**
 * Por Que Política - Indaiatuba
 * Estilos Customizados
 */

/* ===== VARIÁVEIS ===== */
:root {
    --pqp-primary: #1e40af;
    --pqp-secondary: #7c3aed;
    --pqp-accent: #f59e0b;
    --pqp-dark: #1f2937;
    --pqp-light: #f9fafb;
}

/* ===== RESET E BASE ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #374151;
}

/* ===== TIPOGRAFIA ===== */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

.prose {
    max-width: 65ch;
}

.prose p {
    margin-bottom: 1.25em;
}

.prose h2 {
    margin-top: 2em;
    margin-bottom: 1em;
    font-size: 1.5em;
}

.prose h3 {
    margin-top: 1.6em;
    margin-bottom: 0.6em;
    font-size: 1.25em;
}

.prose ul, .prose ol {
    margin-bottom: 1.25em;
    padding-left: 1.625em;
}

.prose li {
    margin-bottom: 0.5em;
}

.prose strong {
    font-weight: 600;
    color: #111827;
}

.prose a {
    color: var(--pqp-primary);
    text-decoration: underline;
}

.prose a:hover {
    color: var(--pqp-secondary);
}

.prose img {
    margin: 2em 0;
    border-radius: 0.5rem;
}

.prose blockquote {
    border-left: 4px solid var(--pqp-primary);
    padding-left: 1em;
    margin: 1.5em 0;
    font-style: italic;
    color: #6b7280;
}

/* ===== UTILITIES ===== */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ===== ANIMAÇÕES ===== */
@keyframes fade-in {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fade-in 0.3s ease-out;
}

@keyframes slide-in {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.animate-slide-in {
    animation: slide-in 0.4s ease-out;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.animate-pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* ===== CARDS ===== */
.card {
    background: white;
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.card:hover {
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

/* ===== BUTTONS ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    font-weight: 600;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
    text-decoration: none;
}

.btn-primary {
    background-color: var(--pqp-primary);
    color: white;
}

.btn-primary:hover {
    background-color: #1e3a8a;
}

.btn-secondary {
    background-color: var(--pqp-secondary);
    color: white;
}

.btn-secondary:hover {
    background-color: #6d28d9;
}

.btn-accent {
    background-color: var(--pqp-accent);
    color: white;
}

.btn-accent:hover {
    background-color: #d97706;
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--pqp-primary);
    color: var(--pqp-primary);
}

.btn-outline:hover {
    background-color: var(--pqp-primary);
    color: white;
}

/* ===== BADGES ===== */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 600;
}

.badge-primary {
    background-color: #dbeafe;
    color: var(--pqp-primary);
}

.badge-success {
    background-color: #d1fae5;
    color: #065f46;
}

.badge-warning {
    background-color: #fef3c7;
    color: #92400e;
}

.badge-danger {
    background-color: #fee2e2;
    color: #991b1b;
}

/* ===== FORMS ===== */
.form-input {
    display: block;
    width: 100%;
    padding: 0.5rem 0.75rem;
    border: 1px solid #d1d5db;
    border-radius: 0.375rem;
    font-size: 1rem;
    transition: all 0.2s ease;
}

.form-input:focus {
    outline: none;
    border-color: var(--pqp-primary);
    box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #374151;
}

.form-error {
    color: #dc2626;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

/* ===== HEADER ===== */
header {
    position: sticky;
    top: 0;
    z-index: 40;
    background: white;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
}

/* ===== FOOTER ===== */
footer {
    background-color: var(--pqp-dark);
    color: white;
}

footer a {
    color: white;
    transition: color 0.2s ease;
}

footer a:hover {
    color: var(--pqp-accent);
}

/* ===== LOADING ===== */
.spinner {
    border: 3px solid #f3f4f6;
    border-top: 3px solid var(--pqp-primary);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ===== TABLES ===== */
table {
    width: 100%;
    border-collapse: collapse;
}

table th {
    background-color: #f9fafb;
    padding: 0.75rem;
    text-align: left;
    font-weight: 600;
    color: #374151;
    border-bottom: 2px solid #e5e7eb;
}

table td {
    padding: 0.75rem;
    border-bottom: 1px solid #e5e7eb;
}

table tr:hover {
    background-color: #f9fafb;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .hide-mobile {
        display: none !important;
    }
}

@media (max-width: 640px) {
    .prose {
        font-size: 0.95rem;
    }
    
    h1 {
        font-size: 1.875rem;
    }
    
    h2 {
        font-size: 1.5rem;
    }
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
    background: #94a3b8;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #64748b;
}

/* ===== ACESSIBILIDADE ===== */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* ===== UTILITÁRIOS EXTRAS ===== */
.shadow-smooth {
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
}

.gradient-primary {
    background: linear-gradient(135deg, var(--pqp-primary) 0%, var(--pqp-secondary) 100%);
}

.text-gradient {
    background: linear-gradient(135deg, var(--pqp-primary) 0%, var(--pqp-secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
