/* --- NEW THEME: Lightbulb (Teal, Purple, Red, Yellow & White) --- */
:root {
    /* The Structural Colors (Cool & Deep) */
    --theme-teal: #00838F;    /* Rich, vibrant Teal for Nav, Footers, and Contact Section */
    --theme-purple: #5E35B1;  /* Deep Purple for dark sections and secondary buttons */

    /* The Action Colors (Warm & Bright) */
    --theme-yellow: #FFC107;  /* Bright yellow for primary buttons, focus rings, and accents */
    --theme-red: #E53935;     /* Energetic red for hover states, active states, and borders */

    /* The Canvas (White/Light for breathing room) */
    --bg-white: #FFFFFF;      /* Pure white for cards and high contrast */
    --bg-offwhite: #F4F7F6;   /* Very soft, cool grey-white for standard section backgrounds */
    
    /* Text Colors */
    --text-dark: #1A1A24;     /* Very dark purple-slate for reading text */
    --text-light: #FFFFFF;    /* White text on dark Teal/Purple backgrounds */
    
    --focus-ring: #FFC107;    /* Yellow focus ring for accessibility */
}

/* --- Global Styles & Accessibility --- */
html {
    scroll-behavior: smooth; 
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: var(--bg-offwhite); /* The canvas is off-white */
    color: var(--text-dark);
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.2s ease, transform 0.2s ease;
}

/* Accessibility: Keyboard Focus States */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible {
    outline: 3px solid var(--focus-ring);
    outline-offset: 3px;
}

/* Accessibility: Skip Link */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--theme-yellow);
    color: var(--text-dark);
    padding: 8px;
    z-index: 2000;
    transition: top 0.3s;
    font-weight: bold;
}

.skip-link:focus {
    top: 0;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: auto;
    text-align: center;
}

h2 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    color: var(--theme-purple); /* Headings anchored in Deep Purple */
}

/* Fix for headings inside dark structural sections */
.section-dark h2, 
.section-teal h2 {
    color: var(--text-light); /* Forces headings to be white so they don't vanish into the background */
}

/* --- Navigation and Logo Styling --- */
header {
    background-color: var(--theme-teal); /* Nav is structural Teal */
    color: var(--text-light);
    padding: 20px 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 4px solid var(--theme-yellow); /* Bright yellow accent line */
    box-shadow: 0 4px 6px rgba(0,0,0,0.15); 
}

.logo-link {
    display: flex;
    align-items: center;
    gap: 15px; /* Adds space between the lightbulb and the new text */
}

.logo-container {
    display: flex;
    align-items: center;
    justify-content: center;
}

.main-logo {
    height: 55px; 
    width: auto; 
    display: block; 
}

/* NEW: Business Title Text Styling */
.logo-text {
    color: var(--text-light);
    font-size: 1.1rem;
    line-height: 1.2;
    text-align: left;
}

.logo-text strong {
    color: var(--theme-yellow); /* Makes "Creative Solutions" pop against the teal header */
    font-size: 1.2rem;
    letter-spacing: 0.5px;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 20px;
    align-items: center;
}

nav ul li a {
    color: var(--text-light); 
    font-weight: 500;
}

nav ul li a:hover {
    color: var(--theme-yellow); /* Yellow hover */
}

.btn-login {
    background-color: var(--theme-purple); /* Login button pops in Purple against Teal */
    color: var(--text-light);
    padding: 8px 16px;
    border-radius: 4px;
    border: none;
}

.btn-login:hover {
    background-color: var(--theme-red); /* Surprising red hover for action */
    transform: translateY(-2px); 
}

/* --- Hero Section --- */
.hero {
    background-color: var(--theme-purple); 
    background-image: linear-gradient(rgba(0, 131, 143, 0.85), rgba(94, 53, 177, 0.90)), url("CSCC Logo.png");
    background-size: contain; 
    background-repeat: no-repeat;
    background-position: center;
    color: var(--text-light);
    min-height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 40px 20px;
}

.hero-content h1 {
    font-size: 3.5rem;
    margin-bottom: 20px;
    color: var(--theme-yellow); /* Title pops in Yellow */
    text-shadow: 0 2px 4px rgba(0,0,0,0.5); 
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    color: var(--text-light); 
    text-shadow: 0 1px 3px rgba(0,0,0,0.5); 
}

