/* ==================================================================
   IB MULTISERVICES - Custom Luxury Dark Theme
   ================================================================== */

:root {
    --ib-dark: #121212;
    --ib-card-bg: #1a1a1a;
    --ib-border: #2a2a2a;
    --ib-bronzo: #c5a059;
    --ib-bronzo-hover: #d4af37;
    --ib-text-muted: #a0a0a0;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--ib-dark);
    color: #e0e0e0;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    overflow-x: hidden;
}

/* Compensa l'altezza della navbar fissa sullo scroll verso ancore e bersagli interni */
section[id],
div[id],
h2[id],
h3[id] {
    scroll-margin-top: 105px;
}

/* Navbar Antracite Metallizzato con contrasto WCAG AAA */
.navbar {
    background: linear-gradient(180deg, #2b2e33 0%, #1d1f22 100%) !important;
    border-bottom: 1px solid rgba(197, 160, 89, 0.45);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
    padding-top: 10px;
    padding-bottom: 10px;
}

.navbar-brand img {
    height: 52px;
    width: 52px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid var(--ib-bronzo);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.navbar .nav-link {
    color: #f0f0f0 !important;
    font-weight: 500;
    transition: color 0.3s ease;
}

.navbar .nav-link:hover,
.navbar .nav-link.active {
    color: var(--ib-bronzo) !important;
}

/* Utility colore bronzo e leggibilità su sfondo scuro */
.text-bronzo {
    color: var(--ib-bronzo) !important;
}

.text-light-custom {
    color: #cccccc !important;
}

.hover-bronzo:hover {
    color: var(--ib-bronzo) !important;
}

.bg-antracite-dark {
    background-color: #181a1d !important;
}

.tracking-widest {
    letter-spacing: 2.5px;
}

/* ==================================
   HERO SECTION (Stile Editoriale Definitivo)
   ================================== */
.hero-section {
    min-height: calc(100vh - 76px);
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.hero-dot {
    width: 7px;
    height: 7px;
    background-color: var(--ib-bronzo);
    border-radius: 50%;
    display: inline-block;
}

.hero-eyebrow {
    font-size: 0.75rem;
    letter-spacing: 2.5px;
    font-weight: 600;
    color: #d4d4d4;
    text-transform: uppercase;
}

.hero-title-editorial {
    font-size: clamp(2.8rem, 6vw, 5.2rem);
    font-weight: 600;
    line-height: 1.08;
    letter-spacing: -1.5px;
    color: #ffffff;
}

.font-serif {
    font-family: Georgia, 'Times New Roman', serif;
}

.hero-bottom-bar {
    border-top: 1px solid rgba(197, 160, 89, 0.25);
}

.hero-meta {
    font-size: 0.75rem;
    letter-spacing: 2px;
    color: #a0a0a0;
    font-weight: 500;
}

/* Pulsanti personalizzati */
.btn-bronzo {
    background-color: var(--ib-bronzo);
    color: #121212;
    font-weight: 600;
    border: none;
    transition: all 0.3s ease;
}

.btn-bronzo:hover {
    background-color: var(--ib-bronzo-hover);
    color: #000000;
    transform: translateY(-2px);
}

.btn-outline-bronzo {
    color: var(--ib-bronzo);
    border-color: var(--ib-bronzo);
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-outline-bronzo:hover {
    background-color: var(--ib-bronzo);
    color: #121212;
}

/* Card servizi in stile luxury */
.service-card {
    background-color: var(--ib-card-bg);
    border: 1px solid var(--ib-border);
    border-radius: 8px;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.service-card:hover {
    transform: translateY(-5px);
    border-color: var(--ib-bronzo);
}

/* Sezioni */
section {
    padding: 80px 0;
}

.bg-card-custom {
    background-color: var(--ib-card-bg);
    border: 1px solid var(--ib-border);
}

/* ==================================
   TAB DETTAGLIO SERVIZI (Luxury Dark - Corretto)
   ================================== */
.ib-service-tabs .nav-link {
    background-color: transparent;
    color: #a0a0a0;
    border: none;
    border-bottom: 1px solid rgba(197, 160, 89, 0.25);
    border-radius: 0;
    padding: 1.25rem 1.5rem;
    font-size: 1.05rem;
    font-weight: 500;
    transition: all 0.25s ease;
}

.ib-service-tabs .nav-link:hover {
    color: #ffffff;
    background-color: rgba(197, 160, 89, 0.06);
    border-bottom-color: rgba(197, 160, 89, 0.25);
}

.ib-service-tabs .nav-link.active {
    background-color: rgba(197, 160, 89, 0.14);
    color: #ffffff;
    border-bottom: 3px solid var(--ib-bronzo);
}

.ib-service-tabs .tab-arrow {
    color: var(--ib-bronzo);
    transition: transform 0.25s ease;
}

.ib-service-tabs .nav-link:hover .tab-arrow,
.ib-service-tabs .nav-link.active .tab-arrow {
    transform: translate(3px, -3px);
}

.ib-role-list li {
    padding: 1rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    color: #e6e6e6;
    font-size: 1.05rem;
    transition: padding-left 0.2s ease, color 0.2s ease;
}

.ib-role-list li:hover {
    padding-left: 8px;
    color: #ffffff;
    border-bottom-color: rgba(197, 160, 89, 0.45);
}

.ib-link-underline {
    color: #ffffff;
    text-decoration: none;
    border-bottom: 1px solid var(--ib-bronzo);
    padding-bottom: 4px;
    font-weight: 500;
    transition: color 0.25s ease;
}

.ib-link-underline:hover {
    color: var(--ib-bronzo);
}

/* ==================================
   BANNER PICCOLI EVENTI (Accent Bronzo)
   ================================== */
.bg-bronzo-banner {
    background-color: var(--ib-bronzo);
}

.ib-link-dark {
    color: #121212;
    text-decoration: none;
    border-bottom: 1.5px solid #121212;
    padding-bottom: 4px;
    font-weight: 600;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.ib-link-dark:hover {
    color: #000000;
    opacity: 0.75;
}

/* ==================================
   FORM & INPUT (Dark Anthracite & Bronze)
   ================================== */
.ib-form-box {
    background-color: #141417;
    border: 1px solid #2b2b32;
    border-radius: 8px;
}

.ib-label {
    color: #e6e6ea;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 0.4rem;
    display: inline-block;
}

/* Card di selezione Macro-Area (Step 1) */
.ib-area-card {
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: 100%;
    height: 100%;
    background-color: #1b1b20;
    border: 1px solid #2e2e36;
    color: #f1f1f4;
    border-radius: 6px;
    padding: 1rem 1.15rem;
    text-align: left;
    cursor: pointer;
    user-select: none;
    transition: border-color 0.2s ease, background-color 0.2s ease, transform 0.15s ease;
}

.ib-area-card .ib-card-sub {
    color: #9e9ea8;
    font-size: 0.82rem;
    display: block;
    margin-top: 0.25rem;
    transition: color 0.2s ease;
}

.ib-area-card:hover {
    background-color: #23232a;
    border-color: var(--ib-bronzo);
    color: #ffffff;
}

.ib-area-card:hover .ib-card-sub {
    color: #c8c8d2;
}

.btn-check:checked + .ib-area-card,
.btn-check:checked + .ib-area-card:hover {
    background-color: #242018;
    border-color: var(--ib-bronzo);
    color: #ffffff;
    box-shadow: inset 3px 0 0 var(--ib-bronzo);
}

.btn-check:checked + .ib-area-card .ib-card-sub {
    color: #d4b97e;
}

/* Campi Input, Select e Textarea */
.ib-input {
    background-color: #1b1b20 !important;
    border: 1px solid #2e2e36 !important;
    color: #f1f1f4 !important;
    border-radius: 6px;
    padding: 0.65rem 0.85rem;
    font-size: 0.95rem;
    transition: border-color 0.2s ease, background-color 0.2s ease;
}

.ib-input::placeholder {
    color: #767682 !important;
    opacity: 1;
}

.ib-input:hover:not(:disabled) {
    border-color: #464652 !important;
}

.ib-input:focus {
    background-color: #1f1f25 !important;
    border-color: var(--ib-bronzo) !important;
    box-shadow: none !important;
    outline: none;
}

.ib-input option {
    background-color: #1b1b20;
    color: #f1f1f4;
}

/* Sottotitolo sezione LAVORA CON NOI */
.ib-text-muted {
    color: var(--ib-text-muted);
}

/* Checkbox */
.ib-checkbox {
    width: 1.05em;
    height: 1.05em;
    background-color: #1b1b20;
    border: 1px solid #464652;
    border-radius: 4px;
    cursor: pointer;
}

.ib-checkbox:hover:not(:disabled) {
    border-color: var(--ib-bronzo);
}

.ib-checkbox:checked {
    background-color: var(--ib-bronzo);
    border-color: var(--ib-bronzo);
    box-shadow: none;
}

.ib-checkbox:focus {
    box-shadow: none;
    border-color: var(--ib-bronzo);
}

/* Nota informativa Curriculum Vitae */
.ib-cv-note {
    background-color: #191815;
    border-left: 3px solid var(--ib-bronzo);
    border-radius: 0 6px 6px 0;
    padding: 0.9rem 1rem;
    color: #d5d5dc;
    font-size: 0.875rem;
    line-height: 1.55;
}

.ib-link {
    color: var(--ib-bronzo);
    text-decoration: underline;
    text-underline-offset: 3px;
    transition: color 0.2s ease;
}

.ib-link:hover,
.ib-link:focus {
    color: var(--ib-bronzo-hover);
}

/* Form di contatto pulito */
/* Selettore data più luminoso e visibile su dark */
.ib-input[type="date"],
.form-control[type="date"] {
    color-scheme: dark;
}

.ib-input[type="date"]::-webkit-calendar-picker-indicator,
.form-control[type="date"]::-webkit-calendar-picker-indicator {
    filter: invert(82%) sepia(42%) saturate(950%) hue-rotate(352deg) brightness(108%) contrast(92%);
    opacity: 0.95;
    cursor: pointer;
    transition: opacity 0.2s ease, filter 0.2s ease, transform 0.2s ease;
}

.ib-input[type="date"]::-webkit-calendar-picker-indicator:hover,
.form-control[type="date"]::-webkit-calendar-picker-indicator:hover {
    filter: invert(88%) sepia(55%) saturate(1100%) hue-rotate(350deg) brightness(118%) contrast(95%);
    opacity: 1;
    transform: scale(1.06);
}

/* Footer */
footer {
    background-color: #0a0a0a;
    border-top: 1px solid var(--ib-border);
    color: var(--ib-text-muted);
    font-size: 0.9rem;
}