/* HavocTech Armory - Custom Styles
   Matching HavocTech.com branding
   Primary Blue: #2E5C99
   Secondary Blue: #1E4070
   Accent Green: #6FB951
*/

:root {
    --ht-primary: #2E5C99;
    --ht-secondary: #1E4070;
    --ht-accent: #6FB951;
    --ht-light-gray: #F5F5F5;
    --ht-gray: #E0E0E0;
    --ht-dark-gray: #333333;
    --ht-text-gray: #666666;
    --ht-border-radius: 8px;
}

/* Base styles */
html {
    font-size: 16px;
    position: relative;
    min-height: 100%;
}

body {
    margin-bottom: 60px;
    font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--ht-dark-gray);
}

/* Headings */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    color: var(--ht-secondary);
}

/* Navbar customization */
.navbar-dark {
    background: linear-gradient(135deg, var(--ht-secondary) 0%, var(--ht-primary) 100%) !important;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

/* Logo Banner */
.logo-banner {
    background: linear-gradient(135deg, var(--ht-secondary) 0%, var(--ht-primary) 100%);
    border-bottom: 3px solid var(--ht-accent);
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    padding: 0;
    margin: 0;
    line-height: 0;
    height: 200px; /* Fixed height - adjust this value as needed */
    display: flex;
    align-items: center; /* Vertically center the logo */
    justify-content: center; /* Horizontally center the logo */
    overflow: hidden; /* Hide any overflow */
}

.logo-banner .container-fluid {
    padding: 0;
    margin: 0;
    height: 100%;
    display: flex;
    align-items: center;
}

.logo-banner .row {
    padding: 0;
    margin: 0;
    width: 100%;
}

.logo-banner .col-12 {
    padding: 0;
    margin: 0;
}

.logo-banner a {
    display: block;
    line-height: 0;
}

.logo-banner-image {
    max-height: 440px; /* Slightly less than banner height for safety */
    height: auto;
    width: auto;
    max-width: 100%;
    transition: transform 0.3s ease;
    display: block;
    margin: 0 auto;
    vertical-align: bottom;
}

.logo-banner-image:hover {
    transform: scale(1.05);
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.navbar-brand i {
    color: var(--ht-accent);
    font-size: 1.8rem;
}

.nav-link {
    font-weight: 500;
    transition: all 0.3s ease;
}

.nav-link:hover {
    color: var(--ht-accent) !important;
    transform: translateY(-2px);
}

.nav-link i {
    margin-right: 5px;
}

/* Buttons */
.btn-primary {
    background-color: var(--ht-primary);
    border-color: var(--ht-primary);
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background-color: var(--ht-secondary);
    border-color: var(--ht-secondary);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(46, 92, 153, 0.3);
}

.btn-success {
    background-color: var(--ht-accent);
    border-color: var(--ht-accent);
}

.btn-success:hover {
    background-color: #5da842;
    border-color: #5da842;
}

.btn-outline-primary {
    color: var(--ht-primary);
    border-color: var(--ht-primary);
}

.btn-outline-primary:hover {
    background-color: var(--ht-primary);
    border-color: var(--ht-primary);
}

/* Cards */
.card {
    border-radius: var(--ht-border-radius);
    border: 1px solid var(--ht-gray);
    transition: all 0.3s ease;
    height: 100%;
}

.card:hover {
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
    transform: translateY(-4px);
}

.card-header {
    background-color: var(--ht-light-gray);
    border-bottom: 2px solid var(--ht-gray);
    font-weight: 600;
}

/* Product Cards */
.product-card {
    border-radius: var(--ht-border-radius);
    overflow: hidden;
    position: relative;
}

.product-card .card-img-top {
    height: 250px;
    object-fit: cover;
    background-color: var(--ht-light-gray);
}

.product-card .card-body {
    display: flex;
    flex-direction: column;
}

.product-card .product-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--ht-dark-gray);
    margin-bottom: 0.5rem;
    min-height: 48px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-card .product-brand {
    font-size: 0.875rem;
    color: var(--ht-text-gray);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.product-card .product-price {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--ht-primary);
    margin-top: auto;
}

.product-card .product-price-sale {
    color: var(--ht-accent);
}

.product-card .product-price-original {
    font-size: 1rem;
    color: var(--ht-text-gray);
    text-decoration: line-through;
}

.product-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 10;
}

.badge-ffl {
    background-color: #dc3545;
}