/* --- Buttons --- */
.btn-primary {
    background-color: var(--theme-yellow); /* Primary call to action is bright yellow */
    color: var(--text-dark); 
    padding: 12px 24px;
    border: none;
    border-radius: 4px;
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.3s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-primary:hover {
    background-color: var(--theme-red); /* Changes to vibrant red on hover */
    color: var(--text-light);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.btn-secondary {
    background-color: var(--theme-purple); /* Secondary buttons are purple */
    color: var(--text-light); 
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    margin-top: 15px;
    transition: background 0.3s ease, transform 0.2s ease;
    display: inline-block; 
    text-align: center;
    font-weight: 500;
}

.btn-secondary:hover {
    background-color: var(--theme-teal); /* Swaps to teal on hover */
    transform: translateY(-2px);
}

/* --- Sections & Dividers --- */
.section-light { 
    background-color: var(--bg-offwhite); /* Clean white canvas */
    padding: 80px 0; 
}
.section-dark { 
    background-color: var(--theme-purple); /* Purple structural section */
    color: var(--text-light); 
    padding: 80px 0; 
}
.section-teal { 
    background-color: var(--theme-teal); /* Teal structural section (Contact) */
    color: var(--text-light); 
    padding: 80px 0; 
}

.divider, .divider-yellow {
    width: 60px;
    height: 4px;
    margin: 0 auto 40px auto;
    border-radius: 2px;
}
.divider { background-color: var(--theme-red); } /* Red accent divider */
.divider-yellow { background-color: var(--theme-yellow); } /* Yellow accent divider */

/* --- Mission Section Text --- */
.mission-text {
    max-width: 800px;
    margin: 0 auto;
    text-align: left;
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text-dark); 
}

.mission-text p {
    margin-bottom: 20px;
}

.mission-text p:last-child {
    margin-bottom: 0;
}

/* --- Services Intro Text --- */
.services-intro {
    max-width: 800px;
    margin: 0 auto 40px auto;
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text-light); 
    text-align: left;
}

.services-intro p {
    margin-bottom: 15px;
}

/* --- Grid Layouts & Cards --- */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); 
    gap: 25px; 
    margin-top: 40px;
}

.course-single {
    max-width: 450px;
    margin: 40px auto 0 auto;
}

.card {
    background-color: var(--bg-white); 
    color: var(--text-dark); 
    padding: 25px; 
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    border-top: 4px solid var(--theme-teal); /* Cards anchored with Teal */
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0,0,0,0.1);
}

.section-dark .card {
    background-color: var(--bg-white); 
    color: var(--text-dark); 
    border-top: 4px solid var(--theme-red); /* Cards on dark backgrounds get Red accent */
}

.card h3 { 
    color: var(--theme-purple); 
    margin-bottom: 15px; 
    font-size: 1.3rem;
}
.section-dark .card h3 { 
    color: var(--theme-purple); 
}

/* --- Service Images --- */
.service-img {
    width: 100%;
    height: auto;
    aspect-ratio: 1 / 1; 
    object-fit: cover; 
    object-position: center;
    border-radius: 18%; 
    margin: 0 auto 20px auto;
    box-shadow: 0 6px 12px rgba(0,0,0,0.15); 
    display: block; 
}

/* --- About Leadership Section --- */
.about-intro {
    max-width: 700px;
    margin: 0 auto 40px auto;
    font-size: 1.1rem;
    color: var(--text-dark);
}

.leadership-grid {
    justify-content: center; 
    gap: 50px;
}

.team-card {
    background-color: var(--bg-white); 
    padding: 40px 20px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    border-top: 4px solid var(--theme-teal); 
    text-align: center;
    max-width: 350px;
    margin: 0 auto;
}

.portrait-btn {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    border-radius: 50%; 
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin-bottom: 20px;
}

.portrait-btn:hover {
    transform: scale(1.05);
}

.portrait-btn:focus-visible {
    outline: 4px solid var(--theme-yellow); 
    outline-offset: 4px;
}

.portrait-img {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--theme-purple); /* Purple borders on portraits */
}

.team-card h3 {
    color: var(--theme-teal); 
    margin-bottom: 5px;
    font-size: 1.5rem;
}

.team-card .title {
    color: var(--text-dark); 
    font-weight: 500;
}

/* --- Friendship Section --- */
.friendship-area {
    margin-top: 80px; 
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;
    background-color: var(--bg-white); 
    padding: 60px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05); 
}

.friendship-content {
    max-width: 800px;
    text-align: left; 
}

.friendship-content h3 {
    color: var(--theme-purple); 
    font-size: 2rem;
    margin-bottom: 5px;
}

.friendship-content p {
    margin-bottom: 20px;
    font-size: 1.1rem;
    color: var(--text-dark); 
    line-height: 1.8;
}

/* --- NEW: Friendship Gallery Perfect Grid Fix --- */
.friendship-gallery {
    display: flex !important;
    flex-wrap: wrap !important;
    justify-content: center !important;
    gap: 20px;
    margin-top: 30px;
}

.gallery-photo {
    flex: 1 1 calc(33.333% - 20px); 
    min-width: 150px; /* Allows them to shrink more on small screens */
    max-width: 250px; /* Shrunk down from 350px for a neater look */
    aspect-ratio: 1 / 1; /* NEW: Forces every photo into a perfect square */
    border-radius: 8px;
    object-fit: cover; /* Ensures the image fills the square without stretching */
    box-shadow: 0 4px 6px rgba(0,0,0,0.1); 
}

