/*
Theme Name: KTPros Marketplace
Description: Local marketplace presentation for the KTPros HivePress prototype.
Template: listinghive
Version: 0.2.5
Text Domain: ktpros-marketplace
*/

:root {
    --kt-navy: #14283F;
    --kt-navy-deep: #102135;
    --kt-amber: #FFB547;
    --kt-gray: #F4F6F8;
    --kt-white: #FFFFFF;
    --kt-teal: #188477;
    --kt-teal-ink: #135f57;
    --kt-muted: #4f5d6b;
    --kt-border: #dbe2e8;
    --kt-radius: 16px;
    --kt-shadow: 0 10px 25px rgb(20 40 63 / 8%);
    --kt-shell: 1256px;
    --kt-gutter: clamp(16px, 4vw, 44px);
}

body {
    background: var(--kt-gray);
    color: var(--kt-navy);
    font-family: system-ui, "Segoe UI", sans-serif;
    font-size: 1rem;
}

.kt-shell,
body.home .site-content > .container {
    width: min(calc(100% - 2 * var(--kt-gutter)), var(--kt-shell));
    max-width: none;
    padding-inline: 0;
    margin-inline: auto;
}

.kt-header,
.kt-home,
.kt-footer {
    line-height: 1.5;
}

.kt-sr {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    clip-path: inset(50%);
    overflow: hidden;
    white-space: nowrap;
}

.skip-link.screen-reader-text:focus {
    z-index: 100000;
    inset: 12px auto auto 12px;
    width: auto;
    height: auto;
    margin: 0;
    padding: 10px 16px;
    clip: auto;
    clip-path: none;
    border-radius: 8px;
    background: var(--kt-amber);
    color: var(--kt-navy);
    font-weight: 750;
}

.kt-header a:focus-visible,
.kt-header button:focus-visible,
.kt-header input:focus-visible,
.kt-header select:focus-visible,
.kt-footer a:focus-visible {
    outline: 3px solid var(--kt-amber);
    outline-offset: 3px;
}

.kt-home a:focus-visible,
.kt-home button:focus-visible,
.kt-home input:focus-visible,
.site-content :is(a, button, input, select, textarea):focus-visible {
    outline: 3px solid var(--kt-teal-ink);
    outline-offset: 3px;
}

.kt-header {
    position: relative;
    z-index: 3;
    background: var(--kt-navy-deep);
    color: var(--kt-white);
}

.kt-header__row {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: clamp(16px, 2.8vw, 40px);
    min-height: 80px;
    padding-block: 14px;
}

.kt-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    align-self: center;
    flex-shrink: 0;
    color: var(--kt-white);
    font-weight: 800;
    font-size: 1.55rem;
    letter-spacing: -.055em;
    text-decoration: none;
    white-space: nowrap;
}

.kt-brand:hover,
.kt-brand:focus {
    color: var(--kt-white);
    text-decoration: none;
}

.kt-brand__mark {
    display: grid;
    width: 36px;
    height: 36px;
    place-items: center;
    border-radius: 11px 11px 11px 4px;
    background: var(--kt-amber);
    color: var(--kt-navy);
    font-size: 1.16rem;
    line-height: 1;
    letter-spacing: 0;
}

.kt-brand__accent {
    color: var(--kt-amber);
}

.kt-header__search {
    min-width: 0;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: stretch;
    gap: 10px;
    margin: 0;
}

.kt-header__city {
    display: grid;
    align-content: center;
    min-width: 0;
    width: clamp(122px, 13vw, 157px);
    border: 1px solid #4c6074;
    border-radius: 9px;
    line-height: 1.2;
}

.kt-header__city label {
    position: absolute;
    top: 6px;
    left: 10px;
    margin: 0;
    pointer-events: none;
    color: #cdd8e4;
    font-size: .875rem;
}

.kt-header__city select {
    appearance: none;
    min-width: 0;
    width: 100%;
    min-height: 44px;
    padding: 18px 22px 3px 10px;
    background: transparent;
    border: 0;
    border-radius: 8px;
    color: var(--kt-white);
    font: inherit;
    font-size: .875rem;
    font-weight: 650;
    cursor: pointer;
}

.kt-header__city select option {
    color: var(--kt-navy);
    background: var(--kt-white);
}

.kt-header__city {
    position: relative;
}

