/* teslim.ai product and store listing; built on the marketing site's style.css tokens. */
.shop-main {
    background: var(--bg-page);
}

/* Components below set their own display, which would otherwise override the hidden attribute. */
.shop-main [hidden] {
    display: none !important;
}

.shop-shell {
    max-width: 1200px;
    margin: 0 auto;
    padding: 32px 24px 72px;
}

.shop-hero {
    position: relative;
    overflow: hidden;
    background: linear-gradient(120deg, var(--brand-blue-light) 0%, var(--bg-page) 70%);
    border-bottom: 1px solid var(--border);
}

.shop-hero::before,
.shop-hero::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    background: var(--brand-accent);
    opacity: 0.08;
    pointer-events: none;
}

.shop-hero::before {
    width: 420px;
    height: 420px;
    right: -120px;
    top: -220px;
}

.shop-hero::after {
    width: 220px;
    height: 220px;
    right: 220px;
    bottom: -150px;
}

.shop-hero-inner {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    padding: 36px 24px 40px;
}

.shop-hero h1 {
    margin: 10px 0 6px;
    overflow-wrap: anywhere;
    font-size: clamp(28px, 5vw, 44px);
    line-height: 1.15;
    color: var(--text-primary);
}

.shop-hero-text {
    margin: 0;
    font-size: clamp(15px, 2vw, 18px);
    color: var(--text-secondary);
}

.shop-trail {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px;
    font-size: 14px;
    color: var(--text-muted);
}

.shop-trail a {
    color: var(--text-secondary);
    text-decoration: none;
}

.shop-trail a:hover,
.shop-trail a[aria-current="page"] {
    color: var(--brand-accent-text);
}

.shop-icon {
    flex: 0 0 auto;
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.shop-toolbar {
    display: flex;
    gap: 12px;
    margin-left: auto;
    align-self: center;
}

.shop-sort select {
    min-width: 220px;
    padding: 10px 12px;
    font: inherit;
    font-size: 14px;
    color: var(--text-primary);
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
}

.shop-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin: 0 0 20px;
}

.shop-section-title {
    margin: 0;
    font-size: clamp(20px, 3vw, 26px);
    color: var(--text-primary);
}

.shop-section-title .shop-count {
    font-weight: 400;
}

.shop-count {
    color: var(--text-muted);
    font-size: 15px;
}

.shop-layout {
    display: grid;
    grid-template-columns: 260px minmax(0, 1fr);
    gap: 24px;
    align-items: start;
}

.shop-filters {
    position: sticky;
    top: 88px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    padding: 22px;
}

.shop-filter + .shop-filter {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

.shop-filter h2 {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 12px;
    font-size: 16px;
    color: var(--text-primary);
}

.shop-filter h2 .shop-icon {
    color: var(--brand-accent-text);
}

.shop-category-list {
    list-style: none;
    margin: 0;
    padding: 0;
    max-height: 320px;
    overflow-y: auto;
    padding-right: 12px;
    scrollbar-gutter: stable;
}

.shop-category-list a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 7px 8px;
    font-size: 14px;
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: var(--radius-sm);
}

.shop-category-list a:hover {
    color: var(--brand-accent-text);
}

.shop-category-list a[aria-current="page"] {
    font-weight: 600;
    color: var(--text-primary);
    background: var(--brand-blue-light);
}

.shop-category-name {
    flex: 1;
    min-width: 0;
    overflow-wrap: anywhere;
}

.shop-check {
    flex: 0 0 16px;
    height: 16px;
    border: 1.5px solid var(--border);
    border-radius: 4px;
    background: var(--bg-card);
}

.shop-category-list a[aria-current="page"] .shop-check {
    border-color: var(--brand-accent);
    background: var(--brand-accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m5 12 5 5 9-10'/%3E%3C/svg%3E") center / 12px no-repeat;
}

.shop-category-list small {
    color: var(--text-muted);
}

.shop-price-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.shop-price-row input {
    width: 100%;
    min-width: 0;
    padding: 10px 12px;
    font: inherit;
    font-size: 14px;
    color: var(--text-primary);
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
}

.shop-price-row input:focus,
.shop-sort select:focus {
    outline: none;
    border-color: var(--border-focus);
}

.shop-filter-apply {
    width: 100%;
    margin-top: 20px;
}

.shop-filter-clear {
    display: block;
    margin-top: 12px;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    color: var(--brand-accent-text);
}

.shop-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px;
}