.gallery-photo:hover {
    transform: scale(1.03); 
    z-index: 2;
    position: relative;
    border-color: var(--theme-red); /* Hover changes border to Red */
}

/* --- Biography Modals --- */
.bio-modal {
    margin: auto;
    padding: 0;
    border: none;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.3);
    background-color: var(--bg-white); 
    max-width: 500px;
    width: 90%;
}

.bio-modal::backdrop {
    background-color: rgba(94, 53, 177, 0.85); /* Purple backdrop */
    backdrop-filter: blur(3px); 
}

.modal-content {
    padding: 40px;
    position: relative;
    color: var(--text-dark); 
    text-align: left;
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 20px;
    background: none;
    border: none;
    font-size: 2rem;
    color: var(--text-dark); 
    cursor: pointer;
    line-height: 1;
    transition: color 0.2s ease;
}

.close-modal:hover, .close-modal:focus-visible {
    color: var(--theme-red); /* Close button hovers Red */
}

.modal-name {
    font-size: 2rem;
    color: var(--theme-teal); 
    margin-bottom: 5px;
}

.modal-title {
    font-size: 1.1rem;
    color: var(--text-dark); 
    margin-bottom: 15px;
    font-weight: normal;
}

.modal-divider {
    margin: 0 0 20px 0; 
}

.modal-content p {
    margin-bottom: 20px;
}

.modal-content ul {
    list-style-position: inside;
    color: var(--theme-purple); 
    font-weight: 500;
}

.modal-content li {
    margin-bottom: 10px;
}

/* --- Forms --- */
.contact-form, .login-form {
    max-width: 600px;
    margin: 40px auto 0 auto;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.login-form { max-width: 400px; }

input, textarea {
    width: 100%;
    padding: 15px;
    border: 1px solid #CCC; 
    background-color: var(--bg-white);
    color: var(--text-dark);
    border-radius: 4px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

input:focus, textarea:focus {
    border-color: var(--theme-teal); 
    outline: none;
}

.section-dark input, .section-teal input, .section-teal textarea {
    background-color: var(--bg-white); 
    color: var(--text-dark);
    border-color: #CCC;
}

.forgot-password a {
    color: var(--theme-yellow); 
    font-size: 0.9rem;
}

.forgot-password a:hover {
    text-decoration: underline;
}

/* --- Footer --- */
footer {
    background-color: #004D54; /* Very dark teal for footer */
    color: var(--text-light); 
    text-align: center;
    padding: 20px 0;
    font-size: 0.9rem;
}

/* --- Mobile Responsiveness --- */
@media (max-width: 768px) {
    header {
        flex-direction: column;
        gap: 15px;
    }
    .logo-link {
        flex-direction: column;
        text-align: center;
    }
    nav ul {
        flex-wrap: wrap;
        justify-content: center;
    }
    .hero-content h1 {
        font-size: 2.5rem;
    }
    .friendship-area {
        padding: 40px 20px;
        gap: 30px;
    }
    .gallery-photo {
        height: 200px; 
    }
}

/* --- NEW: Shop Image Containers --- */
.product-image-container {
    background-color: var(--bg-offwhite);
    height: 250px;
    border-radius: 8px;
    margin-bottom: 20px;
    border: 2px dashed var(--theme-purple);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.product-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* --- NEW: Biography Modal Tab System --- */
.modal-tabs {
    display: flex;
    gap: 20px;
    margin-top: 15px;
    border-bottom: 2px solid #E0E0E0;
}

.tab-btn {
    background: none;
    border: none;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-muted);
    padding: 10px 5px;
    cursor: pointer;
    border-bottom: 3px solid transparent;
    transition: color 0.3s ease, border-color 0.3s ease;
    margin-bottom: -2px; /* Overlaps bottom border */
}

.tab-btn:hover {
    color: var(--theme-teal);
}

.tab-btn.active {
    color: var(--theme-purple);
    border-bottom-color: var(--theme-purple);
}

.tab-content {
    display: none;
    margin-top: 25px;
}

.tab-content.active-content {
    display: block;
    animation: fadeInTab 0.4s ease-in-out;
}

@keyframes fadeInTab {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* --- NEW: Footer Social Media Icons --- */
.social-footer-container {
    display: flex;
    justify-content: center;
    gap: 25px;
    margin-bottom: 20px;
}

.social-icon {
    color: var(--text-light); /* Blends with the footer text */
    opacity: 0.6; /* This creates the "transparent-ish" faded look */
    transition: opacity 0.3s ease, color 0.3s ease, transform 0.2s ease;
    display: inline-block;
}

.social-icon:hover {
    opacity: 1; /* Becomes fully solid on hover */
    color: var(--theme-yellow); /* Changes to your brand yellow */
    transform: translateY(-3px); /* Gives a tiny, satisfying 'pop' upward */
}

.social-icon svg {
    width: 28px;
    height: 28px;
    fill: currentColor; /* Forces the SVG to match the text color */
}