/* --- 1. BRAND "BRAIN" (VARIABLES) --- */
:root {
    --sparco-yellow: #fef31d;
    --sparco-blue: #223dfe;
    --sparco-blue-dark: #001ba3;
    --sparco-white: #fefdfe;
    --text-dark: #1a1a1a;
    --text-muted: #444;
}

/* --- 2. UNIVERSAL RESET & PERFORMANCE --- */
* { 
    margin: 0; 
    padding: 0; 
    box-sizing: border-box; 
    -webkit-tap-highlight-color: transparent; /* Fixes mobile blue tap box */
}

html { 
    scroll-behavior: smooth; 
    -webkit-text-size-adjust: 100%; 
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--sparco-yellow);
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
    /* Professional Graphic Design Rendering */
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* THE CENTERING ENGINE */
.container {
    max-width: 1200px;
    margin-left: auto !important;
    margin-right: auto !important;
    padding: 0 20px;
    width: 100%;
}

/* --- 3. NAVIGATION (PERFECTLY FLUSH LOGO) --- */
header.site-nav {
    background-color: var(--sparco-blue);
    width: 100%;
    position: -webkit-sticky;
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 0 !important; /* Forces logo to touch top and bottom edges */
}

.header-flex {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-pack: justify;
    -ms-flex-pack: justify;
    justify-content: space-between;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center; 
}

.logo-main {
    width: 280px; /* Controls the height of the entire nav bar */
    height: auto;
    display: block !important; /* Removes the text-descender gap at bottom */
    margin: 0 !important;
    padding: 0 !important;
}

/* Desktop Menu Links */
.desktop-nav {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    gap: 25px;
}

.desktop-nav a {
    text-decoration: none;
    color: var(--sparco-white);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 18px;
    -webkit-transition: 0.3s;
    transition: 0.3s;
}

.desktop-nav a:hover { color: var(--sparco-yellow); }

/* Mobile Hamburger */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 32px;
    cursor: pointer;
}

/* --- 4. MOBILE SIDEBAR (NO PEEKING & CROSS-BROWSER) --- */
.side-drawer {
    position: fixed;
    top: 0;
    left: 0;
    width: 300px;
    height: 100vh;
    background-color: var(--sparco-blue);
    z-index: 10000;
    padding: 40px 30px;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
    -ms-flex-direction: column;
    flex-direction: column;
    
    /* Hardware acceleration for mobile */
    -webkit-transform: translateX(-105%);
    -ms-transform: translateX(-105%);
    transform: translateX(-105%); 
    
    visibility: hidden;
    -webkit-transition: -webkit-transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), visibility 0.4s;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), visibility 0.4s;
}

.side-drawer.active {
    -webkit-transform: translateX(0);
    -ms-transform: translateX(0);
    transform: translateX(0);
    visibility: visible;
    box-shadow: 10px 0 30px rgba(0,0,0,0.5);
}

.side-drawer a {
    color: white;
    text-decoration: none;
    font-size: 18px;
    font-weight: 700;
    padding: 15px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.drawer-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.8);
    z-index: 9998;
    display: none;
}

.drawer-overlay.active { display: block; }

.mobile-nav-header {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-pack: justify;
    -ms-flex-pack: justify;
    justify-content: space-between;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    margin-bottom: 30px;
}

/* --- 5. HERO & VIDEO --- */
.hero-white {
    background-color: var(--sparco-white);
    padding: 80px 0;
    border-bottom: 1px solid #ddd;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
}

.hero-text h1 { font-size: 3.5rem; line-height: 1.1; color: var(--sparco-blue); margin-bottom: 20px; }

.hero-text p { font-size: 1.1rem; color: var(--text-muted); margin-bottom: 20px; }

.hero-video-container {
    width: 100%;
    border-radius: 8px;
    box-shadow: 15px 15px 0 var(--sparco-blue);
    overflow: hidden;
    background: #000;
    line-height: 0;
}

.hero-video-container video { width: 100%; height: auto; display: block; }

/* --- 6. INDEX: BRAND PORTFOLIO GRIDS --- */
.brand-grid { display: grid !important; gap: 15px; margin: 30px 0; }

