/* ============================================================
   FORMS — Composants de formulaire et recherche
   Utilisé dans : tarifs.html (calculateur EPCI)
   ============================================================ */

/* Search Input Group */
.search-label {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--secondary);
    margin-bottom: 0.6rem;
}

.search-wrapper {
    position: relative;
}

.search-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--accent-territory);
    pointer-events: none;
}

.search-input {
    width: 100%;
    padding: 1rem 1rem 1rem 3rem;
    border: 2px solid rgba(53, 152, 192, 0.2);
    border-radius: 12px;
    font-family: 'IBM Plex Sans', sans-serif;
    font-size: 1rem;
    color: var(--primary);
    background: #fafcfd;
    outline: none;
    transition: border-color 0.25s, box-shadow 0.25s, background 0.25s;
}

.search-input::placeholder {
    color: rgba(14, 62, 73, 0.35);
}

.search-input:focus {
    border-color: var(--accent-data);
    background: white;
    box-shadow: 0 0 0 4px rgba(53, 152, 192, 0.10);
}

/* Suggestions Dropdown */
.suggestions {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    background: white;
    border: 1.5px solid rgba(53, 152, 192, 0.18);
    border-radius: 12px;
    overflow: hidden;
    max-height: 280px;
    overflow-y: auto;
    z-index: 200;
    box-shadow: 0 8px 32px rgba(14, 62, 73, 0.14);
    display: none;
}

.suggestions.open {
    display: block;
}

.suggestion-item {
    padding: 0.85rem 1.1rem;
    cursor: pointer;
    border-bottom: 1px solid rgba(53, 152, 192, 0.07);
    transition: background 0.15s;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

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

.suggestion-item:hover {
    background: rgba(53, 152, 192, 0.07);
}

.suggestion-nom {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--primary);
}

.suggestion-meta {
    font-size: 0.76rem;
    color: var(--accent-territory);
}

/* Calculator Card */
.calculator-section {
    position: relative;
    z-index: 10;
    margin-top: 2.5rem;
}

.calculator-card {
    background: white;
    border-radius: 20px;
    padding: 3rem;
    box-shadow:
        0 2px 4px rgba(14, 62, 73, 0.04),
        0 8px 32px rgba(14, 62, 73, 0.10),
        0 32px 80px rgba(14, 62, 73, 0.08);
    border: 1px solid rgba(53, 152, 192, 0.10);
    opacity: 0;
    transform: translateY(20px);
    animation: cardReveal 0.6s ease 0.2s forwards;
}

@keyframes cardReveal {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.calc-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 2rem;
    gap: 1rem;
}

.calc-header-text h2 {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.4rem;
}

.calc-header-text p {
    font-size: 0.9rem;
    color: var(--secondary);
    opacity: 0.8;
}

.calc-badge {
    flex-shrink: 0;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    padding: 0.4rem 0.9rem;
    border-radius: 20px;
}

/* Result Panel */
.result-panel {
    margin-top: 1.75rem;
    display: none;
}

.result-panel.visible {
    display: block;
}

.result-inner {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    border-radius: 16px;
    padding: 2rem 2.25rem;
    color: white;
    position: relative;
    overflow: hidden;
}

.result-inner::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -5%;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(53, 152, 192, 0.25) 0%, transparent 70%);
    pointer-events: none;
}

.result-epci {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.result-meta {
    font-size: 0.8rem;
    opacity: 0.65;
    margin-bottom: 1.75rem;
}

.calc-note {
    margin-top: 1.25rem;
    font-size: 0.8rem;
    color: rgba(14, 62, 73, 0.45);
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    line-height: 1.6;
}

.calc-note svg {
    flex-shrink: 0;
    margin-top: 2px;
}
