/*------------------------------------------------------------------
[Table of Contents]

1. CSS Variables
2. Global Styles
    - Typography
    - Links
    - Buttons (Global)
    - Utility Classes
3. Layout (Complementing Bulma)
4. Header / Navigation
5. Hero Section
6. General Section Styling
7. Card Styling (Global & Specific)
    - Generic Card
    - Instructor Card
    - Portfolio Card
    - Case Study Card
    - Gallery Card
    - Resource Card
    - Event Item
8. Instructors Section
9. Portfolio Section
10. Case Studies Section
11. Events Section
12. Gallery Section
13. External Resources Section
14. Contact Section
    - Form Styling
    - Contact Info
15. Footer
16. Specific Page Styles
    - Success Page
    - Privacy/Terms Page Content
17. Animations & Transitions
18. Responsive Adjustments
-------------------------------------------------------------------*/

/* 1. CSS Variables */
:root {
    /* Triadic Color Scheme + Accents */
    --color-primary: #2E86C1; /* Professional Blue */
    --color-primary-darker: #21618C;
    --color-secondary: #2ECC71; /* Vibrant Green */
    --color-secondary-darker: #239B56;
    --color-tertiary: #E67E22; /* Warm Orange */
    --color-tertiary-darker: #AF601A;

    --color-accent: #F1C40F; /* Bright Yellow */
    --color-accent-darker: #B7950B;

    /* Text Colors */
    --text-color-dark: #2c3e50; /* Dark Slate Blue - for high contrast on light bg */
    --text-color-light: #ffffff; /* White */
    --text-color-muted: #7f8c8d; /* Medium Gray */
    --text-color-headings: #1f2937; /* Very Dark Gray for headings */

    /* Background Colors */
    --bg-light: #f8f9fa; /* Very Light Gray */
    --bg-dark: #212529; /* Dark Gray/Black */
    --bg-section-light-alt: #eef2f7; /* Slightly off-white/light blue for alternate sections */
    --bg-footer: var(--text-color-dark);

    /* Fonts */
    --font-heading: 'Oswald', sans-serif;
    --font-body: 'Nunito', sans-serif;

    /* Borders & Shadows */
    --border-radius-small: 4px;
    --border-radius-medium: 8px;
    --border-radius-large: 12px;
    --box-shadow-light: 0 2px 8px rgba(0, 0, 0, 0.06);
    --box-shadow-medium: 0 5px 15px rgba(0, 0, 0, 0.1);
    --box-shadow-heavy: 0 10px 25px rgba(0, 0, 0, 0.15);
    --text-shadow-subtle: 1px 1px 3px rgba(0,0,0,0.3);

    /* Transitions */
    --transition-fast: 0.2s ease-in-out;
    --transition-medium: 0.3s ease-in-out;

    /* Spacing */
    --navbar-height: 60px; /* Approximate, adjust as needed */
    --section-padding-vertical: 4rem;
    --section-padding-horizontal: 1.5rem;
}

/* 2. Global Styles */
html {
    scroll-behavior: smooth;
    font-size: 16px; /* Base font size */
}

body {
    font-family: var(--font-body);
    color: var(--text-color-dark);
    line-height: 1.7;
    background-color: var(--bg-light);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden; /* Prevent horizontal scroll from AOS */
}

/* Typography */
h1, h2, h3, h4, h5, h6,
.title, .subtitle { /* Bulma classes */
    font-family: var(--font-heading);
    color: var(--text-color-headings);
    font-weight: 700; /* Oswald often looks better bolder */
    line-height: 1.3;
}

.title.is-1 { font-size: 3rem; margin-bottom: 1.5rem; }
.title.is-2, .section-title { font-size: 2.5rem; margin-bottom: 1.25rem; color: var(--text-color-headings); text-align: center; }
.title.is-3 { font-size: 2rem; margin-bottom: 1rem; }
.title.is-4 { font-size: 1.5rem; margin-bottom: 0.75rem; }
.subtitle { color: var(--text-color-muted); font-weight: 400; font-family: var(--font-body); }
.subtitle.is-4 { font-size: 1.25rem; }
.subtitle.is-5 { font-size: 1.1rem; }


