:root {
    /* Color Palette */
    --primary-color: #005f6b;
    /* Blu Petrolio */
    --accent-color: #d4af37;
    /* Oro */
    --dark-bg: #0a192f;
    /* Dark Navy for contrast */
    --light-text: #f8f9fa;
    --dark-text: #212529;
    --overlay-color: rgba(0, 95, 107, 0.85);
}

body {
    font-family: 'Montserrat', sans-serif;
    color: var(--dark-text);
    overflow-x: hidden;
}

/* Typography & Headings */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 700;
    color: var(--primary-color);
}

.text-gold {
    color: var(--accent-color) !important;
}

.bg-primary-custom {
    background-color: var(--primary-color) !important;
}

.bg-gold {
    background-color: var(--accent-color) !important;
}

/* Navbar Customization */
.navbar-custom {
    background-color: var(--primary-color);
    padding: 1rem 0;
    transition: all 0.3s ease;
}

.navbar-brand img {
    height: 50px;
    width: auto;
}

.nav-link {
    color: rgba(255, 255, 255, 0.9) !important;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--accent-color) !important;
}

.dropdown-menu {
    background-color: var(--primary-color);
    border: none;
    border-top: 3px solid var(--accent-color);
}

.dropdown-item {
    color: white;
    font-weight: 500;
}

.dropdown-item:hover {
    background-color: rgba(212, 175, 55, 0.2);
    color: var(--accent-color);
}

/* Hero Section */
.hero-section {
    position: relative;
    height: 100vh;
    min-height: 600px;
    /* Background image removed here, handled by inline img */
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    overflow: hidden;
    /* Ensure image doesn't overflow */
}

.hero-bg-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.8) 0%, rgba(0, 50, 60, 0.7) 100%);
    /* Made slightly darker */
    z-index: 2;
    /* Sit on top of image */
}

.hero-content {
    position: relative;
    z-index: 3;
    /* Sit on top of overlay */
    max-width: 800px;
    padding: 20px;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    text-transform: uppercase;
    margin-bottom: 1rem;
    letter-spacing: 2px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
    /* Added shadow for better contrast */
}

.hero-subtitle {
    font-size: 1.5rem;
    font-weight: 300;
    margin-bottom: 2rem;
}

.btn-custom {
    background-color: var(--accent-color);
    color: var(--dark-bg);
    padding: 12px 30px;
    font-weight: 700;
    border-radius: 50px;
    text-transform: uppercase;
    transition: all 0.3s ease;
    border: 2px solid var(--accent-color);
}

.btn-custom:hover {
    background-color: transparent;
    color: var(--accent-color);
}

/* Sections */
.section-padding {
    padding: 80px 0;
}

.bg-light-gray {
    background-color: #2c3e50;
    /* Placeholder color matching dark blue theme */
    color: var(--light-text);
}

.bg-light-gray .section-title {
    color: var(--accent-color);
}

.section-title {
    text-align: center;
    margin-bottom: 50px;
    position: relative;
}

/* Social Hub Styles Removed */

/* Remove old ratio */

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background-color: var(--accent-color);
    margin: 15px auto 0;
}

/* Cards */
.card-custom {
    border: none;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
    overflow: hidden;
    background: white;
    height: 100%;
}

.card-custom:hover {
    transform: translateY(-10px);
}

.card-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

/* Team Images */
.team-img-container {
    width: 100%;
    /* Let it fit the column width */
    max-width: 250px;
    /* Optional: constrain max width if column is too wide */
    height: auto;
    /* Allow height to adjust */
    margin: 0 auto 15px;
    overflow: hidden;
    /* rounded corners for rectangle */
    border-radius: 10px;
    border: 4px solid var(--accent-color);
}

.team-img {
    width: 100%;
    height: auto;
    /* Maintain aspect ratio */
    display: block;
    /* Remove bottom space in container */
}

/* Footer */
.footer {
    background-color: var(--dark-bg);
    color: white;
    padding: 60px 0 20px;
}

.footer h5 {
    color: var(--accent-color);
    margin-bottom: 25px;
    font-size: 1.1rem;
    letter-spacing: 1px;
}

.footer-links li {
    margin-bottom: 12px;
    display: block;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 0.95rem;
}

.footer-links a:hover {
    color: var(--accent-color);
    padding-left: 5px;
}

.social-icons a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: white;
    margin-right: 10px;
    transition: all 0.3s;
}

.social-icons a:hover {
    background: var(--accent-color);
    color: var(--dark-bg);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.2rem;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }
}

/* Utilities */

/* Utilities */
.text-justify {
    text-align: justify;
}

/* Brand Colors for Social Icons */
.social-icons a.social-fb { background-color: #1877F2 !important; border: none; }
.social-icons a.social-ig { background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fdf497 5%, #fd5949 45%, #d6249f 60%, #285AEB 90%) !important; border: none;}
.social-icons a.social-tk { background-color: #000000 !important; border: none;}
.social-icons a.social-yt { background-color: #FF0000 !important; border: none;}
.social-icons a.social-wa { background-color: #25D366 !important; border: none;}

.social-icons a.social-fb:hover,
.social-icons a.social-ig:hover,
.social-icons a.social-tk:hover,
.social-icons a.social-yt:hover,
.social-icons a.social-wa:hover {
    background: white !important;
    color: var(--dark-bg) !important;
    transform: scale(1.1);
}
.doc-card {
    border-radius: 15px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.doc-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 .5rem 1rem rgba(0,0,0,.15)!important;
}

/* Submenu Classifiche SH (Hover su desktop e Layout Accordion su mobile) */
@media (min-width: 992px) {
    .dropdown-submenu {
        position: relative;
    }
    .dropdown-submenu > .dropdown-menu {
        top: 0;
        left: 100%;
        margin-top: -6px;
        margin-left: 0;
        display: none;
    }
    .dropdown-submenu:hover > .dropdown-menu {
        display: block;
    }
    /* Freccia puntata a destra su desktop */
    .dropdown-submenu > .dropdown-toggle::after {
        border-top: 0.3em solid transparent;
        border-right: 0;
        border-bottom: 0.3em solid transparent;
        border-left: 0.3em solid;
        float: right;
        margin-top: 0.5em;
        margin-left: 0.5em;
    }
}

@media (max-width: 991.98px) {
    .dropdown-submenu > .dropdown-menu {
        position: static;
        float: none;
        width: auto;
        margin-top: 0;
        background-color: rgba(255, 255, 255, 0.05);
        border: none;
        box-shadow: none;
        padding-left: 1.5rem;
        display: none;
    }
    .dropdown-submenu > .dropdown-menu.show {
        display: block;
    }
}
