/* ========================================
   Divine Fortune Fasteners - Main Stylesheet
   ======================================== */

/* CSS Variables */
:root {
    --primary-color: #1e3a8a;
    --secondary-color: #dc2626;
    --accent-color: #0ea5e9;
    --text-dark: #1f2937;
    --text-light: #6b7280;
    --border-color: #e5e7eb;
    --bg-light: #f9fafb;
    --white: #ffffff;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--white);
}

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

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ========================================
   HEADER STYLES
   ======================================== */

/* Top Bar */
.top-bar {
    background-color: var(--primary-color);
    color: var(--white);
    padding: 10px 0;
    font-size: 14px;
}

.top-bar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.contact-info a {
    color: var(--white);
    margin-right: 20px;
}

.contact-info a:hover {
    color: var(--accent-color);
}

.contact-info i {
    margin-right: 5px;
}

/* Main Navigation */
.main-nav {
    background-color: var(--white);
    box-shadow: var(--shadow-md);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
}

.logo img {
    height: 60px;
    width: auto;
}

.nav-menu {
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav-menu a {
    color: var(--text-dark);
    font-weight: 500;
    font-size: 15px;
    padding: 8px 0;
    position: relative;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--secondary-color);
    transition: var(--transition);
}

.nav-menu a:hover::after,
.nav-menu li.active a::after {
    width: 100%;
}

.quote-cart-btn {
    background-color: var(--secondary-color);
    color: var(--white);
    padding: 10px 20px;
    border-radius: 5px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
    position: relative;
}

.quote-cart-btn:hover {
    background-color: #b91c1c;
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.quote-count {
    background-color: var(--white);
    color: var(--secondary-color);
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
}

.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background-color: var(--primary-color);
    transition: var(--transition);
}

/* WhatsApp Floating Button */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: #25D366;
    color: var(--white);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    box-shadow: var(--shadow-lg);
    z-index: 999;
    transition: var(--transition);
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 15px 30px rgba(37, 211, 102, 0.4);
}

/* ========================================
   FOOTER STYLES
   ======================================== */

.site-footer {
    background-color: var(--text-dark);
    color: var(--white);
    padding: 60px 0 20px;
    margin-top: 80px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-column h3,
.footer-column h4 {
    margin-bottom: 20px;
    color: var(--white);
}

.footer-column p {
    color: #9ca3af;
    line-height: 1.8;
}

.footer-social {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.footer-social a {
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.footer-social a:hover {
    background-color: var(--secondary-color);
    transform: translateY(-3px);
}

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    color: #9ca3af;
}

.footer-links a:hover {
    color: var(--white);
    padding-left: 5px;
}

.footer-contact li {
    display: flex;
    gap: 12px;
    margin-bottom: 15px;
    color: #9ca3af;
}

.footer-contact i {
    color: var(--secondary-color);
    margin-top: 3px;
    font-size: 18px;
}

.footer-contact a {
    color: #9ca3af;
}

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

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 30px;
    text-align: center;
    color: #9ca3af;
}

.footer-bottom p {
    margin-bottom: 5px;
}

.footer-bottom i.fa-heart {
    color: var(--secondary-color);
}

/* ========================================
   COMMON COMPONENTS
   ======================================== */

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 5px;
    font-weight: 500;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    font-size: 15px;
}

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

