/*
Theme Name: GM Cluster Flash
Theme URI: https://gmclusterflash.com
Author: White Automotive & Media Services
Author URI: https://www.whiteautoandmedia.com
Description: Custom one-page theme for gmclusterflash.com — GM instrument cluster programming, coding, flashing, calibration, and digital cluster upgrade services. All products link to whiteautoandmedia.com.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: gmclusterflash
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
*/

/* ============================================
   RESET & BASE
   ============================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --primary: #c0392b;
    --primary-light: #e74c3c;
    --primary-dark: #962d22;
    --primary-btn: #c0392b;
    --accent: #f39c12;
    --dark: #111111;
    --dark-mid: #1a1a1a;
    --gray-900: #222222;
    --gray-800: #333333;
    --gray-600: #555555;
    --gray-400: #999999;
    --gray-200: #d0d0d0;
    --gray-100: #f0f0f0;
    --white: #ffffff;
    --max-width: 1100px;
}

html { scroll-behavior: smooth; }

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    color: var(--gray-800);
    background: var(--white);
    line-height: 1.7;
    font-size: 17px;
    -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--primary); text-decoration: underline; transition: color 0.2s; }
a:hover { color: var(--primary-dark); }
.logo, .site-nav a, .btn-primary, .card-link, .footer-links a { text-decoration: none; }

.container { max-width: var(--max-width); margin: 0 auto; padding: 0 24px; }

/* --- HEADER --- */
.site-header {
    background: var(--dark);
    padding: 16px 0;
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 3px solid var(--primary-light);
}
.site-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}
.logo { color: var(--white); font-size: 20px; font-weight: 700; letter-spacing: -0.5px; text-decoration: none; }
.logo:hover { color: var(--white); }
.logo span { color: var(--primary-light); }
.logo-sub { color: var(--gray-400); font-size: 12px; font-weight: 400; display: block; letter-spacing: 0.5px; }
.site-nav a {
    color: var(--gray-200);
    font-size: 14px;
    font-weight: 500;
    margin-left: 24px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.site-nav a:hover { color: var(--white); }

/* --- HERO --- */
.hero {
    background: linear-gradient(135deg, var(--dark) 0%, var(--dark-mid) 50%, var(--gray-900) 100%);
    color: var(--white);
    padding: 80px 0 72px;
    text-align: center;
}
.hero h1 {
    font-size: clamp(28px, 5vw, 48px);
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 20px;
    letter-spacing: -1px;
}
.hero h1 em { color: var(--primary-light); font-style: normal; }
.hero > .container > p { font-size: 19px; color: #cccccc; max-width: 700px; margin: 0 auto 36px; line-height: 1.6; }
.hero-badges { display: flex; justify-content: center; flex-wrap: wrap; gap: 16px; margin-bottom: 36px; }
.hero-badge {
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 50px;
    padding: 8px 20px;
    font-size: 14px;
    color: #dddddd;
    font-weight: 500;
}
.btn-primary {
    display: inline-block;
    background: var(--primary-btn);
    color: var(--white);
    padding: 16px 40px;
    border-radius: 8px;
    font-size: 17px;
    font-weight: 600;
    transition: background 0.2s, transform 0.2s;
}
.btn-primary:hover { background: var(--primary-dark); color: var(--white); transform: translateY(-1px); }

/* --- TRUST BAR --- */
.trust-bar {
    background: var(--dark);
    border-top: 1px solid rgba(255,255,255,0.08);
    padding: 20px 0;
}
.trust-items { display: flex; justify-content: center; flex-wrap: wrap; gap: 32px; }
.trust-item {
    font-size: 14px;
    font-weight: 600;
    color: #bbbbbb;
    display: flex;
    align-items: center;
    gap: 8px;
}
.trust-item svg { flex-shrink: 0; }

/* --- SECTIONS --- */
.light-section { padding: 64px 0; background: var(--white); }
.dark-section { padding: 64px 0; background: var(--gray-100); }

.section-label {
    text-transform: uppercase;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--primary);
    margin-bottom: 8px;
}
.section-title {
    font-size: clamp(24px, 4vw, 36px);
    font-weight: 800;
    color: var(--dark);
    margin-bottom: 16px;
    letter-spacing: -0.5px;
    line-height: 1.2;
}
.section-desc {
    font-size: 17px;
    color: var(--gray-600);
    max-width: 720px;
    margin-bottom: 40px;
    line-height: 1.7;
}

/* --- PRODUCT CARDS --- */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
    gap: 20px;
}
.product-card {
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: 10px;
    padding: 24px;
    transition: box-shadow 0.25s, transform 0.25s;
    display: flex;
    flex-direction: column;
}
.product-card:hover { box-shadow: 0 6px 24px rgba(0,0,0,0.1); transform: translateY(-2px); }
.product-card h3 { font-size: 16px; font-weight: 700; color: var(--dark); margin-bottom: 8px; line-height: 1.35; }
.product-card .price { font-size: 20px; font-weight: 800; color: var(--primary); margin-bottom: 12px; }
.product-card .price .sale-original { font-size: 14px; color: var(--gray-600); text-decoration: line-through; font-weight: 400; margin-right: 6px; }
.card-link {
    display: inline-block;
    background: var(--dark);
    color: var(--white);
    padding: 10px 20px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    transition: background 0.2s;
    text-align: center;
    margin-top: auto;
}
.card-link:hover { background: var(--primary-btn); color: var(--white); }