p {
    margin-bottom: 1.25rem;
    color: var(--text-color-dark);
}

strong {
    font-weight: 700;
    color: var(--text-color-headings);
}

/* Links */
a {
    color: var(--color-primary);
    text-decoration: none;
    transition: color var(--transition-fast);
}
a:hover {
    color: var(--color-primary-darker);
    text-decoration: underline;
}

.read-more-link {
    display: inline-block;
    font-weight: bold;
    color: var(--color-secondary);
    text-decoration: none;
    padding-bottom: 2px;
    border-bottom: 2px solid transparent;
    transition: color var(--transition-fast), border-color var(--transition-fast);
}
.read-more-link:hover {
    color: var(--color-secondary-darker);
    border-bottom-color: var(--color-secondary-darker);
    text-decoration: none;
}
.read-more-link::after {
    content: ' →'; /* Optional arrow */
}

/* Buttons (Global) */
.button, button, input[type="submit"], input[type="button"] {
    font-family: var(--font-heading);
    font-weight: bold;
    border-radius: var(--border-radius-medium);
    padding: 0.75em 1.5em;
    transition: background-color var(--transition-medium), color var(--transition-medium), transform var(--transition-fast), box-shadow var(--transition-medium);
    cursor: pointer;
    border: 1px solid transparent;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 0.9rem;
}
.button:hover, button:hover, input[type="submit"]:hover, input[type="button"]:hover {
    transform: translateY(-2px);
    box-shadow: var(--box-shadow-medium);
}
.button:active, button:active, input[type="submit"]:active, input[type="button"]:active {
    transform: translateY(0px);
    box-shadow: var(--box-shadow-light);
}

/* Bulma button overrides for consistency if needed */
.button.is-primary {
    background-color: var(--color-primary);
    border-color: var(--color-primary);
    color: var(--text-color-light);
}
.button.is-primary:hover {
    background-color: var(--color-primary-darker);
    border-color: var(--color-primary-darker);
    color: var(--text-color-light);
}

.button.is-secondary, .button.is-link { /* Using is-link as secondary for this example */
    background-color: var(--color-secondary);
    border-color: var(--color-secondary);
    color: var(--text-color-light);
}
.button.is-secondary:hover, .button.is-link:hover {
    background-color: var(--color-secondary-darker);
    border-color: var(--color-secondary-darker);
    color: var(--text-color-light);
}

.button.is-tertiary {
    background-color: var(--color-tertiary);
    border-color: var(--color-tertiary);
    color: var(--text-color-light);
}
.button.is-tertiary:hover {
    background-color: var(--color-tertiary-darker);
    border-color: var(--color-tertiary-darker);
    color: var(--text-color-light);
}


.button.is-outlined.is-primary {
    background-color: transparent;
    border-color: var(--color-primary);
    color: var(--color-primary);
}
.button.is-outlined.is-primary:hover {
    background-color: var(--color-primary);
    color: var(--text-color-light);
}

.button.is-outlined.is-secondary, .button.is-link.is-outlined {
    background-color: transparent;
    border-color: var(--color-secondary);
    color: var(--color-secondary);
}
.button.is-outlined.is-secondary:hover, .button.is-link.is-outlined:hover {
    background-color: var(--color-secondary);
    color: var(--text-color-light);
}


/* Utility Classes */
.text-center { text-align: center; }
.margin-bottom-md { margin-bottom: 2rem; }
.full-width-image {
    width: 100%;
    height: auto;
    object-fit: cover;
}
.content-padding-top {
    padding-top: calc(var(--navbar-height) + 2rem); /* For content below fixed navbar */
}

/* 3. Layout (Complementing Bulma) */
.container {
    max-width: 1140px; /* Common container width */
    margin-left: auto;
    margin-right: auto;
    padding-left: var(--section-padding-horizontal);
    padding-right: var(--section-padding-horizontal);
}

