/* =========================================================
   GLOBAL VARIABLES (COLORS, FONTS, ETC.)
========================================================= */

:root {
    --black: #000000;
    --white: #ffffff;
    --red: #C3352B;
    --teal: #2CA8A2;
    --gray-light: #f2f2f2;
    --gray-med: #999999;

    --font-sans: 'Inter', sans-serif;
    --font-serif: 'Merriweather', serif;

    --max-wide: 1200px;
    --max-narrow: 900px;
}

/* =========================================================
   GLOBAL ELEMENT STYLES
========================================================= */

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    font-family: var(--font-sans);
    background: var(--white);
    color: var(--black);
    line-height: 1.6;
}

img {
    max-width: 100%;
    display: block;
}

a {
    text-decoration: none;
    color: var(--black);
    transition: 0.2s;
}

a:hover {
    color: var(--red);
}

/* Utility containers */

.inner-wide {
    max-width: var(--max-wide);
    margin: 0 auto;
    padding: 60px 40px;
}

.inner-narrow {
    max-width: var(--max-narrow);
    margin: 0 auto;
    padding: 60px 40px;
}

/* Section headings */

.section-kicker {
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 12px;
    color: var(--gray-med);
    margin-bottom: 10px;
}

.section-title {
    font-family: var(--font-serif);
    font-size: 32px;
    margin: 0 0 20px;
}

/* =========================================================
   HEADER & NAVIGATION
========================================================= */

.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 40px;
    border-bottom: 1px solid var(--gray-light);
    background: var(--white);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.logo img {
    height: 50px;
}

/* Desktop nav */

.desktop-nav {
    display: flex;
    gap: 24px;
}

.desktop-nav a {
    font-weight: 500;
    font-size: 14px;
}

/* Mobile nav */

.mobile-menu-button {
    display: none;
    font-size: 28px;
    cursor: pointer;
}

.mobile-nav {
    display: none;
    flex-direction: column;
    background: white;
    border-top: 1px solid var(--gray-light);
    padding: 20px 40px 10px;
}

.mobile-nav a {
    padding: 10px 0;
    font-size: 16px;
}

/* =========================================================
   BUTTONS
========================================================= */

.btn-primary {
    background: var(--red);
    color: var(--white);
    padding: 12px 20px;
    border-radius: 4px;
    margin-right: 10px;
    font-weight: 600;
    display: inline-block;
}

.btn-primary:hover {
    background: var(--black);
    color: var(--white);
}

.btn-secondary {
    background: var(--teal);
    color: var(--white);
    padding: 12px 20px;
    border-radius: 4px;
    font-weight: 600;
    display: inline-block;
}

.btn-secondary:hover {
    background: var(--black);
    color: var(--white);
}

/* =========================================================
   HOMEPAGE (index.php)
========================================================= */

.hero {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 40px;
    max-width: var(--max-wide);
    margin: 0 auto;
    padding: 60px 40px;
    background: var(--gray-light);
}

.hero-text h1 {
    font-family: var(--font-serif);
    font-size: 42px;
    margin-bottom: 20px;
}

.hero-text .subtext {
    font-size: 18px;
    margin-bottom: 30px;
    max-width: 550px;
}

.hero-kicker {
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-size: 12px;
    color: var(--gray-med);
    margin-bottom: 10px;
}

.hero-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.hero-image {
    width: 50%;
}

/* Split section */

.split-section {
    display: flex;
    gap: 40px;
    max-width: var(--max-wide);
    margin: 0 auto;
    padding: 60px 40px;
}

.split-box {
    flex: 1;
    padding: 32px;
    background: var(--gray-light);
    border-radius: 8px;
}

.split-box h2 {
    margin-top: 0;
    font-family: var(--font-serif);
}

/* Portfolio preview */

.portfolio-preview {
    max-width: var(--max-wide);
    margin: 0 auto;
    padding: 60px 40px;
    text-align: center;
}

.preview-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-top: 40px;
}

.preview-card {
    background: var(--gray-light);
    padding: 30px;
    border-radius: 8px;
    font-weight: 600;
}

/* Short bio */

.short-bio {
    display: flex;
    align-items: center;
    gap: 40px;
    max-width: var(--max-wide);
    margin: 0 auto;
    padding: 60px 40px;
}

.bio-img img {
    border-radius: 8px;
    width: 100%;
    height: auto;
    max-width: 250px;
    max-height: 250px;
    min-width: 150px;
    min-height: 150px;
    object-fit: cover;
}

/* Contact teaser */

.contact-teaser {
    max-width: var(--max-wide);
    margin: 0 auto;
    padding: 60px 40px;
    text-align: center;
    background: var(--teal);
    color: var(--white);
    border-radius: 12px 12px 0 0;
}

/* =========================================================
   FUZZY LOGIC PAGE (fuzzylogic.php)
========================================================= */

.fl-hero {
    background: var(--gray-light);
}

