/*
Theme Name: irMachinery
Theme URI: https://irmachinery.com/
Author: Antigravity AI
Description: V19.6.0 Dynamic Contact Numbers & Call/WhatsApp Integration.
Version: 19.6.0
*/

:root {
    --primary-navy: #0a2342;
    --secondary-navy: #001a38;
    --pw-red: #b73431;
    --pw-blue: #0a2342;
    --pw-green: #2ecc71;
    --dark: #111111;
    --bg-smoke: #f4f7f9;
    --white: #ffffff;
    --text-dark: #222222;
    --text-muted: #666666;
    --shadow-sm: 0 2px 10px rgba(0,0,0,0.05);
    --shadow-md: 0 10px 30px rgba(0,0,0,0.08);
    --transition: all 0.3s ease;
    
    /* legacy variable names mapped to new navy theme */
    --primary-orange: var(--primary-navy);
    --secondary-orange: var(--secondary-navy);
    --primary-green: var(--primary-navy);
    --secondary-green: var(--pw-red);
    --accent-gold: var(--pw-red);
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background: var(--bg-smoke);
    color: var(--dark);
    overflow-x: clip;
    line-height: 1.6;
}

.container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
    box-sizing: border-box;
}

/* ARCHIVE LISTING GRID (3-COLUMN RIGID) */
.machinery-grid {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 40px !important;
    margin-top: 30px !important;
}

.machinery-card {
    background: #fff;
    border-radius: 4px;
    border: 1px solid #e0e0e0;
    overflow: hidden;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}

.machinery-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
    border-color: #ccc;
}

.machinery-card .price {
    font-size: 20px;
    font-weight: 700;
    color: var(--pw-green);
    margin: 10px 0;
}

/* RIGID ICON GRID (BROWSE CATEGORIES) */
.icon-grid, .city-grid, .make-grid {
    display: grid !important;
    grid-template-columns: repeat(6, 1fr) !important;
    gap: 15px !important;
}

.icon-item {
    background: #fff !important;
    min-height: 220px !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 4px !important;
    padding: 30px !important;
    border: 1.5px solid #f0f0f0 !important;
    text-decoration: none !important;
    transition: all 0.4s !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.03) !important;
}

