
/* =========================================
   TIXPINE HOMEPAGE
========================================= */

[hidden] {
    display: none !important;
}

body[data-page="home"] {
    min-height: 100vh;
    margin: 0;
    overflow-x: hidden;
    background: #fff;
    color: #241b35;
    font-family: "DM Sans", Arial, sans-serif;
}

body.vendor-menu-open {
    overflow: hidden;
}

/* HEADER */

.home-header {
    position: relative;
    z-index: 20;
    width: 100%;
    min-height: 76px;
    box-sizing: border-box;
    padding: 0 max(22px, calc((100% - 1160px) / 2));
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #fff;
    border-bottom: 1px solid #f0ebf7;
}

.home-header .brand-logo {
    display: inline-flex;
    align-items: center;
    gap: 1px;
    color: #6d28d9;
    font-size: 27px;
    font-weight: 600;
    letter-spacing: -1.4px;
    line-height: 1;
    text-decoration: none;
    white-space: nowrap;
}

.home-header .brand-logo .brand-mark {
    margin: 0 1px;
    color: #8b5cf6;
    font-size: 25px;
}

.home-header .vendor-menu-btn {
    width: 43px;
    height: 43px;
    padding: 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    border: 1px solid #eee7f7;
    border-radius: 12px;
    background: #fff;
    cursor: pointer;
    transition: background .2s, border-color .2s;
}

.home-header .vendor-menu-btn:hover {
    background: #f8f4ff;
    border-color: #d9c8f7;
}

.home-header .vendor-menu-btn span {
    width: 19px;
    height: 2px;
    display: block;
    border-radius: 2px;
    background: #6d28d9;
}

/* MAIN CONTENT */

.home-main {
    width: 100%;
    max-width: 1160px;
    box-sizing: border-box;
    margin: 0 auto;
    padding: 0 24px;
}

/* INTRODUCTION */