.kt-header__city::after {
    content: "";
    position: absolute;
    right: 12px;
    bottom: 12px;
    width: 7px;
    height: 7px;
    border: solid var(--kt-amber);
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
    pointer-events: none;
}

.kt-searchbar {
    min-width: 0;
    display: flex;
    align-items: stretch;
    border-radius: 10px;
    isolation: isolate;
    background: var(--kt-white);
    outline: 1px solid transparent;
}

.kt-searchbar input[type="search"] {
    box-sizing: border-box;
    min-width: 0;
    width: 100%;
    min-height: 46px;
    margin: 0;
    padding: 10px 14px;
    background: var(--kt-white);
    color: var(--kt-navy);
    border: 1px solid var(--kt-border);
    border-right: 0;
    border-radius: 10px 0 0 10px;
    font: inherit;
    font-size: 1rem;
}

.kt-searchbar input::placeholder {
    color: var(--kt-muted);
    opacity: 1;
}

.kt-searchbar button,
.kt-button-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 46px;
    padding: 9px 18px;
    border: 0;
    background: var(--kt-amber);
    color: var(--kt-navy-deep);
    font: inherit;
    font-weight: 760;
    white-space: nowrap;
    text-decoration: none;
    cursor: pointer;
}

.kt-searchbar button {
    border-radius: 0 10px 10px 0;
}

.kt-searchbar button:hover,
.kt-button-primary:hover {
    background: #ffc570;
    color: var(--kt-navy-deep);
    text-decoration: none;
}

.kt-search-icon {
    display: inline-block;
    width: 15px;
    height: 15px;
    border: 2px solid currentColor;
    border-radius: 50%;
    position: relative;
    flex: 0 0 auto;
    margin-right: 2px;
}

.kt-search-icon::after {
    content: "";
    position: absolute;
    top: 10px;
    left: 10px;
    width: 6px;
    height: 2px;
    border-radius: 2px;
    background: currentColor;
    transform: rotate(45deg);
    transform-origin: left center;
}

.kt-header__actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 15px;
    white-space: nowrap;
}

.kt-header__actions a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    color: var(--kt-white);
    text-decoration: none;
    font-size: .9rem;
    font-weight: 700;
}

.kt-header__actions a:hover {
    color: var(--kt-amber);
}

.kt-header__actions .kt-header__list {
    padding: 6px 12px;
    color: var(--kt-amber);
    border: 1px solid #a88450;
    border-radius: 9px;
}

.kt-header__actions .kt-header__list:hover {
    border-color: var(--kt-amber);
    background: #263c53;
}

.kt-category-nav {
    background: #203950;
}

.kt-category-nav__list {
    display: flex;
    align-items: stretch;
    gap: clamp(17px, 2.8vw, 38px);
    padding: 0;
    margin-block: 0;
    list-style: none;
    overflow-x: auto;
    scrollbar-width: thin;
    scrollbar-color: #71889e #203950;
}

.kt-category-nav__list li {
    margin: 0;
    flex: 0 0 auto;
}

.kt-category-nav a {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 45px;
    padding: 4px 2px;
    color: #edf3f8;
    font-size: .9rem;
    font-weight: 620;
    white-space: nowrap;
    text-decoration: none;
    border-bottom: 2px solid transparent;
}

.kt-category-nav a:hover,
.kt-category-nav a[aria-current="page"],
.kt-category-nav .kt-all-categories {
    color: var(--kt-amber);
}

.kt-category-nav a[aria-current="page"] {
    border-color: var(--kt-amber);
}

.kt-category-nav a:focus-visible {
    outline-offset: -3px;
}

.kt-nav-icon {
    width: 15px;
    height: 11px;
    border-block: 2px solid currentColor;
    display: inline-grid;
    align-items: center;
}

.kt-nav-icon::before {
    content: "";
    height: 2px;
    background: currentColor;
}

body.home .site-content {
    padding: 18px 0 50px;
}

.kt-home h1,
.kt-home h2,
.kt-home h3 {
    margin: 0;
    color: var(--kt-navy);
    font: inherit;
    font-weight: 790;
    letter-spacing: -.034em;
}

.kt-home h2 {
    font-size: clamp(1.42rem, 2.75vw, 2rem);
    line-height: 1.2;
}

.kt-hero {
    overflow: hidden;
    border: 1px solid var(--kt-border);
    border-radius: var(--kt-radius);
    background: var(--kt-white);
    box-shadow: var(--kt-shadow);
}

