:root {
    --primary: #1a365d;
    --secondary: #c53030;
    --accent: #d69e2e;
    --light: #f7fafc;
    --dark: #2d3748;
    --success: #38a169;
    --warning: #d69e2e;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    min-height: 100vh;
    padding: 2rem 1rem;
    color: var(--dark);
}

.container {
    max-width: 800px;
    margin: 0 auto;
    background: white;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.1);
    overflow: hidden;
}

header {
    background: var(--primary);
    color: white;
    padding: 2.5rem 2rem;
    text-align: center;
}

header h1 {
    font-size: 1.6rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    line-height: 1.3;
}

.subtitle {
    opacity: 0.9;
    font-size: 1rem;
}

form {
    padding: 2rem;
}

.form-section {
    margin-bottom: 2.5rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid #e2e8f0;
}

.form-section:last-of-type {
    border-bottom: none;
}

.form-section h2 {
    color: var(--primary);
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.form-group {
    margin-bottom: 1.25rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
}

label {
    display: block;
    font-weight: 500;
    margin-bottom: 0.5rem;
    color: var(--dark);
    font-size: 0.95rem;
}

input[type="text"],
input[type="email"],
input[type="tel"],
select,
textarea {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    font-size: 1rem;
    font-family: inherit;
    transition: all 0.2s;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(26, 54, 93, 0.1);
}

textarea {
    resize: vertical;
    min-height: 100px;
}

.checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.checkbox-group label {
    display: flex;
    align-items: center;
    font-weight: normal;
    margin-bottom: 0;
}

.checkbox-group input[type="checkbox"] {
    width: auto;
    margin-right: 0.5rem;
}

.form-footer {
    margin-top: 2rem;
    text-align: center;
}

.disclaimer {
    font-size: 0.85rem;
    color: #718096;
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

.btn-primary {
    background: var(--primary);
    color: white;
    border: none;
    padding: 1rem 2.5rem;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-primary:hover {
    background: #2d3748;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.15);
}

/* Risultati */
.result-box {
    padding: 3rem 2rem;
    text-align: center;
}

.result-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
}

.result-success {
    color: var(--success);
}

.result-warning {
    color: var(--warning);
}

.result-title {
    font-size: 1.8rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
}

.result-text {
    font-size: 1.1rem;
    line-height: 1.7;
    color: var(--dark);
    margin-bottom: 2rem;
}

.cta-box {
    background: #f7fafc;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 2rem;
    margin: 2rem 0;
}

.cta-box h3 {
    color: var(--primary);
    margin-bottom: 1rem;
}

.cta-box p {
    color: var(--dark);
    line-height: 1.6;
}

/* Responsive */
@media (max-width: 768px) {
    body {
        padding: 1rem;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    header h1 {
        font-size: 1.3rem;
    }
    
    .subtitle {
        font-size: 0.9rem;
    }
}

/* Admin Dashboard Styles */
table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-top: 1rem;
}

th, td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
}

th {
    background: var(--primary);
    color: white;
    font-weight: 600;
}

tr:hover {
    background: #f7fafc;
}

.stato-nuova {
    background: #fed7d7;
    color: #c53030;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.85rem;
}

.stato-in_contatto {
    background: #fef5e7;
    color: #d69e2e;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.85rem;
}

.stato-consulenza {
    background: #d1ecf1;
    color: #0c5460;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.85rem;
}

.coerenza-alto {
    color: var(--success);
    font-weight: bold;
}

.coerenza-buono {
    color: var(--accent);
    font-weight: bold;
}

.coerenza-medio {
    color: #718096;
}

.coerenza-basso {
    color: var(--secondary);
}
