/* MyCar - Main Stylesheet */
/* Brand Colors: #FFE800 (Yellow) and #000000 (Black) */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;700;800;900&display=swap');

:root {
    --primary-color: #FFE800;
    --secondary-color: #000000;
    --text-dark: #1a1a1a;
    --text-light: #666666;
    --bg-light: #f5f5f5;
    --border-color: #e0e0e0;
    --white: #ffffff;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    font-size: 14px;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: #f8f8f8;
}

a {
    color: var(--secondary-color);
    text-decoration: none;
    transition: all 0.3s ease;
}

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

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

/* Header */
.header {
    background: var(--primary-color);
    color: var(--secondary-color);
    padding: 0;
}

.header-top {
    background: rgba(0,0,0,0.03);
    padding: 8px 0;
    font-size: 12px;
    color: var(--secondary-color);
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.header-top a {
    color: var(--secondary-color);
    font-weight: 400;
    transition: opacity 0.3s;
}

.header-top a:hover {
    opacity: 0.7;
}

.header-main {
    padding: 18px 0;
}

.logo {
    font-size: 28px;
    font-weight: 900;
    color: var(--secondary-color);
    text-transform: uppercase;
    letter-spacing: -0.5px;
    display: inline-block;
    transition: opacity 0.2s;
}

.logo:hover {
    opacity: 0.8;
}

/* Navigation */
.navbar {
    background: var(--white);
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.nav-menu {
    list-style: none;
    display: flex;
    align-items: center;
    padding: 0;
    margin: 0;
    gap: 8px;
}

.nav-menu li {
    margin: 0;
}

.nav-menu a {
    display: block;
    padding: 14px 20px;
    color: var(--text-dark);
    font-weight: 400;
    font-size: 14px;
    transition: all 0.3s;
    border-radius: 8px;
}

.nav-menu a:hover,
.nav-menu a.active {
    background: var(--primary-color);
    color: var(--secondary-color);
}

/* Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 15px;
}

.container-fluid {
    padding: 0 15px;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 700;
    text-align: center;
    border: 2px solid transparent;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
    gap: 8px;
}

.btn-primary {
    background: #2c3e50;
    color: var(--white);
    border-color: #2c3e50;
}

.btn-primary:hover {
    background: #1a252f;
    border-color: #1a252f;
    color: var(--white);
    box-shadow: 0 6px 20px rgba(44, 62, 80, 0.3);
}

.btn-secondary {
    background: var(--secondary-color);
    color: var(--white);
}

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

.btn-outline {
    background: transparent;
    color: var(--secondary-color);
    border: 2px solid var(--secondary-color);
}

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

/* Search Box */
.search-box {
    background: var(--white);
    padding: 30px;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    margin: 0 0 30px 0;
}

/* Category Cards */
.category-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin: 20px 0 25px;
    padding: 0 15px;
}

.category-card {
    background: #ffffff;
    border: 1px solid #e8e8e8;
    border-radius: 12px;
    padding: 18px 12px;
    text-align: center;
    transition: all 0.2s;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.category-card:hover {
    background: #ffffff;
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.category-card svg {
    width: 32px;
    height: 32px;
}

.category-card span {
    display: block;
    font-size: 12px;
    font-weight: 400;
    color: var(--text-dark);
}

.search-form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 400;
    color: var(--secondary-color);
}

.form-control {
    width: 100%;
    padding: 10px 15px;
    border: 2px solid var(--border-color);
    border-radius: 4px;
    font-size: 14px;
    transition: border-color 0.3s;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
}

/* Listing Grid */
.listing-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin: 20px 0;
    padding: 0 15px;
}

.listing-card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: all 0.2s;
}

.listing-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
}

.listing-image {
    position: relative;
    height: 140px;
    overflow: hidden;
    background: var(--bg-light);
}

.listing-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.listing-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(255, 232, 0, 0.95);
    color: var(--secondary-color);
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
}

.listing-content {
    padding: 12px;
}

.listing-title {
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--secondary-color);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.listing-price {
    font-size: 16px;
    font-weight: 800;
    color: #e74c3c;
    margin-bottom: 8px;
}

.listing-location {
    font-size: 11px;
    color: #999;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Footer */
.footer {
    background: #f1f1f1;
    color: #333;
    padding: 40px 0 0;
    margin-top: 60px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 40px;
    padding-bottom: 20px;
}

.footer-section h3 {
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 16px;
    color: #333;
    text-transform: capitalize;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section a {
    color: #666;
    font-size: 13px;
    transition: color 0.3s;
}

.footer-section a:hover {
    color: #000;
}

.footer-bottom {
    border-top: 1px solid rgba(0,0,0,0.1);
    padding: 20px 0;
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.mt-20 {
    margin-top: 20px;
}

.mb-20 {
    margin-bottom: 20px;
}

.flex {
    display: flex;
}

.space-between {
    justify-content: space-between;
}

.align-center {
    align-items: center;
}

/* Responsive */
@media (max-width: 768px) {
    .nav-menu {
        flex-direction: column;
    }
    
    .search-form {
        grid-template-columns: 1fr;
    }
    
    .listing-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }
}

@media (max-width: 992px) {
    .footer-content {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 480px) {
    .footer-content {
        grid-template-columns: 1fr;
    }
}
