:root {
    --bg-colour: #f7f3eb;
    --card-white: #ffffff;
    --primary-colour: #3281ce;
    --primary-shadow-colour: #235a91;
    --primary-hover-colour: #478dd3;
    --text-main: #333333;
    --text-muted: #666666;
    --box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);

    /* Default Status Colours */
    --status-positive: #2d6a4f;
    --status-negative: #bc4749;
}

/* --- ACCESSIBILITY MODE OVERRIDES --- */
body.accessible {
    --bg-colour: #ffffff;
    --card-white: #f0f0f0;
    --primary-colour: #004a99; /* Deep High-Contrast Blue */
    --primary-shadow-colour: #002d5e;
    --primary-hover-colour: #005bc1;
    --text-main: #000000;
    --text-muted: #222222;
    --status-positive: #004a99; 
    --status-negative: #e6a500; /* High Contrast Gold */
}

/* Specific UI adjustments for Accessible Mode */
body.accessible .pill-nav {
    background: var(--status-negative) !important;
    border: 2px solid var(--primary-colour) !important;
}

body.accessible .nav-link {
    color: #000000 !important; /* Black text for high contrast on Gold nav */
    font-weight: 700;
}

body.accessible .nav-link.active {
    color: #ffffff !important;
    background: var(--primary-colour);
    border-radius: 20px;
}

/* GLOBAL HOVER & BUTTON OVERRIDES */
body.accessible button:not(.accessibility-toggle):hover,
body.accessible .btn-team:hover,
body.accessible .btn-text:hover,
body.accessible .project-action a:hover,
body.accessible .submit-btn:hover,
body.accessible a.case-link:hover,
body.accessible .location-pill:hover,
body.accessible .btn-primary:hover,
body.accessible .btn-secondary:hover {
    background-color: #000000 !important; /* Pure black background */
    color: #ffffff !important;           /* White text for contrast */
    border: 2px solid var(--status-negative) !important;
    transform: translateY(-2px);
}

/* Specific fix for text buttons */
body.accessible .btn-text, 
body.accessible .project-action a {
    color: #000000 !important;
    text-decoration: underline !important;
    font-weight: 800 !important;
}

/* --- ACCESSIBILITY TOGGLE BUTTON STYLING --- */
.accessibility-toggle {
    position: absolute;
    top: 20px;
    right: 20px;
    background: var(--card-white);
    border: 2px solid var(--primary-colour);
    padding: 10px 18px;
    border-radius: 50px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: inherit;
    font-weight: 700;
    font-size: 13px;
    color: var(--text-main);
    z-index: 2000;
    transition: all 0.3s ease;
    box-shadow: var(--box-shadow);
}

.accessibility-toggle:hover {
    transform: translateY(-2px);
    background: var(--primary-colour);
    color: white;
}

body.accessible .accessibility-toggle:hover {
    background: #000000 !important;
    color: var(--status-negative) !important;
    border-color: #ffffff !important;
}

body.accessible .card, 
body.accessible .case-header, 
body.accessible .section-card {
    border: 1px solid #000000 !important;
    box-shadow: none !important;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-colour);
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    color: var(--text-main);
    display: flex;
    justify-content: center;
    padding: 60px 20px;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* ==========================================================================
   GRID LAYOUTS (BENTO STRUCTURES)
   ========================================================================== */

/* Index Bento Grid */
.grid-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-areas: 
        "intro intro status"
        "football spotify project"
        "templates foundations foundations";
    gap: 25px;
    max-width: 1450px;
    margin: 40px auto;
    align-items: start;
}

/* Explicit Grid Area Mapping */
.grid-container .card-intro { grid-area: intro; }
.grid-container .card-status { grid-area: status; }
.grid-container .card-football { grid-area: football; }
.grid-container .card-spotify { grid-area: spotify; }
.grid-container .card-project { grid-area: project; }
.grid-container .card-templates { grid-area: templates; }
.grid-container .card-foundations { grid-area: foundations; }

/* About Page Bento Grid */
.about-page-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-areas: 
        "about about values"
        "philosophy toolkit education"
        "travel travel interests";
    gap: 25px;
    max-width: 1450px;
    margin: 40px auto;
    align-items: start;
}

.about-page-container .card-about { grid-area: about; }
.about-page-container .card-values { grid-area: values; }
.about-page-container .card-philosophy { grid-area: philosophy; }
.about-page-container .card-toolkit { grid-area: toolkit; }
.about-page-container .card-edu { grid-area: education; }
.about-page-container .card-travel { grid-area: travel; }
.about-page-container .card-interests { grid-area: interests; }

/* Styling for Philosophy and Toolkit cards to match the design system */
.card-philosophy,
.card-toolkit {
    background-color: var(--card-white);
    padding: 35px;
    border-radius: 30px;
    box-shadow: var(--box-shadow);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform 0.3s ease;
}