.badge-sale {
    background-color: var(--ht-accent);
}

.badge-new {
    background-color: #0dcaf0;
}

.badge-out-of-stock {
    background-color: #6c757d;
}

/* Filter Sidebar */
.filter-sidebar {
    background-color: var(--ht-light-gray);
    border-radius: var(--ht-border-radius);
    padding: 1.5rem;
}

.filter-section {
    margin-bottom: 1.5rem;
}

.filter-section h6 {
    font-weight: 600;
    color: var(--ht-secondary);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--ht-gray);
}

.filter-option {
    margin-bottom: 0.5rem;
}

.filter-option label {
    cursor: pointer;
    transition: color 0.2s;
}

.filter-option label:hover {
    color: var(--ht-primary);
}

/* Search and Sort */
.search-sort-bar {
    background-color: #fff;
    border-radius: var(--ht-border-radius);
    padding: 1rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.form-control:focus,
.form-select:focus {
    border-color: var(--ht-primary);
    box-shadow: 0 0 0 0.2rem rgba(46, 92, 153, 0.25);
}

/* Pagination */
.pagination {
    margin-top: 2rem;
}

.page-link {
    color: var(--ht-primary);
    border-color: var(--ht-gray);
}

.page-link:hover {
    color: var(--ht-secondary);
    background-color: var(--ht-light-gray);
    border-color: var(--ht-primary);
}

.page-item.active .page-link {
    background-color: var(--ht-primary);
    border-color: var(--ht-primary);
}

/* Product Details */
.product-detail-image {
    border-radius: var(--ht-border-radius);
    overflow: hidden;
    background-color: var(--ht-light-gray);
}

.product-detail-image img {
    width: 100%;
    height: auto;
}

.product-thumbnails {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.product-thumbnail {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border: 2px solid var(--ht-gray);
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
}

.product-thumbnail:hover,
.product-thumbnail.active {
    border-color: var(--ht-primary);
    transform: scale(1.05);
}

.product-info-box {
    background-color: var(--ht-light-gray);
    border-radius: var(--ht-border-radius);
    padding: 1.5rem;
    margin-bottom: 1rem;
}

.product-info-box h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.product-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.product-specs {
    list-style: none;
    padding: 0;
}

.product-specs li {
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--ht-gray);
    display: flex;
    justify-content: space-between;
}

.product-specs li:last-child {
    border-bottom: none;
}

.spec-label {
    font-weight: 600;
    color: var(--ht-dark-gray);
}

.spec-value {
    color: var(--ht-text-gray);
}

/* Reviews */
.review-item {
    padding: 1.5rem;
    background-color: #fff;
    border: 1px solid var(--ht-gray);
    border-radius: var(--ht-border-radius);
    margin-bottom: 1rem;
}

.review-rating {
    color: #ffc107;
}

.review-author {
    font-weight: 600;
    color: var(--ht-secondary);
}

.review-date {
    font-size: 0.875rem;
    color: var(--ht-text-gray);
}

/* Brand Page */
.brand-card {
    text-align: center;
    padding: 2rem;
    border: 2px solid var(--ht-gray);
    border-radius: var(--ht-border-radius);
    transition: all 0.3s ease;
}

.brand-card:hover {
    border-color: var(--ht-primary);
    box-shadow: 0 4px 16px rgba(0,0,0,0.1);
    transform: translateY(-4px);
}

.brand-logo {
    max-height: 80px;
    max-width: 100%;
    object-fit: contain;
    margin-bottom: 1rem;
}

.brand-name {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--ht-secondary);
    margin-bottom: 0.5rem;
}

.brand-count {
    font-size: 0.875rem;
    color: var(--ht-text-gray);
}

/* Age Verification Modal */
.age-verification-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.age-verification-modal {
    background: white;
    border-radius: var(--ht-border-radius);
    padding: 2rem;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

.age-verification-modal h2 {
    color: var(--ht-secondary);
    margin-bottom: 1rem;
}

.age-verification-icon {
    font-size: 4rem;
    color: var(--ht-primary);
    text-align: center;
    margin-bottom: 1rem;
}

.age-warning {
    background-color: #fff3cd;
    border: 2px solid #ffc107;
    border-radius: var(--ht-border-radius);
    padding: 1rem;
    margin-bottom: 1rem;
}

/* Cart Page */
.cart-item {
    background-color: #fff;
    border: 1px solid var(--ht-gray);
    border-radius: var(--ht-border-radius);
    padding: 1rem;
    margin-bottom: 1rem;
}

.cart-item-image {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 4px;
}

.cart-summary {
    background-color: var(--ht-light-gray);
    border-radius: var(--ht-border-radius);
    padding: 1.5rem;
}

.cart-summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--ht-gray);
}

