/* The Code Guy - Site Styles */

@font-face {
    font-family: 'BigNoodleTitling';
    src: url('BigNoodleTitling.eot?#iefix') format('embedded-opentype'),
         url('BigNoodleTitling.woff') format('woff'),
         url('BigNoodleTitling.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

html {
    font-size: 14px;
    position: relative;
    min-height: 100%;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

body {
    font-family: "Open Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;
    margin: 0;
    padding: 0;
}

/* Home Hero Section */
.home {
    background: url('../images/grid.webp') repeat #64a8f2;
    position: relative;
    min-height: 680px;
    padding-bottom: 50px;
}

.home-inner {
    max-width: 1600px;
    margin: 0 auto;
    position: relative;
    height: 100%;
    min-height: 680px;
}

.home-book {
    position: absolute;
    top: 0;
    left: 14%;
    width: 32%;
    max-width: 440px;
    z-index: 2;
}

.home-doodles {
    position: absolute;
    top: 48%;
    left: 18%;
    width: 26%;
    max-width: 360px;
    z-index: 1;
}

.home-logo {
    position: absolute;
    top: 40%;
    left: 52%;
    transform: translate(-50%, -50%);
    width: 40%;
    max-width: 620px;
    text-align: center;
    z-index: 3;
}

.home-right {
    position: absolute;
    top: 33%;
    transform: translateY(-50%);
    right: 5%;
    width: 24%;
    max-width: 290px;
    z-index: 4;
}

.home-arrow {
    position: absolute;
    bottom: 55px;
    left: 52%;
    transform: translateX(-50%);
    z-index: 4;
}

.home-coffee {
    position: absolute;
    bottom: 10px;
    right: 18%;
    width: 26%;
    max-width: 360px;
    z-index: 2;
}

/* Mobile hero adjustments */
@media (max-width: 768px) {
    .home {
        min-height: 400px;
        padding-bottom: 40px;
    }

    .home-inner {
        min-height: 400px;
    }

    .home-doodles,
    .home-right {
        display: none;
    }

    .home-book {
        left: 0;
        width: 40%;
        max-width: 180px;
    }

    .home-logo {
        width: 80%;
        max-width: 340px;
        top: 40%;
    }

    .home-arrow {
        bottom: 70px;
    }

    .home-coffee {
        right: 0;
        width: 35%;
        max-width: 160px;
        bottom: 50px;
    }
}

/* Overview Text (About section on home page) */
.overview-text {
    line-height: 180%;
    letter-spacing: -0.5px;
}

/* Section Styles */
.section {
    padding: 100px 0;
}

.section-light {
    background-color: #fcfcfc;
}

.section-blue {
    background-color: #e0eefc;
}

.section-orange {
    background-color: #f7ba4d;
    color: #452200;
}

.section h2 {
    font-family: "BigNoodleTitling", sans-serif;
    font-size: 3em;
    color: #64a8f2;
    margin-bottom: 30px;
}

.section-orange h2 {
    color: #452200;
}

/* Product Cards */
.product-card {
    background: white;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    height: 100%;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.product-card h3 {
    color: #333;
    margin-bottom: 15px;
}

.product-card p {
    color: #666;
    line-height: 1.7;
}

.product-card .btn {
    margin-top: 15px;
}

/* Client Logos */
.client-logo {
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 150px;
}

.client-logo img {
    max-height: 80px;
    max-width: 100%;
    filter: grayscale(20%);
    transition: filter 0.3s ease;
}

.client-logo img:hover {
    filter: grayscale(0%);
}

/* Service Cards */
.service-item {
    padding: 30px;
    text-align: center;
}

.service-item h4 {
    color: #333;
    margin-top: 15px;
    margin-bottom: 10px;
}

.service-item p {
    color: #666;
}

/* Buttons */
.btn-primary {
    background-color: #64a8f2;
    border-color: #64a8f2;
}

.btn-primary:hover {
    background-color: #4a94e0;
    border-color: #4a94e0;
}

.btn-orange {
    background-color: #f7ba4d;
    border-color: #f7ba4d;
    color: white;
}

.btn-orange:hover {
    background-color: #e5a83b;
    border-color: #e5a83b;
    color: white;
}

/* Navigation */
.navbar {
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.navbar-collapse .navbar-nav {
    align-items: flex-end;
}

/* Hero navigation - always horizontal */
.home .navbar .navbar-nav {
    flex-wrap: wrap;
    justify-content: center;
}

.navbar-nav .nav-link {
    padding: 8px 16px;
    margin: 0 4px;
    border-radius: 6px;
    transition: background-color 0.2s ease;
}

.navbar-nav .nav-link:hover {
    background-color: #f0f0f0;
    color: #64a8f2;
}

/* Paul Photo - Homepage */
.paul-photo-frame {
    display: inline-block;
    position: relative;
    transform: rotate(-3deg);
    padding: 8px;
    background: white;
    border-radius: 50%;
    box-shadow: 4px 6px 0 rgba(0,0,0,0.1), 0 0 0 3px #64a8f2, 0 0 0 7px #f7ba4d;
}

.paul-photo {
    width: 240px;
    height: 240px;
    object-fit: cover;
    border-radius: 50%;
    display: block;
}

@media (max-width: 768px) {
    .paul-photo {
        width: 180px;
        height: 180px;
    }
}

/* About Page */
.about-image {
    max-width: 300px;
    border-radius: 8px;
}

/* Contact Section */
.contact-section {
    background-color: #64a8f2;
    color: white;
    padding: 80px 0;
    text-align: center;
}

.contact-section a {
    color: white;
    text-decoration: underline;
}

.contact-section a:hover {
    color: #f0f0f0;
}

/* Error Page */
.error-page {
    padding: 100px 0;
    text-align: center;
}

.error-page h1 {
    font-family: "BigNoodleTitling", sans-serif;
    font-size: 5em;
    color: #64a8f2;
}

/* Find Out More Button */
.btn-findoutmore {
    display: inline-block;
    position: relative;
    background-color: #64a8f2;
    color: white;
    font-family: "BigNoodleTitling", sans-serif;
    font-size: 1.4em;
    letter-spacing: 1px;
    text-transform: uppercase;
    text-decoration: none;
    padding: 10px 28px;
    transform: skewX(-8deg);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    border: none;
    box-shadow: 3px 3px 0 rgba(0,0,0,0.15);
}

.btn-findoutmore:hover {
    background-color: #64a8f2;
    color: white;
    text-decoration: none;
    transform: skewX(-8deg) translate(-2px, -2px);
    box-shadow: 5px 5px 0 rgba(0,0,0,0.2);
}

.btn-findoutmore:active {
    transform: skewX(-8deg) translate(1px, 1px);
    box-shadow: 1px 1px 0 rgba(0,0,0,0.15);
}

/* Sketchy underline scribble */
.btn-findoutmore::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 10%;
    width: 80%;
    height: 3px;
    background: #f7ba4d;
    border-radius: 2px;
    transform: skewX(8deg) rotate(-1deg);
}

.section-orange .btn-findoutmore {
    background-color: white;
    color: #452200;
    box-shadow: 3px 3px 0 rgba(0,0,0,0.1);
}

.section-orange .btn-findoutmore:hover {
    background-color: white;
    color: #5a3000;
    box-shadow: 5px 5px 0 rgba(0,0,0,0.15);
}

.section-orange .btn-findoutmore::after {
    background: #64a8f2;
}

.section-forest {
    background-color: #d8f3dc;
    color: #1b4332;
}

.section-forest h2 {
    color: #1b4332;
}

.section-forest .btn-findoutmore {
    background-color: #2d6a4f;
    color: white;
    box-shadow: 3px 3px 0 rgba(0,0,0,0.1);
}

.section-forest .btn-findoutmore:hover {
    background-color: #1b4332;
    color: white;
    box-shadow: 5px 5px 0 rgba(0,0,0,0.15);
}

.section-forest .btn-findoutmore::after {
    background: #40916c;
}

/* Utility */
.text-blue {
    color: #64a8f2;
}

.bg-blue {
    background-color: #64a8f2;
}

/* Product Page Heroes */
.product-hero {
    padding: 60px 0 80px;
}

.product-hero-taskboard {
    background: linear-gradient(135deg, #f7931e, #f7ba4d);
}

.product-hero-testplan {
    background: linear-gradient(135deg, #0F172A, #1e293b);
}

.product-hero-cosurf {
    background: linear-gradient(135deg, #1E1B4B, #312e81);
}

.product-hero-clubright {
    background: linear-gradient(135deg, #f06522, #f2935b);
}

.product-hero-codezone {
    background: linear-gradient(135deg, #390352, #5B5FA3);
}

/* Product Page Steps */
.product-step {
    background: white;
    border-radius: 12px;
    padding: 30px 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.06);
    height: 100%;
}

.product-step-number {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    color: white;
    font-size: 1.2em;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 15px;
}

/* Blog Cards */
.blog-card-link {
    text-decoration: none;
    display: block;
    margin-bottom: 30px;
}

.blog-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    display: flex;
}

.blog-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.blog-card-accent {
    width: 5px;
    flex-shrink: 0;
}

.blog-card-body {
    padding: 30px 35px;
    flex: 1;
}

.blog-card-meta {
    display: flex;
    gap: 15px;
    font-size: 0.85em;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.blog-card-category {
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.blog-card-date,
.blog-card-read {
    color: #94a3b8;
}

.blog-card-title {
    color: #1a1a2e;
    font-size: 1.5em;
    font-weight: 700;
    margin-bottom: 10px;
    line-height: 1.3;
}

.blog-card-summary {
    color: #64748b;
    line-height: 1.7;
    margin-bottom: 15px;
}

.blog-card-readmore {
    font-weight: 600;
    font-size: 0.95em;
}

/* Forest School Card */
.blog-card-forest {
    background: linear-gradient(135deg, rgba(236,245,239,0.92), rgba(216,243,220,0.92)), url('/images/forest-school-header.png') center/cover no-repeat;
    border: 1px solid #b7e4c7;
}

.blog-card-forest .blog-card-title {
    color: #1b4332;
}

.blog-card-forest .blog-card-summary {
    color: #40916c;
}

.blog-card-forest .blog-card-date,
.blog-card-forest .blog-card-read {
    color: #52796f;
}

.blog-card-forest:hover {
    box-shadow: 0 8px 25px rgba(45, 106, 79, 0.15);
}

.blog-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    justify-content: center;
}

.blog-category-pill {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 14px;
    font-size: 0.72em;
    font-weight: 500;
    text-decoration: none;
    color: #94a3b8;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.15);
    transition: all 0.2s ease;
    white-space: nowrap;
}

.blog-category-pill:hover {
    color: white;
    background: rgba(255,255,255,0.15);
    border-color: rgba(255,255,255,0.3);
    text-decoration: none;
}

.blog-category-pill.active {
    background: #14b8a6;
    color: white;
    border-color: #14b8a6;
}

button.blog-category-more {
    cursor: pointer;
    font-family: inherit;
}

.blog-categories-more {
    display: contents;
}

.blog-categories-hidden {
    display: none;
}

/* Blog Content */
.blog-content {
    font-size: 1.1em;
    line-height: 1.9;
    color: #333;
}

.blog-content p {
    margin-bottom: 1.5em;
}

.blog-content h3 {
    color: #1a1a2e;
    font-size: 1.4em;
    font-weight: 700;
    margin-top: 2.5em;
    margin-bottom: 0.8em;
}

.blog-content strong {
    color: #1a1a2e;
}

.blog-content a {
    color: #64a8f2;
    text-decoration: underline;
}

.blog-content a:hover {
    color: #4a94e0;
}

.blog-content code {
    background: #f1f5f9;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.9em;
    color: #e83e8c;
}

.blog-content ol,
.blog-content ul {
    margin-bottom: 1.5em;
    padding-left: 1.5em;
}

.blog-content li {
    margin-bottom: 0.5em;
}

.blog-content blockquote {
    border-left: 3px solid #64a8f2;
    padding-left: 25px;
    margin: 2em 0;
    color: #555;
    font-style: italic;
}

/* Forest School Theme */
.blog-forest-school .blog-content h3 {
    color: #1b4332;
}

.blog-forest-school .blog-content strong {
    color: #1b4332;
}

.blog-forest-school .blog-content a {
    color: #2d6a4f;
}

.blog-forest-school .blog-content a:hover {
    color: #1b4332;
}

.blog-forest-school .blog-content blockquote {
    border-left-color: #2d6a4f;
}

.blog-forest-school .blog-content code {
    background: #ecf5ef;
    color: #1b4332;
}

.blog-forest-school .blog-nav-link:hover .blog-nav-title {
    color: #2d6a4f;
}

/* Blog Post Navigation */
.blog-nav-link {
    text-decoration: none;
    display: block;
    flex: 1;
    min-width: 200px;
}

.blog-nav-label {
    display: block;
    font-size: 0.85em;
    color: #94a3b8;
    margin-bottom: 5px;
}

.blog-nav-title {
    display: block;
    color: #1a1a2e;
    font-weight: 600;
    font-size: 1.05em;
    line-height: 1.4;
}

.blog-nav-link:hover .blog-nav-title {
    color: #64a8f2;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .container {
        padding-left: 20px;
        padding-right: 20px;
    }

    .section {
        padding: 40px 0;
    }

    .section h2 {
        font-size: 2em;
    }

    .product-hero {
        padding: 40px 0 60px;
    }

    .product-hero h1 {
        font-size: 2.5em !important;
    }

    .blog-card-body {
        padding: 20px 22px;
    }

    .blog-card-title {
        font-size: 1.25em;
    }

    .blog-content {
        font-size: 1em;
    }

    /* Showcase mobile fixes */
    .showcase-hero-img {
        max-height: 250px;
        width: auto !important;
        object-fit: contain;
    }

    .showcase-logo-box {
        padding: 12px 20px !important;
    }

    .showcase-logo-box img {
        max-height: 60px !important;
    }

    /* Centre-align body text on mobile */
    .col-lg-5,
    .col-lg-6,
    .col-lg-7,
    .col-lg-8 {
        text-align: center;
    }

    .col-lg-5 h1, .col-lg-5 h2, .col-lg-5 h3,
    .col-lg-6 h1, .col-lg-6 h2, .col-lg-6 h3,
    .col-lg-7 h1, .col-lg-7 h2, .col-lg-7 h3,
    .col-lg-8 h1, .col-lg-8 h2, .col-lg-8 h3 {
        text-align: left;
    }

    .col-lg-5 ul, .col-lg-6 ul,
    .col-lg-7 ul, .col-lg-8 ul {
        text-align: left;
        display: inline-block;
    }

    .col-lg-5 div[style*="display: flex"],
    .col-lg-6 div[style*="display: flex"],
    .col-lg-7 div[style*="display: flex"] {
        justify-content: center;
    }

    .blog-content {
        text-align: left;
    }
}
