/* General Resets & Variables */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --charcoal: #292929;
    --rust: #A63D2F;
    --moss-green: #596D56;
    --tan: #D9C8A7;
    --light-tan: #EDE0C7; /* Slightly lighter for contrast */
    --text-color: var(--tan);
    --bg-color: var(--charcoal);
    --heading-font: 'Bebas Neue', sans-serif;
    --body-font: 'Special Elite', cursive;
    --accent-font: 'Rock Salt', cursive;
    --max-width: 1200px;
    --content-padding: 4rem 2rem;
    --border-style: 2px dashed var(--rust);
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--body-font);
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-color);
    background-image: url('images/image_14.png'); /* Worn paper base texture */
    background-repeat: repeat;
    overflow-x: hidden; /* Prevent horizontal scroll from effects */
}

/* Base Grunge Section Styling */
.grunge-section {
    position: relative;
    padding: var(--content-padding);
    margin-bottom: 2rem;
    background-color: var(--charcoal);
    background-image: url('images/image_15.png'), url('images/image_16.png'); /* Layered textures */
    background-blend-mode: multiply, screen;
    border: var(--border-style);
    overflow: hidden; /* For torn edge effects */
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
}

.grunge-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(0,0,0,0.1), rgba(0,0,0,0.3)), /* Dark overlay */
                radial-gradient(circle at 10% 10%, rgba(255,255,255,0.05) 5%, transparent 15%), /* Subtle noise/grain */
                radial-gradient(circle at 90% 90%, rgba(255,255,255,0.05) 5%, transparent 15%);
    pointer-events: none;
    mix-blend-mode: overlay;
    z-index: 0;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--heading-font);
    color: var(--light-tan);
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    filter: drop-shadow(2px 2px 3px rgba(0,0,0,0.7));
}

h1 {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    color: var(--rust);
    margin-bottom: 1.5rem;
}

h2 {
    font-size: clamp(2rem, 5vw, 3.5rem);
    color: var(--moss-green);
    border-bottom: var(--border-style);
    padding-bottom: 0.5rem;
    margin-bottom: 2rem;
    text-align: center;
}

h3 {
    font-size: clamp(1.5rem, 4vw, 2.5rem);
    color: var(--tan);
    margin-top: 1.5rem;
    margin-bottom: 1rem;
}

h4 {
    font-size: clamp(1.2rem, 3vw, 1.8rem);
    color: var(--light-tan);
    margin-bottom: 0.75rem;
}

p {
    margin-bottom: 1rem;
}

ul {
    list-style: none;
    padding-left: 0;
    margin-bottom: 1rem;
}

ul li {
    padding-left: 1.5rem;
    position: relative;
    margin-bottom: 0.5rem;
}

ul li::before {
    content: ''; /* Using a pseudo-element instead of icon entities */
    position: absolute;
    left: 0;
    top: 0.25em;
    width: 0.8em;
    height: 0.8em;
    border: 2px solid var(--rust);
    transform: rotate(45deg);
    background-color: var(--rust);
    box-shadow: 0 0 5px rgba(0,0,0,0.5);
}

.pre-heading {
    font-family: var(--accent-font);
    color: var(--rust);
    font-size: 1.2rem;
    text-transform: capitalize;
    margin-bottom: 0.5rem;
}

.emphasized-text {
    font-family: var(--accent-font);
    font-size: 1.5rem;
    color: var(--light-tan);
    text-align: center;
    margin-top: 2rem;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.8);
}

/* Buttons */
.button {
    display: inline-block;
    background-color: var(--rust);
    color: var(--light-tan);
    font-family: var(--accent-font);
    font-size: 1.1rem;
    padding: 0.8rem 1.8rem;
    border: 2px solid var(--light-tan);
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s ease-in-out;
    filter: drop-shadow(3px 3px 5px rgba(0,0,0,0.6));
    position: relative;
    overflow: hidden;
}

.button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(var(--light-tan-rgb), 0.1); /* Use RGB for cleaner alpha */
    transition: all 0.5s ease;
    mix-blend-mode: overlay;
}