.grid-passenger { grid-template-columns: repeat(3, 1fr) !important; } /* 3x2 Grid */
.grid-truck { grid-template-columns: repeat(4, 1fr) !important; }     /* 4x1 Grid */

.brand-item {
    background: var(--sparco-white);
    height: 110px;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

.brand-item img { max-width: 100%; max-height: 85px; object-fit: contain; }

/* --- 7. CAREERS: DIVIDERS & BENEFITS --- */
.career-banner {
    background-color: var(--sparco-white);
    padding: 80px 20px;
    text-align: center;
    border-bottom: 15px solid var(--sparco-blue);
}

.title-divider {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    margin: 80px 0 40px;
}

.title-divider .line {
    -webkit-box-flex: 1;
    -ms-flex-positive: 1;
    flex-grow: 1;
    height: 2px;
    background: -webkit-gradient(linear, left top, right top, from(transparent), color-stop(var(--sparco-blue)), to(transparent));
    background: linear-gradient(to right, transparent, var(--sparco-blue), transparent);
    opacity: 0.3;
}

.title-divider h2 { margin: 0 30px; font-size: 2.8rem; font-weight: 900; text-transform: uppercase; }

.status-box {
    background: linear-gradient(135deg, var(--sparco-blue) 0%, var(--sparco-blue-dark) 100%);
    color: white; padding: 30px; text-align: center; border-radius: 12px; margin-bottom: 60px;
    box-shadow: 0 10px 30px rgba(34, 61, 254, 0.2);
}

.benefits-section { background: var(--sparco-white); padding: 80px 40px; border-radius: 24px; margin-bottom: 80px; }

.benefits-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 30px; margin-top: 50px; }

.benefit-card { background: #fdfdfd; padding: 40px; border-radius: 16px; border: 1px solid #eee; -webkit-transition: 0.3s; transition: 0.3s; }

.benefit-card:hover { 
    -webkit-transform: translateY(-10px); 
    -ms-transform: translateY(-10px); 
    transform: translateY(-10px); 
    border-color: var(--sparco-blue); 
    box-shadow: 0 15px 40px rgba(0,0,0,0.1); 
}

.benefit-card i { font-size: 2rem; color: var(--sparco-blue); margin-bottom: 15px; }

/* --- 8. AWESOME VACANCIES (ALIGNED BUTTONS) --- */
.job-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr)); 
    gap: 30px; 
    -webkit-box-align: stretch; 
    -ms-flex-align: stretch; 
    align-items: stretch; 
}

.job-card {
    background: var(--sparco-white);
    border-radius: 16px;
    padding: 40px;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
    -ms-flex-direction: column;
    flex-direction: column;
    position: relative;
    overflow: hidden;
    -webkit-transition: 0.4s;
    transition: 0.4s;
    border-top: 8px solid var(--sparco-blue);
    box-shadow: 0 10px 30px rgba(0,0,0,0.03);
}

.job-card:hover { 
    -webkit-transform: translateY(-10px); 
    -ms-transform: translateY(-10px); 
    transform: translateY(-10px); 
    box-shadow: 0 20px 40px rgba(34, 61, 254, 0.15); 
}

.job-card-content { -webkit-box-flex: 1; -ms-flex-positive: 1; flex-grow: 1; } /* Pushes button to bottom */

.job-card h3 { font-size: 1.75rem; font-weight: 800; color: var(--sparco-blue-dark); margin-bottom: 8px; }

.job-card ul { list-style: none; margin: 20px 0 30px 0; }
.job-card li { position: relative; padding-left: 28px; margin-bottom: 12px; font-size: 0.95rem; color: #555; }

.job-card li::before {
    content: "→";
    position: absolute;
    left: 0;
    color: var(--sparco-blue);
    font-weight: 900;
}

/* --- 9. BUTTONS & BACK TO TOP --- */
.btn-primary {
    display: -webkit-inline-box;
    display: -ms-inline-flexbox;
    display: inline-flex;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    background: var(--sparco-blue);
    color: white;
    padding: 14px 30px;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 700;
    text-transform: uppercase;
    -webkit-transition: 0.3s;
    transition: 0.3s;
    width: 100%;
}

.btn-primary:hover { background: var(--sparco-blue-dark); -webkit-transform: translateY(-2px); transform: translateY(-2px); }

#backToTop {
    position: fixed; bottom: 30px; right: 30px;
    width: 55px; height: 55px;
    background-color: var(--sparco-white);
    color: var(--sparco-blue);
    border-radius: 50%;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    font-size: 30px;
    cursor: pointer;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    z-index: 2000;
    visibility: hidden; opacity: 0;
    -webkit-transition: 0.4s;
    transition: 0.4s;
}
#backToTop.show { visibility: visible; opacity: 1; }

