/* --- GOOGLE FONTS IMPORT --- */
@import url('https://fonts.googleapis.com/css2?family=Lexend:wght@300;400;600;800&display=swap');

/* --- THEME VARIABLES --- */
:root {
    --bg-color: #faf8f5;        /* Warm cream white */
    --text-color: #1e1e24;      /* Deep charcoal */
    --text-muted: #64748b;      /* Accessible secondary text */
    --header-bg: #3b2d54;       /* Signature deep purple */
    --header-text: #ffffff;
    --button-bg: #5b4d6e;       /* Muted purple gradient start */
    --button-hover: #9b7eb8;    /* Light purple gradient end */
    --frame-bg: #ffffff;
    --form-bg: rgba(30, 30, 36, 0.05);
    --form-border: rgba(30, 30, 36, 0.15);
    --shadow-color: rgba(91, 77, 110, 0.15);
}

[data-theme="dark"] {
    --bg-color: #202024;        /* Clean dark grey */
    --text-color: #f5f5f7;      /* Crisp off-white */
    --text-muted: #94a3b8;      /* Readable dark mode paragraph gray */
    --header-bg: #181424;       /* Extra dark eggplant purple */
    --header-text: #ffffff;
    --button-bg: #745f8f;       /* Brighter vibrant purple start */
    --button-hover: #b293d1;    /* Bright gradient end */
    --frame-bg: #2a2a30;
    --form-bg: rgba(255, 255, 255, 0.05);
    --form-border: rgba(255, 255, 255, 0.15);
    --shadow-color: rgba(0, 0, 0, 0.4);
}

/* --- GLOBAL LAYOUT RESETS --- */
* {
    box-sizing: border-box;
    -webkit-font-smoothing: antialiased;
}

html {
    scroll-behavior: smooth;
    /* Adds a protective top cushion so jumped content lands cleanly below the header */
    scroll-padding-top: 120px; 
}

body {
    margin: 0;
    font-family: 'Lexend', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.7;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    transition: background-color 0.3s ease, color 0.3s ease;
}

main {
    /* flex: 1; */
    width: 100%;
    margin: 0 auto;
    /* padding: 60px 20px; */
    text-align: center;
}

h1 {
    font-size: 2.5rem;
    font-weight: 650;
    margin-bottom: 20px;
    line-height: 1.4;
    background: linear-gradient(135deg, var(--button-bg), var(--button-hover));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

p {
    font-size: 1.0rem;
    color: var(--text-muted);
    margin-bottom: 10px;
}

/* --- HEADER & NAVIGATION --- */
header {
    background-color: var(--header-bg);
    color: var(--header-text);
    padding: 5px 0;
    width: 100%;
    transition: background-color 0.3s ease;
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 5px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-nav {
    display: flex;
    align-items: center;
    gap: 15px;
}

.header-nav a {
	color: var(--header-text);
	text-decoration: none;
	font-weight: 500;
	font-size: .8rem;
}

/* Converts the toggle icon to grayscale and matches your logo's aesthetics */
#theme-toggle {
    filter: grayscale(100%);
    opacity: 0.75;
    transition: opacity 0.2s ease, filter 0.2s ease;
}

/* Restores a bit of pop when hovered */
#theme-toggle:hover {
    opacity: 1;
    filter: grayscale(50%); /* Subtle hint of color on hover, or keep 100% if preferred */
}

.header-nav a:hover {
	color: var(--button-hover);
}


.main-footer {
	background-color: var(--header-bg);
	color: var(--header-text);
	text-align: center;
	padding: 15px 0;
	margin-top: auto;
}

.main-footer a {
	color: var(--header-text);
	text-decoration: none;
	font-weight: 500;
}

.license-container a {
    color: var(--header-text);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    opacity: 0.8;
    transition: opacity 0.2s ease, color 0.2s ease;
}

.license-container a:hover {
    opacity: 1;
    color: var(--button-hover);
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: inherit;
}

.trades-logo {
    height: 40px;
    width: auto;
}

.company-name {
    font-size: 1.2rem;
    font-weight: 700;
}

/* --- INTERACTIVE COMPONENTS --- */
.cta-button {
    display: inline-block;
    width: fit-content;
    margin: 0 auto;
    text-align: center;
    padding: 5px 10px;
    color: #ffffff;
    border-radius: 3px;
    text-decoration: none;
    text-wrap: nowrap;
    font-weight: 500;
    cursor: pointer;
    font-family: inherit;
    appearance: none;
    background: linear-gradient(135deg, var(--button-bg), var(--button-hover));
    border: none;
    transition: filter 0.3s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.cta-button:hover {
    filter: brightness(1.15); 
    transform: translateY(-2px);
    box-shadow: 0 6px 15px var(--shadow-color);
}

/* --- SLIDESHOW SECTION --- */
.carousel-main {
    position: relative;
    width: 100vw;
    margin-left: calc(-50vw + 50%); 
    margin-right: calc(-50vw + 50%);
    overflow: hidden;
    padding: 40px 0;
}

.carousel-track {
    display: flex;
    gap: 40px;
    position: relative;
    transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    padding-left: 50%;
    transform: translateX(-250px);
    will-change: transform;
}

.carousel-frame {
    position: relative;
    flex: 0 0 500px; /* Fixed width for consistent scaling and spacing */
    background-color: var(--frame-bg);
    border: 4px solid var(--frame-bg);
    border-radius: 8px;
    box-shadow: 0 10px 30px var(--shadow-color);

    filter: blur(2px);
    opacity: 0.8;
    transition: transform 0.5s ease, filter 0.5s ease, opacity 0.5s ease, border-color 0.5s ease, box-shadow
}

.carousel-frame.active {
    filter: blur(0);
    opacity: 1;
    border-color: var(--button-bg);
    box-shadow: 0 15px 40px var(--shadow-color);
}

.carousel-frame img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: fill;
}

