:root {
    color-scheme: light;
    --ink: #0f172a;
    --muted: #64748b;
    --line: #e2e8f0;
    --paper: #ffffff;
    --soft: #f8fafc;
    --soft-teal: #ecfdf5;
    --teal: #0f766e;
    --teal-dark: #115e59;
    --amber: #f59e0b;
    --rose: #b91c1c;
    --slate: #334155;
    --shadow: 0 18px 42px rgba(15, 23, 42, .08);
    --radius: 8px;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    background: var(--soft);
    color: var(--ink);
    font-family: "Segoe UI", Tahoma, Arial, sans-serif;
    line-height: 1.6;
}

body.auth-modal-open {
    overflow: hidden;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    display: block;
    max-width: 100%;
}

button,
input,
select,
textarea {
    font: inherit;
}

button,
.primary-action,
.secondary-action,
.open-store {
    min-height: 42px;
    border: 0;
    border-radius: var(--radius);
    cursor: pointer;
}

.site-header,
.site-footer {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
}

.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 14px 0;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-weight: 800;
    letter-spacing: 0;
}

.brand span:last-child {
    display: grid;
    gap: 1px;
}

.brand strong {
    line-height: 1.1;
}

.brand small {
    color: var(--muted);
    font-size: .78rem;
    font-weight: 700;
}

.brand-mark {
    width: 64px;
    height: 64px;
    padding: 0;
    border: 1px solid rgba(15, 118, 110, .16);
    border-radius: 16px;
    background: #fff;
    object-fit: cover;
    box-shadow: 0 12px 26px rgba(15, 23, 42, .10);
}

.site-nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 6px;
}

.site-header nav a {
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    padding: 7px 10px;
    border-radius: var(--radius);
    color: var(--muted);
    font-weight: 700;
}

.site-header nav a:hover {
    background: #eef6f3;
    color: var(--teal-dark);
}

.language-switch {
    display: inline-flex;
    align-items: center;
    padding: 3px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
}

.site-header nav .language-switch a {
    min-height: 30px;
    padding: 4px 9px;
    color: var(--slate);
    font-size: .82rem;
}

.site-header nav .language-switch a.is-active {
    background: var(--teal);
    color: #fff;
}

main {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto 48px;
}

.site-footer {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 28px 0;
    color: var(--muted);
    border-top: 1px solid var(--line);
}

.site-footer a {
    font-weight: 700;
}

.eyebrow {
    margin: 0 0 8px;
    color: var(--teal);
    font-size: .82rem;
    font-weight: 800;
    text-transform: uppercase;
}

h1,
h2,
p {
    margin-top: 0;
}

h1 {
    margin-bottom: 12px;
    font-size: clamp(2rem, 4.6vw, 3.8rem);
    line-height: 1.08;
    letter-spacing: 0;
}

h2 {
    font-size: 1.2rem;
    letter-spacing: 0;
}

.directory-shell,
.checkout-shell,
.success-shell {
    padding: 28px 0 64px;
}