.cart-summary-row:last-child {
    border-bottom: none;
}

.cart-summary-total {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--ht-primary);
}

/* Quantity Input */
.quantity-input {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.quantity-input input {
    width: 60px;
    text-align: center;
}

.quantity-btn {
    width: 35px;
    height: 35px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Alerts */
.alert {
    border-radius: var(--ht-border-radius);
    border-left: 4px solid;
}

.alert-success {
    border-left-color: var(--ht-accent);
}

.alert-info {
    border-left-color: var(--ht-primary);
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 4rem 2rem;
}

.empty-state-icon {
    font-size: 5rem;
    color: var(--ht-gray);
    margin-bottom: 1rem;
}

.empty-state h3 {
    color: var(--ht-text-gray);
    margin-bottom: 1rem;
}

/* Footer */
footer {
    margin-top: 4rem;
}

footer a:hover {
    color: var(--ht-accent) !important;
}

/* Breadcrumbs */
.breadcrumb {
    background-color: var(--ht-light-gray);
    border-radius: var(--ht-border-radius);
    padding: 0.75rem 1rem;
}

.breadcrumb-item.active {
    color: var(--ht-primary);
}

.breadcrumb-item a {
    color: var(--ht-text-gray);
    text-decoration: none;
}

.breadcrumb-item a:hover {
    color: var(--ht-primary);
}

/* Loading Spinner */
.spinner-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9998;
}

/* Stock Status */
.stock-status {
    font-weight: 600;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    display: inline-block;
    font-size: 0.875rem;
}

.stock-in-stock {
    background-color: #d1f2eb;
    color: #0f5132;
}

.stock-low-stock {
    background-color: #fff3cd;
    color: #664d03;
}

.stock-out-of-stock {
    background-color: #f8d7da;
    color: #842029;
}

/* Category navigation */
.category-nav {
    background-color: #fff;
    border-radius: var(--ht-border-radius);
    padding: 1rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.category-nav-item {
    display: inline-block;
    padding: 0.5rem 1rem;
    margin: 0.25rem;
    border-radius: 20px;
    background-color: var(--ht-light-gray);
    color: var(--ht-dark-gray);
    text-decoration: none;
    transition: all 0.2s;
}

.category-nav-item:hover,
.category-nav-item.active {
    background-color: var(--ht-primary);
    color: white;
}

/* ===================================
   HOMEPAGE STYLES
   =================================== */

/* Hero Banner Section */
.hero-banner {
    margin: 0;
    padding: 0;
}

.hero-slide {
    min-height: 500px;
    background-size: cover;
    background-position: center;
    position: relative;
}

.hero-slide::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(30, 64, 112, 0.8) 0%, rgba(46, 92, 153, 0.6) 100%);
    z-index: 1;
}

.hero-slide .container,
.hero-slide .row {
    position: relative;
    z-index: 2;
}

.hero-slide-1 {
    background-image: linear-gradient(135deg, rgba(30, 64, 112, 0.9) 0%, rgba(46, 92, 153, 0.7) 100%),
                      url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 600"><rect fill="%232E5C99" width="1200" height="600"/></svg>');
}

.hero-slide-2 {
    background-image: linear-gradient(135deg, rgba(30, 64, 112, 0.9) 0%, rgba(46, 92, 153, 0.7) 100%),
                      url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 600"><rect fill="%231E4070" width="1200" height="600"/></svg>');
}

.hero-slide-3 {
    background-image: linear-gradient(135deg, rgba(46, 92, 153, 0.9) 0%, rgba(111, 185, 81, 0.3) 100%),
                      url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 600"><rect fill="%232E5C99" width="1200" height="600"/></svg>');
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
    background-color: rgba(0, 0, 0, 0.3);
    border-radius: 50%;
    padding: 2rem;
}