/* 4. Header / Navigation */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background-color: rgba(255, 255, 255, 0.85); /* Slight glassmorphism */
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: background-color var(--transition-medium);
}
.header .navbar {
    background-color: transparent; /* Bulma navbar within header */
    min-height: var(--navbar-height);
}
.header .navbar-brand .navbar-item img {
    max-height: calc(var(--navbar-height) - 20px);
}
.site-title { /* Custom class from HTML */
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--color-primary);
}
.navbar-item {
    font-family: var(--font-body);
    font-weight: 600;
    color: var(--text-color-dark);
    transition: color var(--transition-fast), background-color var(--transition-fast);
}
.navbar-item:hover, .navbar-item.is-active {
    color: var(--color-primary) !important; /* Bulma override */
    background-color: rgba(0,0,0,0.03) !important; /* Subtle hover */
}
.navbar-burger span {
    background-color: var(--text-color-dark);
    height: 2px;
}

/* 5. Hero Section */
#hero {
    color: var(--text-color-light);
    position: relative; /* For overlay */
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}
.hero.has-background-parallax {
    background-attachment: fixed; /* Parallax effect */
}
.hero-background-overlay { /* Separate div for overlay in HTML */
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(0,0,0,0.55), rgba(0,0,0,0.55));
    z-index: 1;
}
#hero .hero-body { /* Bulma class */
    position: relative;
    z-index: 2;
    width: 100%;
    padding: var(--section-padding-vertical) var(--section-padding-horizontal);
}
#hero .hero-title {
    color: var(--text-color-light) !important;
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    text-shadow: var(--text-shadow-subtle);
}
#hero .hero-subtitle {
    color: var(--text-color-light) !important;
    opacity: 0.9;
    font-size: 1.4rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 2.5rem;
    text-shadow: var(--text-shadow-subtle);
}
#hero .button {
    padding: 0.8em 2em;
    font-size: 1.1rem;
}

/* 6. General Section Styling */
.section {
    padding-top: var(--section-padding-vertical);
    padding-bottom: var(--section-padding-vertical);
}
.section .subtitle.is-5 { /* Subtitle often used below section title */
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 3rem;
}
.has-background-light-triad {
    background-color: var(--bg-section-light-alt);
}

/* 7. Card Styling (Global & Specific) */
/* Generic Card */
.card {
    background-color: var(--card-bg, #ffffff);
    border-radius: var(--border-radius-large);
    box-shadow: var(--box-shadow-medium);
    overflow: hidden;
    transition: transform var(--transition-medium), box-shadow var(--transition-medium);
    height: 100%; /* For equal height cards in Bulma columns */
    display: flex;
    flex-direction: column;
}
.card:hover {
    transform: translateY(-8px);
    box-shadow: var(--box-shadow-heavy);
}

.card .card-image { /* Bulma's card-image */
    position: relative;
    overflow: hidden; /* Ensures image corners match card radius if image is top */
    /* Centering logic for image container */
    display: flex;
    flex-direction: column;
    align-items: center; /* Horizontal centering */
    justify-content: center; /* Vertical centering if needed, but usually not for top image */
}
.card .card-image.image-container { /* custom class for image containers inside card */
    height: 220px; /* Fixed height for image containers */
    width: 100%;
}
.card .card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Ensures image covers the container without distortion */
    transition: transform 0.4s ease;
}
.card:hover .card-image img {
    transform: scale(1.05);
}
.card .card-content {
    padding: 1.75rem;
    flex-grow: 1; /* Allows content to take remaining space */
    display: flex;
    flex-direction: column;
    text-align: center; /* Center text content */
}
.card .card-content .title {
    margin-bottom: 0.75rem;
    color: var(--text-color-headings);
}
.card .card-content .subtitle {
    color: var(--text-color-muted);
    margin-bottom: 1rem;
    flex-grow: 1; /* Pushes button to bottom if present */
}
.card .card-content .button {
    margin-top: auto; /* Pushes button to the bottom of card-content */
    align-self: center;
}

/* Instructor Card */
.instructor-card .card-image.image-container {
    height: 300px; /* Taller for profile pics */
}
.instructor-card .card-content .title.is-4 {
    color: var(--color-primary);
}