.button:hover {
    background-color: var(--moss-green);
    border-color: var(--moss-green);
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 5px 15px rgba(0,0,0,0.4);
}

.button:hover::before {
    left: 0;
}

.button-small {
    padding: 0.6rem 1.2rem;
    font-size: 0.9rem;
}

/* Header & Navigation */
header {
    background-color: var(--charcoal);
    padding: 1rem 2rem;
    border-bottom: var(--border-style);
    position: sticky;
    top: 0;
    z-index: 1000;
    background-image: url('images/image_15.png');
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: var(--max-width);
    margin: 0 auto;
}

.logo {
    font-family: var(--accent-font);
    font-size: 1.8rem;
    color: var(--tan);
    text-transform: uppercase;
    letter-spacing: 3px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.7);
}

.nav-links {
    display: flex;
    gap: 1.5rem;
    list-style: none;
}

.nav-links a {
    color: var(--tan);
    text-decoration: none;
    font-family: var(--heading-font);
    font-size: 1.1rem;
    text-transform: uppercase;
    padding: 0.5rem 0;
    position: relative;
    transition: color 0.3s ease;
}

.nav-links a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 2px;
    background-color: var(--rust);
    transition: width 0.3s ease-in-out;
}

.nav-links a:hover::after {
    width: 100%;
}

.nav-links a:hover {
    color: var(--rust);
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--tan);
    font-size: 1.8rem;
    cursor: pointer;
    transition: color 0.3s ease;
}

/* Hero Section (SHOWCASE/HIGHLIGHTS) */
.hero {
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background-image: url('images/image_17.jpg'), url('images/image_18.png'); /* Grunge texture over main image */
    background-size: cover, auto;
    background-position: center center;
    background-attachment: fixed;
    position: relative;
    padding: 10rem 2rem; /* Ensure space for content */
}

.hero-image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(var(--charcoal-rgb), 0.7); /* Dark overlay */
    background-image: url('images/image_19.png'); /* Another texture layer */
    background-blend-mode: multiply;
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    margin: 0 auto;
    filter: drop-shadow(4px 4px 8px rgba(0,0,0,0.8));
}

.hero-content h1 {
    color: var(--rust);
    text-shadow: 3px 3px 6px rgba(0,0,0,0.9);
}

.hero-content p {
    font-size: 1.15rem;
    margin-bottom: 1.5rem;
    color: var(--light-tan);
}

/* Mission Section (TWO COLUMN) */
.mission-section {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 3rem;
    max-width: var(--max-width);
    margin: 2rem auto;
    padding: var(--content-padding);
}

.mission-content {
    flex: 2;
    min-width: 300px;
}

.mission-images {
    flex: 1;
    min-width: 280px;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.mission-images img {
    width: 100%;
    height: auto;
    object-fit: cover;
    border: var(--border-style);
    filter: grayscale(80%) brightness(80%);
    transition: all 0.3s ease-in-out;
}

.mission-images img:hover {
    filter: grayscale(0%) brightness(100%);
    transform: scale(1.03);
    box-shadow: 0 0 20px rgba(var(--rust-rgb), 0.5);
}

/* Service Section (FEATURE HIGHLIGHTS - 3 cards per row) */
.services-section {
    text-align: center;
    max-width: var(--max-width);
    margin: 2rem auto;
}

.service-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2.5rem;
    padding: 2rem 0;
    justify-content: center;
}

.service-card {
    background-color: var(--charcoal);
    padding: 2rem;
    border: var(--border-style);
    text-align: center;
    position: relative;
    overflow: hidden;
    filter: drop-shadow(5px 5px 10px rgba(0,0,0,0.5));
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.service-card::before {
    content: '';
    position: absolute;
    top: -10%;
    left: -10%;
    width: 120%;
    height: 120%;
    background: url('images/image_20.png');
    opacity: 1;.1;
    mix-blend-mode: overlay;
    pointer-events: none;
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.6);
}

.service-card img {
    max-width: 100%;
    height: 200px;
    object-fit: cover;
    margin-bottom: 1.5rem;
    border: 1px solid var(--moss-green);
    filter: brightness(85%) saturate(70%);
    transition: filter 0.3s ease;
}