.home-intro {
    width: 100%;
    max-width: none;
    box-sizing: border-box;
    margin: 35px 0 35px;
    padding: 0;
    border: 0;
    border-radius: 0;
    background:
        radial-gradient(
            circle at 90% 10%,
            rgba(196, 181, 253, .35),
            transparent 35%
        ),
        linear-gradient(120deg, #faf7ff, #f1eaff);
    box-shadow: none;
    text-align: center;
}

.home-eyebrow {
    display: inline-block;
    color: #8b5cf6;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1.8px;
    line-height: 1.6;
}

.home-intro h1 {
    max-width: 700px;
    margin: 13px auto 12px;
    color: #24133f;
    font-size: clamp(30px, 4vw, 43px);
    font-weight: 800;
    letter-spacing: -1.5px;
    line-height: 1.2;
}

.home-intro p {
    max-width: 650px;
    margin: 0 auto;
    color: #766b84;
    font-size: 15px;
    line-height: 1.8;
}

/* CITY AND CATEGORY FILTERS */

.discovery-filters {
    position: relative;
    z-index: 5;
    width: 100%;
    box-sizing: border-box;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 22px;
    margin: 0 0 45px;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

.filter-control {
    position: relative;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.filter-control label {
    color: #40334f;
    font-size: 13px;
    font-weight: 700;
}

/* CITY SEARCH */

.city-search-wrapper {
    position: relative;
    width: 100%;
    max-width: 520px;
    height: 51px;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 14px;
    border: 1px solid #e6deef;
    border-radius: 11px;
    background: #fff;
    transition: border-color .2s, box-shadow .2s;
}

.city-search-wrapper:focus-within {
    border-color: #9b6be5;
    box-shadow: 0 0 0 3px rgba(124, 58, 237, .09);
}

.city-search-icon {
    flex: 0 0 auto;
    color: #8c829c;
    font-size: 23px;
    line-height: 1;
}

.city-search-wrapper input {
    width: 100%;
    min-width: 0;
    height: 100%;
    padding: 0;
    border: 0;
    outline: 0;
    background: transparent;
    color: #241b35;
    font-family: inherit;
    font-size: 14px;
}

.city-search-wrapper input::placeholder {
    color: #a49bad;
}

.city-search-wrapper input::-webkit-search-cancel-button {
    display: none;
}

.clear-filter-btn {
    flex: 0 0 auto;
    width: 27px;
    height: 27px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: #f2edfa;
    color: #6d28d9;
    font-size: 19px;
    line-height: 1;
    cursor: pointer;
}

.clear-filter-btn:hover {
    background: #e8def9;
}

/* CITY OPTIONS */

.city-options {
    position: absolute;
    left: 0;
    right: 0;
    z-index: 50;
    max-width: 520px;
    max-height: 250px;
    overflow-x: hidden;
    overflow-y: auto;
    padding: 6px;
    border: 1px solid #e9e1f2;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 12px 30px rgba(37, 20, 61, .13);
}

.city-option {
    width: 100%;
    min-height: 42px;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 12px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #40334f;
    font-family: inherit;
    font-size: 13px;
    text-align: left;
    cursor: pointer;
    transition: background .15s, color .15s;
}

.city-option:hover,
.city-option.selected {
    background: #f5f0ff;
    color: #6d28d9;
}

.city-option-check {
    flex: 0 0 auto;
    color: #7c3aed;
    font-weight: 800;
}

.city-option-empty {
    padding: 14px 12px;
    color: #887d99;
    font-size: 13px;
    text-align: center;
}

.city-options:empty {
    display: none;
}

/* CATEGORY CAROUSEL */

.category-filter-control {
    width: 100%;
    overflow: hidden;
}

.category-filter-control select {
    display: none !important;
}

.category-carousel {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 2px 1px 10px;
    scroll-behavior: smooth;
    scroll-snap-type: x proximity;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.category-carousel::-webkit-scrollbar {
    display: none;
}

.category-chip {
    flex: 0 0 auto;
    min-height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 18px;
    border: 1px solid #e8e0f1;
    border-radius: 999px;
    background: #fff;
    color: #625771;
    font-family: inherit;
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    cursor: pointer;
    scroll-snap-align: start;
    transition:
        background .2s,
        border-color .2s,
        color .2s,
        box-shadow .2s;
}

.category-chip:hover {
    border-color: #cbb5ef;
    background: #faf7ff;
    color: #6d28d9;
}

.category-chip.active {
    border-color: #7c3aed;
    background: #7c3aed;
    color: #fff;
    box-shadow: 0 4px 12px rgba(124, 58, 237, .18);
}

.category-chip:focus-visible {
    outline: 3px solid rgba(124, 58, 237, .2);
    outline-offset: 2px;
}

/* VENDOR SECTION */

.home-vendors {
    position: relative;
    z-index: 1;
    padding: 0 0 65px;
}

.home-section-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    margin-bottom: 23px;
}

.home-section-heading h2 {
    margin: 0;
    color: #241b35;
    font-size: clamp(25px, 3vw, 32px);
    font-weight: 800;
    letter-spacing: -1px;
    line-height: 1.3;
}

.vendor-result-count {
    flex: 0 0 auto;
    color: #82788f;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

/* VENDOR SEARCH */

.home-search {
    width: 100%;
    max-width: 550px;
    height: 52px;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 25px;
    padding: 0 16px;
    border: 1px solid #e9e1f2;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 4px 18px rgba(49, 26, 89, .045);
    transition: border-color .2s, box-shadow .2s;
}

.home-search:focus-within {
    border-color: #9b6be5;
    box-shadow: 0 0 0 3px rgba(124, 58, 237, .10);
}

.home-search > span {
    flex: 0 0 auto;
    color: #8c829c;
    font-size: 24px;
    line-height: 1;
}

.home-search input {
    flex: 1;
    width: 100%;
    min-width: 0;
    height: 100%;
    padding: 0;
    border: 0;
    outline: 0;
    background: transparent;
    color: #241b35;
    font-family: inherit;
    font-size: 14px;
}

.home-search input::placeholder {
    color: #a49bad;
}

/* VENDOR GRID */

.vendor-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: stretch;
    gap: 22px;
}

/* VENDOR CARD */

.vendor-card {
    min-width: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid #eee9f7;
    border-radius: 17px;
    background: #fff;
    color: inherit;
    text-decoration: none;
    box-shadow: 0 5px 22px rgba(49, 26, 89, .045);
    cursor: pointer;
    transition:
        transform .2s ease,
        box-shadow .2s ease,
        border-color .2s ease;
}

.vendor-card:hover {
    transform: translateY(-4px);
    border-color: #d8c9f7;
    box-shadow: 0 12px 30px rgba(76, 29, 149, .09);
}

.vendor-card-image {
    width: 100%;
    height: 180px;
    overflow: hidden;
    background: #eee8f8;
}

.vendor-card-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .35s;
}

.vendor-card:hover .vendor-card-image img {
    transform: scale(1.045);
}

.vendor-card-body {
    min-width: 0;
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 18px;
}

.vendor-card-body h3 {
    margin: 0 0 9px;
    color: #24133f;
    font-size: 17px;
    font-weight: 700;
    line-height: 1.4;
}

.vendor-card-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 7px;
    margin: 0 0 9px;
    color: #82788f;
    font-size: 12px;
    line-height: 1.5;
}

.vendor-meta-separator {
    color: #b7a9c8;
}

.vendor-card-description {
    min-height: 64px;
    margin: 0;
    overflow: hidden;
    color: #777084;
    font-size: 13px;
    line-height: 1.65;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

/* RATINGS */

.vendor-rating {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: 10px;
    color: #625a70;
    font-size: 13px;
}

.vendor-rating-star {
    color: #f59e0b;
    font-size: 16px;
    line-height: 1;
}

.vendor-rating-value {
    color: #291b3e;
    font-size: 13px;
    font-weight: 800;
}

.vendor-rating-count {
    color: #81798d;
    font-size: 12px;
}

.vendor-rating-new {
    color: #7c3aed;
    font-weight: 600;
}

/* CARD FOOTER */

.vendor-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: auto;
    padding-top: 15px;
    border-top: 1px solid #f0edf5;
    color: #7041c7;
    font-size: 13px;
    font-weight: 600;
}

.vendor-card-arrow {
    width: 30px;
    height: 30px;
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #f3edff;
    color: #6d28d9;
    font-size: 17px;
    transition: transform .2s ease;
}

.vendor-card:hover .vendor-card-arrow {
    transform: translateX(3px);
}

/* LOADING, EMPTY AND ERROR */

.vendor-loading {
    grid-column: 1 / -1;
    min-height: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px dashed #ded3ed;
    border-radius: 14px;
    background: #fcfaff;
    color: #887d99;
    font-size: 14px;
}

.vendor-empty,
.vendor-error {
    margin-top: 20px;
    padding: 42px 20px;
    border: 1px dashed #ded3ed;
    border-radius: 14px;
    background: #fcfaff;
    text-align: center;
}

.vendor-empty h3,
.vendor-error h3 {
    margin: 0 0 8px;
    color: #332444;
    font-size: 18px;
}

.vendor-empty p,
.vendor-error p {
    margin: 0;
    color: #887d99;
    font-size: 13px;
    line-height: 1.6;
}

.home-reset-btn {
    min-height: 42px;
    margin-top: 20px;
    padding: 0 20px;
    border: 0;
    border-radius: 10px;
    background: #7c3aed;
    color: #fff;
    font-family: inherit;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: background .2s, transform .2s;
}

.home-reset-btn:hover {
    transform: translateY(-1px);
    background: #6d28d9;
}

/* ABOUT TIXPINE */

.home-about {
    width: 100%;
    box-sizing: border-box;
    margin: 10px 0 75px;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    text-align: center;
}

.home-about h2 {
    margin: 12px auto;
    color: #291b3e;
    font-size: 27px;
    font-weight: 800;
    letter-spacing: -.8px;
}

.home-about p {
    max-width: 720px;
    margin: 0 auto;
    color: #766b84;
    font-size: 14px;
    line-height: 1.9;
}

/* NAVIGATION DRAWER */

.vendor-menu-backdrop {
    position: fixed;
    inset: 0;
    z-index: 90;
    visibility: hidden;
    background: rgba(24, 13, 39, .42);
    opacity: 0;
    transition: opacity .25s ease, visibility .25s ease;
}

.vendor-menu-backdrop.visible {
    visibility: visible;
    opacity: 1;
}

.vendor-menu {
    position: fixed;
    top: 0;
    right: 0;
    z-index: 100;
    width: min(340px, 88vw);
    height: 100%;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    padding: 25px;
    background: #fff;
    box-shadow: -12px 0 35px rgba(25, 12, 43, .12);
    transform: translateX(105%);
    transition: transform .28s ease;
}

.vendor-menu.open {
    transform: translateX(0);
}

.vendor-menu-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 22px;
    border-bottom: 1px solid #f0ebf7;
}