.shop-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    color: inherit;
    text-decoration: none;
    transition: box-shadow 0.2s, transform 0.2s;
}

.shop-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.shop-card-link {
    display: flex;
    flex-direction: column;
    flex: 1;
    color: inherit;
    text-decoration: none;
}

.shop-card-add {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin: 0 14px 14px;
    padding: 10px 12px;
    font: inherit;
    font-size: 14px;
    font-weight: 600;
    color: #fff;
    background: var(--brand-blue);
    border: 0;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: filter 0.2s;
}

.shop-card-add:hover {
    filter: brightness(1.1);
}

.shop-card-add.is-added {
    background: var(--success);
}

.shop-header-cart {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.shop-header-cart .shop-icon {
    width: 20px;
    height: 20px;
}

.shop-cart-count {
    min-width: 22px;
    padding: 1px 6px;
    font-size: 12px;
    font-weight: 700;
    line-height: 18px;
    text-align: center;
    color: var(--brand-blue);
    background: #fff;
    border-radius: var(--radius-full);
}

.shop-card-image {
    aspect-ratio: 1;
    padding: 8px;
    background: #fff;
    border-bottom: 1px solid var(--border);
}

.shop-card-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.shop-card-body {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 12px 14px 14px;
    flex: 1;
}

.shop-card-store {
    font-size: 12px;
    font-weight: 600;
    color: var(--brand-accent-text);
}

.shop-card-name {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    overflow-wrap: anywhere;
    font-size: 14px;
    line-height: 1.4;
    color: var(--text-primary);
}

.shop-card-price {
    margin-top: auto;
    padding-top: 6px;
    font-size: 17px;
    color: var(--text-primary);
}

.shop-more {
    display: flex;
    justify-content: center;
    margin-top: 28px;
}

.shop-more-button {
    min-width: 220px;
    color: var(--brand-accent-text);
    background: var(--bg-card);
    border: 1px solid var(--border);
}

.shop-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 56px 16px;
    text-align: center;
    color: var(--text-secondary);
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
}

.shop-empty-icon {
    width: 40px;
    height: 40px;
    fill: none;
    stroke: var(--text-muted);
    stroke-width: 2;
    stroke-linecap: round;
}

.shop-store-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
    gap: 16px;
}

.shop-store-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 18px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    color: inherit;
    text-decoration: none;
    transition: box-shadow 0.2s, transform 0.2s;
}

.shop-store-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.shop-store-logo {
    display: grid;
    place-items: center;
    flex: 0 0 64px;
    height: 64px;
    overflow: hidden;
    border-radius: var(--radius-md);
    background: var(--brand-blue-light);
    color: var(--brand-accent-text);
}

.shop-store-logo img {
    width: 64px;
    height: 64px;
    object-fit: cover;
    background: #fff;
}

.shop-store-initial {
    font-size: 28px;
    font-weight: 700;
}