.service-card:hover img {
    filter: brightness(100%) saturate(100%);
}

.service-card h4 {
    color: var(--moss-green);
    font-family: var(--heading-font);
    margin-bottom: 1rem;
}

.service-card p {
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
    flex-grow: 1; /* Ensures cards are equal height if text varies */
}

/* Solutions Section (COMPARISON TABLE) */
.solutions-section {
    max-width: var(--max-width);
    margin: 2rem auto;
    text-align: center;
}

.comparison-table-container {
    overflow-x: auto;
    margin-top: 2rem;
    border: var(--border-style);
    filter: drop-shadow(5px 5px 10px rgba(0,0,0,0.5));
}

.comparison-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 600px; /* Ensure table is wide enough for content */
}

.comparison-table th, .comparison-table td {
    border: 1px solid rgba(var(--rust-rgb), 0.3);
    padding: 1rem;
    text-align: left;
    font-size: 0.9rem;
}

.comparison-table th {
    background-color: rgba(var(--moss-green-rgb), 0.2);
    color: var(--moss-green);
    font-family: var(--heading-font);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 1rem;
}

.comparison-table td {
    background-color: rgba(var(--charcoal-rgb), 0.5);
    color: var(--light-tan);
}

.comparison-table tbody tr:nth-child(odd) td {
    background-color: rgba(var(--charcoal-rgb), 0.3);
}

.comparison-table tbody tr:hover td {
    background-color: rgba(var(--rust-rgb), 0.2);
    cursor: default;
}

/* Clients Section (CAROUSEL SLIDER) */
.clients-section {
    text-align: center;
    max-width: var(--max-width);
    margin: 2rem auto;
}

.carousel-container {
    position: relative;
    max-width: 900px; /* Adjust for single testimonial card width */
    margin: 2rem auto;
    overflow: hidden;
    padding: 1rem;
    border: var(--border-style);
    background-color: rgba(var(--charcoal-rgb), 0.7);
    filter: drop-shadow(5px 5px 10px rgba(0,0,0,0.5));
}

.carousel-track {
    display: flex;
    transition: transform 0.5s ease-in-out;
}

.testimonial-card {
    min-width: 100%; /* Each card takes full width of container */
    padding: 2.5rem 3rem;
    text-align: center;
    font-style: italic;
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--light-tan);
    background-color: rgba(var(--charcoal-rgb), 0.8);
    border: 1px dashed var(--tan);
    margin: 0 1rem; /* Space between cards, adjusted for min-width */
    box-shadow: inset 0 0 10px rgba(0,0,0,0.5), 0 0 15px rgba(0,0,0,0.3);
}

.testimonial-card cite {
    display: block;
    margin-top: 1.5rem;
    font-style: normal;
    font-weight: bold;
    color: var(--rust);
    font-family: var(--heading-font);
    font-size: 1.2rem;
    text-transform: uppercase;
}

.carousel-button {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(var(--rust-rgb), 0.7);
    border: 1px solid var(--tan);
    color: var(--tan);
    padding: 0.8rem 1.2rem;
    cursor: pointer;
    font-size: 1.5rem;
    line-height: 1;
    z-index: 10;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.carousel-button:hover {
    background-color: var(--moss-green);
    color: var(--light-tan);
}

.carousel-button.prev {
    left: 10px;
}

.carousel-button.next {
    right: 10px;
}

.carousel-nav-dots {
    display: flex;
    justify-content: center;
    margin-top: 1.5rem;
    gap: 0.5rem;
}

.dot {
    width: 10px;
    height: 10px;
    background-color: rgba(var(--tan-rgb), 0.5);
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
    border: 1px solid var(--rust);
}

.dot.active {
    background-color: var(--rust);
    transform: scale(1.2);
}

/* Team Section (CIRCULAR PHOTOS - 3 cards per row) */
.team-section {
    text-align: center;
    max-width: var(--max-width);
    margin: 2rem auto;
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2.5rem;
    padding: 2rem 0;
    justify-content: center;
}

.team-member {
    background-color: var(--charcoal);
    padding: 2rem;
    border: var(--border-style);
    text-align: center;
    filter: drop-shadow(5px 5px 10px rgba(0,0,0,0.5));
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.team-member:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.6);
}