.carousel-frame::after {
    content: attr(data-label);
    position: absolute;
    top: 15px;
    left: 15px;
    background: rgba(0, 0, 0, 0.75);
    color: #ffffff;
    padding: 6px 14px;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    pointer-events: none;
}


.carousel-frame[data-label="After"] {
    border-color: #4caf50;
    box-shadow: 0 10px 30px rgba(76, 175, 80, 0.25);
}

.carousel-frame[data-label="Progress"]::after {
    display: none;
}

.carousel-frame[data-label="Progress"] {
    border-color: #6b7fa3;
    box-shadow: 0 10px 30px rgba(107, 127, 163, 0.25);
}

#progression-catalog-comment {
    max-width: 80vw;
    margin: 40px auto;
    text-align: left;
}

/* --- Controls Restyling --- */
.carousel-buttons {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 100%;
    display: flex;
    justify-content: space-between;
    padding: 0 40px;
    box-sizing: border-box;
    pointer-events: none;
    z-index: 10;
}

.carousel-buttons button {
    pointer-events: auto;
    background: rgba(30, 30, 36, 0.4); /* Dark translucent glass to pop over any background */
    backdrop-filter: blur(4px);
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s ease, transform 0.2s ease;
}

.carousel-buttons button:hover {
    background: rgba(30, 30, 36, 0.8);
}

.carousel-buttons button:active {
    transform: scale(0.95);
}

.carousel-buttons button:focus-visible {
    outline: 3px solid #007acc;
}

.left::before, .right::before {
    content: '';
    width: 15px;
    height: 15px;
    border-top: 4px solid #ffffff;
    border-right: 4px solid #ffffff;
    display: inline-block;
}

.left::before { transform: rotate(-135deg); margin-left: 6px; }
.right::before { transform: rotate(45deg); margin-right: 6px; }


/* --- ABOUT US SECTION --- */
#about {
    max-width: 80vw; /* Constrains block width so it stays neatly grouped in the viewport */
    margin: 40px auto; /* Auto margins center the entire section container horizontally */
    text-align: left; /* Forces all interior headlines, text, and text blocks to be left-aligned */
}

/* --- FAQ SECTION --- */
#FAQ {
    max-width: 80vw; /* Constrains block width so it stays neatly grouped in the viewport */
    margin: 40px auto; /* Auto margins center the entire section container horizontally */
    text-align: left; /* Forces all interior headlines, text, and text blocks to be left-aligned */
}

/* Force the wrapper section header to be left-aligned as well */
.faq-section h2 {
    text-align: left;
    margin-bottom: 10px;
}

.faq-subtitle {
    text-align: left; /* Overrides any inherited parent centering */
    margin-bottom: 30px;
    font-size: 1.1rem;
}

.faq-answer {
	text-align: left;
}

/* --- CONTACT FORM --- */
.contact-form {
    background-color: var(--form-bg);
    backdrop-filter: blur(5px);
    padding: 30px;
    border-radius: 12px;
    border: 1px solid var(--form-border);
    max-width: 500px;
    margin: 20px auto;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.contact-form input, 
.contact-form textarea {
    width: 100%;
    padding: 10px;
    margin-top: 5px;
    border-radius: 6px;
    border: 1px solid var(--form-border);
    background-color: var(--frame-bg);
    color: var(--text-color);
    box-sizing: border-box;
}

.contact-info a {
    color: var(--button-bg);
    text-decoration: none;
    font-weight: 400;
    font-size: 18px;
    text-transform: uppercase;
}

/* --- RESPONSIVE MEDIA QUERIES --- */
@media (max-width: 600px) {
    .header-content {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }

    .header-nav {
        width: 100%;
        justify-content: center;
        gap: 20px;
        flex-wrap: wrap;
    }

    .header-nav a {
        font-size: 0.8rem;
        padding: 2px 2px;
    }

    h1 {
        font-size: 2rem;
        margin-bottom: 15px;
    }

    .carousel-track {
        gap: 20px;                      /* Tighter gaps on mobile screens */
    }  

    .carousel-frame {
        flex: 0 0 280px;                /* Drop to 280px so it fits cleanly on phones without swallowing screen edges */
    }
}