@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@100..900&display=swap');

/* Global Search Grid Styles */

:root {
    --gsg-red: #d32f2f;
    --gsg-text: #333;
    --gsg-border: #e0e0e0;
    --gsg-bg-card: #ffffff;
    --gsg-bg-page: #f9f9f9;
    --gsg-card-shadow: 0 4px 6px rgba(0,0,0,0.05);
}

.gsg-search-form-wrapper {
    max-width: 600px;
    /*margin: 0 auto 30px;*/
    position: relative;
}

.gsg-input-group {
    display: flex;
    align-items: center;
    border: 1px solid var(--gsg-border);
    border-radius: 30px;
    padding: 5px 15px;
    background: #fff;
}

.gsg-search-icon {
    color: #888;
    margin-right: 10px;
}
.gsg-search-submit-btn{
    border:none !important;
}

.gsg-search-input {
    border: none !important;
    background: transparent;
    flex-grow: 1;
    padding: 10px;
    font-size: 16px;
    outline: none;
    box-shadow: none;
}

.gsg-search-input:focus {
    box-shadow: none;
    background: transparent;
}

.gsg-search-button {
    background: var(--gsg-red);
    color: #fff;
    border: none !important;
    border-radius: 20px;
    padding: 8px 20px;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.3s;
}

.gsg-search-button:hover {
    background: #b71c1c;
}

.gsg-search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid var(--gsg-border);
    border-radius: 8px;
    margin-top: 5px;
    box-shadow: var(--gsg-card-shadow);
    display: none;
    z-index: 100;
}

.gsg-search-suggestions a {
    display: block;
    padding: 10px 15px;
    color: var(--gsg-text);
    text-decoration: none;
    border-bottom: 1px solid #f0f0f0;
}

.gsg-search-suggestions a:last-child {
    border-bottom: none;
}

.gsg-search-suggestions a:hover {
    background: #f9f9f9;
}

.gsg-results-section {
    margin-bottom: 50px;
}

.gsg-results-heading {
    text-align: center;
    color: var(--gsg-red);
    font-weight: 700;
    margin-bottom: 30px;
    font-size: 24px;
}

.gsg-results-heading span {
    color: inherit;
}

.gsg-view-all {
    display: inline-block;
    margin-left: 20px;
    font-size: 14px;
    font-weight: 600;
    color: var(--gsg-text);
    text-decoration: underline;
    vertical-align: middle;
    transition: color 0.3s;
}

.gsg-view-all:hover {
    color: var(--gsg-red);
}


.gsg-grid {
    display: grid;
    gap: 20px;
}

.gsg-grid-4 {
    grid-template-columns: repeat(4, 1fr);
}

.gsg-card {
    background: var(--gsg-bg-card);
    border: 1px solid var(--gsg-border);
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
}

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

.gsg-card-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
    position: relative;
    background: #f0f0f0;
}

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

.gsg-placeholder {
    width: 100%;
    height: 100%;
    background: #eee;
}

.gsg-card-content {
    padding: 20px;
    text-align: center;
}

.gsg-card-title {
    font-size: 16px;
    margin: 0 0 15px;
    font-weight: 600;
}

.gsg-card-title a {
    color: inherit;
    text-decoration: none;
}

.gsg-text-red {
    color: var(--gsg-red);
}

.gsg-card-excerpt {
    font-size: 14px;
    color: #666;
    line-height: 1.5;
}

.gsg-card-actions {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 15px;
}

.gsg-btn-outline {
    border: 1px solid #111;
    background: transparent;
    color: #111;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    text-decoration: none;
    transition: all 0.3s;
    font-weight: 500;
}

.gsg-btn-outline:hover {
    background: #111;
    color: #fff;
}

.gsg-pagination {
    display: flex;
    justify-content: center;
    margin-top: 40px;
}

.gsg-pagination ul {
    display: flex;
    list-style: none;
    padding: 0;
    margin: 0;
    gap: 5px;
}

.gsg-pagination li a, .gsg-pagination li span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 35px;
    height: 35px;
    border: 1px solid var(--gsg-border);
    background: #fff;
    color: var(--gsg-text);
    text-decoration: none;
    font-size: 14px;
    transition: all 0.3s;
}

.gsg-pagination li span.current {
    background: var(--gsg-red);
    color: #fff;
    border-color: var(--gsg-red);
}

.gsg-pagination li a:hover {
    background: #f0f0f0;
}

.gsg-no-results {
    text-align: center;
    color: #666;
    font-size: 16px;
    padding: 20px;
    background: #fff;
    border: 1px dashed var(--gsg-border);
}

/* Pixel-Perfect "View More" Button Wrapper */
.gsg-search-container .gsg-view-more-wrapper,
.gsg-results-section .gsg-view-more-wrapper {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    margin: 40px 0 !important;
    width: 100% !important;
    clear: both !important;
}

/* Button Design */
a.gsg-view-more {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    background-color: #E53935 !important;
    color: #ffffff !important;
    padding: 13px 32px !important;
    border-radius: 999px !important;
    text-decoration: none !important;
    font-weight: 600 !important;
    font-size: 17px !important;
    transition: all 0.3s ease !important;
    border: none !important;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1) !important;
    line-height: 1 !important;
    visibility: visible !important;
    opacity: 1 !important;
    cursor: pointer !important;
}

a.gsg-view-more:hover {
    background-color: #D32F2F !important;
    transform: translateY(-1px) scale(1.03) !important;
    box-shadow: 0 4px 8px rgba(0,0,0,0.15) !important;
    color: #ffffff !important;
    text-decoration: none !important;
}

a.gsg-view-more::after {
    content: "→" !important;
    font-size: 20px !important;
    margin-left: 8px !important;
    display: inline-block !important;
    line-height: 1 !important;
    vertical-align: middle !important;
}

/* Responsive */
@media (max-width: 991px) {
    .gsg-grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 575px) {
    .gsg-grid-4 {
        grid-template-columns: 1fr;
    }
}



/* Product grid safety: 4 columns desktop, 2 tablet, 1 mobile */
.catp-product-grid,
.gsg-product-grid {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 20px !important;
}

@media (max-width: 991px) {
    .catp-product-grid,
    .gsg-product-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }
}

@media (max-width: 575px) {
    .catp-product-grid,
    .gsg-product-grid {
        grid-template-columns: 1fr !important;
    }
}


/* Container spacing fix */
.gsg-search-container,
.gsg-results-wrapper,
.gsg-results-section {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding-left: 30px;
    padding-right: 30px;
    box-sizing: border-box;
}

.gsg-grid,
.catp-product-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 25px;
    width: 100%;
}

.gsg-card,
.catp-product-card {
    width: 100%;
    min-width: 0;
}

@media (min-width: 1600px) {
    .gsg-search-container,
    .gsg-results-wrapper,
    .gsg-results-section {
        max-width: 1500px;
    }
}

@media (max-width: 991px) {
    .gsg-grid,
    .catp-product-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 575px) {
    .gsg-search-container,
    .gsg-results-wrapper,
    .gsg-results-section {
        padding-left: 15px;
        padding-right: 15px;
    }

    .gsg-grid,
    .catp-product-grid {
        grid-template-columns: 1fr;
    }
}