.team-member img {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    object-fit: cover;
    border: 5px solid var(--moss-green);
    margin-bottom: 1.5rem;
    filter: grayscale(70%) contrast(1.1);
    transition: filter 0.3s ease, border-color 0.3s ease;
}

.team-member:hover img {
    filter: grayscale(0%) contrast(1);
    border-color: var(--rust);
}

.team-member h4 {
    color: var(--light-tan);
    font-family: var(--heading-font);
    margin-bottom: 0.5rem;
}

.team-member .role {
    font-family: var(--accent-font);
    color: var(--rust);
    font-size: 1rem;
    margin-bottom: 1rem;
    text-transform: uppercase;
}

.team-member p {
    font-size: 0.9rem;
}

/* Gallery Section (SLIDESHOW) */
.gallery-section {
    text-align: center;
    max-width: var(--max-width);
    margin: 2rem auto;
}

.slideshow-container {
    position: relative;
    max-width: 900px;
    margin: 2rem auto;
    overflow: hidden;
    border: var(--border-style);
    background-color: rgba(var(--charcoal-rgb), 0.7);
    filter: drop-shadow(5px 5px 10px rgba(0,0,0,0.5));
}

.slideshow-slide {
    display: none; /* Hidden by default */
    position: relative;
}

.slideshow-slide img {
    width: 100%;
    height: 500px; /* Fixed height for consistency */
    object-fit: cover;
    display: block;
}