/* Portfolio Card, Case Study Card */
.portfolio-card .card-image.image-container,
.case-study-card .card-image.image-container {
    height: 250px;
}
.case-study-card .card-content {
    text-align: left; /* Case studies often have more text */
}
.case-study-card .card-content strong {
    color: var(--color-secondary);
}

/* Gallery Card */
.gallery-card .card-image.image-container {
    height: 280px;
}
.gallery-card {
    box-shadow: none; /* Simpler look for gallery items */
    border: 1px solid #eee;
}
.gallery-card:hover {
    box-shadow: var(--box-shadow-medium);
    transform: translateY(-5px);
}

/* Resource Card */
.resource-card {
    background-color: var(--bg-section-light-alt);
    box-shadow: var(--box-shadow-light);
}
.resource-card:hover {
    box-shadow: var(--box-shadow-medium);
}
.resource-card .card-content .title.is-5 a {
    color: var(--color-tertiary);
}
.resource-card .card-content .title.is-5 a:hover {
    color: var(--color-tertiary-darker);
}
.resource-card .card-content .subtitle.is-6 {
    font-size: 0.9rem;
    line-height: 1.5;
}

/* Event Item (uses .box from Bulma) */
.event-item {
    border-left: 5px solid var(--color-secondary);
    transition: box-shadow var(--transition-medium);
    margin-bottom: 1.5rem; /* Spacing between event items */
}
.event-item:hover {
    box-shadow: var(--box-shadow-medium);
}
.event-item figure.image {
    max-height: 180px;
    overflow: hidden;
    border-radius: var(--border-radius-small);
}
.event-item figure.image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.event-item .title.is-4 {
    color: var(--color-primary);
}
.event-item p strong.has-text-primary { /* Bulma class */
    color: var(--color-secondary) !important;
}

/* 14. Contact Section */
/* Form Styling */
#contactForm .label {
    font-family: var(--font-heading);
    color: var(--text-color-headings);
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 0.5em;
}
#contactForm .input,
#contactForm .textarea {
    font-family: var(--font-body);
    border-radius: var(--border-radius-medium);
    border: 1px solid #ccc; /* Lighter border */
    box-shadow: var(--box-shadow-light);
    padding: 0.8em 1em;
    transition: border-color var(--transition-medium), box-shadow var(--transition-medium);
}
#contactForm .input:focus,
#contactForm .textarea:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 0.125em rgba(46, 134, 193, 0.25); /* Primary color focus ring */
}
#contactForm .button.is-primary {
    width: 100%;
    padding: 0.9em 1.5em;
    font-size: 1rem;
}

/* Contact Info */
.contact-info-item {
    margin-bottom: 1rem;
    font-size: 1rem;
}
.contact-info-item strong {
    color: var(--text-color-headings);
    font-family: var(--font-heading);
}
.contact-info-item a {
    color: var(--color-secondary);
}
.contact-info-item a:hover {
    color: var(--color-secondary-darker);
}

/* 15. Footer */
.footer {
    background-color: var(--bg-footer);
    color: var(--text-color-light);
    padding: 4rem var(--section-padding-horizontal) 2rem;
}
.footer .title.is-5, .footer .footer-title { /* footer-title from HTML */
    color: var(--text-color-light) !important; /* Override Bulma's default if necessary */
    font-family: var(--font-heading);
    margin-bottom: 1.25rem;
}
.footer p, .footer li {
    color: rgba(255,255,255,0.75);
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
}
.footer a {
    color: rgba(255,255,255,0.85);
    transition: color var(--transition-fast);
}
.footer a:hover {
    color: var(--color-secondary); /* Accent hover for footer links */
    text-decoration: none;
}
.footer hr {
    background-color: rgba(255,255,255,0.15);
    height: 1px;
    margin: 2rem 0;
}
.footer .content.has-text-centered p {
    color: rgba(255,255,255,0.6);
    font-size: 0.9rem;
}
.footer .column ul {
    list-style: none;
    margin-left: 0;
}
.footer .column ul li a::before {
    /* Optional: add a subtle marker for list items */
    /* content: "› "; */
    /* margin-right: 0.3em; */
}

