/* --- Variáveis e Cores --- */
:root {
    --bg-color: #ffffff;
    --text-color: #1a1a1a;
    --header-bg: rgba(255, 255, 255, 0.85);
    --border-color: #eaeaea;
    --accent-color: #000000;
    --secondary-text: #666666;
    --container-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
    --status-green: #22c55e;
    --status-red: #ef4444;
    --header-height: 64px;
    --max-width: 1000px;
    
    /* Constantes de Consistência */
    --input-padding: 12px 14px;
    --input-radius: 8px;
    --font-size-base: 0.9rem;
    --font-size-label: 0.8rem;
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg-color: #0a0a0a;
        --text-color: #ededed;
        --header-bg: rgba(10, 10, 10, 0.85);
        --border-color: #222222;
        --accent-color: #ffffff;
        --secondary-text: #888888;
        --container-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    }
}

/* --- Estilos Base --- */
body {
    font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    margin: 0;
    padding: 0;
    background-color: var(--bg-color);
    color: var(--text-color);
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100vh;
    transition: background-color 0.3s;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* Limpeza Global de Links (Sem sublinhado) */
a {
    text-decoration: none;
    color: inherit;
    transition: opacity 0.2s, color 0.2s;
}

a:hover {
    opacity: 0.7;
}

/* --- Cabeçalho --- */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: var(--header-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    height: var(--header-height);
    z-index: 1000;
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
    padding: 0 24px;
    box-sizing: border-box;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
}

#logo {
    height: 22px;
    width: auto;
    display: block;
}

.header-nav {
    display: flex;
    gap: 24px;
}

.header-nav a {
    color: var(--secondary-text);
    font-size: 0.85rem;
    font-weight: 500;
}

.header-nav a:hover {
    color: var(--accent-color);
    opacity: 1;
}

/* --- Layout --- */
.main-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: 100%;
    max-width: 800px;
    padding: calc(var(--header-height) + 40px) 24px 60px;
    box-sizing: border-box;
}

.container {
    width: 100%;
    padding: 48px;
    background-color: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    box-shadow: var(--container-shadow);
    animation: fadeIn 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    box-sizing: border-box;
}

h1 {
    font-size: 2rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    margin: 0 0 16px;
    line-height: 1.2;
    color: var(--accent-color);
}

.subtitle {
    font-size: 0.95rem;
    color: var(--secondary-text);
    margin-bottom: 32px;
}

/* --- Consistência Global de Formulários --- */
.form-group {
    margin-bottom: 20px;
    text-align: left;
}

.form-group label {
    display: block;
    font-size: var(--font-size-label);
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--secondary-text);
}

/* Estilo unificado para campos de entrada */
input[type="text"],
input[type="email"],
select,
textarea,
.newsletter-input {
    width: 100%;
    padding: var(--input-padding);
    border: 1px solid var(--border-color);
    border-radius: var(--input-radius);
    background: var(--bg-color);
    color: var(--text-color);
    font-family: inherit;
    font-size: var(--font-size-base);
    transition: all 0.2s ease;
    box-sizing: border-box;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 1px var(--accent-color);
}

.btn-primary {
    padding: var(--input-padding);
    background-color: var(--accent-color);
    color: var(--bg-color);
    border: none;
    border-radius: var(--input-radius);
    cursor: pointer;
    font-weight: 500;
    font-size: var(--font-size-base);
    transition: opacity 0.2s, transform 0.1s;
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-primary:hover {
    opacity: 0.9;
}

.btn-primary:active {
    transform: scale(0.98);
}

/* --- Componentes da Página de Status --- */
.status-header {
    background-color: var(--status-green);
    color: #fff;
    padding: 16px 20px;
    border-radius: 10px;
    font-size: 0.9rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 24px;
}

.status-header .dot {
    background-color: #fff;
    box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.2);
}

.status-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0;
    border-bottom: 1px solid var(--border-color);
}

.status-item:last-child {
    border-bottom: none;
}

.status-label {
    font-size: 0.9rem;
    font-weight: 500;
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--status-green);
    text-transform: uppercase;
}

.dot {
    height: 8px;
    width: 8px;
    background-color: var(--status-green);
    border-radius: 50%;
    flex-shrink: 0;
}

/* --- Formulário Newsletter --- */
.input-group {
    display: flex;
    gap: 10px;
    width: 100%;
}

/* --- Grelha da Página de Contacto --- */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 60px;
    align-items: start;
}

.info-block {
    margin-top: 32px;
}

.info-block h3 {
    font-size: 0.7rem;
    text-transform: uppercase;
    color: var(--secondary-text);
    margin-bottom: 6px;
    letter-spacing: 0.08em;
    font-weight: 600;
}

.info-block p {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 500;
}

select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
}

/* --- Rodapé --- */
.site-footer {
    width: 100%;
    padding: 40px 24px;
    border-top: 1px solid var(--border-color);
    box-sizing: border-box;
    margin-top: auto;
}

.copyright-section p {
    font-size: 0.75rem;
    color: var(--secondary-text);
    text-align: center;
    margin: 0;
}

/* --- Animações --- */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* --- Ajustes Mobile --- */
@media (max-width: 768px) {
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    .container {
        padding: 32px 24px;
    }
    .input-group {
        flex-direction: column;
    }
    .btn-primary {
        width: 100%;
    }
}