.directory-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 420px);
    gap: 24px;
    align-items: end;
    margin-bottom: 28px;
    padding: clamp(22px, 4vw, 38px);
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.software-promo {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(190px, .7fr) minmax(180px, auto);
    gap: 16px;
    align-items: center;
    margin: 0 0 28px;
    padding: 16px 18px;
    border: 1px solid rgba(15, 118, 110, .14);
    border-radius: var(--radius);
    background: linear-gradient(135deg, #ffffff 0%, #f7fbfa 100%);
    box-shadow: 0 12px 28px rgba(15, 23, 42, .045);
}

.software-promo .eyebrow {
    margin-bottom: 5px;
    font-size: .74rem;
}

.software-promo h2 {
    max-width: 520px;
    margin-bottom: 7px;
    color: var(--ink);
    font-size: clamp(1.2rem, 1.65vw, 1.55rem);
    line-height: 1.24;
}

.software-promo p {
    margin-bottom: 0;
    color: var(--muted);
    font-size: .92rem;
    line-height: 1.65;
}

.software-promo__points {
    display: grid;
    gap: 7px;
}

.software-promo__points span {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 24px;
    color: var(--slate);
    font-size: .9rem;
    font-weight: 800;
}

.software-promo__points span::before {
    content: "";
    width: 7px;
    height: 7px;
    flex: 0 0 auto;
    border-radius: 50%;
    background: var(--amber);
    box-shadow: 0 0 0 4px rgba(245, 158, 11, .13);
}

.software-promo__actions {
    display: grid;
    gap: 8px;
    min-width: 190px;
}

.software-promo__actions .primary-action,
.software-promo__actions .secondary-action {
    min-height: 38px;
    padding: 8px 13px;
    font-size: .9rem;
}

.software-promo__actions .secondary-action.whatsapp-action {
    background: #f1f5f9;
    color: var(--ink);
}

.software-promo__actions .secondary-action.whatsapp-action:hover {
    background: #dcfce7;
    color: #166534;
}

.policy-shell {
    max-width: 920px;
    padding: 40px 0 72px;
}

.policy-lead {
    max-width: 720px;
    color: var(--muted);
    font-size: 1.08rem;
}

.policy-panel {
    margin-top: 18px;
    padding: 22px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--paper);
    box-shadow: var(--shadow);
}

.policy-panel h2 {
    margin-bottom: 10px;
}

.policy-panel p,
.policy-panel ol {
    margin-bottom: 0;
    color: var(--muted);
}

.policy-panel ol {
    padding-inline-start: 24px;
}

.policy-action {
    width: fit-content;
    margin-top: 18px;
}

.policy-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
    margin-top: 18px;
}

.policy-grid .policy-panel {
    margin-top: 0;
}

.policy-updated {
    margin-top: 18px;
    color: var(--muted);
    font-size: .92rem;
}

.directory-copy {
    max-width: 560px;
    color: var(--muted);
    font-size: 1.08rem;
}

.store-search,
.catalog-toolbar {
    display: flex;
    gap: 10px;
}

.store-search input,
.catalog-toolbar input,
.catalog-toolbar select,
.checkout-form input,
.checkout-form select,
.checkout-form textarea,
.qty-form input,
.buy-box input {
    width: 100%;
    min-height: 44px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    padding: 10px 12px;
    color: var(--ink);
    outline: none;
}

.store-search input:focus,
.catalog-toolbar input:focus,
.catalog-toolbar select:focus,
.checkout-form input:focus,
.checkout-form select:focus,
.checkout-form textarea:focus,
.qty-form input:focus,
.buy-box input:focus {
    border-color: rgba(15, 118, 110, .55);
    box-shadow: 0 0 0 3px rgba(15, 118, 110, .12);
}

.store-search button,
.catalog-toolbar button,
.card-action button,
.buy-box button,
.qty-form button,
.primary-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: var(--teal);
    color: #fff;
    padding: 0 18px;
    font-weight: 800;
}

.store-search button:hover,
.catalog-toolbar button:hover,
.card-action button:hover,
.buy-box button:hover,
.qty-form button:hover,
.primary-action:hover {
    background: var(--teal-dark);
}

button:disabled {
    cursor: not-allowed;
    opacity: .45;
}

.store-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.store-card,
.product-card,
.order-summary,
.checkout-form,
.cart-line {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: var(--radius);
}