/* --- CATEGORY HEADERS --- */
.category-header {
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--primary-light);
}
.category-header h2 { font-size: 24px; font-weight: 800; color: var(--dark); margin-bottom: 8px; }
.category-header p { font-size: 15px; color: var(--gray-600); max-width: 700px; }

/* --- VEHICLE GRID --- */
.vehicle-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin-top: 32px;
}
.vehicle-card { background: var(--white); border: 1px solid var(--gray-200); border-radius: 8px; padding: 20px; }
.vehicle-card h3 { font-size: 16px; font-weight: 700; color: var(--dark); margin-bottom: 8px; }
.vehicle-card ul { list-style: none; font-size: 14px; color: var(--gray-600); }
.vehicle-card li { padding: 3px 0; }

/* --- WHY / PROCESS SECTION --- */
.why-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 24px; }
.why-item { text-align: center; padding: 24px; }
.why-icon {
    width: 56px; height: 56px;
    background: rgba(192,57,43,0.1);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 16px;
}
.why-item h3 { font-size: 18px; font-weight: 700; margin-bottom: 8px; color: var(--dark); }
.why-item p { font-size: 15px; color: var(--gray-600); }

/* --- PROCESS STEPS --- */
.process-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 24px; counter-reset: step; }
.process-step { text-align: center; padding: 24px; position: relative; }
.process-step::before {
    counter-increment: step;
    content: counter(step);
    display: flex; align-items: center; justify-content: center;
    width: 48px; height: 48px;
    background: var(--primary);
    color: var(--white);
    border-radius: 50%;
    font-size: 20px; font-weight: 800;
    margin: 0 auto 16px;
}
.process-step h3 { font-size: 16px; font-weight: 700; color: var(--dark); margin-bottom: 8px; }
.process-step p { font-size: 14px; color: var(--gray-600); }

/* --- FAQ --- */
.faq-list { max-width: 800px; }
.faq-item { border-bottom: 1px solid var(--gray-200); padding: 24px 0; }
.faq-item:first-child { border-top: 1px solid var(--gray-200); }
.faq-q {
    font-size: 18px; font-weight: 700; color: var(--dark);
    cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px;
    background: none; border: none; width: 100%; text-align: left; padding: 0; font-family: inherit;
}
.faq-q::after { content: '+'; font-size: 24px; font-weight: 300; color: var(--gray-400); flex-shrink: 0; transition: transform 0.3s; }
.faq-item.open .faq-q::after { content: '\2212'; }
.faq-a { max-height: 0; overflow: hidden; transition: max-height 0.35s ease, padding 0.35s ease; }
.faq-item.open .faq-a { max-height: 500px; padding-top: 12px; }
.faq-a p { font-size: 16px; color: var(--gray-600); line-height: 1.7; }

/* --- CTA BANNER --- */
.cta-banner {
    background: linear-gradient(135deg, var(--dark) 0%, var(--gray-900) 100%);
    color: var(--white);
    padding: 64px 0;
    text-align: center;
}
.cta-banner h2 { font-size: clamp(24px, 4vw, 36px); font-weight: 800; margin-bottom: 12px; }
.cta-banner p { font-size: 17px; color: #bbbbbb; margin-bottom: 28px; }

/* --- FOOTER --- */
.site-footer {
    background: var(--dark);
    color: #aaaaaa;
    padding: 40px 0 24px;
    font-size: 14px;
    border-top: 3px solid var(--primary-light);
}
.footer-content { display: flex; justify-content: space-between; align-items: start; flex-wrap: wrap; gap: 32px; margin-bottom: 32px; }
.footer-brand p { max-width: 320px; line-height: 1.6; }
.footer-links a { display: block; color: #aaaaaa; padding: 4px 0; }
.footer-links a:hover { color: var(--white); }
.footer-links h3 { color: var(--white); font-size: 14px; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 12px; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.1); padding-top: 20px; text-align: center; font-size: 13px; }

/* --- RESPONSIVE --- */
@media (max-width: 768px) {
    .hero { padding: 56px 0 48px; }
    .light-section, .dark-section { padding: 48px 0; }
    .site-nav a { margin-left: 16px; font-size: 13px; }
    .product-grid { grid-template-columns: 1fr; }
    .process-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 480px) {
    .site-header .container { justify-content: center; text-align: center; }
    .site-nav { width: 100%; display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; }
    .site-nav a { margin-left: 0; }
    .process-grid { grid-template-columns: 1fr; }
}