.btn-primary:hover {
    background-color: #1e40af;
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

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

.btn-secondary:hover {
    background-color: #b91c1c;
}

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

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

/* Alerts */
.alert {
    padding: 15px 20px;
    border-radius: 5px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.alert-success {
    background-color: #d1fae5;
    color: #065f46;
    border-left: 4px solid #10b981;
}

.alert-error {
    background-color: #fee2e2;
    color: #991b1b;
    border-left: 4px solid #ef4444;
}

.alert-info {
    background-color: #dbeafe;
    color: #1e40af;
    border-left: 4px solid #3b82f6;
}

/* Cards */
.card {
    background-color: var(--white);
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-5px);
}

/* Loading Spinner */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(0, 0, 0, 0.1);
    border-radius: 50%;
    border-top-color: var(--primary-color);
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Section Titles */
.section-title {
    text-align: center;
    margin-bottom: 50px;
}

.section-title h2 {
    font-size: 36px;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.section-title p {
    font-size: 18px;
    color: var(--text-light);
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */

@media (max-width: 968px) {
    .nav-menu {
        position: fixed;
        top: 100px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 100px);
        background-color: var(--white);
        flex-direction: column;
        padding: 40px;
        box-shadow: var(--shadow-lg);
        transition: var(--transition);
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .mobile-menu-toggle {
        display: flex;
    }
    
    .quote-cart-btn {
        position: fixed;
        bottom: 100px;
        right: 20px;
        z-index: 998;
    }
}

@media (max-width: 768px) {
    .top-bar-content {
        flex-direction: column;
        gap: 10px;
    }
    
    .contact-info {
        display: flex;
        flex-direction: column;
        gap: 5px;
        text-align: center;
    }
    
    .contact-info a {
        margin-right: 0;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
    }
    
    .section-title h2 {
        font-size: 28px;
    }
}

@media (max-width: 480px) {
    .whatsapp-float {
        width: 50px;
        height: 50px;
        font-size: 28px;
        bottom: 20px;
        right: 20px;
    }
    
    .btn {
        padding: 10px 20px;
        font-size: 14px;
    }
}

/* ========================================
   PRODUCTS PAGE STYLES
   ======================================== */

.page-header {
    background: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 100%);
    color: white;
    padding: 60px 0;
    text-align: center;
}

.page-header h1 {
    font-size: 42px;
    margin-bottom: 10px;
}

.page-header p {
    font-size: 18px;
    opacity: 0.9;
}

.products-section {
    padding: 60px 0;
    background-color: var(--bg-light);
}

.products-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 30px;
}

.products-sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.filter-card {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
}

.filter-card h3 {
    color: var(--primary-color);
    font-size: 16px;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--border-color);
}

.search-form {
    display: flex;
    gap: 10px;
}

.search-input {
    flex: 1;
    padding: 10px;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    font-size: 14px;
}

.search-input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.search-form .btn {
    padding: 10px 15px;
}

.filter-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.filter-list a {
    color: var(--text-dark);
    padding: 8px 12px;
    border-radius: 5px;
    transition: var(--transition);
    display: block;
}

.filter-list a:hover {
    background-color: var(--bg-light);
    padding-left: 16px;
}

.filter-list a.active {
    background-color: var(--primary-color);
    color: white;
}

.filter-select {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    font-size: 14px;
    background-color: white;
    cursor: pointer;
}

.filter-select:focus {
    outline: none;
    border-color: var(--primary-color);
}

.mobile-filter-toggle {
    display: none;
    width: 100%;
    padding: 12px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    cursor: pointer;
    margin-bottom: 20px;
}

.mobile-filter-toggle i {
    margin-right: 8px;
}

.products-main {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.active-filters {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
}

.active-filters h4 {
    color: var(--primary-color);
    font-size: 14px;
    margin-bottom: 10px;
}

.filter-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.filter-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    background-color: var(--primary-color);
    color: white;
    border-radius: 20px;
    font-size: 14px;
}

.filter-tag a {
    color: white;
    font-size: 18px;
    font-weight: bold;
    line-height: 1;
}

.filter-tag a:hover {
    color: var(--secondary-color);
}

.results-info {
    background: white;
    padding: 15px 20px;
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
}

.results-info p {
    margin: 0;
    color: var(--text-light);
    font-size: 14px;
}

.no-products {
    background: white;
    padding: 60px 20px;
    border-radius: 8px;
    text-align: center;
    box-shadow: var(--shadow-sm);
}

.no-products i {
    font-size: 80px;
    color: var(--border-color);
    margin-bottom: 20px;
}

.no-products h3 {
    color: var(--text-dark);
    margin-bottom: 10px;
}

.no-products p {
    color: var(--text-light);
    margin-bottom: 30px;
}

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin-top: 30px;
}

.pagination-btn {
    padding: 10px 15px;
    background: white;
    color: var(--primary-color);
    border: 1px solid var(--border-color);
    border-radius: 5px;
    font-size: 14px;
    cursor: pointer;
    transition: var(--transition);
}

.pagination-btn:hover {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.pagination-btn.active {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.pagination-btn i {
    font-size: 12px;
}

@media (max-width: 968px) {
    .products-layout {
        grid-template-columns: 1fr;
    }
    
    .products-sidebar {
        position: fixed;
        left: -100%;
        top: 0;
        width: 280px;
        height: 100vh;
        background: white;
        z-index: 1000;
        padding: 20px;
        overflow-y: auto;
        transition: var(--transition);
        box-shadow: var(--shadow-lg);
    }
    
    .products-sidebar.active {
        left: 0;
    }
    
    .mobile-filter-toggle {
        display: block;
    }
}

@media (max-width: 768px) {
    .page-header h1 {
        font-size: 32px;
    }
    
    .products-grid {
        grid-template-columns: 1fr;
    }
    
    .pagination {
        flex-wrap: wrap;
    }
}