/* Style headings for cards without card-headers */
.card-about h2,
.card-values h3,
.card-edu h3,
.card-interests h3 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-top: 0;
    margin-bottom: 1rem;
    position: relative;
    padding-bottom: 0.5rem;
}

.card-about h2::after,
.card-values h3::after,
.card-edu h3::after,
.card-interests h3::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 40px;
    height: 3px;
    background-color: var(--primary-colour);
    border-radius: 2px;
}

.card-edu .edu-title {
    font-weight: 600;
    margin-top: 0.5rem;
}

.card-edu .edu-meta {
    color: var(--text-muted, #666);
    font-size: 0.95rem;
    margin-bottom: 1rem;
}

.card-philosophy:hover,
.card-toolkit:hover {
    transform: translateY(-5px);
}

.card-philosophy .card-header,
.card-toolkit .card-header {
    margin-bottom: 15px;
}

.card-philosophy h3,
.card-toolkit h3 {
    font-size: 15px;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--primary-colour);
    margin: 0;
    font-weight: 800;
}

.card-philosophy p,
.card-toolkit p {
    margin: 0;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-main);
    font-weight: 400;
}

/* ==========================================================================
   INDEX & COMPONENT CARD STYLING
   ========================================================================== */

.card-intro {
    grid-area: intro;
    background-color: var(--card-white);
    padding: 40px;
    border-radius: 30px;
    box-shadow: var(--box-shadow);
}

.intro-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
}

.intro-text {
    flex: 2;
}

.intro-text h1 {
    font-size: 42px;
    margin-bottom: 20px;
    color: var(--text-main);
}

.intro-text p {
    font-size: 18px;
    line-height: 1.6;
    color: var(--text-muted);
    margin: 0;
}

.intro-image {
    flex: 1;
    display: flex;
    justify-content: center;
}

.intro-image img {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
    border: 5px solid var(--primary-colour);
    box-shadow: var(--box-shadow);
}

.card-status {
    grid-area: status;
    background-color: var(--card-white);
    padding: 30px;
    border-radius: 30px;
    box-shadow: var(--box-shadow);
    font-family: 'Segoe UI', Roboto, sans-serif;
}

.availability-list {
    list-style: none;
    padding: 0;
    margin: 20px 0;
}

.availability-list li {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
    font-size: 15px;
    color: var(--text-main);
}

.availability-list li i {
    color: var(--primary-colour);
    font-size: 18px;
    width: 25px;
    text-align: center;
}

.status-links-minimal {
    display: flex;
    gap: 15px;
    justify-content: flex-start;
    margin-top: 25px;
}

.status-links-minimal a {
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--primary-shadow-colour);
    color: var(--bg-colour);
    border-radius: 80px;
    text-decoration: none;
    font-size: 20px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.status-links-minimal a:hover {
    background-color: var(--primary-hover-colour);
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(50, 129, 206, 0.3);
}

.card-football {
    grid-area: football;
    background-color: var(--card-white);
    padding: 30px;
    border-radius: 30px;
    box-shadow: var(--box-shadow);
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease;
}

.card-football:hover {
    transform: translateY(-5px);
}

/* Team Switcher */
.team-switcher {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 25px;
}

.btn-team {
    flex: 1;
    padding: 10px 5px;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    color: white;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-dufc { background-color: #FF6601; }
.btn-nufc { background-color: #000000; border: 1px solid #D4AF37 !important; }
.btn-fcb { background-color: #A50044; }

.btn-team:hover {
    transform: scale(1.05);
    filter: brightness(1.2);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.history-title {
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    color: var(--text-muted);
}

#match-status {
    font-size: 10px;
    font-weight: 900;
    text-transform: uppercase;
    color: #e91e63;
    padding: 4px 8px;
    background: rgba(233, 30, 99, 0.1);
    border-radius: 20px;
}

.live-pulse {
    animation: pulse-red 2s infinite;
}

@keyframes pulse-red {
    0% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.6; transform: scale(0.95); }
    100% { opacity: 1; transform: scale(1); }
}

#match-container {
    transition: opacity 0.4s ease;
}

.match-info-top {
    text-align: center;
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 15px;
}

.scoreboard {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
}

.team {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.logo-wrapper {
    width: 65px;
    height: 65px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.team img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: opacity 0.3s ease;
}

.team span {
    font-size: 14px;
    font-weight: 700;
    text-align: center;
    color: var(--text-main);
}

.score-display {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 38px;
    font-weight: 900;
    color: var(--text-main);
}

.score-display .divider {
    color: var(--text-muted);
    font-size: 22px;
    opacity: 0.5;
}

.logo-wrapper img {
    width: 50px;
    height: 50px;
    object-fit: contain;
    display: block;
    margin: 0 auto;
}

/* Spotify Card */
.card-spotify { 
    grid-area: spotify; 
    background-color: var(--primary-colour);
    display: flex;
    flex-direction: column;
    border-radius: 30px;
    color: var(--card-white);
    padding: 25px;
    min-height: 700px;
    box-shadow: var(--box-shadow);
    transition: transform 0.2s ease;
}

.card-spotify:hover {
    transform: translateY(-5px);
    background-color: var(--primary-hover-colour);
}

.card-spotify span, .history-title {
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 15px;
    display: block;
}

#track-art { 
    width: 100%;
    aspect-ratio: 1 / 1;
    max-width: 220px;
    border-radius: 15px;
    object-fit: cover;
    margin-bottom: 20px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}

#track-title { 
    font-size: 22px; 
    font-weight: 700; 
    color: var(--card-white);
    margin: 0;
    line-height: 1.2;
}

#track-artist { 
    color: rgba(255, 255, 255, 0.9);
    margin: 6px 0 20px 0; 
    font-size: 15px; 
}

