/* Modern CSS for introbella.com */

/* 1. CSS Reset / Normalization */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px; /* Base font size for rem units */
}

body {
    font-family: 'Metrophobic', Arial, sans-serif;
    line-height: 1.6;
    color: #444;
    background-color: #f4f4f4;
    text-align: center;
}

/* 2. Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Gruppo', Verdana, sans-serif;
    color: #333;
    margin-top: 1em;
    margin-bottom: 0.5em;
}

h1 {
    font-size: 3.5rem;
    letter-spacing: 0.5rem;
    color: #fff;
    margin-top: 0.5em;
    margin-bottom: 0.5em;
}

h3 {
    font-size: 1.8rem;
}

p {
    margin-bottom: 1em;
}

a {
    color: #222222;
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    text-decoration: underline;
    color: #000000;
}

ul {
    list-style: none;
    margin-bottom: 1em;
}

li {
    margin-bottom: 0.5em;
}

abbr {
    text-decoration: none;
    border-bottom: 1px dotted #999;
    cursor: help;
}

/* 3. Layout - Header */
header {
    background-color: #B30000;
    color: #fff;
    padding: 1rem 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    position: relative; /* For positioning the menu toggle */
}

.header-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.site-title h1 {
    margin: 0;
    font-size: 2.5rem;
    letter-spacing: 0.3rem;
}

/* Menu Toggle Button */
.menu-toggle {
    display: none; /* Hidden by default, shown on small screens */
    background: none;
    border: none;
    color: #fff;
    font-size: 1.8rem;
    cursor: pointer;
    padding: 0.5rem;
    position: absolute;
    top: 1rem;
    right: 1rem;
    z-index: 1000; /* Ensure it's above other content */
}

/* Animation for hamburger to X */
.menu-toggle .fa-bars {
    transition: transform 0.3s ease-in-out;
}

.menu-toggle.active .fa-bars {
    transform: rotate(90deg); /* Rotate to form an X */
}

.main-nav {
    width: 100%;
    max-height: 0; /* Hidden by default */
    overflow: hidden;
    transition: max-height 0.3s ease-in-out;
}

.main-nav.active {
    max-height: 1000px; /* Increased to ensure all menu items are visible */
}

.main-nav ul {
    display: flex;
    flex-direction: column; /* Stack vertically on small screens */
    padding: 0;
    margin: 1rem 0;
    width: 100%;
    text-align: center;
}

.main-nav li {
    margin: 0.5rem 0;
}

.main-nav a {
    color: #fff;
    font-weight: bold;
    padding: 0.5rem 0;
    display: block;
    transition: color 0.3s ease;
}

.main-nav a:hover {
    color: #000000;
    text-decoration: none;
}

.main-nav .external-links-heading h3 {
    color: #fff;
    font-size: 1.2rem;
    margin-top: 1rem;
    margin-bottom: 0.5rem;
}

.main-nav li a i {
    margin-right: 0.5rem;
}

/* 4. Layout - Content */
#content {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
}

#text {
    background-color: #fff;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    flex: 1;
    min-width: 300px;
    text-align: left;
}

#text article {
    margin-bottom: 2em;
}

#text article:last-child {
    margin-bottom: 0;
}

#text strong {
    color: #B30000; /* Make strong text red */
}

/* 5. Layout - Footer */
footer {
    background-color: #B30000;
    color: #fff;
    padding: 1rem 0;
    margin-top: 2rem;
    box-shadow: 0 -2px 5px rgba(0,0,0,0.2);
}

footer small {
    margin: 0 0.5rem;
}

footer a {
    color: #222222;
}

footer a:hover {
    color: #000000;
}

/* 6. Responsive Design */
@media (max-width: 767px) {
    .header-content {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }

    .site-title {
        flex-grow: 1;
        text-align: left;
    }

    .menu-toggle {
        display: block; /* Show hamburger on small screens */
    }

    .main-nav {
        position: absolute;
        top: 100%; /* Position below the header */
        left: 0;
        background-color: #B30000; /* Same as header */
        box-shadow: 0 2px 5px rgba(0,0,0,0.2);
        padding: 1rem 0;
        z-index: 999;
    }

    .main-nav ul {
        padding-bottom: 1rem; /* Add some padding at the bottom of the menu */
    }

    .main-nav .external-links-heading {
        display: block; /* Show heading on mobile */
        color: #fff; /* Ensure heading is white */
    }

    .main-nav li.external-link-item a {
        color: #fff; /* Ensure external links are white */
        padding: 0.75rem 0; /* Add more padding for better touch targets */
    }

    .main-nav li a i {
        font-size: 1.5rem; /* Adjust icon size for mobile */
    }
}

@media (min-width: 768px) {
    .header-content {
        flex-direction: row;
        justify-content: space-between;
    }

    .site-title {
        flex-grow: 1;
        text-align: left;
    }

    .menu-toggle {
        display: none; /* Hide hamburger on larger screens */
    }

    .main-nav {
        display: block; /* Ensure menu is visible on larger screens */
        width: auto;
        max-height: none; /* Remove max-height restriction */
        overflow: visible;
        position: static; /* Reset position for desktop */
        background-color: transparent; /* Reset background for desktop */
        box-shadow: none; /* Remove shadow for desktop */
        padding: 0; /* Remove padding for desktop */
    }

    .main-nav ul {
        flex-direction: row; /* Horizontal layout on larger screens */
        justify-content: flex-end;
        margin: 0;
    }

    .main-nav li {
        margin: 0 1rem;
    }

    .main-nav .external-links-heading {
        display: none; /* Hide heading on desktop */
    }

    .main-nav li a i {
        font-size: 2rem; /* Reset icon size for desktop */
    }

    .main-nav li:last-child {
        margin-right: 0; /* Remove right margin for the last item */
    }
}

@media (min-width: 1024px) {
    .site-title h1 {
        font-size: 3.5rem;
    }
}