/* --- 10. BULLETPROOF FOOTER --- */
footer {
    background: var(--sparco-blue);
    color: var(--sparco-white);
    padding: 80px 0 40px;
    text-align: center;
    width: 100%;
}

.footer-row {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -ms-flex-wrap: wrap;
    flex-wrap: wrap;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    gap: 60px;
    margin-bottom: 40px;
}

.footer-block { flex: 1; min-width: 280px; max-width: 350px; text-align: left; }
.footer-block h2 { color: var(--sparco-yellow); font-size: 1.5rem; margin-bottom: 25px; text-transform: uppercase; }
.footer-icon { color: var(--sparco-yellow); width: 25px; margin-right: 12px; text-align: center; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.1); padding-top: 30px; margin-top: 20px; font-size: 0.9rem; opacity: 0.8; }

/* --- 11. RESPONSIVE QUERIES --- */
@media (max-width: 900px) {
    .desktop-nav { display: none !important; }
    .menu-toggle { display: block !important; }
    .logo-main { width: 180px !important; }
    .hero-grid { grid-template-columns: 1fr; }
    .grid-passenger, .grid-truck { grid-template-columns: repeat(2, 1fr) !important; }
    .footer-block { text-align: center; }
    .footer-block p { -webkit-box-pack: center; -ms-flex-pack: center; justify-content: center; }
}

@media (max-width: 600px) {
    .grid-passenger, .grid-truck { grid-template-columns: 1fr !important; }
    .hero-text h1 { font-size: 2.5rem; }
}

/* --- 12. COMPANY PROFILE SPECIFIC STYLES --- */
.profile-hero {
    background-size: cover;
    background-position: center;
    color: white;
    padding: 100px 0;
    text-align: center;
}

.content-section {
    background: var(--sparco-white);
    padding: 80px 0;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-top: 50px;
    text-align: center;
}

.stat-item h2 {
    font-size: 3rem;
    color: var(--sparco-blue);
    margin-bottom: 5px;
}

.values-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    margin-top: 60px;
}

.value-card {
    padding: 40px;
    border-left: 5px solid var(--sparco-blue);
    background: #f9f9f9;
    border-radius: 0 15px 15px 0;
}

.value-card i {
    font-size: 2.5rem;
    color: var(--sparco-blue);
    margin-bottom: 20px;
}

.profile-text {
    font-size: 1.15rem;
    line-height: 1.8;
    color: var(--text-muted);
    max-width: 900px;
    margin: 0 auto;
}


/* --- 13. CONTACT PAGE ENHANCEMENTS --- */
.branch-container {
    display: flex;
    flex-direction: column;
    gap: 40px;
    margin-bottom: 80px;
}