.vendor-menu-title {
    color: #291b3e;
    font-size: 19px;
    font-weight: 800;
}

.vendor-menu-close {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 10px;
    background: #f5f0ff;
    color: #6d28d9;
    font-size: 17px;
    cursor: pointer;
}

.vendor-menu-nav {
    display: flex;
    flex-direction: column;
    padding: 10px 1px 1px 1px;
}

.vendor-menu-link {
    display: flex;
    align-items: center;
    gap: 13px;
    padding: 14px 12px;
    border-radius: 11px;
    color: #40334f;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: background .2s, color .2s;
}

.vendor-menu-link:hover {
    background: #f6f1ff;
    color: #6d28d9;
}

.vendor-menu-icon {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 9px;
    background: #f3edff;
    color: #6d28d9;
}

.vendor-menu-arrow {
    margin-left: auto;
    color: #9b8eac;
}

/* FOOTER */

.home-footer {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 35px 20px;
    border-top: 1px solid #eee9f4;
    background: #fff;
    text-align: center;
}

.home-footer strong {
    color: #6d28d9;
    font-size: 22px;
    font-weight: 600;
    letter-spacing: -.7px;
}

.home-footer span {
    margin-top: 7px;
    color: #82788f;
    font-size: 12px;
}

.home-footer p {
    margin: 18px 0 0;
    color: #a39aaa;
    font-size: 11px;
    line-height: 1.6;
}

