/* ============================================
   David's Tire Shop - Styles
   ============================================ */

:root {
    /* Blue color palette - deep, bold, professional */
    --blue-50: #e6f0ff;
    --blue-100: #b3d1ff;
    --blue-200: #80b3ff;
    --blue-300: #4d94ff;
    --blue-400: #1a75ff;
    --blue-500: #0052cc;
    --blue-600: #003d99;
    --blue-700: #002966;
    --blue-800: #001a4d;
    --blue-900: #000d26;
    --blue-950: #000714;

    /* Primary colors */
    --primary: #0066ff;
    --primary-dark: #0052cc;
    --primary-light: #3385ff;
    
    /* Accent - warm yellow/orange for contrast */
    --accent: #ffc107;
    --accent-dark: #e6ac00;
    
    /* Neutrals */
    --white: #ffffff;
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --gray-900: #0f172a;
    
    /* Typography */
    --font-display: 'Bebas Neue', sans-serif;
    --font-body: 'DM Sans', sans-serif;
    
    /* Spacing */
    --container-width: 1200px;
    --section-padding: 100px;
    
    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition-base: 0.3s ease;
    --transition-slow: 0.5s ease;
}

/* ============================================
   Reset & Base
   ============================================ */

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    color: var(--gray-800);
    background: var(--white);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img {
    max-width: 100%;
    height: auto;
}

a {
    color: inherit;
    text-decoration: none;
}

ul, ol {
    list-style: none;
}

/* ============================================
   Container
   ============================================ */

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

/* ============================================
   Typography
   ============================================ */

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-display);
    font-weight: 400;
    line-height: 1.1;
    letter-spacing: 0.02em;
}

.section-tag {
    display: inline-block;
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--primary);
    margin-bottom: 12px;
}

.section-title {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    color: var(--blue-900);
    margin-bottom: 16px;
}

.section-desc {
    font-size: 1.125rem;
    color: var(--gray-600);
    max-width: 600px;
}

.section-header {
    text-align: center;
    margin-bottom: 64px;
}

.section-header .section-desc {
    margin: 0 auto;
}

/* ============================================
   Buttons
   ============================================ */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 16px 32px;
    font-family: var(--font-body);
    font-size: 1rem;
    font-weight: 600;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    transition: all var(--transition-base);
}

.btn-primary {
    background: var(--primary);
    color: var(--white);
    box-shadow: 0 4px 14px rgba(0, 102, 255, 0.35);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 102, 255, 0.45);
}

.btn-secondary {
    background: var(--white);
    color: var(--blue-800);
    border: 2px solid var(--blue-200);
}

.btn-secondary:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.btn-full {
    width: 100%;
}

/* ============================================
   Navigation
   ============================================ */

.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 20px 0;
    transition: all var(--transition-base);
}

.nav.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    padding: 12px 0;
}

.nav-container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-display);
    font-size: 1.5rem;
    color: var(--blue-900);
    letter-spacing: 0.02em;
}

.logo-icon {
    color: var(--primary);
    font-size: 1.75rem;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 32px;
}

.nav-links a {
    font-weight: 500;
    color: var(--gray-700);
    transition: color var(--transition-fast);
}

.nav-links a:hover {
    color: var(--primary);
}

.nav-cta {
    background: var(--primary);
    color: var(--white) !important;
    padding: 12px 24px;
    border-radius: 6px;
}

.nav-cta:hover {
    background: var(--primary-dark);
    color: var(--white) !important;
}

.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    padding: 8px;
    background: none;
    border: none;
    cursor: pointer;
}

.mobile-menu-btn span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--gray-800);
    transition: all var(--transition-base);
}

.mobile-menu-btn.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.mobile-menu-btn.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-btn.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* ============================================
   Hero Section
   ============================================ */

.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 120px 0 80px;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--blue-50) 0%, var(--white) 50%, var(--blue-50) 100%);
    z-index: -2;
}

.tire-pattern {
    position: absolute;
    top: 50%;
    right: -10%;
    width: 800px;
    height: 800px;
    background: 
        repeating-radial-gradient(
            circle at center,
            transparent 0,
            transparent 20px,
            var(--blue-100) 20px,
            var(--blue-100) 22px
        );
    border-radius: 50%;
    transform: translateY(-50%);
    opacity: 0.5;
}

.hero-content {
    position: relative;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
    z-index: 1;
}

.hero-tagline {
    display: inline-block;
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--primary);
    margin-bottom: 24px;
    animation: fadeInUp 0.6s ease forwards;
}

.hero-title {
    font-size: clamp(3rem, 8vw, 5.5rem);
    color: var(--blue-900);
    margin-bottom: 24px;
    animation: fadeInUp 0.6s ease 0.1s forwards;
    opacity: 0;
}

.hero-title .highlight {
    color: var(--primary);
}

.hero-description {
    font-size: 1.25rem;
    color: var(--gray-600);
    max-width: 540px;
    margin-bottom: 40px;
    animation: fadeInUp 0.6s ease 0.2s forwards;
    opacity: 0;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 64px;
    animation: fadeInUp 0.6s ease 0.3s forwards;
    opacity: 0;
}

.hero-stats {
    display: flex;
    align-items: center;
    gap: 32px;
    animation: fadeInUp 0.6s ease 0.4s forwards;
    opacity: 0;
}

.stat {
    display: flex;
    flex-direction: column;
}

.stat-number {
    font-family: var(--font-display);
    font-size: 2.5rem;
    color: var(--blue-900);
    letter-spacing: 0.02em;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--gray-500);
}

.stat-divider {
    width: 1px;
    height: 40px;
    background: var(--gray-300);
}

/* Tire illustration */
.hero-visual {
    position: absolute;
    right: 5%;
    top: 50%;
    transform: translateY(-50%);
    z-index: 0;
    display: none;
}

.tire-illustration {
    width: 400px;
    height: 400px;
}

.tire-outer {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--gray-800) 0%, var(--gray-900) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 
        inset 0 0 60px rgba(0, 0, 0, 0.5),
        0 20px 60px rgba(0, 0, 0, 0.3);
    animation: tireSpin 20s linear infinite;
}

.tire-inner {
    width: 70%;
    height: 70%;
    background: linear-gradient(135deg, var(--gray-700) 0%, var(--gray-800) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 0 30px rgba(0, 0, 0, 0.4);
}

.tire-center {
    width: 40%;
    height: 40%;
    background: linear-gradient(135deg, var(--gray-400) 0%, var(--gray-500) 100%);
    border-radius: 50%;
    position: relative;
    box-shadow: 
        inset 0 2px 10px rgba(255, 255, 255, 0.2),
        0 4px 20px rgba(0, 0, 0, 0.3);
}

.lug {
    position: absolute;
    width: 12px;
    height: 12px;
    background: var(--gray-600);
    border-radius: 50%;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.3);
}

.lug:nth-child(1) { top: 10%; left: 50%; transform: translateX(-50%); }
.lug:nth-child(2) { top: 35%; right: 8%; }
.lug:nth-child(3) { bottom: 15%; right: 20%; }
.lug:nth-child(4) { bottom: 15%; left: 20%; }
.lug:nth-child(5) { top: 35%; left: 8%; }

@keyframes tireSpin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================================
   Services Section
   ============================================ */

.services {
    padding: var(--section-padding) 0;
    background: var(--white);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 32px;
}

.service-card {
    position: relative;
    padding: 40px;
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: 16px;
    transition: all var(--transition-base);
    opacity: 0;
    transform: translateY(30px);
}

.service-card.animate-in {
    opacity: 1;
    transform: translateY(0);
}

.service-card:hover {
    border-color: var(--primary);
    box-shadow: 0 20px 40px rgba(0, 102, 255, 0.1);
    transform: translateY(-5px);
}

.service-card.animate-in:hover {
    transform: translateY(-5px);
}

.service-card.featured {
    background: linear-gradient(135deg, var(--blue-600) 0%, var(--blue-800) 100%);
    border: none;
    color: var(--white);
}

.service-card.featured:hover {
    box-shadow: 0 20px 40px rgba(0, 82, 204, 0.3);
}

.featured-badge {
    position: absolute;
    top: -12px;
    left: 24px;
    padding: 6px 16px;
    background: var(--accent);
    color: var(--gray-900);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-radius: 4px;
}

.service-icon {
    margin-bottom: 24px;
    color: var(--primary);
}

.service-card.featured .service-icon {
    color: var(--blue-200);
}

.service-card h3 {
    font-size: 1.75rem;
    margin-bottom: 16px;
}

.service-card p {
    color: var(--gray-600);
    margin-bottom: 24px;
}

.service-card.featured p {
    color: var(--blue-200);
}

.service-price {
    display: inline-block;
    font-weight: 600;
    color: var(--primary);
}

.service-card.featured .service-price {
    color: var(--accent);
}

/* Specialty service card - for rare/hard-to-find services */
.service-card.specialty {
    background: linear-gradient(135deg, #065f46 0%, #064e3b 100%);
    border: none;
    color: var(--white);
}

.service-card.specialty:hover {
    box-shadow: 0 20px 40px rgba(6, 95, 70, 0.3);
}

.service-card.specialty .service-icon {
    color: #6ee7b7;
}

.service-card.specialty p {
    color: #a7f3d0;
}

.service-card.specialty .service-price {
    color: #6ee7b7;
}

.specialty-badge {
    background: #10b981 !important;
    color: var(--white) !important;
}

/* Used tires inventory card */
.service-card.inventory {
    background: linear-gradient(135deg, #b45309 0%, #92400e 100%);
    border: none;
    color: var(--white);
}

.service-card.inventory:hover {
    box-shadow: 0 20px 40px rgba(180, 83, 9, 0.3);
}

.service-card.inventory .service-icon {
    color: #fcd34d;
}

.service-card.inventory p {
    color: #fde68a;
}

.service-card.inventory .service-price {
    color: #fcd34d;
}

.inventory-badge {
    background: #f59e0b !important;
    color: var(--gray-900) !important;
}

/* ============================================
   How It Works Section
   ============================================ */

.how-it-works {
    padding: var(--section-padding) 0;
    background: var(--blue-900);
    color: var(--white);
}

.how-it-works .section-tag {
    color: var(--blue-300);
}

.how-it-works .section-title {
    color: var(--white);
}

.steps {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
    align-items: start;
}

.step {
    position: relative;
    text-align: center;
    padding: 0 24px;
    opacity: 0;
    transform: translateY(30px);
}

.step.animate-in {
    opacity: 1;
    transform: translateY(0);
}

.step-number {
    font-family: var(--font-display);
    font-size: 4rem;
    color: var(--blue-400);
    margin-bottom: 24px;
    opacity: 0.6;
}

.step-content h3 {
    font-size: 1.5rem;
    margin-bottom: 12px;
}

.step-content p {
    color: var(--blue-300);
    font-size: 0.9375rem;
}

.step-connector {
    display: none;
}

/* ============================================
   About Section
   ============================================ */

.about {
    padding: var(--section-padding) 0;
    background: var(--gray-50);
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.about-image {
    position: relative;
}

/* Building illustration */
.building-illustration {
    position: relative;
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
}

.building {
    position: relative;
}

.building-roof {
    width: 100%;
    height: 40px;
    background: linear-gradient(135deg, var(--blue-700) 0%, var(--blue-800) 100%);
    clip-path: polygon(0 100%, 10% 0, 90% 0, 100% 100%);
}

.building-body {
    position: relative;
    width: 100%;
    height: 200px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--blue-600) 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    padding-bottom: 20px;
    box-shadow: 
        inset 0 0 60px rgba(0, 0, 0, 0.1),
        0 20px 60px rgba(0, 102, 255, 0.2);
}

.shop-sign {
    position: absolute;
    top: 20px;
    font-family: var(--font-display);
    font-size: 2rem;
    color: var(--white);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
    letter-spacing: 0.1em;
}

.garage-door {
    width: 70%;
    height: 120px;
    background: linear-gradient(180deg, var(--gray-300) 0%, var(--gray-400) 100%);
    border-radius: 4px 4px 0 0;
    position: relative;
    overflow: hidden;
}

.door-lines {
    position: absolute;
    inset: 0;
    background: 
        repeating-linear-gradient(
            180deg,
            transparent 0,
            transparent 28px,
            var(--gray-500) 28px,
            var(--gray-500) 30px
        );
}

.building-ground {
    width: 120%;
    height: 30px;
    background: var(--gray-400);
    margin-left: -10%;
    border-radius: 4px;
}

.about-content p {
    color: var(--gray-600);
    margin-bottom: 16px;
}

.about-features {
    margin-top: 32px;
}

.about-features li {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    font-weight: 500;
    color: var(--gray-800);
    border-bottom: 1px solid var(--gray-200);
    opacity: 0;
    transform: translateX(-20px);
}

.about-features li.animate-in {
    opacity: 1;
    transform: translateX(0);
}

.about-features li:last-child {
    border-bottom: none;
}

.about-features svg {
    color: var(--primary);
    flex-shrink: 0;
}

/* ============================================
   Contact Section
   ============================================ */

.contact {
    padding: var(--section-padding) 0;
    background: var(--white);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: start;
}

.contact-details {
    margin-top: 40px;
}

.contact-item {
    display: flex;
    gap: 20px;
    padding: 24px 0;
    border-bottom: 1px solid var(--gray-200);
    opacity: 0;
    transform: translateY(20px);
}

.contact-item.animate-in {
    opacity: 1;
    transform: translateY(0);
}

.contact-item:last-child {
    border-bottom: none;
}

.contact-icon {
    width: 48px;
    height: 48px;
    background: var(--blue-50);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    flex-shrink: 0;
}

.contact-item h4 {
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--gray-500);
    margin-bottom: 4px;
}

.contact-item p {
    color: var(--gray-800);
}

.contact-item a {
    color: var(--gray-800);
    transition: color var(--transition-fast);
}

.contact-item a:hover {
    color: var(--primary);
}

.link {
    display: inline-block;
    margin-top: 8px;
    font-weight: 600;
    color: var(--primary) !important;
}

.contact-card {
    background: linear-gradient(135deg, var(--blue-50) 0%, var(--blue-100) 100%);
    border-radius: 20px;
    padding: 40px;
    border: 1px solid var(--blue-200);
}

.contact-card-header {
    margin-bottom: 24px;
}

.contact-card-header h3 {
    font-size: 1.75rem;
    color: var(--blue-900);
    margin-bottom: 8px;
}

.contact-card-header p {
    color: var(--gray-600);
}

.shipping-address {
    background: var(--white);
    padding: 24px;
    border-radius: 12px;
    margin-bottom: 20px;
    border: 2px dashed var(--blue-300);
}

.shipping-address p {
    color: var(--gray-700);
    line-height: 1.8;
}

.contact-note {
    font-size: 0.875rem;
    color: var(--gray-600);
    margin-bottom: 24px;
    padding: 16px;
    background: var(--white);
    border-radius: 8px;
}

/* ============================================
   Footer
   ============================================ */

.footer {
    background: var(--blue-950);
    color: var(--white);
    padding: 60px 0 30px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding-bottom: 40px;
    border-bottom: 1px solid var(--blue-800);
}

.footer-brand .logo {
    color: var(--white);
    margin-bottom: 16px;
}

.footer-brand p {
    color: var(--blue-400);
    max-width: 280px;
}

.footer-links {
    display: flex;
    gap: 32px;
}

.footer-links a {
    color: var(--blue-300);
    transition: color var(--transition-fast);
}

.footer-links a:hover {
    color: var(--white);
}

.footer-bottom {
    padding-top: 30px;
    text-align: center;
}

.footer-bottom p {
    color: var(--blue-500);
    font-size: 0.875rem;
}

.footer-bottom .credit {
    font-size: 0.75rem;
    color: var(--blue-600);
    margin-top: 12px;
}

.footer-bottom .credit a {
    color: var(--blue-400);
    transition: color var(--transition-fast);
}

.footer-bottom .credit a:hover {
    color: var(--white);
}

/* ============================================
   Mobile Responsive
   ============================================ */

@media (min-width: 1200px) {
    .hero-visual {
        display: block;
    }
}

@media (max-width: 1024px) {
    .steps {
        grid-template-columns: repeat(2, 1fr);
        gap: 48px;
    }
    
    .about-grid,
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 48px;
    }
    
    .about-image {
        order: -1;
    }
}

@media (max-width: 768px) {
    :root {
        --section-padding: 60px;
    }
    
    .nav-links {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background: var(--white);
        flex-direction: column;
        padding: 24px;
        gap: 16px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: all var(--transition-base);
    }
    
    .nav-links.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }
    
    .mobile-menu-btn {
        display: flex;
    }
    
    .hero-title {
        font-size: clamp(2.5rem, 10vw, 4rem);
    }
    
    .hero-stats {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
    
    .stat-divider {
        display: none;
    }
    
    .steps {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .step {
        text-align: left;
        padding: 0;
        display: flex;
        gap: 24px;
    }
    
    .step-number {
        font-size: 2.5rem;
        margin-bottom: 0;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 32px;
    }
    
    .footer-links {
        flex-wrap: wrap;
        gap: 16px 24px;
    }
}

@media (max-width: 480px) {
    .hero-actions {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .service-card {
        padding: 32px 24px;
    }
}

/* ============================================
   Animation Delays for Stagger Effect
   ============================================ */

.service-card:nth-child(1) { transition-delay: 0s; }
.service-card:nth-child(2) { transition-delay: 0.1s; }
.service-card:nth-child(3) { transition-delay: 0.2s; }
.service-card:nth-child(4) { transition-delay: 0.3s; }
.service-card:nth-child(5) { transition-delay: 0.4s; }
.service-card:nth-child(6) { transition-delay: 0.5s; }

.step:nth-child(1) { transition-delay: 0s; }
.step:nth-child(3) { transition-delay: 0.1s; }
.step:nth-child(5) { transition-delay: 0.2s; }
.step:nth-child(7) { transition-delay: 0.3s; }

.contact-item:nth-child(1) { transition-delay: 0s; }
.contact-item:nth-child(2) { transition-delay: 0.1s; }
.contact-item:nth-child(3) { transition-delay: 0.2s; }

.about-features li:nth-child(1) { transition-delay: 0s; }
.about-features li:nth-child(2) { transition-delay: 0.1s; }
.about-features li:nth-child(3) { transition-delay: 0.2s; }
.about-features li:nth-child(4) { transition-delay: 0.3s; }