.fl-hero .inner-narrow {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.fl-title {
    font-family: var(--font-serif);
    font-size: 32px;
    margin: 0;
}

.fl-tagline {
    font-style: italic;
    font-size: 18px;
}

/* Description blocks */

.fl-description,
.fl-series-info,
.fl-excerpt {
    background: var(--white);
}

.fl-description p,
.fl-excerpt p {
    font-family: var(--font-serif);
    font-size: 17px;
}

/* Series info list */

.fl-series-info ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.fl-series-info li::before {
    content: "• ";
    color: var(--red);
}

/* Character lineup */

.fl-character-strip {
    background: var(--white);
    border-top: 1px solid var(--gray-light);
    border-bottom: 1px solid var(--gray-light);
}

.fl-character-row {
    display: flex;
    gap: 24px;
    overflow-x: auto;
    padding-bottom: 12px;
}

.fl-character {
    min-width: 120px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.fl-character img {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 8px;
    transition: transform 0.25s ease;
}

.fl-character:hover img {
    transform: scale(1.05);
}

/* Character names under the circular thumbnails */
.fl-character-name {
    font-weight: 600;
    font-size: 14px;
    margin-top: 4px;
    color: var(--black);
}

/* Optional smaller secondary text (used for subtitles or species notes) */
.small-text {
    font-size: 11px;
    font-weight: 300;   /* lighter weight */
    color: var(--gray-med);
}


/* Sample illustrations */

.fl-illustrations {
    background: var(--gray-light);
}

.fl-illustration-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
}

/* CTA */

.fl-cta {
    text-align: center;
    background: var(--black);
    color: var(--white);
}

.fl-cta p {
    margin-bottom: 20px;
}

/* =========================================================
   PORTFOLIO PAGE (portfolio.php)
   ========================================================= */

.portfolio-hero {
    background: var(--gray-light);
}

.portfolio-hero .inner-wide {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.portfolio-hero h1 {
    font-family: var(--font-serif);
    margin: 0;
}

.portfolio-hero p {
    max-width: 720px;
    font-size: 17px;
    color: var(--gray-med);
    margin: 0;
}

/* CATEGORY TABS (B1: underline style) */

.category-buttons {
    padding-top: 0;
    border-bottom: 1px solid var(--gray-light);
}

.category-buttons .inner-wide {
    padding-top: 20px;
    padding-bottom: 0;
}

.category-buttons .categories {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
}

/* tab buttons */
.portfolio-tab {
    background: none;
    border: none;
    padding: 10px 0;
    font-family: var(--font-sans);
    font-size: 15px;
    font-weight: 500;
    color: var(--gray-med);
    cursor: pointer;
    position: relative;
    transition: color 0.2s ease;
}

/* underline (active tab) */
.portfolio-tab::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -8px;
    width: 0;
    height: 3px;
    background: var(--red);
    transition: width 0.2s ease;
}

/* active tab */
.portfolio-tab.active {
    color: var(--black);
}

.portfolio-tab.active::after {
    width: 100%;
}

/* hover (desktop) */
@media (hover: hover) {
    .portfolio-tab:hover {
        color: var(--black);
    }
}

/* =========================
   PORTFOLIO GALLERY STRUCTURE
========================= */

.main-gallery {
    padding-top: 0;
}

.gallery-container {
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin-top: 20px;
}

/* Horizontal scrolling thumbnails */
.thumbnails-horizontal {
    display: flex;
    gap: 16px;
    overflow-x: auto;
    padding: 16px;
    background: var(--gray-light);   /* <-- adds the light-gray strip */
    border-radius: 8px;              /* optional: smooth corners */
}


.thumbnails-horizontal::-webkit-scrollbar {
    height: 8px;
}

.thumbnails-horizontal::-webkit-scrollbar-thumb {
    background: var(--gray-med);
    border-radius: 4px;
}

/* Each thumb wrapper */
.thumbnail {
    flex: 0 0 auto;
    width: 64px;
    height: 64px;
    cursor: pointer;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.2s ease-in-out, box-shadow 0.2s;
}

/* Actual thumbnail image */
.thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Hover state */
.thumbnail:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

/* Active (current) thumbnail – no red box, just stronger emphasis */
.thumbnail.active-thumb {
    transform: scale(1.1);
    box-shadow: 0 6px 16px rgba(0,0,0,0.25);
}

/* MAIN IMAGE BELOW THUMBNAILS */
.main-image {
    width: 100%;
    display: flex;
    justify-content: center;
}

.main-image img {
    display: block;
    max-width: 800px;     /* limit width */
    max-height: 800px;    /* limit height */
    width: auto;          /* scale down naturally */
    height: auto;         /* scale down naturally */
    border-radius: 12px;
    object-fit: contain;
    box-shadow: 0 6px 18px rgba(0,0,0,0.15);
}


/* =========================================================
   ABOUT PAGE (about.php)
   ========================================================= */

.about-hero {
    background: var(--gray-light);
    padding: 40px 0;
}

.about-hero .inner-narrow {
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: flex-start;
    text-align: left;
}

.about-hero h1 {
    font-family: var(--font-serif);
    font-size: 36px;
    margin: 0;
    color: var(--black);
}

.about-hero p {
    font-family: var(--font-sans);
    font-size: 18px;
    margin: 0 auto;
    /* max-width: 700px; */
    color: var(--gray-med);
    line-height: 1.5;
}

/* Layout for the About section */
.about-main .inner-narrow {
    display: flex;
    flex-direction: column;
    gap: 40px;
    align-items: flex-start;
    margin-top: 40px;
}

.about-photo {
    flex: 0 0 260px;
    max-width: 300px;
    height: auto;
    margin-bottom: 20px;
}

.about-photo img {
    width: 100%;
    height: auto;
    border-radius: 10px;
    object-fit: cover;
}

.about-text {
    flex: 1;
    text-align: left;
}

.about-text h2 {
    font-family: var(--font-serif);
    font-size: 28px;
    margin-top: 0;
    color: var(--black);
}

.about-text p {
    font-size: 16px;
    color: var(--gray-med);
    margin-bottom: 16px;
    line-height: 1.5;
}

.about-cv {
    margin-top: 20px;
    font-size: 16px;
    color: var(--teal);
}

.about-cv a {
    text-decoration: none;
    color: var(--white);
    font-weight: bold;
}

/* About responsive tweaks */

@media (max-width: 900px) {
    .about-main .inner-narrow {
        flex-direction: column;
        gap: 30px;
    }

    .about-photo {
        flex: 0 0 200px;
    }

    .about-text h2 {
        font-size: 24px;
    }

    .about-text p {
        font-size: 14px;
    }

    .about-cv {
        font-size: 14px;
    }
}

@media (max-width: 600px) {
    .about-hero h1 {
        font-size: 28px;
    }

    .about-hero p {
        font-size: 16px;
    }

    .about-photo {
        flex: 0 0 180px;
    }

    .about-text h2 {
        font-size: 22px;
    }

    .about-text p {
        font-size: 14px;
    }

    .about-cv {
        font-size: 12px;
    }
}

/* =========================================================
   CONTACT PAGE (contact.php)
   ========================================================= */

.contact-hero {
    background: var(--gray-light);
    padding: 40px 0;
}

.contact-hero .inner-narrow {
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: flex-start;
    text-align: left;
}

.contact-hero h1 {
    font-family: var(--font-serif);
    font-size: 36px;
    margin: 0;
    color: var(--black);
}

.contact-hero p {
    font-family: var(--font-sans);
    font-size: 18px;
    margin: 0 auto;
    /* max-width: 700px; */
    color: var(--gray-med);
    line-height: 1.5;
}

/* Layout for the Contact section */

.contact-main .inner-narrow {
    display: flex;
    flex-direction: column;
    gap: 40px;
    align-items: flex-start;
    margin-top: 40px;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
    background: var(--white);
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    max-width: 700px;
    margin: 0 auto;
}

.contact-form label {
    font-weight: 600;
    font-size: 16px;
    color: var(--black);
    margin-bottom: 8px;
}

.contact-form input,
.contact-form textarea,
.contact-form select {
    padding: 12px 16px;
    border: 1px solid var(--gray-med);
    border-radius: 6px;
    font-family: var(--font-sans);
    font-size: 16px;
    color: var(--black);
    margin-bottom: 16px;
}

.contact-form input,
.contact-form select {
    height: 45px;
}

.contact-form textarea {
    resize: vertical;
    min-height: 150px;
}

.contact-form button {
    background: var(--teal);
    color: var(--white);
    padding: 12px 20px;
    border-radius: 6px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    margin-top: 20px;
}

.contact-form button:hover {
    background: var(--black);
}

/* Contact section text */

.contact-email {
    font-size: 16px;
    color: var(--teal);
    margin-top: 20px;
    text-align: left;
}

.contact-email a {
    text-decoration: none;
    color: var(--teal);
    font-weight: bold;
}

.contact-email a:hover {
    text-decoration: underline;
}

/* Contact responsive */

@media (max-width: 900px) {
    .contact-hero .inner-narrow {
        text-align: left;
    }

    .contact-main .inner-narrow {
        padding: 40px 20px;
    }

    .contact-form {
        width: 100%;
    }

    .contact-email {
        font-size: 14px;
    }
}

/* =========================================================
   FOOTER
========================================================= */

.site-footer {
    text-align: center;
    padding: 20px 40px;
    background: var(--black);
    color: var(--white);
    font-size: 14px;
}

/* =========================================================
   GLOBAL RESPONSIVE
========================================================= */

@media (max-width: 900px) {

    .desktop-nav { display: none; }
    .mobile-menu-button { display: block; }

    .hero {
        flex-direction: column;
        text-align: center;
    }

    .hero-image {
        width: 100%;
    }

    .split-section {
        flex-direction: column;
    }

    .short-bio {
        flex-direction: column;
        text-align: center;
    }

    .preview-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {

    .preview-grid {
        grid-template-columns: 1fr;
    }

    .inner-wide,
    .inner-narrow {
        padding: 40px 20px;
    }

    .site-header {
        padding: 16px 20px;
    }
	
	   /* MOBILE FIX FOR PORTFOLIO IMAGES */
    .main-image img {
        max-width: 100%;
        width: auto;
        height: auto;
        max-height: 60vh;
    }
}