.slide-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: rgba(var(--rust-rgb), 0.8);
    color: var(--light-tan);
    padding: 1rem;
    font-family: var(--accent-font);
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.slideshow-button {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(var(--moss-green-rgb), 0.7);
    border: 1px solid var(--tan);
    color: var(--tan);
    padding: 0.8rem 1.2rem;
    cursor: pointer;
    font-size: 1.5rem;
    line-height: 1;
    z-index: 10;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.slideshow-button:hover {
    background-color: var(--rust);
    color: var(--light-tan);
}

.slideshow-button.prev {
    left: 10px;
}

.slideshow-button.next {
    right: 10px;
}

.slideshow-dots {
    display: flex;
    justify-content: center;
    margin-top: 1.5rem;
    gap: 0.5rem;
}

.slideshow-dot {
    width: 10px;
    height: 10px;
    background-color: rgba(var(--tan-rgb), 0.5);
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
    border: 1px solid var(--moss-green);
}

.slideshow-dot.active {
    background-color: var(--moss-green);
    transform: scale(1.2);
}

/* Newsletter Section (INLINE FORM - adapted) */
.newsletter-section {
    text-align: center;
    max-width: 800px;
    margin: 2rem auto;
    padding: var(--content-padding);
    background-color: rgba(var(--moss-green-rgb), 0.2);
    border: var(--border-style);
    box-shadow: inset 0 0 10px rgba(0,0,0,0.5);
}

.newsletter-content h3 {
    color: var(--rust);
    margin-bottom: 1rem;
}

.newsletter-content p {
    font-size: 1.05rem;
    margin-bottom: 1.5rem;
}

/* FAQ Section (INTERACTIVE CHAT - adapted to accordion) */
.faq-section {
    max-width: 900px;
    margin: 2rem auto;
    padding: var(--content-padding);
    background-color: rgba(var(--charcoal-rgb), 0.8);
    border: var(--border-style);
    filter: drop-shadow(5px 5px 10px rgba(0,0,0,0.5));
}

.chat-header {
    text-align: center;
    color: var(--moss-green);
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 1rem;
}

.faq-section h3 {
    text-align: center;
    margin-bottom: 2rem;
    color: var(--light-tan);
}

.chat-container {
    max-width: 700px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.chat-message {
    padding: 1rem 1.5rem;
    border-radius: 1.5rem;
    box-shadow: 2px 2px 5px rgba(0,0,0,0.5);
    position: relative;
    max-width: 85%;
    font-size: 1rem;
    line-height: 1.5;
    transition: background-color 0.3s ease, transform 0.2s ease;
    cursor: pointer; /* Makes user message feel clickable */
}

.chat-message span {
    display: block;
    font-size: 0.75rem;
    color: rgba(var(--text-color-rgb), 0.7);
    margin-top: 0.5rem;
    font-family: 'Courier New', monospace;
}

.bot-message {
    background-color: rgba(var(--moss-green-rgb), 0.2);
    align-self: flex-start;
    border-top-left-radius: 0;
    border: 1px solid var(--moss-green);
}

.user-message {
    background-color: rgba(var(--rust-rgb), 0.2);
    align-self: flex-end;
    border-top-right-radius: 0;
    border: 1px solid var(--rust);
    text-align: right;
    cursor: pointer;
}

.user-message:hover {
    transform: translateY(-3px);
    background-color: rgba(var(--rust-rgb), 0.3);
}

.faq-answer {
    padding: 1rem 1.5rem;
    border-radius: 1.5rem;
    box-shadow: 2px 2px 5px rgba(0,0,0,0.5);
    position: relative;
    max-width: 85%;
    font-size: 1rem;
    line-height: 1.5;
    transition: all 0.3s ease-out; /* For smooth show/hide */
    overflow: hidden;
    background-color: rgba(var(--moss-green-rgb), 0.2);
    align-self: flex-start;
    border-top-left-radius: 0;
    border: 1px solid var(--moss-green);
}

.faq-item {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.faq-item .faq-question {
    width: fit-content; /* Make button fit content */
    align-self: flex-end; /* Align user questions to right */
    border: 1px solid var(--rust); /* Add border to user message */
}

.faq-item .faq-answer {
    width: fit-content; /* Make answer fit content */
    align-self: flex-start; /* Align bot answers to left */
    border: 1px solid var(--moss-green); /* Add border to bot message */
    margin-left: 0; /* Override default button margin */
}

/* Support Section (SIDE BY SIDE) */
.support-section {
    display: flex;
    flex-wrap: wrap;
    gap: 3rem;
    align-items: center;
    max-width: var(--max-width);
    margin: 2rem auto;
    padding: var(--content-padding);
}

.support-content {
    flex: 1;
    min-width: 300px;
    color: var(--light-tan);
}

.support-content h2 {
    text-align: left;
    color: var(--moss-green);
    border-bottom: var(--border-style);
    padding-bottom: 0.5rem;
    margin-bottom: 1.5rem;
}

.support-content h3 {
    color: var(--tan);
    margin-top: 1.5rem;
    margin-bottom: 1rem;
}

.support-visual {
    flex: 1;
    min-width: 300px;
    text-align: center;
}

.support-visual img {
    max-width: 100%;
    height: auto;
    object-fit: cover;
    border: var(--border-style);
    filter: sepia(50%) brightness(80%) saturate(120%);
    transition: filter 0.3s ease;
}

.support-visual img:hover {
    filter: sepia(0%) brightness(100%) saturate(100%);
}

.visual-caption {
    font-family: var(--accent-font);
    font-size: 0.9rem;
    color: var(--rust);
    margin-top: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Footer */
footer {
    text-align: center;
    padding: 2rem;
    border-top: var(--border-style);
    color: var(--tan);
    font-size: 0.9rem;
    background-color: var(--charcoal);
    background-image: url('images/image_14.png');
}

footer p {
    margin-bottom: 0.5rem;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .nav-links {
        gap: 1rem;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
        flex-direction: column;
        width: 100%;
        background-color: var(--charcoal);
        position: absolute;
        top: 100%;
        left: 0;
        padding: 1rem 0;
        border-top: var(--border-style);
    }

    .nav-links.active {
        display: flex;
    }

    .nav-links li {
        text-align: center;
        margin: 0.5rem 0;
    }

    .menu-toggle {
        display: block;
    }

    .mission-section,
    .support-section {
        flex-direction: column;
    }

    .mission-images {
        flex-direction: row;
        gap: 1rem;
    }

    .mission-images img {
        width: calc(50% - 0.5rem);
    }

    .hero-content h1 {
        font-size: clamp(2rem, 8vw, 4rem);
    }

    .carousel-button {
        padding: 0.6rem 1rem;
        font-size: 1.2rem;
    }

    .slideshow-slide img {
        height: 350px;
    }

    .chat-message {
        max-width: 95%;
        padding: 0.8rem 1rem;
    }
    .chat-message p {
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    body {
        font-size: 14px;
    }

    h1 {
        font-size: clamp(2rem, 9vw, 3.5rem);
    }

    h2 {
        font-size: clamp(1.8rem, 8vw, 3rem);
    }

    .logo {
        font-size: 1.5rem;
    }

    .button {
        padding: 0.6rem 1.2rem;
        font-size: 0.9rem;
    }

    .mission-images {
        flex-direction: column;
        gap: 1.5rem;
    }
    .mission-images img {
        width: 100%;
    }

    .service-grid, .team-grid {
        grid-template-columns: 1fr;
    }

    .slideshow-slide img {
        height: 250px;
    }

    .comparison-table th, .comparison-table td {
        padding: 0.8rem;
        font-size: 0.8rem;
    }
    .comparison-table th {
        font-size: 0.9rem;
    }
}

/* Helper for RGBA color calculations */
/* Convert hex to rgb for rgba usage (requires JS or pre-processor in real project) */
/* For this context, I'll just manually define */
/* --charcoal-rgb: 41, 41, 41; */
/* --rust-rgb: 166, 61, 47; */
/* --moss-green-rgb: 89, 109, 86; */
/* --tan-rgb: 217, 200, 167; */
/* --light-tan-rgb: 237, 224, 199; */
/* Visible state helpers */
+ .animate-fade-in-up.visible,
+ .animate-fade-in-left.visible,
+ .animate-fade-in-right.visible,
+ .animate-bounce-y.visible,
+ .section-scroll-animate.visible,
+ .text-animate-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Universal Icon Fixes for Buttons */
button svg, .carousel-next svg, .carousel-prev svg, .slider-next svg, .slider-prev svg,
.next svg, .prev svg, .tab-button svg, .tab-btn svg {
    display: inline-block;
    vertical-align: middle;
    pointer-events: none;
    width: 1em;
    height: 1em;
    fill: currentColor;
}

button i, .carousel-next i, .carousel-prev i, .slider-next i, .slider-prev i,
.next i, .prev i, .tab-button i, .tab-btn i {
    display: inline-block;
    vertical-align: middle;
    pointer-events: none;
    font-style: normal;
}

button .icon, .carousel-next .icon, .carousel-prev .icon,
.slider-next .icon, .slider-prev .icon, .tab-button .icon {
    display: inline-block;
    vertical-align: middle;
    pointer-events: none;
}

/* Ensure carousel buttons are clickable even with icons */
.carousel-next, .carousel-prev, .slider-next, .slider-prev,
.next, .prev, .next-btn, .prev-btn {
    cursor: pointer;
    position: relative;
}

.carousel-next *, .carousel-prev *, .slider-next *, .slider-prev *,
.next *, .prev *, .next-btn *, .prev-btn * {
    pointer-events: none;
}

/* Tab button icon fixes */
.tab-button, .tab-btn, .tab {
    cursor: pointer;
    position: relative;
}

.tab-button *, .tab-btn *, .tab * {
    pointer-events: none;
}

/* Ensure icons don't block clicks */
button > svg, button > i, button > .icon,
.carousel-next > svg, .carousel-prev > svg,
.tab-button > svg, .tab-button > i {
    pointer-events: none !important;
}

/* Enhanced: Team grid stabilization */
+ .team-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
+ @media (max-width: 900px) { .team-grid { grid-template-columns: repeat(2, 1fr); } }
+ @media (max-width: 600px) { .team-grid { grid-template-columns: 1fr; } }

/* Safe visibility overrides (auto-added) */
:root, html, body, main, header, footer, section, .container, .content {
  opacity: 1 !important;
  visibility: visible !important;
}

/* Accessibility focus outlines */
:focus{outline:2px solid #5ac8fa;outline-offset:2px;}
:focus:not(:focus-visible){outline:none;}