.kt-hero__top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px 16px;
    padding: 8px clamp(16px, 3vw, 34px);
}

.kt-hero__top h1 {
    font-size: clamp(1rem, 2vw, 1.375rem);
    line-height: 1.3;
    letter-spacing: -.02em;
}

.kt-hero__controls {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 7px;
}

.kt-hero__controls[hidden] {
    display: flex;
    visibility: hidden;
}

.kt-hero__controls button {
    min-height: 44px;
    padding: 4px 9px;
    border: 1px solid var(--kt-border);
    border-radius: 8px;
    background: var(--kt-white);
    color: var(--kt-navy);
    font: inherit;
    font-size: .875rem;
    font-weight: 650;
    cursor: pointer;
}

.kt-hero__controls [data-rotation] {
    min-inline-size: 7.125rem;
}

.kt-hero__controls button:hover {
    background: var(--kt-amber);
}

.kt-hero__controls [aria-disabled="true"] {
    color: var(--kt-muted);
    background: var(--kt-gray);
    cursor: default;
}

.kt-hero__controls [data-count] {
    display: grid;
    min-inline-size: 6ch;
    color: var(--kt-muted);
    font-size: .875rem;
    font-variant-numeric: tabular-nums;
    text-align: center;
}

[data-count] > span {
    grid-area: 1 / 1;
}

[data-count-size] {
    visibility: hidden;
}

