@import url('https://fonts.googleapis.com/css2?family=Roboto+Condensed:wght@300;400;700&display=swap');

:root {
    --primary-color: #e31e23;
    --primary-dark: #b8161b;
    --secondary-color: #0d0d0d;
    --accent-color: #f3f4f6;
    --text-main: #212529;
    --text-muted: #6c757d;
    --white: #ffffff;
    --border-color: #e5e7eb;
    --font-family: 'Roboto Condensed', sans-serif;
    --transition-base: all 0.3s ease;
    --shadow-sm: 0 2px 4px rgba(0,0,0,0.05);
    --shadow-md: 0 4px 6px rgba(0,0,0,0.08);
}

body {
    font-family: var(--font-family);
    color: var(--text-main);
    background-color: var(--white);
    line-height: 1.6;
}

/* Header & Navigation */
.top-bar {
    background: #000;
    color: #fff;
    font-size: 13px;
    padding: 6px 0;
    font-weight: 300;
}

.top-link {
    color: #fff;
    text-decoration: none;
    transition: var(--transition-base);
    font-size: 12px;
}

.top-link:hover {
    color: var(--primary-color);
}

.header-main {
    padding: 15px 0;
    background: #fff;
    border-bottom: 1px solid var(--border-color);
    position: relative;
    z-index: 1001;
}

.header-logo {
    font-family: 'Roboto Condensed', sans-serif;
    font-size: 30px;
    font-weight: 700;
    color: #0d0d0d !important;
    text-transform: uppercase;
    letter-spacing: -1px;
    white-space: nowrap;
}

.header-logo span {
    color: var(--primary-color);
}

.header-search {
    flex-grow: 1;
    max-width: 50% !important;
}

.header-search form {
    display: flex !important;
    background: #f3f4f6;
    border-radius: 4px;
    overflow: hidden;
    height: 44px;
    width: 100%;
}

.header-search input {
    border: none !important;
    background: transparent !important;
    padding: 0 15px;
    flex-grow: 1;
    font-size: 14px;
}

.header-search input:focus {
    outline: none;
    box-shadow: none !important;
}

.header-search button {
    background: #000;
    color: #fff;
    border: none;
    padding: 0 20px;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.header-action-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 10px;
    color: #0d0d0d;
    text-decoration: none;
    font-weight: 700;
    min-width: 50px;
}

.header-action-item i {
    font-size: 22px;
}

