/* Reset e configurações básicas */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #374151;
    background-color: #f8fafc;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Container principal */
.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Cabeçalho */
.header {
    background-color: white;
    color: #1e3a8a;
    padding: 20px 0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    border-bottom: 1px solid #e5e7eb;
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.header-logo {
    height: 40px;
    width: auto;
    object-fit: contain;
    display: block;
}

.header-title {
    font-size: 24px;
    font-weight: 600;
    margin: 0;
    color: #1e3a8a;
}

/* Seletor de idioma */
.language-selector {
    display: flex;
    gap: 8px;
}

.lang-btn {
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    color: #374151;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
    min-width: 70px;
}

.lang-btn:hover {
    background: #e5e7eb;
    transform: translateY(-1px);
    border-color: #d1d5db;
}

.lang-btn.active {
    background: #10b981;
    border-color: #10b981;
    color: white;
    box-shadow: 0 2px 4px rgba(16, 185, 129, 0.3);
}

/* Conteúdo principal */
.main-content {
    flex: 1;
    padding: 40px 0;
}

/* Estados de loading, erro e conteúdo */
.loading-state,
.error-state,
.policy-content {
    text-align: center;
    padding: 40px 20px;
}

/* Estado de loading */
.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #e5e7eb;
    border-top: 4px solid #1e3a8a;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

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

.loading-text {
    font-size: 16px;
    color: #6b7280;
}

/* Estado de erro */
.error-state {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    border: 1px solid #fecaca;
    max-width: 500px;
    margin: 0 auto;
}

.error-icon {
    font-size: 48px;
    margin-bottom: 16px;
}

.error-title {
    font-size: 20px;
    font-weight: 600;
    color: #ef4444;
    margin-bottom: 12px;
}

.error-message {
    font-size: 16px;
    color: #6b7280;
    margin-bottom: 16px;
}

.error-url {
    font-size: 14px;
    color: #9ca3af;
    font-family: 'Monaco', 'Menlo', monospace;
    background: #f3f4f6;
    padding: 8px 12px;
    border-radius: 6px;
    display: inline-block;
}

/* Conteúdo da política */
.policy-content {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    text-align: left;
    max-width: 800px;
    margin: 0 auto;
}

.app-info {
    text-align: center;
    padding: 30px 30px 20px;
    border-bottom: 1px solid #e5e7eb;
}

.app-name {
    font-size: 28px;
    font-weight: 700;
    color: #1e3a8a;
    margin-bottom: 8px;
    text-transform: capitalize;
}

.app-subtitle {
    font-size: 16px;
    color: #6b7280;
    font-weight: 500;
}

.policy-text {
    padding: 30px;
}

.policy-description {
    font-size: 16px;
    line-height: 1.8;
    color: #374151;
}

.policy-description p {
    margin-bottom: 16px;
}

.policy-description h3 {
    font-size: 18px;
    font-weight: 600;
    color: #1e3a8a;
    margin: 24px 0 12px;
}

.policy-description ul,
.policy-description ol {
    margin: 16px 0;
    padding-left: 24px;
}

.policy-description li {
    margin-bottom: 8px;
}

/* Rodapé */
.footer {
    background-color: #f1f5f9;
    border-top: 1px solid #e2e8f0;
    padding: 20px 0;
    margin-top: auto;
}

.footer .container {
    text-align: center;
}

.footer-text {
    font-size: 14px;
    color: #64748b;
    margin-bottom: 4px;
}

.footer-update {
    font-size: 12px;
    color: #94a3b8;
}

/* Utilitários */
.hidden {
    display: none !important;
}

/* Responsividade */
@media (max-width: 768px) {
    .container {
        padding: 0 16px;
    }
    
    .header .container {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }
    
    .header-title {
        font-size: 20px;
    }
    
    .main-content {
        padding: 20px 0;
    }
    
    .policy-content {
        margin: 0 16px;
    }
    
    .app-info,
    .policy-text {
        padding: 20px;
    }
    
    .app-name {
        font-size: 24px;
    }
    
    .lang-btn {
        padding: 10px 16px;
        font-size: 16px;
        min-width: 80px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 12px;
    }
    
    .header {
        padding: 16px 0;
    }
    
    .app-info,
    .policy-text {
        padding: 16px;
    }
    
    .policy-description {
        font-size: 15px;
    }
    
    .error-state,
    .loading-state {
        padding: 30px 16px;
    }
}

/* Animações suaves */
.policy-content,
.error-state {
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}