/* TABLET */

@media (max-width: 850px) {
    .home-main {
        padding-right: 22px;
        padding-left: 22px;
    }

    .vendor-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px;
    }

    .vendor-card-image {
        height: 170px;
    }

    .home-intro {
        margin-top: 28px;
    }
}

/* MOBILE */

@media (max-width: 600px) {
    .home-header {
        min-height: 65px;
        padding: 0 17px;
    }

    .home-header .brand-logo {
        font-size: 30px;
    }

    .home-header .brand-logo .brand-mark {
        font-size: 33px;
    }

    .home-header .vendor-menu-btn {
        width: 40px;
        height: 40px;
    }

    .home-main {
        padding: 0 17px;
    }

    .home-intro {
        margin: 0 0 20px;
        padding: 2px;
        text-align: center;
    }

    .home-intro h1 {
        margin-top: 11px;
        font-size: 22px;
        letter-spacing: -1px;
    }

    .home-intro p {
        font-size: 13px;
        line-height: 1.75;
    }

    .discovery-filters {
        gap: 19px;
        margin-bottom: 35px;
        padding: 0;
    }

    .filter-control label {
        font-size: 12px;
    }

    .city-search-wrapper {
        height: 48px;
    }

    .city-options {
        max-height: 220px;
    }

    .category-carousel {
        gap: 8px;
        padding-bottom: 8px;
    }

    .category-chip {
        min-height: 37px;
        padding: 0 15px;
        font-size: 12px;
    }

    .home-vendors {
        padding-bottom: 45px;
    }

    .home-section-heading {
        align-items: center;
        gap: 8px;
        margin-bottom: 19px;
    }

    .home-section-heading h2 {
        font-size: 22px;
    }

    .vendor-result-count {
        font-size: 11px;
    }

    .home-search {
        height: 48px;
        margin-bottom: 20px;
    }

    .home-search input {
        font-size: 12px;
    }

    .vendor-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .vendor-card {
        display: grid;
        grid-template-columns: 118px minmax(0, 1fr);
        border-radius: 13px;
    }

    .vendor-card-image {
        height: 100%;
        min-height: 155px;
    }

    .vendor-card-body {
        padding: 12px;
    }

    .vendor-card-body h3 {
        margin-bottom: 6px;
        font-size: 14px;
    }

    .vendor-card-meta {
        gap: 5px;
        margin-bottom: 7px;
        font-size: 10px;
    }

    .vendor-card-description {
        min-height: 0;
        margin-bottom: 8px;
        font-size: 11px;
        line-height: 1.5;
        -webkit-line-clamp: 2;
    }

    .vendor-card-footer {
        padding-top: 8px;
        font-size: 11px;
    }

    .vendor-card-arrow {
        width: 25px;
        height: 25px;
        font-size: 15px;
    }

    .vendor-rating {
        gap: 4px;
        margin-top: 6px;
        font-size: 11px;
    }

    .vendor-rating-star {
        font-size: 13px;
    }

    .vendor-rating-value {
        font-size: 11px;
    }

    .vendor-rating-count {
        font-size: 10px;
    }

    .vendor-empty,
    .vendor-error {
        padding: 32px 16px;
    }

    .home-about {
        margin: 0 0 45px;
        padding: 0;
        text-align: center;
    }

    .home-about h2 {
        font-size: 23px;
    }

    .home-about p {
        font-size: 13px;
    }

    .home-footer {
        padding: 28px 16px;
    }
}

/* SMALL MOBILE */

@media (max-width: 360px) {
    .home-main {
        padding-right: 13px;
        padding-left: 13px;
    }

    .home-header {
        padding-right: 13px;
        padding-left: 13px;
    }

    .home-intro h1 {
        font-size: 22px;
    }

    .home-section-heading h2 {
        font-size: 20px;
    }

    .vendor-card {
        grid-template-columns: 102px minmax(0, 1fr);
    }

    .vendor-card-body {
        padding: 10px;
    }

    .category-chip {
        padding: 0 13px;
    }
}