.shop-avatar-1 { background: #fde8ec; color: #c2335a; }
.shop-avatar-2 { background: #e8f6ec; color: #2c7a47; }
.shop-avatar-3 { background: #efeafd; color: #6247c2; }
.shop-avatar-4 { background: #fdf1e3; color: #b3621b; }
.shop-avatar-5 { background: #edf0f3; color: #4a5866; }

html[data-theme="dark"] .shop-card-add {
    color: #04121f;
    background: #009fe3;
}

html[data-theme="dark"] .shop-card-add.is-added {
    background: #4caf50;
}

html[data-theme="dark"] .shop-avatar-1 { background: #3a1621; color: #f59ab3; }
html[data-theme="dark"] .shop-avatar-2 { background: #12301c; color: #8fd8a6; }
html[data-theme="dark"] .shop-avatar-3 { background: #241c45; color: #b9a8f5; }
html[data-theme="dark"] .shop-avatar-4 { background: #3a2410; color: #f3b77a; }
html[data-theme="dark"] .shop-avatar-5 { background: #1c2733; color: #b8c6d8; }

.shop-store-body {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
    flex: 1;
}

.shop-store-body strong {
    font-size: 17px;
    overflow-wrap: break-word;
    color: var(--text-primary);
}

.shop-store-description {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 14px;
    color: var(--text-secondary);
}

.shop-store-body small {
    color: var(--text-muted);
}

.shop-store-cta {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex: 0 0 auto;
    padding-left: 16px;
    font-size: 14px;
    font-weight: 600;
    color: var(--brand-accent-text);
    border-left: 1px solid var(--border);
}

.shop-filter-toggle {
    display: none;
}

/* Shared cart (/sepet) */
.cart-loading {
    padding: 40px 0;
    color: var(--text-muted);
}

.cart-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 24px;
    align-items: start;
}

.cart-main {
    display: flex;
    flex-direction: column;
    gap: 16px;
    min-width: 0;
}

.cart-stores {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.cart-card {
    padding: 22px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}

.cart-card h2 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 18px;
    font-size: 19px;
    color: var(--text-primary);
}

.cart-card h2 .shop-icon {
    width: 22px;
    height: 22px;
    color: var(--brand-accent-text);
}

.cart-card h3 {
    margin: 0 0 10px;
    font-size: 15px;
    color: var(--text-primary);
}

.cart-summary {
    position: sticky;
    top: 88px;
}

.cart-store-head {
    margin: -22px -22px 6px;
    padding: 16px 22px;
    border-bottom: 1px solid var(--border);
}

.cart-store-head + .cart-line {
    border-top: 0;
}

.cart-store-name::before {
    content: "";
    flex: 0 0 22px;
    height: 22px;
    background: var(--brand-accent-text);
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 10v9h16v-9M3 6l2-3h14l2 3v2a3 3 0 0 1-6 0 3 3 0 0 1-6 0 3 3 0 0 1-6 0V6ZM10 19v-5h4v5'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 10v9h16v-9M3 6l2-3h14l2 3v2a3 3 0 0 1-6 0 3 3 0 0 1-6 0 3 3 0 0 1-6 0V6ZM10 19v-5h4v5'/%3E%3C/svg%3E") center / contain no-repeat;
}

.cart-store-name {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    text-decoration: none;
    overflow-wrap: anywhere;
}

.cart-line {
    display: grid;
    grid-template-columns: 72px minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    padding: 12px 0;
    border-top: 1px solid var(--border);
}

.cart-line-image {
    width: 72px;
    height: 72px;
    border: 1px solid var(--border);
    object-fit: contain;
    background: #fff;
    border-radius: var(--radius-sm);
}

.cart-line-body {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.cart-line-name {
    font-size: 14px;
    color: var(--text-primary);
    overflow-wrap: anywhere;
}

.cart-line-options {
    color: var(--text-muted);
}

.cart-line-total {
    font-size: 15px;
    color: var(--text-primary);
    white-space: nowrap;
}

.cart-line-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.cart-remove {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    color: var(--text-muted);
    background: none;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
}

.cart-remove:hover {
    color: var(--danger);
    border-color: var(--danger);
}

.cart-stepper {
    display: inline-flex;
    align-items: center;
    align-self: flex-start;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
}

.cart-step {
    width: 36px;
    height: 34px;
    font-size: 18px;
    color: var(--text-primary);
    background: none;
    border: 0;
    cursor: pointer;
}

.cart-step:disabled {
    color: var(--text-muted);
    cursor: default;
}

.cart-quantity {
    min-width: 28px;
    font-size: 14px;
    text-align: center;
    color: var(--text-primary);
}

.cart-delivery {
    margin-top: 12px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
}

.cart-delivery-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.cart-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    transition: border-color 0.2s, background 0.2s;
    cursor: pointer;
}

.cart-option input {
    accent-color: var(--brand-accent);
}

.cart-option:has(input:checked) {
    border-color: var(--brand-accent);
    box-shadow: 0 0 0 1px var(--brand-accent);
    background: var(--brand-blue-light);
}

.cart-option.is-unavailable {
    opacity: 0.6;
}

.cart-option-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
}

.cart-option-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

.cart-option-detail {
    font-size: 13px;
    color: var(--text-muted);
}

.cart-option-fee {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
}

.cart-option-fee.is-free {
    color: var(--success);
}

.cart-store-totals {
    margin-top: 10px;
}

.cart-total-row {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 4px 0;
    font-size: 14px;
    color: var(--text-secondary);
}

.cart-grand-total {
    align-items: center;
    margin-top: 12px;
    padding: 14px 16px;
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    background: var(--brand-blue-light);
    border-radius: var(--radius-md);
}

.cart-grand-total strong {
    font-size: 24px;
}

.cart-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 14px;
}

.cart-field label {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

.cart-field small {
    font-weight: 400;
    color: var(--text-muted);
}

.cart-field input,
.cart-field textarea,
.cart-field select {
    width: 100%;
    padding: 10px 12px;
    font: inherit;
    font-size: 15px;
    color: var(--text-primary);
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
}

.cart-field input:focus,
.cart-field textarea:focus,
.cart-field select:focus {
    outline: none;
    border-color: var(--border-focus);
}

.cart-consents {
    display: flex;
    flex-direction: column;
    gap: 8px;
    font-size: 14px;
    color: var(--text-secondary);
}

.cart-check {
    display: flex;
    gap: 8px;
    align-items: center;
    margin-bottom: 14px;
    font-size: 14px;
    color: var(--text-primary);
}

.cart-consents label {
    display: flex;
    gap: 8px;
    align-items: flex-start;
}

.cart-note {
    margin: 8px 0;
    font-size: 13px;
    color: var(--text-muted);
}

.cart-warning {
    margin: 10px 0 0;
    font-size: 14px;
    color: var(--warning);
}

.cart-store-link {
    display: inline-block;
    margin-top: 8px;
    font-weight: 600;
    color: var(--brand-accent-text);
}

.cart-alert {
    margin: 12px 0;
    padding: 10px 12px;
    font-size: 14px;
    color: var(--danger);
    background: var(--danger-bg);
    border-radius: var(--radius-sm);
}

.cart-pay {
    width: 100%;
    margin-top: 14px;
    padding: 14px 18px;
    font-size: 17px;
}

.cart-pay:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.cart-field-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    column-gap: 14px;
}

.cart-secure {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin: 16px 0 0;
    padding-top: 14px;
    font-size: 13px;
    color: var(--text-secondary);
    border-top: 1px solid var(--border);
}

.cart-secure .shop-icon {
    color: var(--brand-accent-text);
}

.cart-link-button {
    width: 100%;
    margin-top: 8px;
    padding: 8px;
    font: inherit;
    font-size: 14px;
    color: var(--brand-accent-text);
    background: none;
    border: 0;
    cursor: pointer;
}

.cart-link-button:disabled {
    color: var(--text-muted);
    cursor: default;
}

.cart-continue {
    display: inline-block;
    margin-top: 20px;
    font-weight: 600;
    color: var(--brand-accent-text);
}

@media (max-width: 860px) {
    .cart-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .cart-summary {
        position: static;
    }
}

@media (max-width: 860px) {
    .shop-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .shop-toolbar {
        flex-basis: 100%;
        margin-left: 0;
    }

    .shop-head:has(.shop-section-title) .shop-toolbar {
        flex-basis: auto;
        margin-left: auto;
    }

    .shop-filter-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        flex: 1;
        padding: 10px 12px;
        font: inherit;
        font-size: 14px;
        font-weight: 600;
        color: var(--text-primary);
        background: var(--bg-card);
        border: 1px solid var(--border);
        border-radius: var(--radius-sm);
        cursor: pointer;
    }

    .shop-sort {
        flex: 1;
        min-width: 0;
    }

    .shop-sort select {
        width: 100%;
        min-width: 0;
    }

    .shop-filters {
        display: none;
        position: static;
    }

    .shop-filters.is-open {
        display: block;
    }

    .shop-category-list {
        max-height: 220px;
    }
}

@media (max-width: 560px) {
    .shop-shell {
        padding: 20px 16px 56px;
    }

    .shop-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }

    .shop-card-body {
        padding: 10px;
    }

    .shop-card-add {
        margin: 0 10px 10px;
    }

    .shop-store-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .shop-hero-inner {
        padding: 24px 16px 28px;
    }

    .shop-store-cta {
        padding-left: 0;
        border-left: 0;
        font-size: 0;
    }
}