/* Groups share one row so the tallest item reserves its height before rotation. */
.kt-hero__slides {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    background: linear-gradient(115deg, #fff7e8, var(--kt-white) 72%);
}

.kt-hero__slides > .kt-banner {
    display: grid;
    grid-template-columns: minmax(0, .95fr) minmax(0, 1.05fr);
    min-height: clamp(216px, 23vw, 300px);
}


.kt-hero__item {
    grid-row: 1;
    grid-column: var(--kt-slot-small);
    min-width: 0;
    visibility: hidden;
}

.kt-hero__slides[data-ready] > :not([hidden]) {
    visibility: visible;
}

@media (width < 768px) {
    .kt-hero__slides:not([data-ready]) > [data-group-small="0"] {
        visibility: visible;
    }
}

@media (768px <= width < 1200px) {
    .kt-hero__item {
        grid-column: var(--kt-slot-medium);
    }

    .kt-hero__slides:not([data-ready]) > [data-group-medium="0"] {
        visibility: visible;
    }
}

@media (width >= 1200px) {
    .kt-hero__item {
        grid-column: var(--kt-slot-large);
    }

    .kt-hero__slides:not([data-ready]) > [data-group-large="0"] {
        visibility: visible;
    }
}

.kt-hero__item--business {
    display: flex;
    padding: clamp(7px, 1vw, 14px);
}

.kt-hero-business {
    display: flex;
    flex: 1;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
    border: 1px solid var(--kt-border);
    border-radius: 12px;
    background: var(--kt-white);
    color: var(--kt-navy);
}

.kt-hero-business__image {
    position: relative;
    height: clamp(110px, 15vw, 186px);
    background: var(--kt-gray);
}

.kt-hero-business__image img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.kt-hero-business__body {
    display: flex;
    flex: 1;
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
    padding: clamp(14px, 1.5vw, 22px);
    overflow-wrap: anywhere;
}

.kt-hero-business__body h2 {
    font-size: clamp(1.25rem, 2vw, 1.7rem);
    line-height: 1.15;
}

.kt-hero-business__body p {
    margin: 0;
    color: var(--kt-muted);
    font-size: .9375rem;
    line-height: 1.4;
}

.kt-hero-business__body .kt-hero-business__category {
    color: var(--kt-teal-ink);
    font-weight: 700;
}

.kt-hero-business__city,
.kt-hero-business__headline {
    font-weight: 650;
}

.kt-hero-business__action {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 44px;
    margin-top: auto;
    padding-top: 6px;
    color: var(--kt-teal-ink);
    font-weight: 750;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.kt-hero-business:hover .kt-hero-business__action {
    color: var(--kt-navy);
}

.kt-banner__copy {
    align-self: center;
    padding: clamp(22px, 4vw, 54px);
    overflow-wrap: anywhere;
}

.kt-banner__copy h2 {
    font-size: clamp(1.7rem, 4vw, 3.25rem);
    line-height: 1.07;
    text-wrap: balance;
}

.kt-banner__copy p {
    max-width: 52ch;
    margin: 10px 0 16px;
    color: var(--kt-muted);
}

.kt-banner__copy .kt-button-primary {
    min-height: 44px;
}

.kt-banner__image {
    position: relative;
    min-width: 0;
    background: var(--kt-gray);
}

.kt-banner__image img {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.kt-sample-label {
    display: inline-block;
    width: fit-content;
    margin-block: 3px;
    padding: 2px 8px;
    border-radius: 999px;
    background: #fff1db;
    color: var(--kt-navy);
    font-size: .8rem;
    font-weight: 700;
}

.kt-text-link {
    color: var(--kt-teal-ink);
    font-weight: 730;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.kt-section {
    margin-top: clamp(29px, 4.2vw, 54px);
}

.kt-section__head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 6px 18px;
    margin-bottom: 16px;
}

.kt-category-grid,
.kt-business-grid,
.kt-services {
    display: grid;
    padding: 0;
    margin: 0;
    list-style: none;
}

.kt-category-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: clamp(9px, 1.6vw, 19px);
}

.kt-category-grid li,
.kt-business-grid li,
.kt-services li {
    min-width: 0;
    margin: 0;
}

.kt-category-tile {
    display: grid;
    height: 100%;
    min-height: 132px;
    grid-template-rows: auto 1fr;
    gap: 10px;
    padding: 9px 9px 12px;
    border: 1px solid var(--kt-border);
    border-radius: var(--kt-radius);
    background: var(--kt-white);
    box-shadow: 0 5px 12px rgb(20 40 63 / 5%);
    color: var(--kt-navy);
    text-align: center;
    text-decoration: none;
    font-size: .9375rem;
    font-weight: 750;
}

.kt-category-tile__image,
.kt-business-card__image {
    position: relative;
    overflow: hidden;
    border-radius: 11px;
    background: linear-gradient(145deg, #d2e7e3, #f6e4c8);
}

.kt-category-tile__image {
    aspect-ratio: 1.62;
}

.kt-category-grid li:nth-child(3n + 2) .kt-category-tile__image {
    background: linear-gradient(145deg, #ece1d1, #f3ecde);
}

.kt-category-grid li:nth-child(3n + 3) .kt-category-tile__image {
    background: linear-gradient(145deg, #d8e3ed, #e8eef3);
}

.kt-category-tile img,
.kt-business-card__image img {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.kt-category-tile:hover,
.kt-business-card:hover,
.kt-services a:hover {
    border-color: var(--kt-teal);
    color: var(--kt-navy);
    text-decoration: none;
    box-shadow: var(--kt-shadow);
}

.kt-business-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: clamp(12px, 1.65vw, 21px);
}

.kt-business-card {
    display: grid;
    grid-template-rows: auto 1fr;
    padding: 9px;
    height: 100%;
    border: 1px solid var(--kt-border);
    border-radius: var(--kt-radius);
    background: var(--kt-white);
    color: var(--kt-navy);
    text-decoration: none;
}

.kt-business-card__image {
    width: 100%;
    min-height: 0;
    aspect-ratio: 1.85;
}

.kt-business-card__body {
    padding: 12px 7px 7px;
}

.kt-business-card__category {
    display: inline-block;
    color: var(--kt-teal-ink);
    font-size: .875rem;
    font-weight: 740;
}

.kt-business-card h3 {
    margin: 3px 0 5px;
    line-height: 1.2;
    font-size: 1.12rem;
}

.kt-business-card__city,
.kt-business-card__description {
    margin: 0 0 7px;
    color: var(--kt-muted);
    font-size: .9rem;
}

.kt-business-card__city {
    font-weight: 650;
}

.kt-business-card__description {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    overflow: hidden;
    line-height: 1.45;
}

.kt-services {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.kt-services a {
    display: flex;
    align-items: center;
    gap: 15px;
    min-height: 54px;
    padding: 10px 15px;
    border: 1px solid var(--kt-border);
    border-radius: 12px;
    background: var(--kt-white);
    color: var(--kt-navy);
    font-weight: 700;
    text-decoration: none;
}

.kt-services .kt-search-icon {
    color: var(--kt-teal-ink);
}

.kt-explore {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 13px;
}

.kt-explore__tile {
    display: grid;
    align-content: center;
    gap: 6px;
    min-height: 142px;
    padding: 20px clamp(17px, 3vw, 36px);
    border: 1px solid var(--kt-border);
    border-radius: var(--kt-radius);
    color: var(--kt-navy);
    text-decoration: none;
}

.kt-explore__tile--local {
    background: #fff3dc;
    border-color: #f0d8af;
}

.kt-explore__tile--region {
    background: #e6f4f0;
    border-color: #c5e3dc;
}

.kt-explore__tile h3 {
    font-size: clamp(1.3rem, 2.4vw, 1.8rem);
    line-height: 1.2;
}

.kt-explore__tile:hover {
    color: var(--kt-navy);
    text-decoration: none;
    border-color: var(--kt-teal);
}

.kt-owner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    margin-top: clamp(25px, 4vw, 42px);
    padding: clamp(20px, 3.6vw, 36px);
    border-radius: var(--kt-radius);
    background: var(--kt-navy);
    color: var(--kt-white);
}

.kt-owner h2 {
    color: var(--kt-white);
}

.kt-owner p {
    margin: 6px 0 0;
    color: #e1e9f1;
}

.kt-button-primary {
    border-radius: 10px;
}

.kt-owner a:focus-visible {
    outline-color: var(--kt-amber);
}

.kt-footer {
    background: var(--kt-navy-deep);
    color: #d4dfe9;
}

.kt-footer__row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 18px;
    padding-block: 27px;
}

.kt-footer p {
    margin: 8px 0 0;
    font-size: .875rem;
}

.kt-footer nav {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0 20px;
}

.kt-footer nav a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    color: #edf3f8;
    font-weight: 650;
    font-size: .9rem;
    text-decoration: none;
}

.kt-footer nav a:hover {
    text-decoration: underline;
}

.hp-listing__title a,
.hp-page__title,
.hp-listing__title {
    color: var(--kt-navy);
}

@media (max-width: 980px) {
    .kt-header__row {
        grid-template-columns: minmax(0, 1fr) auto;
        gap: 10px 14px;
    }

    .kt-header__search {
        order: 3;
        grid-column: 1 / -1;
    }

    .kt-header__actions {
        grid-column: 2;
    }

    .kt-category-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .kt-business-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

}

@media (max-width: 610px) {
    body.home .site-content {
        padding-block: 12px 30px;
    }

    .kt-hero__slides > .kt-banner {
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: 1fr auto;
    }

    .kt-banner__copy {
        padding: 20px 16px;
    }

    .kt-banner__image {
        height: clamp(124px, 34vw, 182px);
    }

    .kt-category-grid,
    .kt-services {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .kt-category-tile {
        min-height: 120px;
    }

    .kt-owner,
    .kt-footer__row {
        flex-direction: column;
        align-items: flex-start;
    }

    .kt-explore {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 450px) {
    .kt-header__row {
        gap: 9px 8px;
    }

    .kt-header .kt-brand {
        gap: 7px;
        font-size: 1.32rem;
    }

    .kt-header .kt-brand__mark {
        width: 31px;
        height: 31px;
        font-size: 1rem;
    }

    .kt-header__actions {
        gap: 9px;
    }

    .kt-header__actions a {
        font-size: .875rem;
    }

    .kt-header__actions .kt-header__list {
        padding-inline: 8px;
    }

    .kt-header__search {
        gap: 7px;
    }

    .kt-header__city {
        width: 119px;
    }

    .kt-header__city label {
        left: 8px;
    }

    .kt-header__city select {
        padding-left: 8px;
    }

    .kt-header__city::after {
        right: 8px;
    }

    .kt-header .kt-searchbar input[type="search"] {
        padding-inline: 8px;
    }

    .kt-header .kt-searchbar button {
        min-width: 44px;
        padding-inline: 11px;
    }

    .kt-header .kt-searchbar button > span:last-child {
        position: absolute;
        clip-path: inset(50%);
        width: 1px;
        height: 1px;
        overflow: hidden;
    }

    .kt-business-card__body {
        padding-inline: 4px;
    }

    .kt-services a {
        gap: 10px;
        padding-inline: 10px;
        font-size: .9375rem;
    }
}

@media (prefers-reduced-motion: no-preference) {
    .kt-category-tile,
    .kt-business-card,
    .kt-services a,
    .kt-explore__tile {
        transition: border-color .16s ease, box-shadow .16s ease;
    }
}