.progress-container {
    width: 100%;
    background: rgba(255, 255, 255, 0.2);
    height: 5px;
    border-radius: 10px;
    margin: 10px 0;
}

#progress-bar {
    height: 100%;
    background: var(--primary-shadow-colour);
    width: 0%;
    transition: width 1s linear;
    border-radius: 10px;
}

.time-info {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: var(--card-white);
    margin-top: 8px;
    font-family: monospace;
}

.history-section {
    margin-top: 40px;
}

.history-item { 
    display: flex; 
    align-items: center; 
    gap: 12px; 
    margin-bottom: 12px;
    padding: 8px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    transition: background 0.2s ease;
}

.history-item:hover {
    background: rgba(255, 255, 255, 0.15);
    cursor: pointer;
}

.history-item img { 
    width: 48px; 
    height: 48px; 
    border-radius: 8px; 
    object-fit: cover; 
}

.history-info p {
    margin: 0;
    font-size: 13px;
    color: var(--card-white);
    font-weight: 500;
}

.h-artist {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.8) !important;
}

.history-title {
    color: var(--primary-colour);
}

/* Project & Templates Cards */
.card-project { 
    grid-area: project; 
    box-shadow: var(--box-shadow);
    background-color: var(--card-white);
    border-radius: 30px;
    padding: 30px;
}

.card-project img {
    width: 100%;
    height: 160px;
    object-fit: cover;
    background-color: #e0e0e0;
    border-radius: 20px;
    margin: 15px 0;
    display: block;
    box-shadow: var(--box-shadow);
}

.card-project button {
    background-color: #6a8d7a;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    width: fit-content;
    transition: transform 0.2s;
}

.card-project button:hover {
    transform: scale(1.03);
}

.card-templates {
    grid-area: templates;
    background-color: var(--card-white);
    padding: 30px;
    border-radius: 30px;
    box-shadow: var(--box-shadow);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.card-templates h2 {
    font-size: 20px;
    color: var(--text-main);
    margin-bottom: 12px;
}

.card-templates p {
    font-size: 15px;
    color: var(--text-muted);
    line-height: 1.5;
    margin: 0;
}

/* Foundations Card */
.card-foundations {
    grid-area: foundations;
    background-color: var(--card-white);
    padding: 30px;
    border-radius: 30px;
    box-shadow: var(--box-shadow);
}

.foundation-item {
    display: flex;
    align-items: flex-start;
    gap: 25px;
    margin-bottom: 30px;
}

.foundation-item:last-child {
    margin-bottom: 0;
}

.icon-box {
    width: 55px;
    height: 55px;
    background-color: var(--card-white);
    border: #3281ce solid 2px;
    color: var(--primary-colour);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex-shrink: 0;
}

.info h3 {
    font-size: 17px;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--primary-colour);
    margin: 0 0 8px 0;
    font-weight: 800;
}

.info p {
    margin: 0;
    font-size: 15px;
    color: var(--text-main);
    line-height: 1.5;
    font-weight: 500;
}

.edu-title {
    font-size: 18px !important;
    font-weight: 700;
    margin-bottom: 4px !important;
}

.edu-meta {
    font-size: 15px !important;
    color: var(--text-muted) !important;
    font-weight: 400 !important;
}

/* Story / About Page Cards */
.card-story {
    grid-area: story;
    background-color: var(--card-white);
    padding: 35px;
    border-radius: 30px;
    box-shadow: var(--box-shadow);
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.story-section {
    position: relative;
}

.story-section:not(:last-child):after {
    content: "";
    display: block;
    width: 60px;
    height: 2px;
    background: var(--bg-colour);
    margin-top: 25px;
    border-radius: 2px;
}

.story-section h3 {
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--primary-colour);
    margin: 0 0 12px 0;
    font-weight: 800;
}

.story-section p {
    margin: 0;
    font-size: 17px;
    line-height: 1.6;
    color: var(--text-main);
    font-weight: 400;
}

.story-section p strong {
    color: var(--text-muted);
    font-weight: 700;
    background: linear-gradient(180deg, transparent 70%, rgba(50, 129, 206, 0.1) 30%);
}

.card-story h2 {
    margin-bottom: 10px;
}

/* Travel Card */
.card-travel {
    grid-area: travel;
    background-color: var(--card-white);
    padding: 30px;
    border-radius: 30px;
    box-shadow: var(--box-shadow);
}

.travel-bio {
    font-size: 15px;
    line-height: 1.6;
    color: var(--text-muted);
    margin-bottom: 25px;
}

.location-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}

.location-pill {
    background-color: var(--card-white);
    border: #004a99 solid 1px;
    color: var(--text-main);
    padding: 8px 14px;
    border-radius: 20px;
    font-size: 16px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
}

.fi {
    border-radius: 2px;
}

.next-destination {
    margin-top: 30px;
    padding: 20px;
    background: linear-gradient(135deg, #f7f3eb 50%, #3281ce 100%);
    border-radius: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    border: 1px solid rgba(0,0,0,0.05);
}

.flag-large {
    font-size: 30px;
    width: 40px !important;
    height: auto;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.next-info {
    display: flex;
    flex-direction: column;
}

.next-label {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 800;
    color: var(--primary-colour);
}

.next-country {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-main);
}

.card {
    background-color: white;
    border-radius: 30px;
    padding: 30px;
    height: 100%; 
}

/* ==========================================================================
   PILL NAVIGATION & SLIDER
   ========================================================================== */

.pill-nav {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 6px;
    border-radius: 100px;
    display: flex;
    align-items: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    z-index: 1000;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.nav-slider {
    position: absolute;
    height: calc(100% - 12px); 
    top: 6px;
    left: 6px;
    background: var(--primary-colour);
    border-radius: 100px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1;
}

.nav-link {
    position: relative;
    z-index: 2;
    text-decoration: none;
    color: var(--text-muted);
    padding: 10px 25px;
    font-weight: 600;
    font-size: 14px;
    transition: color 0.3s ease;
    min-width: 90px;
    text-align: center;
}

.nav-link.active {
    color: #ffffff;
}

.nav-link:not(.active):hover {
    color: var(--text-main);
}

/* ==========================================================================
   CONTACT PAGE STYLES
   ========================================================================== */

.contact-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    max-width: 1200px;
    margin: 40px auto;
    width: 100%;
}

.hero-card, .form-card, .resume-card {
    grid-column: span 3;
    background-color: var(--card-white);
    padding: 40px;
    border-radius: 30px;
    box-shadow: var(--box-shadow);
}

.hero-card h1 {
    font-size: 42px;
    margin-bottom: 15px;
    color: var(--text-main);
}

.social-grid {
    grid-column: span 3;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.social-item {
    text-decoration: none;
    transition: transform 0.3s ease;
}

.social-item .card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.social-item i {
    font-size: 24px;
    color: var(--primary-colour);
}

.social-item .arrow {
    color: var(--text-muted);
    font-weight: bold;
}

.social-item h3 {
    font-size: 18px;
    margin-bottom: 5px;
    color: var(--text-main);
}

.form-title {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.availability-badge {
    background-color: rgba(50, 129, 206, 0.1);
    color: var(--primary-colour);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 700;
}

.input-row {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

#contact-form input, 
#contact-form textarea {
    width: 100%;
    padding: 15px 20px;
    border-radius: 15px;
    border: 2px solid var(--primary-colour);
    background-color: var(--card-white);
    font-family: inherit;
    font-size: 16px;
    transition: all 0.3s ease;
}

#contact-form input:focus, 
#contact-form textarea:focus {
    outline: none;
    border-color: var(--primary-hover-colour);
    background-color: rgba(50, 129, 206, 0.05);
}

.submit-btn {
    background-color: var(--primary-colour);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 15px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 10px;
    transition: background 0.3s ease;
}

.submit-btn:hover {
    background-color: var(--primary-hover-colour);
}

.resume-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.download-btn {
    text-decoration: none;
    background-color: var(--primary-shadow-colour);
    color: white;
    padding: 15px 30px;
    border-radius: 80px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.download-btn:hover {
    background-color: var(--primary-hover-colour);
    transform: translateY(-3px);
}

/* ==========================================================================
   PROJECTS PAGE LAYOUT
   ========================================================================== */

.projects-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 20px 140px 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.project-sub-nav {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-bottom: 10px;
}

.sub-link {
    background: rgba(255, 255, 255, 0.5);
    border: 1px solid rgba(0, 0, 0, 0.05);
    padding: 8px 24px;
    border-radius: 100px;
    font-size: 14px;
    font-weight: 600;
    color: #666;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.sub-link:hover {
    background: #fff;
    color: var(--text-main);
}

.sub-link.active {
    background: #fff;
    color: var(--primary-colour);
    border-color: rgba(0, 0, 0, 0.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.project-header-card {
    text-align: left;
    padding: 40px;
}

.project-header-card h1 {
    font-size: 32px;
    margin-bottom: 10px;
    color: var(--primary-colour);
}

.project-view {
    display: none;
    flex-direction: column;
    gap: 20px;
    animation: fadeIn 0.4s ease forwards;
}

.project-view.active {
    display: flex;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.project-preview-layout {
    display: flex;
    align-items: center;
    gap: 40px;
    padding: 40px;
    background-color: var(--card-white);
    border-radius: 24px;
    width: 100%;
    box-sizing: border-box;
}

.project-preview-large {
    flex: 1;
    width: 50%;
    height: 100%;
}

.project-image-container {
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.featured-project-card:hover .project-image {
    transform: scale(1.03);
}

.project-info {
    flex: 1;
    width: 50%;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.project-title-row h2 {
    font-size: 24px;
    color: #1a1b23;
    font-weight: 700;
    line-height: 1.3;
    margin: 0;
}

.project-info p {
    font-size: 15px;
    color: #555;
    line-height: 1.6;
    margin: 0;
}

.project-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    font-size: 13px;
    color: #777;
    margin-top: 5px;
}

.project-action {
    margin-top: 20px;
}

.secondary-projects-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.small-project-card {
    background: #ffffff;
    border-radius: 24px;
    border: 1px solid #f0f0f0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.small-project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.project-preview-small {
    background-color: #fdf8f3;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 250px;
    width: 100%;
    overflow: hidden;
}

.small-image-size {
    width: 100%;
}

.small-project-card:hover .desktop-mock {
    transform: scale(1.05) rotate(-1deg);
}

.project-image {
    width: 100%;
    height: auto;
    object-fit: cover;
}

.analytics-bg { background-color: #1a1b23; }
.mobile-bg { background-color: #eef6ff; }
.ux-study-bg { 
    background-color: #f8f9fa; 
    color: var(--primary-colour);
    font-size: 3rem;
}

.project-title-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.project-info h2, .project-info h3 {
    font-size: 22px;
    margin-bottom: 10px;
}

.btn-primary {
    display: inline-block;
    padding: 12px 28px;
    background-color: var(--primary-colour);
    color: white;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(50, 129, 206, 0.2);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(50, 129, 206, 0.3);
    filter: brightness(1.1);
}

.btn-secondary {
    display: inline-block;
    padding: 12px 28px;
    background-color: var(--card-white);
    color: var(--primary-colour);
    border: 2px solid var(--primary-colour);
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    transform: translateY(-2px);
    background-color: rgba(50, 129, 206, 0.05);
}

.btn-text {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--primary-colour);
    text-decoration: none;
    font-weight: 700;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: gap 0.2s ease, color 0.2s ease;
    margin-top: 10px;
}

.btn-text i {
    font-size: 12px;
}

.btn-text:hover {
    gap: 12px;
    color: var(--text-main);
}

.arrow-icon {
    color: #ccc;
    font-size: 20px;
    transition: color 0.3s ease;
}

.card:hover .arrow-icon {
    color: var(--primary-colour);
}

.category-tag {
    display: inline-block;
    font-size: 11px;
    font-weight: 700;
    color: var(--primary-colour);
    background: rgba(50, 129, 206, 0.1);
    padding: 4px 10px;
    border-radius: 50px;
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.extra-projects-card {
    padding: 40px;
}

.extra-content {
    display: flex;
    align-items: center;
    gap: 30px;
}

.extra-content .icon-box {
    width: 60px;
    height: 60px;
    background: #f0f7ff;
    color: var(--primary-colour);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.extra-text {
    flex-grow: 1;
}

.view-all-btn {
    padding: 12px 25px;
    background: var(--primary-colour);
    color: white;
    text-decoration: none;
    border-radius: 100px;
    font-weight: 600;
    transition: transform 0.2s ease;
}

.view-all-btn:hover {
    transform: scale(1.05);
}

/* ==========================================================================
   CASE STUDY PAGE STYLES (CENTERED)
   ========================================================================== */

.case-study-page {
    background-color: var(--bg-colour);
    display: block; 
    margin: 0;
    padding: 0;
    width: 100%;
}

.case-container {
    max-width: 900px; 
    margin: 0 auto; 
    padding: 40px 20px 180px 20px;
    display: flex;
    flex-direction: column;
    gap: 60px;
    box-sizing: border-box;
}

.case-nav {
    max-width: 900px;
    margin: 40px auto 0 auto;
    padding: 0 20px;
    box-sizing: border-box;
    text-align: left;
}

.back-btn {
    text-decoration: none;
    color: #888;
    font-size: 14px;
    font-weight: 600;
    transition: color 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.back-btn:hover { color: var(--primary-colour); }

.case-sub-nav {
    margin: 30px auto 0 auto;
    display: flex;
    justify-content: center;
    gap: 12px;
}

.version-view {
    display: none;
    flex-direction: column;
    gap: 60px;
    animation: caseFadeIn 0.5s ease forwards;
}

.version-view.active {
    display: flex;
}

@keyframes caseFadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.case-header .project-type {
    text-transform: uppercase;
    font-size: 11px;
    letter-spacing: 1px;
    color: #999;
    font-weight: 700;
}

.case-header h1 {
    font-size: 36px;
    margin: 10px 0 0 0;
    color: #1a1b23;
}

.section-number {
    font-size: 18px;
    font-weight: 700;
    color: #1a1b23;
    margin-bottom: 5px;
}

.section-divider {
    width: 40px;
    height: 3px;
    background: var(--primary-colour);
    margin-bottom: 25px;
}

.section-content p {
    font-size: 16px;
    line-height: 1.7;
    color: #555;
    max-width: 750px;
}

.hero-display-card {
    padding: 0 !important;
    overflow: hidden;
    height: 500px;
}

.prototype-wrapper {
    width: 100%;
    height: 100%;
}

.adobe-prototype {
    width: 100%;
    height: 100%;
    display: block;
    border: none;
}

.goal-list {
    list-style-type: none;
    padding-left: 0;
    margin-bottom: 30px;
}

.goal-list li {
    display: flex;
    gap: 12px;
    margin-bottom: 15px;
    font-size: 16px;
    line-height: 1.6;
    color: #555;
}

.goal-list .bullet {
    color: var(--primary-colour);
    font-weight: bold;
}

.goal-list strong {
    color: #333;
}

.section-content p + p {
    margin-top: 15px;
}

.research-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 25px;
    width: 100%;
}

.research-card {
    padding: 25px;
    background: white;
    border-radius: 20px;
    border: 1px solid #eee;
    display: flex;
    flex-direction: column;
    text-align: left;
    transition: transform 0.3s ease;
}

.research-card h4 {
    font-size: 15px;
    margin: 0 0 10px 0;
    color: var(--primary-colour);
    font-weight: 700;
}

.research-card p {
    font-size: 13px;
    line-height: 1.5;
    color: #666;
    margin: 0;
}

/* ==========================================================================
   SECTION 03: DESIGN SOLUTION (ARTEFACT GRID)
   ========================================================================== */

.artefact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

.artefact-card {
    background: white;
    border-radius: 20px;
    border: 1px solid #eee;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.image-container {
    width: 100%;
    height: 220px;
    background-color: #f5f7fa;
    display: flex;
    overflow: hidden;
}

.artefact-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.wide-card {
    grid-column: 1 / -1;
}

.wide-card .image-container {
    height: 350px;
}

.wide-card .dual-image {
    display: flex;
    justify-content: space-around;
    padding: 20px;
    gap: 20px;
}

.wide-card .dual-image .artefact-img {
    width: 50%;
    height: auto;
    object-fit: contain;
}

.artefact-label {
    padding: 20px;
}

.artefact-label h4 {
    margin: 0 0 8px 0;
    font-size: 17px;
    color: #1a1b23;
}

.artefact-label p {
    margin: 0;
    font-size: 14px;
    line-height: 1.5;
    color: #555;
}

.artefact-card:first-child .artefact-img {
    object-fit: contain;
    padding: 20px;
}

.section-subtitle {
    font-size: 20px;
    font-weight: 700;
    color: #1a1b23;
    margin-top: 40px;
    margin-bottom: 15px;
}

.link-card {
    background: #f0f7ff;
    border: 2px dashed var(--primary-colour);
    align-items: center;
    text-align: center;
}

.link-card i {
    font-size: 24px;
    color: var(--primary-colour);
    margin-bottom: 12px;
}

.result-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 20px;
}

.result-item {
    padding: 30px;
    background: white;
    border-radius: 20px;
    border: 1px solid #eee;
}

.result-item .label {
    display: block;
    font-size: 11px;
    text-transform: uppercase;
    color: #999;
    margin-bottom: 10px;
}

.result-value {
    font-size: 28px;
    font-weight: 700;
    color: var(--primary-colour);
    margin: 0;
}

.coming-soon-card {
    height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: linear-gradient(145deg, #ffffff, #f0f4f8);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.coming-soon-content {
    max-width: 500px;
    padding: 40px;
}

.icon-pulse {
    font-size: 3rem;
    color: var(--primary-colour);
    margin-bottom: 20px;
    animation: pulse 2s infinite;
}

.coming-soon-content h2 {
    font-size: 32px;
    margin-bottom: 15px;
    color: #1a1b23;
}

.coming-soon-content p {
    color: #666;
    line-height: 1.6;
    margin-bottom: 30px;
}

.status-tag {
    display: inline-block;
    padding: 6px 16px;
    background: rgba(50, 129, 206, 0.1);
    color: var(--primary-colour);
    border-radius: 100px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

@keyframes pulse {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.1); opacity: 0.7; }
    100% { transform: scale(1); opacity: 1; }
}

/* --- VA Dundee Case Study Extras --- */
.iframe-container {
    width: 100%;
    height: 100%;
    position: relative;
}

.case-external-links {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
    flex-wrap: wrap;
}

.live-demo-link, .github-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 0.8rem 1.5rem;
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.live-demo-link {
    background-color: var(--primary-colour);
    color: white;
}

.github-link {
    background-color: var(--primary-colour);
    color: var(--text-color, #fff);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.live-demo-link:hover, .github-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.prototype-container {
    margin: 2rem 0;
    padding: 1.5rem;
    background: #fdf8f3; 
    border-radius: 24px;
    border: 1px solid #f0f0f0;
}

.prototype-image-wrapper {
    display: block;
    background: #1a1b23;
    border-radius: 12px;
    width: 100%;
    height: 500px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
    cursor: -moz-zoom-in;
}

.va-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top;
    display: block;
    transition: transform 0.5s ease;
}

.prototype-container:hover .va-img {
    transform: scale(1.02);
}

.research-grid-VA {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.research-card-VA h3 {
    margin-bottom: 10px;
    font-size: 1.2rem;
    color: var(--text-color);
}

.result-value-VA {
    color: #2ecc71;
    font-size: 2.5rem;
    margin: 10px 0;
}

/* --- Case Study: Design Solution Bento Grid --- */

.cs-design-persona-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 25px;
}

.cs-design-artefact-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 25px;
}

.cs-design-bento-card {
    background: var(--card-white);
    border-radius: 25px;
    border: 1px solid rgba(0,0,0,0.08);
    box-shadow: var(--box-shadow);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.cs-design-img-box {
    width: 100%;
    height: 200px; 
    background-color: #f8f9fa;
    overflow: hidden;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    cursor: -webkit-grab;
}

.cs-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    padding: 40px;
    backdrop-filter: blur(5px);
}

.cs-lightbox.active {
    display: flex;
}

.cs-lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 85vh;
}

.cs-lightbox-img {
    width: 100%;
    height: auto;
    max-height: 85vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 0 30px rgba(0,0,0,0.5);
}

.cs-lightbox-close {
    position: absolute;
    top: -50px;
    right: 0;
    background: none;
    border: none;
    color: white;
    font-size: 35px;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.cs-lightbox-close:hover {
    transform: scale(1.2);
}

.cs-design-artefact-row .cs-design-img-box {
    height: 280px;
}

.cs-design-bento-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.cs-design-bento-content {
    padding: 24px;
}

.cs-design-bento-content h4 {
    margin: 0 0 10px 0;
    font-size: 18px;
    font-weight: 700;
    color: var(--text-main);
    letter-spacing: -0.01em;
}

.cs-design-bento-content p {
    margin: 0;
    font-size: 14px;
    line-height: 1.6;
    color: var(--text-muted);
}

/* --- AcclimatizeMeNow Specific Styles --- */

.acme-section {
    margin: 5px;
}

.acme-bento-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.acme-card {
    background: var(--card-white);
    padding: 2rem;
    border-radius: 20px;
    border: 1px solid #f0f0f0;
}

.acme-strategy-box {
    background: var(--card-white);
    border-left: 5px solid #333;
    padding: 3rem;
    margin-top: 2rem;
    margin-bottom: 2rem;
    border-radius: 0 15px 15px 0;
}

.acme-strategy-box h3 {
    margin-top: 0;
    margin-bottom: 1rem;
    font-size: 1.5rem;
    color: #222;
    letter-spacing: -0.5px;
}

.acme-strategy-box p {
    line-height: 1.7;
    color: #444;
    margin-bottom: 1.5rem;
}

.acme-goal-list {
    list-style: none;
    padding: 0;
    margin-top: 1.5rem;
}

.acme-goal-list li {
    margin-bottom: 1.25rem;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    line-height: 1.5;
    color: #333;
}

.acme-bullet {
    color: #333;
    font-weight: 900;
    font-size: 1.2rem;
    line-height: 1;
    margin-top: 2px;
}

.acme-goal-list strong {
    color: #000;
    font-weight: 700;
}

.acme-persona-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: stretch;
}

.acme-persona-img-container {
    width: 100%;
    aspect-ratio: 1 / 1; 
    overflow: hidden;
    cursor: pointer;
}

.acme-persona-img {
    width: 100%;
    height: 100%;
    object-fit: cover; 
    object-position: top; 
    display: block;
}

.acme-persona-info {
    padding: 2.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.acme-flow-container {
    background: var(--card-white);
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid #eee;
    margin: 2rem 0;
    transition: transform 0.3s ease;
}

.acme-flow-container:hover {
    transform: translateY(-5px);
}

.acme-table-container { 
    overflow-x: auto; 
    margin-top: 1.5rem; 
    border-radius: 12px; 
    border: 1px solid #eee; 
}

.acme-analysis-table { 
    width: 100%; 
    border-collapse: collapse; 
    background: #fff; 
    text-align: left; 
}

.acme-analysis-table th, 
.acme-analysis-table td { 
    padding: 1.2rem; 
    border-bottom: 1px solid #eee; 
}

.acme-analysis-table th { 
    background: var(--card-white); 
    font-weight: 700; 
    font-size: 0.85rem; 
}

.acme-check { color: var(--status-positive); font-weight: bold; text-align: center; }
.acme-cross { color: var(--status-negative); font-weight: bold; text-align: center; }

.acme-visual-grid { 
    display: grid; 
    grid-template-columns: 1fr 1fr; 
    gap: 2rem; 
}

.acme-img-wrapper { 
    width: 100%; 
    height: 450px; 
    overflow: hidden; 
    border-radius: 12px; 
    background: #eee; 
    margin-bottom: 1.5rem; 
    cursor: pointer;
}

.acme-fit-img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
    object-position: top; 
    display: block; 
}

.acme-subtitle { margin: 2rem 0 1rem; font-size: 1.25rem; font-weight: 700; }
.acme-margin-v { margin: 3rem 0; }
.acme-label { font-size: 0.8rem; text-transform: uppercase; opacity: 0.6; }
.acme-result-value { font-size: 2.5rem; margin-top: 0.5rem; color: #333; }

.acme-result-card {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 250px;
    transition: transform 0.3s ease, border-color 0.3s ease;
    background: var(--card-white);
}

.acme-result-card:hover {
    transform: translateY(-5px);
    border-color: #333;
    background: #fff;
}

.acme-result-card p {
    font-size: 0.9rem;
    color: #555;
    line-height: 1.4;
}

/* --- DUCT Gallery Layout Fix --- */

/* Ensure the main page container hosting the gallery expands fully */
.duct-page-container, 
.gallery-wrapper {
    max-width: 1450px;
    margin: 0 auto;
    padding: 0 20px;
}

.duct-gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 25px;
    width: 100%;
    margin-top: 3rem;
    padding-bottom: 5rem;
    align-items: start;
}

.duct-gallery-card {
    width: 100%;
    box-sizing: border-box;
    background-color: var(--card-white, #ffffff);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}
/* ==========================================================================
   MASTER MOBILE RESPONSIVE BLOCK (MAX-WIDTH: 768px)
   ========================================================================== */

@media (max-width: 768px) {
    body {
        padding: 20px 15px 120px 15px;
    }

    .grid-container,
    .about-page-container {
        display: flex;
        flex-direction: column;
        grid-template-areas: none;
        gap: 15px;
        margin: 20px auto;
    }

    .card-intro { padding: 25px; }
    .intro-content {
        flex-direction: column-reverse;
        text-align: center;
        gap: 20px;
    }
    .intro-image img { width: 150px; height: 150px; }
    .intro-text h1 { font-size: 32px; }

    .pill-nav {
        width: 95%;
        bottom: 15px;
        padding: 4px;
        justify-content: space-around;
    }
    .nav-link {
        padding: 12px 10px;
        font-size: 12px;
        min-width: 65px;
    }

    .project-header-card { padding: 25px; text-align: center; }
    
    .project-preview-layout {
        flex-direction: column;
        padding: 20px;
    }
    .project-preview-large, .project-info { width: 100%; }

    .secondary-projects-grid {
        grid-template-columns: 1fr;
    }

    .contact-container, 
    .social-grid, 
    .input-row {
        grid-template-columns: 1fr;
        flex-direction: column;
    }
    .hero-card, .form-card, .resume-card { grid-column: span 1; padding: 25px; }
    .hero-card h1 { font-size: 30px; }

    .accessibility-toggle {
        top: 10px;
        right: 10px;
        padding: 8px 12px;
        font-size: 11px;
    }

    .duct-gallery-grid {
        grid-template-columns: 1fr;
    }
    
}