.store-card {
    display: grid;
    grid-template-rows: 164px 1fr auto;
    overflow: hidden;
    min-height: 378px;
    box-shadow: 0 10px 24px rgba(15, 23, 42, .05);
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.store-card:hover,
.product-card:hover {
    transform: translateY(-2px);
    border-color: rgba(15, 118, 110, .28);
    box-shadow: 0 16px 34px rgba(15, 23, 42, .09);
}

.store-card-media,
.product-media,
.product-gallery,
.line-media,
.store-logo {
    display: grid;
    place-items: center;
    background: var(--soft-teal);
    color: var(--teal);
    font-weight: 900;
    overflow: hidden;
}

.store-card-media {
    padding: 18px 30px;
    border-bottom: 1px solid rgba(226, 232, 240, .75);
    background: #fff;
}

.store-card-media img {
    width: auto;
    height: auto;
    max-width: min(100%, 286px);
    max-height: 128px;
    object-fit: contain;
}

.store-logo img {
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.product-gallery img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-media img,
.line-media img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 20px;
}

.line-media img {
    padding: 10px;
}

.product-gallery img {
    object-fit: contain;
    padding: clamp(28px, 6vw, 70px);
    background: var(--soft-teal);
}

.store-card-body {
    display: grid;
    align-content: start;
    gap: 10px;
    padding: 18px;
}

.store-card-title {
    display: -webkit-box;
    overflow: hidden;
    min-height: 3rem;
    margin-bottom: 8px;
    font-size: 1.12rem;
    line-height: 1.35;
    font-weight: 900;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.store-card-body p,
.store-card-meta,
.muted,
.order-summary p,
.product-description {
    color: var(--muted);
}

.store-card-body p {
    display: -webkit-box;
    overflow: hidden;
    min-height: 3rem;
    margin-bottom: 0;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.store-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    font-size: .9rem;
}

.store-card-meta span {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 3px 9px;
    border-radius: 999px;
    background: #f1f5f9;
    color: var(--slate);
}

.open-store {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 18px 18px;
    background: var(--soft-teal);
    color: var(--teal-dark);
    font-weight: 800;
}

.open-store:hover {
    background: var(--teal);
    color: #fff;
}

.empty-state {
    padding: 44px;
    text-align: center;
    background: var(--paper);
    border: 1px dashed #b9c9c2;
    border-radius: var(--radius);
}

.empty-state.compact {
    padding: 28px;
}

.service-state {
    border-color: #e2b3bd;
    background: #fff7f8;
}

.service-state code {
    display: block;
    overflow-x: auto;
    margin-top: 16px;
    padding: 12px;
    border-radius: var(--radius);
    background: #ffffff;
    color: var(--ink);
    direction: ltr;
    text-align: left;
    white-space: nowrap;
}

.store-hero {
    position: relative;
    min-height: 248px;
    margin-bottom: 28px;
    overflow: hidden;
    border-radius: var(--radius);
    background:
        radial-gradient(circle at 16% 18%, rgba(15, 118, 110, .10), transparent 28%),
        linear-gradient(135deg, #ffffff 0%, #f8fafc 58%, #eef6f3 100%);
    border: 1px solid var(--line);
    box-shadow: 0 18px 38px rgba(15, 23, 42, .06);
}

.store-hero-media {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.store-hero-media::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(255,255,255,.98), rgba(255,255,255,.88) 52%, rgba(255,255,255,.68));
}

[dir="rtl"] .store-hero-media::after {
    background:
        linear-gradient(270deg, rgba(255,255,255,.98), rgba(255,255,255,.88) 52%, rgba(255,255,255,.68));
}

.store-hero-media img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    padding: 18px;
    opacity: .12;
    filter: saturate(.8);
}

.store-hero-content {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 164px minmax(0, 1fr);
    grid-template-rows: auto auto;
    gap: 24px;
    align-items: center;
    min-height: 248px;
    padding: 28px;
}

.store-hero-content > div:not(.store-logo) {
    grid-column: 2;
    grid-row: 1 / 3;
    min-width: 0;
}

.store-hero .eyebrow {
    display: inline-flex;
    align-items: center;
    max-width: 100%;
    min-height: 30px;
    margin-bottom: 10px;
    padding: 3px 10px;
    overflow: hidden;
    border-radius: 999px;
    background: rgba(15, 118, 110, .08);
    color: var(--teal-dark);
    text-overflow: ellipsis;
    white-space: nowrap;
    text-transform: none;
}

.store-hero h1 {
    max-width: 900px;
    margin-bottom: 10px;
    color: var(--ink);
    font-size: clamp(2rem, 3.1vw, 3.15rem);
    line-height: 1.06;
    text-wrap: balance;
}

.store-hero-content p:not(.eyebrow) {
    max-width: 780px;
    margin-bottom: 14px;
    color: #334155;
    font-size: 1rem;
    line-height: 1.7;
}

.store-logo {
    grid-column: 1;
    grid-row: 1;
    justify-self: stretch;
    width: 118px;
    height: 118px;
    padding: 12px;
    border-radius: var(--radius);
    border: 1px solid var(--line);
    overflow: hidden;
    background: #fff;
    box-shadow: 0 14px 30px rgba(15, 23, 42, .08);
}

.store-contact-row,
.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.store-contact-row span,
.detail-meta span,
.stock {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 3px 10px;
    border-radius: 999px;
    background: #eef6f3;
    color: var(--teal-dark);
    font-size: .9rem;
    font-weight: 700;
}

.cart-pill {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    min-height: 52px;
    padding: 0;
    border: 1px solid rgba(15, 118, 110, .18);
    border-radius: 16px;
    background: #fff;
    color: var(--teal);
    font-weight: 900;
    white-space: nowrap;
    box-shadow: 0 12px 26px rgba(15, 23, 42, .10);
    transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}

.cart-pill:hover {
    transform: translateY(-1px);
    background: #f0fdfa;
    box-shadow: 0 16px 32px rgba(15, 118, 110, .16);
}

.store-hero .cart-pill {
    grid-column: 1;
    grid-row: 2;
    justify-self: center;
    margin-top: -8px;
}

.cart-pill__icon,
.floating-cart__icon {
    display: grid;
    place-items: center;
}

.cart-pill__icon svg,
.floating-cart__icon svg {
    width: 27px;
    height: 27px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2.15;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.cart-pill__badge,
.floating-cart__badge {
    position: absolute;
    inset-block-start: -7px;
    inset-inline-end: -7px;
    display: grid;
    place-items: center;
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    border: 2px solid #fff;
    border-radius: 999px;
    background: var(--amber);
    color: #fff;
    font-size: .75rem;
    font-weight: 900;
    line-height: 1;
    box-shadow: 0 8px 18px rgba(245, 158, 11, .28);
}

.cart-pill__badge[hidden],
.floating-cart__badge[hidden] {
    display: none;
}

.cart-pill.inline {
    width: fit-content;
    min-width: 52px;
    margin-top: 18px;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    clip-path: inset(50%);
}

.cart-toast {
    position: fixed;
    left: 50%;
    top: 18px;
    z-index: 40;
    width: min(360px, calc(100% - 28px));
    transform: translateX(-50%) translateY(-10px);
    padding: 12px 16px;
    border: 1px solid rgba(15, 118, 110, .20);
    border-radius: var(--radius);
    background: #ffffff;
    color: var(--teal-dark);
    box-shadow: var(--shadow);
    font-weight: 900;
    text-align: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity .18s ease, transform .18s ease;
}

.cart-toast.is-visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.floating-cart {
    position: fixed;
    inset-block-end: 18px;
    inset-inline-start: max(18px, calc((100vw - 1240px) / 2 + 18px));
    z-index: 35;
}

.floating-cart[hidden] {
    display: none;
}

.floating-cart__button {
    position: relative;
    display: grid;
    place-items: center;
    width: 58px;
    height: 58px;
    border: 1px solid rgba(15, 118, 110, .18);
    border-radius: 18px;
    background: #fff;
    color: var(--teal);
    box-shadow: 0 18px 40px rgba(15, 23, 42, .16);
    transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}

.floating-cart__button:hover {
    transform: translateY(-2px);
    background: #f0fdfa;
    box-shadow: 0 22px 48px rgba(15, 118, 110, .18);
}

.catalog-shell {
    display: grid;
    gap: 16px;
    align-items: start;
}

.category-rail {
    position: sticky;
    top: 16px;
    z-index: 2;
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 4px 0 10px;
    background: var(--soft);
    scrollbar-width: thin;
}

.category-chip {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    min-height: 42px;
    padding: 8px 12px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--paper);
    color: var(--muted);
    font-weight: 800;
}

.category-chip.is-active {
    background: var(--teal);
    color: #fff;
    border-color: var(--teal);
}

.catalog-main {
    min-width: 0;
}

.catalog-toolbar {
    margin-bottom: 16px;
}

.catalog-toolbar select {
    max-width: 180px;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
}

.product-card {
    display: grid;
    grid-template-rows: 174px 1fr auto;
    overflow: hidden;
    box-shadow: 0 10px 22px rgba(15, 23, 42, .05);
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.product-media {
    position: relative;
    height: 174px;
    min-height: 0;
}

.product-media img {
    position: absolute;
    inset: 0;
}

.product-body {
    position: relative;
    z-index: 1;
    display: grid;
    gap: 8px;
    padding: 16px;
    background: var(--paper);
}

.product-body a {
    display: -webkit-box;
    overflow: hidden;
    min-height: 2.8rem;
    font-weight: 900;
    line-height: 1.4;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.product-body .muted {
    display: block;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.price-row {
    display: flex;
    align-items: baseline;
    gap: 8px;
    flex-wrap: wrap;
}

.price-row strong {
    font-size: 1.08rem;
}

.price-row.large strong {
    font-size: 1.65rem;
}

del {
    color: var(--muted);
}

.stock {
    width: fit-content;
    background: #eef7ef;
    color: #237541;
}

.stock.out {
    background: #fff0f2;
    color: var(--rose);
}

.card-action {
    padding: 0 16px 16px;
}

.card-action button {
    width: 100%;
}

.product-detail {
    display: grid;
    grid-template-columns: minmax(300px, 540px) minmax(0, 1fr);
    gap: 26px;
    padding: 26px 0 64px;
}

.product-gallery {
    min-height: 520px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
}

.product-panel {
    align-self: start;
    padding: 28px;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.back-link {
    display: inline-flex;
    margin-bottom: 18px;
    color: var(--teal-dark);
    font-weight: 900;
}

.buy-box,
.checkout-form {
    display: grid;
    gap: 14px;
}

.buy-box {
    margin-top: 24px;
    grid-template-columns: minmax(110px, 150px) minmax(0, 1fr);
    align-items: end;
}

.buy-box label,
.checkout-form label {
    display: grid;
    gap: 6px;
    color: var(--muted);
    font-weight: 800;
}

.checkout-form label:has([data-use-current-location]) {
    position: relative;
}

.field-icon-button {
    display: inline-grid;
    place-items: center;
    width: 38px;
    height: 38px;
    min-height: 38px;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: #fff;
    color: var(--teal-dark);
    font-size: 1.05rem;
    box-shadow: 0 8px 22px rgba(15, 23, 42, .08);
}

.field-icon-button:hover {
    border-color: rgba(15, 118, 110, .45);
    background: #ecfdf5;
}

.address-location-button {
    position: absolute;
    inset-block-start: 0;
    inset-inline-end: 0;
}

.location-status {
    min-height: 18px;
    color: var(--teal-dark);
    font-size: .82rem;
    font-weight: 800;
}

.location-status.is-error {
    color: var(--rose);
}

.section-title-row {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 18px;
}

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

.cart-lines {
    display: grid;
    gap: 12px;
}

.cart-line {
    display: grid;
    grid-template-columns: 84px minmax(0, 1fr) 150px auto auto;
    gap: 14px;
    align-items: center;
    padding: 12px;
}

.line-media {
    width: 84px;
    height: 84px;
    border-radius: var(--radius);
    overflow: hidden;
}

.line-media span {
    font-size: 1.7rem;
}

.line-info {
    display: grid;
    gap: 4px;
}

.line-info a {
    font-weight: 900;
}

.qty-form {
    display: flex;
    gap: 8px;
}

.qty-form input {
    max-width: 82px;
}

.ghost-danger {
    min-height: 38px;
    padding: 0 12px;
    color: var(--rose);
    background: #fff0f2;
    font-weight: 800;
}

.order-summary {
    display: grid;
    gap: 14px;
    padding: 18px;
    position: sticky;
    top: 16px;
}

.order-summary div {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.summary-total {
    padding-top: 14px;
    border-top: 1px solid var(--line);
}

.checkout-form {
    padding: 18px;
}

.checkout-auth-card {
    display: grid;
    gap: 14px;
    padding: 16px;
    background: #f7fbfa;
    border-inline-start: 4px solid var(--teal);
}

.checkout-auth-copy {
    display: grid;
    gap: 4px;
}

.checkout-auth-copy span,
.checkout-auth-signed span {
    color: var(--teal-dark);
    font-size: .82rem;
    font-weight: 900;
}

.checkout-auth-copy strong {
    color: var(--ink);
    font-size: 1.15rem;
}

.checkout-auth-copy strong.auth-card-title-prompt {
    font-size: 0;
}

.checkout-auth-copy strong.auth-card-title-prompt::after {
    content: "Log in or sign up in seconds";
    font-size: 1.15rem;
}

.checkout-auth-copy p {
    margin: 0;
    color: var(--muted);
    line-height: 1.7;
}

.checkout-auth-message {
    padding: 10px 12px;
    background: #e8f7ef;
    color: #166534;
    font-weight: 800;
}

.checkout-auth-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(120px, 180px);
    gap: 12px;
}

.checkout-auth-actions,
.checkout-auth-signed {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
}

.auth-open-action {
    width: fit-content;
}

.auth-modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: grid;
    place-items: center;
    padding: 24px;
    background: rgba(15, 23, 42, .48);
    color: var(--ink);
}

.auth-modal[hidden] {
    display: none;
}

.auth-modal__surface {
    position: relative;
    display: grid;
    gap: 16px;
    width: min(430px, 100%);
    padding: 22px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: 0 26px 72px rgba(15, 23, 42, .24);
}

.auth-modal__head {
    padding-inline-end: 44px;
}

.auth-modal__head h2 {
    margin-bottom: 0;
    font-size: 1.45rem;
    line-height: 1.25;
}

.auth-modal__head p {
    margin: 6px 0 0;
    color: var(--muted);
    font-size: .95rem;
    line-height: 1.5;
}

.auth-modal__close {
    position: absolute;
    inset-block-start: 12px;
    inset-inline-end: 12px;
    display: grid;
    place-items: center;
    width: 34px;
    min-height: 34px;
    height: 34px;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: #fff;
    color: var(--slate);
    font-size: 1rem;
    font-weight: 900;
}

.auth-provider-list,
.auth-email-panel {
    display: grid;
    gap: 10px;
}

.auth-provider-button {
    display: grid;
    grid-template-columns: 30px minmax(0, 1fr);
    align-items: center;
    width: 100%;
    min-height: 46px;
    padding: 8px 12px;
    border: 1px solid #cbd5e1;
    border-radius: var(--radius);
    background: #fff;
    color: var(--ink);
    font-weight: 900;
    text-align: center;
}

.auth-provider-button:hover {
    border-color: rgba(15, 118, 110, .36);
    background: #f8fafc;
}

.auth-provider-icon {
    display: grid;
    place-items: center;
    width: 24px;
    height: 24px;
    color: var(--ink);
    font-weight: 900;
    line-height: 1;
}

.auth-provider-icon--google {
    color: #2563eb;
}

.auth-email-panel {
    display: none;
    padding-top: 6px;
}

.auth-email-panel.is-open {
    display: grid;
}

.logout-action,
.auth-summary-action {
    font-size: 0;
}

.logout-action::after,
.auth-summary-action::after {
    font-size: .95rem;
}

.logout-action::after {
    content: "Log out";
}

.auth-summary-action::after {
    content: "Log in or sign up";
}

.branch-pill {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    min-height: 34px;
    padding: 6px 12px;
    background: #e8f7ef;
    color: var(--teal-dark);
    font-weight: 900;
}

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

.segmented label {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
}

.validation-box,
span.field-validation-error {
    color: var(--rose);
    font-weight: 800;
}

.success-shell {
    min-height: 60vh;
    display: grid;
    place-items: center;
    align-content: center;
    text-align: center;
}

.success-mark {
    display: grid;
    place-items: center;
    width: 76px;
    height: 76px;
    margin-bottom: 16px;
    border-radius: 50%;
    background: #e8f7ef;
    color: #237541;
    font-size: 2.6rem;
    font-weight: 900;
}

.success-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 18px;
}

.primary-action,
.secondary-action {
    padding: 10px 18px;
    font-weight: 900;
}

.secondary-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #eef3f0;
    color: var(--ink);
}

@media (max-width: 980px) {
    .directory-head,
    .software-promo,
    .product-detail,
    .cart-layout,
    .checkout-layout {
        grid-template-columns: 1fr;
    }

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

    .product-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .order-summary {
        position: static;
    }

    .checkout-auth-grid {
        grid-template-columns: 1fr;
    }

    .category-chip {
        min-width: fit-content;
    }

    .product-gallery {
        min-height: 380px;
    }

    .store-hero-content {
        grid-template-columns: 96px minmax(0, 1fr);
    }

    .store-hero h1 {
        font-size: clamp(1.8rem, 5vw, 2.7rem);
    }

    .store-logo {
        width: 96px;
        height: 96px;
    }

    .store-hero .cart-pill {
        grid-column: 1;
        justify-self: center;
    }

    .cart-line {
        grid-template-columns: 76px minmax(0, 1fr);
    }
}

@media (max-width: 640px) {
    main,
    .site-header,
    .site-footer {
        width: min(100% - 22px, 1180px);
    }

    .site-header,
    .site-footer,
    .section-title-row,
    .store-search,
    .catalog-toolbar,
    .buy-box {
        flex-direction: column;
        display: flex;
        align-items: stretch;
    }

    .site-nav {
        justify-content: stretch;
    }

    .site-header nav a {
        justify-content: center;
    }

    .brand {
        justify-content: center;
    }

    .brand-mark {
        width: 54px;
        height: 54px;
        border-radius: 15px;
    }

    h1 {
        font-size: 2.15rem;
    }

    .directory-head,
    .store-hero-content,
    .product-panel {
        padding: 20px;
    }

    .software-promo {
        gap: 12px;
        padding: 14px;
    }

    .software-promo h2 {
        font-size: 1.22rem;
        line-height: 1.2;
    }

    .software-promo p {
        font-size: .88rem;
        line-height: 1.55;
    }

    .software-promo__points {
        gap: 4px;
    }

    .software-promo__actions {
        gap: 7px;
    }

    .store-grid,
    .product-grid,
    .policy-grid {
        grid-template-columns: 1fr;
    }

    .store-hero-content {
        grid-template-columns: 72px minmax(0, 1fr);
        gap: 14px;
        min-height: 230px;
    }

    .store-hero h1 {
        font-size: clamp(1.55rem, 8vw, 2.15rem);
    }

    .store-hero-content p:not(.eyebrow) {
        font-size: .95rem;
    }

    .store-logo {
        width: 72px;
        height: 72px;
        padding: 8px;
    }

    .store-hero .cart-pill {
        grid-column: 1;
        width: 52px;
    }

    .catalog-toolbar select {
        max-width: none;
    }

    .floating-cart {
        inset-inline: auto 16px;
        inset-block-end: 11px;
    }

    [dir="rtl"] .floating-cart {
        inset-inline: 16px auto;
    }
}