.branch-entry {
    display: grid;
    grid-template-columns: 1fr 300px;
    background: var(--sparco-white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    border: 1px solid #eee;
}

.branch-info { padding: 40px; }
.branch-info h2 { color: var(--sparco-blue); margin-bottom: 15px; font-size: 2rem; }

.map-link-container {
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.map-link-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: 0.5s;
}

.map-link-container:hover img { transform: scale(1.1); }

.map-overlay-btn {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    background: var(--sparco-blue);
    color: white;
    padding: 10px 20px;
    border-radius: 5px;
    font-weight: 700;
    pointer-events: none;
    opacity: 0.9;
}

/* Departments Grid */
.dept-section {
    background: var(--sparco-blue);
    color: white;
    padding: 80px 0;
}

.dept-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.dept-card {
    background: rgba(255,255,255,0.1);
    padding: 30px;
    border-radius: 10px;
    border-left: 4px solid var(--sparco-yellow);
}

.dept-card h3 { color: var(--sparco-yellow); margin-bottom: 15px; text-transform: uppercase; }
.dept-card p { margin-bottom: 5px; font-size: 0.95rem; }

/* Hours Table */
.hours-box {
    background: var(--sparco-white);
    padding: 40px;
    border-radius: 15px;
    margin-top: 60px;
    border: 2px dashed var(--sparco-blue);
}

@media (max-width: 768px) {
    .branch-entry { grid-template-columns: 1fr; }
    .map-link-container { height: 200px; }
}

/* --- 13. CONTACT PAGE MAPS & DEPT UPGRADES --- */
.map-widget {
    width: 100%;
    height: 300px;
    border: 0;
    display: block;
}

.branch-entry {
    display: grid;
    grid-template-columns: 1fr 450px; /* Wider map area */
    background: var(--sparco-white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    margin-bottom: 40px;
    border: 1px solid #eee;
}

/* Department Grid Improvements */
/* --- 13. IMPROVED DEPARTMENT CARDS --- */
.dept-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.dept-card {
    background: white;
    border-radius: 12px;
    padding: 40px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border-top: 6px solid var(--sparco-blue);
    display: flex;
    flex-direction: column;
    transition: 0.3s ease;
}

.dept-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.15);
}

.dept-card i {
    font-size: 2rem;
    color: var(--sparco-blue);
    margin-bottom: 15px;
}

.dept-card h3 {
    font-size: 1.4rem;
    color: var(--sparco-blue-dark);
    margin-bottom: 25px;
    border-bottom: 2px solid var(--sparco-yellow);
    padding-bottom: 10px;
    font-weight: 800;
}

/* The Context Labels (Direct Line, Sales Team, etc) */
.contact-group-label {
    font-size: 0.75rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #888;
    margin-bottom: 8px;
    display: block;
}

.contact-item {
    font-size: 1.1rem;
    color: var(--text-dark);
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.contact-item a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 700;
    transition: color 0.2s;
}

.contact-item a:hover {
    color: var(--sparco-blue);
}

.contact-item span.tel-label {
    font-weight: 400;
    color: #555;
    margin-right: 5px;
}

.dept-label {
    font-weight: 800;
    text-transform: uppercase;
    font-size: 0.75rem;
    color: #888;
    display: block;
    margin-top: 15px;
}

/* Operating Hours Style */
.hours-container {
    background: #f8f9fa;
    padding: 50px;
    border-radius: 15px;
    margin-top: 60px;
    border-left: 10px solid var(--sparco-blue);
}

@media (max-width: 992px) {
    .branch-entry { grid-template-columns: 1fr; }
    .map-widget { height: 250px; }
}


/* --- 14. PASSENGER CARS PAGE STYLES --- */
.product-intro-section {
    background: var(--sparco-white);
    padding: 80px 0;
}

.intro-content-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.logistics-box {
    background: var(--sparco-blue);
    color: white;
    padding: 40px;
    border-radius: 20px;
    border-bottom: 10px solid var(--sparco-yellow);
}

.brand-section-title {
    text-align: center;
    margin: 60px 0 40px;
    font-size: 2.5rem;
    color: var(--sparco-blue);
    text-transform: uppercase;
    font-weight: 800;
}

/* --- 14. BRAND LOGO CARDS (AS LINKS) --- */
.logo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 25px;
    margin-bottom: 80px;
}

/* We style the <a> tag as the card directly */
.logo-card {
    background: white;
    height: 180px;
    display: flex;             /* Centering engine */
    align-items: center;       /* Vertical center */
    justify-content: center;    /* Horizontal center */
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    border: 1px solid #eee;
    text-decoration: none;     /* Removes link underline */
    transition: all 0.3s ease;
}

/* Card Hover Effect */
.logo-card:hover {
    transform: translateY(-8px);
    border-color: var(--sparco-blue);
    box-shadow: 0 15px 35px rgba(34, 61, 254, 0.15);
}

.logo-card img {
    max-width: 100%;
    max-height: 100px;
    object-fit: contain;
    display: block;
}

