/* Variáveis Globais de Cores (Padrão Forecast) */
:root {
    --bg-color: #f4f6f8;
    --text-main: #2c3e50;
    --text-muted: #7f8c8d;
    --primary: #45276F;       /* Roxo Marca */
    --primary-light: #f4f0f9;
    --accent: #e67e22;        /* Laranja/Dourado */
    --card-bg: #ffffff;
    --border: #e0e6ed;
}

/* Reset Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', 'Segoe UI', sans-serif;
}

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    line-height: 1.6;
}

/* =========================================
   CABEÇALHO E PÁGINA INICIAL
   ========================================= */
header {
    background: var(--card-bg);
    padding: 20px 40px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.03);
    display: flex;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo span { font-weight: 300; color: var(--text-muted); }

main {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
}

.hero-title { font-size: 2rem; margin-bottom: 10px; color: var(--text-main); }
.hero-subtitle { color: var(--text-muted); margin-bottom: 40px; font-size: 1.1rem; }

.category-section { margin-bottom: 50px; }
.category-title {
    font-size: 1.2rem; font-weight: 600; color: var(--primary);
    margin-bottom: 20px; display: flex; align-items: center; gap: 10px;
    border-bottom: 2px solid var(--border); padding-bottom: 10px;
}

/* Cards de Ferramentas */
.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.card {
    background: var(--card-bg); border: 1px solid var(--border);
    border-radius: 12px; padding: 25px; cursor: pointer;
    transition: all 0.3s ease; display: flex; flex-direction: column;
    position: relative; overflow: hidden;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 24px rgba(69, 39, 111, 0.08);
    border-color: var(--primary);
}

.card::before {
    content: ''; position: absolute; top: 0; left: 0;
    width: 100%; height: 4px; background: var(--accent);
    transform: scaleX(0); transform-origin: left; transition: transform 0.3s ease;
}

.card:hover::before { transform: scaleX(1); }

.card-icon {
    width: 50px; height: 50px; background: var(--primary-light);
    color: var(--primary); border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    margin-bottom: 15px; transition: all 0.3s;
}

.card:hover .card-icon { background: var(--primary); color: white; }
.card-title { font-size: 1.1rem; font-weight: 600; margin-bottom: 8px; }
.card-desc { font-size: 0.9rem; color: var(--text-muted); flex-grow: 1; }

footer {
    text-align: center; padding: 30px; color: var(--text-muted);
    font-size: 0.9rem; border-top: 1px solid var(--border); margin-top: 40px;
}

/* =========================================
   SISTEMA DE MODAIS (JANELAS DAS FERRAMENTAS)
   ========================================= */
.tool-modal-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(44, 62, 80, 0.6); backdrop-filter: blur(4px);
    z-index: 2000; display: flex; justify-content: center; align-items: center;
    animation: fadeIn 0.2s ease;
}

.tool-modal-window {
    background: var(--card-bg); 
    width: 800px; /* <--- ALTERADO AQUI: De 600px para 800px */
    max-width: 95%;
    border-radius: 12px; 
    box-shadow: 0 20px 50px rgba(0,0,0,0.2);
    overflow: hidden; 
    animation: slideUp 0.3s ease;
    display: flex; 
    flex-direction: column; 
    max-height: 90vh;
}

.tool-modal-header {
    background: var(--primary); color: white; padding: 15px 25px;
    display: flex; justify-content: space-between; align-items: center;
}

.tool-modal-header h2 { font-size: 1.2rem; font-weight: 600; margin: 0; }

.tool-modal-close {
    background: none; border: none; color: white; font-size: 28px;
    cursor: pointer; line-height: 1; opacity: 0.8; transition: opacity 0.2s;
}
.tool-modal-close:hover { opacity: 1; }

.tool-modal-content { padding: 30px; overflow-y: auto; }

/* Controles de Formulário e UI Generica para Ferramentas */
.tabs-container {
    display: flex; gap: 10px; background: #f0f2f5;
    padding: 5px; border-radius: 8px; margin-bottom: 25px;
}

.tool-tab {
    flex: 1; border: none; background: transparent; padding: 10px;
    font-size: 0.95rem; font-weight: 600; color: var(--text-muted);
    border-radius: 6px; cursor: pointer; transition: all 0.2s;
}

.tool-tab:hover { color: var(--primary); }
.tool-tab.active { background: white; color: var(--primary); box-shadow: 0 2px 5px rgba(0,0,0,0.05); }

/* Animações */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideUp { from { transform: translateY(20px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }