* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    min-height: 100vh;
    padding: 20px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    padding: 30px;
}

/* Header */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 3px solid #dc2626;
    padding-bottom: 20px;
    margin-bottom: 30px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 15px;
}

.pi-logo {
    background: #dc2626;
    color: white;
    font-size: 36px;
    font-weight: bold;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-style: italic;
}

.logo-text {
    font-size: 11px;
    line-height: 1.3;
    font-weight: 700;
}

.form-info h1 {
    font-size: 24px;
    color: #1f2937;
    margin: 0;
}

.form-number {
    font-size: 14px;
    color: #6b7280;
    margin-top: 5px;
}

/* User Info */
.user-info {
    background: #f9fafb;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
}

.user-info p {
    margin: 0;
    font-size: 14px;
    color: #374151;
}

.user-info strong {
    color: #1f2937;
}

/* Instructions */
.instructions {
    background: #fef3c7;
    border-left: 4px solid #f59e0b;
    padding: 20px;
    margin-bottom: 25px;
    border-radius: 8px;
}

.instructions p {
    margin: 0 0 10px 0;
    line-height: 1.6;
    color: #78350f;
}

.instructions p:last-child {
    margin-bottom: 0;
}

.instruction-note {
    font-size: 13px;
    font-style: italic;
}

/* Form Groups */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: #374151;
    font-size: 14px;
}

.form-group input[type="text"],
.form-group input[type="date"] {
    width: 100%;
    padding: 12px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 15px;
    transition: border-color 0.3s;
}

.form-group input:focus {
    outline: none;
    border-color: #dc2626;
}

/* Counter */
.counter {
    background: #f3f4f6;
    padding: 15px;
    border-radius: 8px;
    text-align: center;
    margin-bottom: 20px;
    font-size: 18px;
    font-weight: 600;
}

#selectedCount {
    color: #e74c3c;
    font-size: 24px;
}

/* Palavras Container */
.palavras-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-bottom: 30px;
}

.coluna {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.palavra-item {
    display: flex;
    align-items: center;
    padding: 10px;
    border: 2px solid #e5e7eb;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    background: white;
}

.palavra-item:hover {
    background: #f9fafb;
    border-color: #dc2626;
}

.palavra-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-right: 10px;
    cursor: pointer;
    accent-color: #dc2626;
}

.palavra-item input[type="checkbox"]:checked + span {
    font-weight: 600;
    color: #dc2626;
}

.palavra-item span {
    font-size: 14px;
    color: #374151;
}

/* Buttons */
.btn-primary,
.btn-secondary {
    padding: 12px 30px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
    display: inline-block;
}

.btn-primary {
    background: #dc2626;
    color: white;
}

.btn-primary:hover {
    background: #b91c1c;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(220, 38, 38, 0.3);
}

.btn-secondary {
    background: #6b7280;
    color: white;
}

.btn-secondary:hover {
    background: #4b5563;
}

.form-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 30px;
}

/* Success Message */
.success-message {
    background: #d1fae5;
    border-left: 4px solid #10b981;
    padding: 25px;
    border-radius: 8px;
    margin-bottom: 30px;
    text-align: center;
}

.success-message h2 {
    color: #065f46;
    margin-bottom: 10px;
    font-size: 24px;
}

.success-message p {
    color: #047857;
    font-size: 16px;
}

/* Resultado */
.resultado {
    margin: 30px 0;
}

.resultado h3 {
    color: #1f2937;
    margin-bottom: 20px;
    font-size: 20px;
}

.resultado-secao {
    margin-bottom: 30px;
    background: #f9fafb;
    padding: 20px;
    border-radius: 8px;
}

.resultado-secao h4 {
    color: #374151;
    margin-bottom: 15px;
    font-size: 16px;
}

.palavras-resultado {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 10px;
}

.palavra-tag {
    background: #dc2626;
    color: white;
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
}

.count-info {
    font-size: 13px;
    color: #6b7280;
    font-style: italic;
    margin-top: 10px;
}

/* Footer */
footer {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid #e5e7eb;
    text-align: center;
}

footer p {
    color: #6b7280;
    font-size: 12px;
    margin: 5px 0;
}

.file-info {
    color: #9ca3af;
    font-style: italic;
}

/* Responsive */
@media (max-width: 768px) {
    .container {
        padding: 20px;
    }

    .header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }

    .palavras-container {
        grid-template-columns: 1fr;
    }

    .user-info {
        flex-direction: column;
        gap: 10px;
    }

    .form-actions {
        flex-direction: column;
    }

    .btn-primary,
    .btn-secondary {
        width: 100%;
    }
}

@media print {
    body {
        background: white;
    }

    .container {
        box-shadow: none;
    }

    .form-actions,
    footer {
        display: none;
    }
}