/* Footer Social Links (Text-based) */
#footer-social-links p { /* Assuming a container with this ID or class */
    margin-bottom: 0.5rem;
}
#footer-social-links a {
    display: inline-block; /* Better spacing and hover */
    padding: 0.2em 0;
}

/* 16. Specific Page Styles */
/* Success Page */
.success-page-container { /* Apply to main container or section on success.html */
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 2rem;
}
.success-page-container .success-icon {
    font-size: 5rem;
    color: var(--color-secondary);
    margin-bottom: 1.5rem;
}
.success-page-container .title.is-1 {
    color: var(--text-color-headings);
}
.success-page-container .subtitle.is-4 {
    color: var(--text-color-muted);
}

/* Privacy/Terms Page Content */
.privacy-content-area, .terms-content-area {
    padding-top: calc(var(--navbar-height) + 3rem); /* Ensure content is below fixed navbar */
    padding-bottom: 3rem;
}
.privacy-content-area .content h2, .terms-content-area .content h2,
.privacy-content-area .content h3, .terms-content-area .content h3 {
    font-family: var(--font-heading);
    color: var(--text-color-headings);
    margin-top: 2rem;
    margin-bottom: 1rem;
}
.privacy-content-area .content p, .terms-content-area .content p,
.privacy-content-area .content ul, .terms-content-area .content ul {
    font-family: var(--font-body);
    color: var(--text-color-dark);
    line-height: 1.8;
}
.privacy-content-area .content ul, .terms-content-area .content ul {
    margin-left: 1.5em;
    margin-bottom: 1em;
}

/* 17. Animations & Transitions (AOS is handled by JS, these are for hovers etc.) */
/* General interactive element hover */
.interactive-hover-effect {
    transition: transform var(--transition-medium), box-shadow var(--transition-medium);
}
.interactive-hover-effect:hover {
    transform: translateY(-3px);
    box-shadow: var(--box-shadow-medium);
}

/* 18. Responsive Adjustments */
@media screen and (max-width: 1023px) { /* Bulma's tablet breakpoint */
    .navbar-menu { /* For mobile menu */
        background-color: #ffffff;
        box-shadow: 0 8px 16px rgba(10,10,10,.1);
        border-top: 1px solid #f0f0f0;
        padding: 0.5rem 0;
    }
    .navbar-item {
        padding: 0.75rem 1rem;
    }
    #hero .hero-title {
        font-size: 2.8rem;
    }
    #hero .hero-subtitle {
        font-size: 1.2rem;
    }
    .section-title, .title.is-2 {
        font-size: 2rem;
    }
}

@media screen and (max-width: 768px) { /* Bulma's mobile breakpoint */
    html {
        font-size: 15px;
    }
    #hero .hero-title {
        font-size: 2.2rem;
    }
    #hero .hero-subtitle {
        font-size: 1.1rem;
    }
    .section-title, .title.is-2 {
        font-size: 1.8rem;
    }
    .title.is-3 { font-size: 1.6rem; }
    .title.is-4 { font-size: 1.3rem; }

    .footer {
        text-align: center;
    }
    .footer .columns {
        display: block; /* Stack columns */
    }
    .footer .column {
        margin-bottom: 2rem;
    }
    .footer .column:last-child {
        margin-bottom: 0;
    }
}

/* Cookie Consent Styles (from previous HTML, integrated here for completeness) */
#cookieConsentPopup {
    font-family: var(--font-body); /* Use theme font */
}
#cookieConsentPopup p a {
    color: var(--color-secondary); /* Use theme accent */
}
#cookieConsentPopup button#acceptCookieButton {
    background-color: var(--color-secondary); /* Use theme accent */
    font-family: var(--font-body); /* Consistent font */
    border-radius: var(--border-radius-small);
    padding: 8px 18px;
    font-size: 0.85em;
}
#cookieConsentPopup button#acceptCookieButton:hover {
    background-color: var(--color-secondary-darker);
}