.icon-item:hover        /* GLOBAL MODERN UI */
        .card-shadow { box-shadow: 0 10px 30px rgba(0,0,0,0.05) !important; border: 1px solid #eee !important; }
        .section-title { font-size: 36px; font-weight: 900; color: var(--primary-navy); margin-bottom: 40px; text-align: center; }
        
        /* FORM CONTROLS V15.0 */
        input[type="text"], input[type="file"], select, textarea {
            width: 100%; padding: 15px 20px !important; border: 1px solid #ddd !important; 
            border-radius: 4px !important; font-weight: 600 !important; font-size: 14px !important; 
            background: #fff !important; outline: none !important; transition: 0.3s !important; 
            box-sizing: border-box !important;
        }
        input:focus, select:focus, textarea:focus { border-color: var(--primary-navy) !important; }
        label { display: block; font-weight: 800 !important; margin-bottom: 8px !important; font-size: 13px !important; text-transform: uppercase !important; color: #444 !important; }
    justify-content: center !important;
    gap: 8px !important;
    border: none !important;
    cursor: pointer !important;
    transition: var(--transition) !important;
    color: #fff !important;
}

.btn-vivid:hover {
    opacity: 0.9;
    transform: none !important;
}

.btn-wa { background: #25D366 !important; }
.btn-call { background: #3498db !important; }
.btn-post { background: var(--pw-red) !important; }

/* MODERN UNIFIED SEARCH BAR */
.hero-search-wrapper {
    max-width: 900px;
    width: 100%;
    margin: 0 auto;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.15);
    border: 1px solid #ddd;
    overflow: hidden;
}

.hero-search-form {
    display: flex;
    align-items: stretch;
    width: 100%;
    margin: 0;
    padding: 0;
}

.search-field-group {
    flex: 1;
    display: flex;
    align-items: center;
    border-right: 1px solid #eee;
    background: #fff;
    position: relative;
}

.search-field-group.keyword-field {
    flex: 1.5;
    border-right: none;
}

.search-select, .search-input {
    width: 100%;
    padding: 16px 20px !important;
    border: none !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    background: transparent !important;
    outline: none !important;
    color: #333 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    margin: 0 !important;
}

.search-select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23666666'%3E%3Cpath d='M7 10l5 5 5-5z'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 15px center !important;
    background-size: 20px !important;
    padding-right: 35px !important;
    cursor: pointer;
}

.search-submit-btn {
    background: var(--primary-navy, #0a2342);
    color: #fff !important;
    border: none;
    padding: 0 35px;
    cursor: pointer;
    font-size: 18px;
    transition: background 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-submit-btn:hover {
    background: var(--secondary-navy, #001a38);
}

@media (max-width: 768px) {
    .hero-search-form {
        flex-direction: column;
    }
    .search-field-group {
        border-right: none;
        border-bottom: 1px solid #eee;
        width: 100%;
    }
    .search-select, .search-input {
        padding: 14px 15px !important;
    }
    .search-submit-btn {
        padding: 15px;
        border-radius: 0;
        width: 100%;
    }
}

/* PREMIUM 4-COLUMN FOOTER */
.site-footer {
    background: var(--footer-dark) !important;
    color: #fff !important;
    padding: 80px 0 40px !important;
    border-top: none !important;
}

.footer-grid {
    display: grid !important;
        .form-group input { 
            width: 100% !important; padding: 15px 20px !important; border-radius: 4px !important; border: 1px solid #ddd !important; 
            font-size: 15px !important; font-weight: 600 !important; transition: 0.3s; outline: none !important; box-sizing: border-box !important;
            background: #f9f9f9 !important;
        }
        .form-group input:focus { border-color: var(--primary-navy) !important; background: #fff !important; box-shadow: 0 0 10px rgba(10,35,66,0.1) !important; }
        .auth-btn { 
            width: 100%; background: var(--pw-red); color: #fff !important; border: none; 
            padding: 15px; border-radius: 4px; font-weight: 800; font-size: 16px; 
            cursor: pointer; transition: 0.3s; margin-top: 20px;
        }

.footer-col h4 {
    color: #fff !important;
    font-size: 20px !important;
    font-weight: 800 !important;
    margin-bottom: 25px !important;
    text-transform: capitalize !important;
    letter-spacing: 0.5px !important;
}

.footer-col ul {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

.footer-col ul li {
    margin-bottom: 18px !important;
}

.footer-col ul li a {
    color: #aaa !important;
    text-decoration: none !important;
    font-weight: 600 !important;
    font-size: 15px !important;
    transition: 0.3s !important;
}

.footer-col ul li a:hover {
    color: #fff !important;
    padding-left: 10px;
}

.footer-branding p {
    color: #889;
    font-size: 16px;
    margin: 30px 0;
    line-height: 1.8;
}

/* BROWSE TABS (Modern V12.0) */
.tab-link {
    padding: 15px 35px;
    background: #fff;
    border-radius: 4px;
    font-weight: 900;
    font-size: 14px;
    text-transform: uppercase;
    cursor: pointer;
    border: 2px solid #eee;
    color: #666;
    transition: 0.3s;
}

.tab-link.active {
    background: var(--primary-orange);
    color: #fff;
    border-color: var(--primary-orange);
    box-shadow: 0 10px 20px rgba(255, 107, 74, 0.2);
}

/* RESPONSIVE & MOBILE MENU */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    color: #fff;
    font-size: 28px;
    cursor: pointer;
}

@media (max-width: 1100px) {
    .container {
        max-width: 95%;
    }

    .machinery-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr !important;
    }
}

@media (max-width: 991px) {
    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        .modal-content {
            background: #fff; width: 100%; max-width: 520px; border-radius: 4px;
            padding: 50px; position: relative; box-shadow: 0 50px 150px rgba(0,0,0,0.5);
            border: 1px solid rgba(255,255,255,0.3); animation: slideUp 0.5s cubic-bezier(0.19, 1, 0.22, 1);
            max-height: 95vh; overflow-y: auto;
        }
        height: 100vh;
        background: var(--footer-dark);
        z-index: 10000;
        transition: 0.5s;
        padding: 100px 40px;
        box-shadow: -10px 0 30px rgba(0, 0, 0, 0.3);
    }

    .nav-menu.active {
        right: 0;
    }

    .nav-menu ul {
        flex-direction: column;
        gap: 40px;
    }

    .nav-menu a {
        font-size: 20px;
        letter-spacing: 1px;
    }

    .mobile-menu-toggle {
        display: block;
    }

    .header-cta {
        display: none !important;
    }

    /* Hide desktop CTA on small screens */

    .hero-v12 h1 {
        font-size: 42px !important;
    }

    .section-title {
        font-size: 32px !important;
    }
}

@media (max-width: 768px) {

    .machinery-grid,
    .blog-grid,
    .video-grid {
        grid-template-columns: 1fr !important;
        gap: 25px !important;
    }

    .footer-grid {
        grid-template-columns: 1fr !important;
        gap: 40px !important;
        text-align: center;
    }

    .icon-grid, .city-grid, .make-grid {
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 15px !important;
    }
}

@media (max-width: 480px) {
    .icon-grid, .city-grid, .make-grid {
        grid-template-columns: 1fr 1fr !important;
    }

    .logo img {
        height: 60px !important;
    }
}