.carousel-indicators button {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

/* Category Quick Links */
.category-quick-link {
    display: block;
    text-align: center;
    padding: 1.5rem 1rem;
    background: white;
    border-radius: var(--ht-border-radius);
    text-decoration: none;
    color: var(--ht-dark-gray);
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.category-quick-link:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
    color: var(--ht-primary);
}

.category-icon {
    font-size: 2.5rem;
    color: var(--ht-primary);
    margin-bottom: 0.5rem;
}

.category-quick-link:hover .category-icon {
    color: var(--ht-accent);
}

.category-quick-link h6 {
    font-weight: 600;
    margin-bottom: 0.25rem;
    color: var(--ht-secondary);
}

/* Promotional Banner */
.promo-banner {
    background: linear-gradient(135deg, var(--ht-secondary) 0%, var(--ht-primary) 100%);
    position: relative;
    overflow: hidden;
}

.promo-banner::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(111, 185, 81, 0.2) 0%, transparent 70%);
    border-radius: 50%;
}

/* Features Section */
.feature-icon {
    font-size: 3rem;
    color: var(--ht-primary);
}

.feature-icon i {
    transition: all 0.3s ease;
}

.feature-icon:hover i {
    color: var(--ht-accent);
    transform: scale(1.1);
}

/* Brand Showcase */
.brand-showcase-card {
    display: block;
    text-align: center;
    padding: 1.5rem 1rem;
    background: white;
    border: 2px solid var(--ht-gray);
    border-radius: var(--ht-border-radius);
    text-decoration: none;
    color: var(--ht-dark-gray);
    transition: all 0.3s ease;
    height: 100%;
}

.brand-showcase-card:hover {
    border-color: var(--ht-primary);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.1);
}

.brand-showcase-logo {
    max-height: 60px;
    max-width: 100%;
    object-fit: contain;
    margin-bottom: 1rem;
    filter: grayscale(50%);
    transition: filter 0.3s ease;
}

.brand-showcase-card:hover .brand-showcase-logo {
    filter: grayscale(0%);
}

.brand-showcase-placeholder {
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: var(--ht-gray);
    margin-bottom: 1rem;
}

.brand-showcase-name {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--ht-secondary);
    margin: 0;
}

.brand-showcase-card:hover .brand-showcase-name {
    color: var(--ht-primary);
}

/* Section Headers */
.display-5 {
    font-weight: 700;
}

.display-5 i {
    vertical-align: middle;
}

/* Responsive Hero */
@media (max-width: 768px) {
    .hero-slide {
        min-height: 400px;
    }
    
    .hero-slide h1 {
        font-size: 2rem;
    }
    
    .hero-slide .lead {
        font-size: 1rem;
    }
    
    .category-icon {
        font-size: 2rem;
    }
    
    .feature-icon {
        font-size: 2.5rem;
    }
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeInUp 0.6s ease-out;
}

/* Additional Product Card Enhancements for Homepage */
.product-card {
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 32px rgba(0,0,0,0.15);
}

/* Badge Styles */
.badge {
    font-weight: 600;
    padding: 0.35rem 0.65rem;
}

.badge.bg-success {
    background-color: var(--ht-accent) !important;
}

.badge.bg-danger {
    background-color: #dc3545 !important;
}

/* Hover Effects for Links */
a.text-decoration-none:hover {
    text-decoration: none !important;
}

/* Section Spacing */
section {
    position: relative;
}

section.bg-light {
    background-color: var(--ht-light-gray) !important;
}

/* Print Styles */
@media print {
    .navbar,
    .footer,
    .btn,
    .contact-form {
        display: none !important;
    }
    
    .hero-section {
        background: white !important;
        color: black !important;
        padding: 1rem 0 !important;
    }
    
    .service-card {
        box-shadow: none !important;
        border: 1px solid var(--medium-gray) !important;
    }
}

/* Product Pricing Styles */
.product-price-from {
    line-height: 1.2;
}

.product-price-from small {
    display: block;
    font-size: 0.75rem;
    color: #6c757d;
    text-transform: lowercase;
    margin-bottom: 2px;
    font-weight: 400;
}

.product-price-from .product-price-amount {
    font-size: 1.25rem;
    font-weight: 600;
    color: #198754;
    display: block;
}

.product-price {
    font-size: 1.25rem;
    font-weight: 600;
    color: #212529;
}

.product-price-sale {
    font-size: 1.5rem;
    font-weight: 700;
    color: #dc3545;
}

.product-price-original {
    font-size: 0.875rem;
    color: #6c757d;
    text-decoration: line-through;
}