.cart-box {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    padding: 5px 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.cart-box-info {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.nav-row {
    background: #fff;
    padding: 0;
    border-bottom: 2px solid var(--primary-color);
    position: relative;
    z-index: 1000;
}

.nav-row .container {
    display: flex !important;
    flex-direction: row !important;
    justify-content: space-between !important;
    align-items: center !important;
}

.nav-list-flex {
    display: flex !important;
    flex-direction: row !important;
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
    gap: 0 !important;
    flex-wrap: nowrap !important;
}

.nav-link-custom {
    color: #0d0d0d;
    text-decoration: none;
    font-weight: 700;
    font-size: 14px;
    text-transform: uppercase;
    padding: 12px 15px;
    display: inline-block;
}

.nav-link-custom:hover {
    color: var(--primary-color);
}

main {
    padding-bottom: 80px; /* Space for mobile tab bar */
}

@media (min-width: 992px) {
    main { padding-bottom: 0; }
}

/* Slider Height & Positioning */
.home-slider {
    position: relative;
    max-height: 500px;
    overflow: hidden;
}

.home-slider .carousel-item {
    height: 500px;
}

.home-slider .carousel-item img {
    height: 100%;
    width: 100%;
    object-fit: cover;
}

@media (max-width: 991px) {
    .home-slider, .home-slider .carousel-item {
        height: 350px;
    }
}

.garaj-btn-box {
    background: #f3f4f6;
    border-radius: 4px;
    padding: 6px 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    white-space: nowrap;
}

.garaj-icon-wrap {
    color: var(--primary-color);
    font-size: 20px;
}

/* Product Cards */
.product-card {
    position: relative;
    background: #fff;
    border: 1px solid var(--border-color);
    transition: var(--transition-base);
    text-align: center;
    padding: 20px;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    border-color: var(--primary-color);
    box-shadow: var(--shadow-md);
}

.product-img-container {
    position: relative;
    height: 180px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-img {
    max-height: 100%;
    max-width: 100%;
    object-fit: contain;
}

.product-title {
    font-size: 14px;
    font-weight: 400;
    color: #0d0d0d;
    margin-bottom: 10px;
    height: 40px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.product-price {
    font-size: 18px;
    font-weight: 700;
    color: #0d0d0d;
    margin-top: auto;
}

/* Home Category Grid */
.home-cat-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-top: 40px;
}

.home-cat-item {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    aspect-ratio: 16/10;
}

.home-cat-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.home-cat-item:hover .home-cat-img {
    transform: scale(1.1);
}

.home-cat-overlay {
    position: absolute;
    bottom: 0;
    width: 100%;
    padding: 20px;
    background: linear-gradient(transparent, rgba(0,0,0,0.8));
    color: #fff;
    text-align: right;
}

.home-cat-title {
    font-size: 22px;
    font-weight: 700;
    text-transform: uppercase;
}

/* Mobile Tab Bar */
.mobile-tab-bar {
    position: fixed;
    bottom: 0;
    width: 100%;
    background: #ffffff;
    display: flex;
    justify-content: space-around;
    padding: 8px 0;
    border-top: 1px solid var(--border-color);
    z-index: 9999;
}

.tab-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #333;
    text-decoration: none;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
}

.tab-item i {
    font-size: 22px;
    margin-bottom: 1px;
}

.tab-item.active {
    color: var(--primary-color);
}

/* Support Bubble */
.support-bubble {
    position: fixed;
    bottom: 80px;
    right: 20px;
    width: 50px;
    height: 50px;
    background: #25d366;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    z-index: 999;
}

/* Footer Custom */
.footer-main {
    background: #0d0d0d;
    color: #fff;
    padding: 60px 0 30px;
    margin-bottom: 60px; /* Space for mobile tab bar */
}

@media (min-width: 992px) {
    .footer-main { margin-bottom: 0; }
    .mobile-tab-bar { display: none !important; }
}

@media (max-width: 991px) {
    .home-cat-grid { grid-template-columns: repeat(2, 1fr); }
    .header-main { padding: 10px 0; }
    .header-logo { font-size: 20px; min-width: 150px; }
    .nav-row { display: none !important; }
    .top-bar { display: none !important; }
    .header-actions { gap: 10px; }
    .header-action-item { min-width: 40px; }
    .header-action-item span { display: none; }
    .cart-box { min-width: auto; padding: 5px 8px; }
}

/* Cart Page Specific Styles */
.cart-page-title {
    font-weight: 700;
    margin-bottom: 2rem;
    position: relative;
    padding-bottom: 15px;
}

.cart-page-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 4px;
    background: var(--primary-color);
}

.cart-table-container {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    margin-bottom: 2rem;
}

.cart-table {
    width: 100%;
}

.cart-table thead {
    background: #f8f9fa;
    border-bottom: 1px solid #eeeff1;
}

.cart-table th {
    font-weight: 700;
    text-transform: uppercase;
    font-size: 13px;
    letter-spacing: 0.5px;
    padding: 1.25rem 1rem;
    color: #495057;
}

.cart-table td {
    padding: 1.5rem 1rem;
    vertical-align: middle;
    border-bottom: 1px solid #eeeff1;
}

.cart-item-img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #eee;
}

.cart-item-title {
    font-size: 16px;
    font-weight: 700;
    color: #333;
    margin-bottom: 4px;
    display: block;
    text-decoration: none;
}

.cart-item-title:hover {
    color: var(--primary-color);
}

.cart-item-variant {
    font-size: 13px;
    color: #888;
}

.quantity-picker {
    display: inline-flex;
    align-items: center;
    background: #f1f3f5;
    border-radius: 8px;
    padding: 2px;
}

.quantity-btn {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: #fff;
    border-radius: 6px;
    color: #333;
    transition: all 0.2s;
    cursor: pointer;
}

.quantity-btn:hover {
    background: var(--primary-color);
    color: #fff;
}

.quantity-input {
    width: 40px;
    text-align: center;
    border: none;
    background: transparent;
    font-weight: 700;
    font-size: 14px;
}

/* Remove arrows from number input */
.quantity-input::-webkit-outer-spin-button,
.quantity-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.cart-summary-card {
    border: none;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    background: #fff;
}

.price-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
    font-size: 15px;
}

.price-total {
    display: flex;
    justify-content: space-between;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 2px dashed #eee;
    font-size: 20px;
    font-weight: 700;
    color: var(--primary-color);
}

.checkout-btn-premium {
    background: var(--primary-color);
    color: #fff;
    border: none;
    padding: 15px 25px;
    border-radius: 10px;
    font-weight: 700;
    font-size: 16px;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    text-decoration: none;
    margin-top: 20px;
}

.checkout-btn-premium:hover {
    background: var(--primary-dark);
    color: #fff;
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(227, 30, 35, 0.2);
}

.remove-btn {
    color: #adb5bd;
    transition: color 0.2s;
    background: none;
    border: none;
    font-size: 1.2rem;
    padding: 5px;
}

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

.product-img-wrap {
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}