/* Tecnobuy v2 — design system tokens + utilities (basado en el handoff de
   claude.ai/design). Se carga desde el layout default.php y convive por
   prefijo `tb-` con los estilos legacy de tecno.css. */

:root {
    --tb-black: #0a0a0b;
    --tb-ink: #111113;
    --tb-ink2: #2a2a2d;
    --tb-gray: #6b6b70;
    --tb-gray2: #9a9aa0;
    --tb-line: #e7e7ea;
    --tb-line2: #f2f2f4;
    --tb-bg: #fafafa;
    --tb-white: #ffffff;
    --tb-accent: #1e40af;
    --tb-accent-soft: #eff3fd;
    --tb-green: #0a7a43;
    --tb-green-soft: #e8f5ee;
    --tb-red: #c8372d;
    --tb-red-soft: #fdebe9;
    --tb-yellow: #f5c518;
    --tb-yellow-soft: #fff6d4;

    --tb-line-strong: #c9c9cf;
    --tb-line-soft: #f1f1f3;
    --tb-card: #ffffff;
    --tb-accent-ring: rgba(30, 64, 175, .18);
    --tb-focus: 0 0 0 4px var(--tb-accent-ring);
    --tb-radius-sm: 6px;
    --tb-radius: 8px;
    --tb-radius-lg: 12px;

    --tb-font-stack: -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", Roboto, sans-serif;
    --tb-font-mono: "JetBrains Mono", "SF Mono", ui-monospace, Menlo, monospace;
}

.tb * { box-sizing: border-box; }
.tb {
    font-family: var(--tb-font-stack);
    color: var(--tb-ink);
    background: var(--tb-bg);
}
.tb .tb-sans { font-family: var(--tb-font-stack); }
.tb .tb-mono { font-family: var(--tb-font-mono); }

/* Container */
.tb-container { max-width: 1400px; margin: 0 auto; padding: 0 32px; }
@media (max-width: 768px) { .tb-container { padding: 0 16px; } }

/* ─── Ticker superior ─── */
.tb-ticker {
    background: #000;
    color: #fff;
    font-size: 14px;
    height: 34px;
    overflow: hidden;
    white-space: nowrap;
    font-weight: 500;
    letter-spacing: 0;
    display: flex;
    align-items: center;
    text-transform: uppercase;
}
.tb-ticker__track {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    width: 100%;
    min-width: 100%;
}
.tb-ticker__track span {
    flex: 0 0 auto;
}
.tb-ticker__track span:not(:first-child) {
    display: none;
}
.tb-ticker__track span::after {
    content: "";
    margin-left: 0;
}
@keyframes tb-ticker {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* ─── Header ─── */
.tb-header {
    background: #fff;
    border-bottom: 1px solid var(--tb-line);
    position: sticky;
    top: 0;
    z-index: 30;
}
.tb-header__bar {
    padding: 14px 32px;
    display: flex;
    align-items: center;
    gap: 32px;
    max-width: 1500px;
    margin: 0 auto;
}
.tb-logo { line-height: 1; cursor: pointer; flex-shrink: 0; text-decoration: none; color: inherit; display: flex; flex-direction: column; }
.tb-logo__upper { font-weight: 700; font-size: 12px; letter-spacing: 1px; }
.tb-logo__main { font-weight: 900; font-size: 20px; letter-spacing: -.3px; margin-top: 1px; }
.tb-logo__sub { font-size: 9px; font-style: italic; margin-top: 2px; opacity: .7; }

.tb-search { flex: 1; max-width: 560px; position: relative; }
.tb-search__input {
    width: 100%;
    display: flex;
    align-items: center;
    background: #fff;
    border: 2px solid var(--tb-line);
    border-radius: 8px;
    transition: border-color .15s;
}
.tb-search__input:focus-within { border-color: var(--tb-ink); }
.tb-search__input input {
    width: 100%;
    padding: 12px 16px;
    font-size: 14px;
    background: transparent;
    border: none;
    outline: none;
    font-family: inherit;
}
.tb-search__btn {
    padding: 0 16px;
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--tb-gray);
}
.tb-search__dropdown {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid var(--tb-line);
    border-radius: 10px;
    box-shadow: 0 12px 32px rgba(0,0,0,.12);
    padding: 16px;
    z-index: 40;
    font-size: 13px;
    display: none;
}
.tb-search:focus-within .tb-search__dropdown,
.tb-search__dropdown.is-open { display: block; }
.tb-search__label {
    font-size: 10px;
    color: var(--tb-gray);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
    margin-bottom: 10px;
}
.tb-search__chips { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 18px; }
.tb-search__chip {
    padding: 5px 10px;
    background: var(--tb-line2);
    border-radius: 14px;
    font-size: 12px;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
}
.tb-search__result {
    display: flex;
    gap: 12px;
    padding: 8px;
    border-radius: 6px;
    cursor: pointer;
    align-items: center;
    text-decoration: none;
    color: inherit;
}
.tb-search__result:hover { background: var(--tb-line2); }
.tb-search__result-thumb {
    width: 44px; height: 44px;
    background: var(--tb-line2);
    border-radius: 6px;
    display: grid; place-items: center;
    flex-shrink: 0;
    overflow: hidden;
}
.tb-search__result-thumb img { max-width: 100%; max-height: 100%; object-fit: contain; }

/* Header account / cart */
.tb-header__actions { display: flex; gap: 24px; align-items: center; font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .3px; }
.tb-header__account {
    display: flex; align-items: center; gap: 8px;
    cursor: pointer; color: var(--tb-ink);
    text-decoration: none;
    white-space: nowrap;
}
.tb-header__account:hover { color: var(--tb-accent); }
.tb-header__cart {
    display: flex; align-items: center; gap: 10px;
    color: var(--tb-ink);
    text-decoration: none;
    white-space: nowrap;
    font-weight: 700;
}
.tb-header__cart:hover { color: var(--tb-accent); }
.tb-header__cart-icon { position: relative; }
.tb-header__cart-badge {
    position: absolute; top: -6px; right: -8px;
    background: var(--tb-red); color: #fff;
    font-size: 9px; font-weight: 700;
    border-radius: 8px; padding: 1px 5px;
    min-width: 14px; text-align: center;
}
.tb-header__cart-total { font-size: 12px; font-weight: 600; }

/* Header category nav */
.tb-nav {
    background: var(--tb-ink);
    display: flex;
    padding: 0 32px;
    justify-content: center;
    gap: 12px;
    position: relative;
}
.tb-nav__group { position: relative; }
.tb-nav__item {
    display: inline-flex; align-items: center;
    padding: 14px 22px;
    font-size: 14px; font-weight: 600;
    cursor: pointer;
    letter-spacing: .3px;
    color: rgba(255,255,255,.85);
    border-bottom: 2px solid transparent;
    text-decoration: none;
    text-transform: capitalize;
    white-space: nowrap;
}
.tb-nav__item:hover,
.tb-nav__group:hover > .tb-nav__item,
.tb-nav__item.is-active { color: #fff; border-bottom-color: #fff; }
.tb-nav__item.is-hot { color: var(--tb-yellow); text-transform: uppercase; }
.tb-nav__item.is-hot:hover { color: var(--tb-yellow); border-bottom-color: var(--tb-yellow); }

/* Dropdown de subcategorías */
.tb-nav__dropdown {
    position: absolute; top: 100%; left: 0;
    background: #fff;
    border: 1px solid var(--tb-line);
    border-top: 2px solid var(--tb-ink);
    box-shadow: 0 12px 32px rgba(0,0,0,.12);
    min-width: 240px;
    z-index: 40;
    padding: 8px 0;
    display: none;
}
.tb-nav__group:hover .tb-nav__dropdown { display: block; }
.tb-nav__dropdown-inner { display: flex; flex-direction: column; }
.tb-nav__sublink {
    padding: 10px 20px;
    font-size: 13px; font-weight: 500;
    color: var(--tb-ink); text-decoration: none;
    text-transform: capitalize;
}
.tb-nav__sublink:hover { background: var(--tb-line2); color: var(--tb-ink); }

.tb-brand-menu {
    position: absolute; top: 100%; left: 0;
    background: #fff;
    border: 1px solid var(--tb-line); border-top: none;
    box-shadow: 0 12px 32px rgba(0,0,0,.12);
    border-radius: 0 0 12px 12px;
    padding: 24px;
    width: 640px;
    z-index: 40;
    display: none;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}
.tb-brand-menu.is-open,
.tb-nav__brand:hover .tb-brand-menu { display: grid; }
.tb-brand-menu__card {
    padding: 18px;
    border: 1px solid var(--tb-line);
    border-radius: 10px;
    cursor: pointer;
    background: #fff;
    text-decoration: none;
    color: inherit;
}
.tb-brand-menu__card.is-featured { border: 2px solid var(--tb-ink); background: var(--tb-line2); }
.tb-brand-menu__head { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 10px; }
.tb-brand-menu__name { font-weight: 900; font-size: 22px; letter-spacing: 1px; }
.tb-brand-menu__count {
    font-size: 10px; color: var(--tb-gray);
    background: #fff; padding: 2px 7px;
    border-radius: 10px; border: 1px solid var(--tb-line);
}
.tb-brand-menu__lines { font-size: 11px; color: var(--tb-gray); line-height: 1.6; }
.tb-brand-menu__cta { font-size: 11px; font-weight: 600; color: var(--tb-accent); margin-top: 10px; }
.tb-brand-menu__foot {
    grid-column: span 2;
    font-size: 11px; color: var(--tb-gray);
    padding-top: 4px;
    border-top: 1px solid var(--tb-line);
    display: flex; justify-content: space-between;
}

/* ─── Footer ─── */
.tb-footer {
    background: var(--tb-ink);
    color: #fff;
    padding: 40px 32px 24px;
    font-size: 12px;
}
.tb-footer__inner { max-width: 1400px; margin: 0 auto; }
.tb-footer__brand { max-width: 420px; margin-bottom: 32px; }
.tb-footer__brand-title { font-weight: 800; font-size: 18px; margin-bottom: 8px; letter-spacing: -.3px; }
.tb-footer__brand-title .dot { color: var(--tb-accent); }
.tb-footer__brand-txt { opacity: .65; line-height: 1.6; font-size: 12.5px; }

.tb-footer__grid {
    display: grid; grid-template-columns: repeat(4, 1fr);
    gap: 32px;
    padding-bottom: 24px;
    border-bottom: 1px solid rgba(255,255,255,.08);
}
.tb-footer__accordion { display: none; }
.tb-footer__col { min-width: 0; }
.tb-footer__col > summary { list-style: none; cursor: default; }
.tb-footer__col > summary::-webkit-details-marker { display: none; }
.tb-footer__col-title {
    font-size: 11px; letter-spacing: 1.2px; text-transform: uppercase;
    font-weight: 700; margin: 0 0 12px;
    display: flex; justify-content: space-between; align-items: center;
}
.tb-footer__col-chev { display: none; opacity: .5; font-size: 18px; font-weight: 300; line-height: 1; }
.tb-footer__col-txt { opacity: .75; line-height: 1.9; font-size: 13px; }
.tb-footer__col-txt a { color: inherit; text-decoration: none; display: block; padding: 2px 0; }
.tb-footer__col-txt a:hover { opacity: 1; color: #fff; }

.tb-footer__pay {
    margin-top: 18px; font-size: 11px; opacity: .5;
    display: flex; gap: 8px; flex-wrap: wrap;
}
.tb-footer__pay span { font-weight: 600; opacity: 1; color: rgba(255,255,255,.8); }

.tb-footer__bottom {
    margin-top: 14px; padding-top: 14px; border-top: 1px solid rgba(255,255,255,.08);
    font-size: 11px; opacity: .45;
}

@media (min-width: 901px) {
    .tb-footer__inner {
        display: grid;
        grid-template-columns: minmax(220px, 320px) minmax(0, 1fr);
        gap: 22px 56px;
        align-items: start;
    }
    .tb-footer__brand {
        margin-bottom: 0;
    }
    .tb-footer__grid {
        padding-bottom: 0;
        border-bottom: 0;
    }
    .tb-footer__pay,
    .tb-footer__bottom {
        grid-column: 1 / -1;
    }
    .tb-footer__pay {
        padding-top: 18px;
        border-top: 1px solid rgba(255,255,255,.08);
    }
}

/* ─── Card producto (reusable) ─── */
.tb-card {
    background: #fff;
    border: 1px solid var(--tb-line);
    border-radius: 12px;
    padding: 16px;
    cursor: pointer;
    position: relative;
    transition: all .15s;
    display: flex;
    flex-direction: column;
    gap: 10px;
    text-decoration: none;
    color: inherit;
}
.tb-card:hover { border-color: var(--tb-ink); transform: translateY(-2px); }
.tb-card__discount {
    position: absolute; top: 12px; left: 12px;
    background: #3d2785; color: #fff;
    font-size: 11px; font-weight: 700;
    padding: 6px 9px; border-radius: 0;
    z-index: 2;
}
.tb-card__fav {
    position: absolute; top: 12px; right: 12px; z-index: 2;
    width: 28px; height: 28px; border-radius: 14px;
    background: #fff; border: 1px solid var(--tb-line);
    display: grid; place-items: center;
    cursor: pointer;
}
.tb-card__image {
    aspect-ratio: 1/1;
    background: var(--tb-line2);
    border-radius: 8px;
    display: grid;
    place-items: center;
    overflow: hidden;
}
.tb-card__image img { max-width: 90%; max-height: 90%; object-fit: contain; }
.tb-card__brand {
    font-size: 10px;
    color: var(--tb-gray);
    text-transform: uppercase;
    letter-spacing: .8px;
    font-weight: 600;
}
.tb-card__name {
    font-size: 13px;
    font-weight: 600;
    color: var(--tb-ink);
    line-height: 1.35;
    min-height: 36px;
}
.tb-card__name-color { color: var(--tb-gray); font-weight: 400; }
.tb-card__prices { display: flex; align-items: baseline; gap: 8px; }
.tb-card__was { font-size: 12px; color: var(--tb-gray); text-decoration: line-through; }
.tb-card__ahorra { font-size: 11px; font-weight: 600; color: var(--tb-ink); }
.tb-card__price { font-size: 18px; font-weight: 700; color: var(--tb-ink); }
.tb-card__info { display: flex; flex-direction: column; gap: 2px; font-size: 10px; color: var(--tb-gray); }
.tb-card__cuota { display: none; font-size: 11px; font-weight: 700; color: var(--tb-green); }
.tb-card__cta {
    display: block; background: var(--tb-ink); color: #fff;
    padding: 10px 14px; border-radius: 6px;
    font-size: 11px; font-weight: 700; letter-spacing: .5px;
    text-align: center; margin-top: auto;
}
.tb-card:hover .tb-card__cta { background: var(--tb-accent); }

@media (max-width: 768px) {
    .tb-card { padding: 10px; gap: 6px; border-radius: 10px; }
    .tb-card__image { aspect-ratio: 1/1; }
    .tb-card__brand { display: none; }
    .tb-card__name { font-size: 11px; font-weight: 600; min-height: 28px; line-height: 1.25; }
    .tb-card__price { font-size: 15px; color: var(--tb-ink); font-weight: 800; text-decoration: none; }
    .tb-card__was { font-size: 10px; color: var(--tb-gray); text-decoration: line-through; }
    .tb-card__ahorra { display: block; font-size: 10px; color: var(--tb-green); font-weight: 700; }
    .tb-card__cuota { display: block; font-size: 12px; color: var(--tb-green); font-weight: 700; }
    .tb-card__info, .tb-card__cta { display: none; }
    .tb-card__discount { top: 8px; left: 8px; font-size: 12px; padding: 6px 10px; }
    .tb-card__fav { top: 6px; right: 6px; width: 24px; height: 24px; }
}

/* ─── Buttons ─── */
.tb-btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    text-decoration: none;
    text-align: center;
    transition: all .15s;
    font-family: inherit;
}
.tb-btn--primary { background: var(--tb-ink); color: #fff; }
.tb-btn--primary:hover { background: var(--tb-ink2); color: #fff; }
.tb-btn--white { background: #fff; color: var(--tb-ink); }
.tb-btn--white:hover { background: var(--tb-line2); }
.tb-btn--ghost { background: transparent; color: var(--tb-ink); border: 1px solid var(--tb-line); }
.tb-btn--ghost:hover { border-color: var(--tb-ink); }
.tb-btn--block { width: 100%; display: block; }
.tb-btn--lg { padding: 14px 28px; font-size: 15px; }
.tb-btn--sm { padding: 8px 14px; font-size: 12px; }

/* ─── Badges ─── */
.tb-badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .3px;
}
.tb-badge--red { background: var(--tb-red-soft); color: var(--tb-red); }
.tb-badge--green { background: var(--tb-green-soft); color: var(--tb-green); }
.tb-badge--accent { background: var(--tb-accent-soft); color: var(--tb-accent); }
.tb-badge--dark { background: var(--tb-ink); color: #fff; }
.tb-badge--yellow { background: #fff8e1; color: #8a6a00; }

/* Section titles */
.tb-section { padding: 48px 0; }
.tb-section__head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 20px; }
.tb-section__title { font-size: 22px; font-weight: 700; letter-spacing: -.5px; margin: 0; }
.tb-section__link { font-size: 13px; color: var(--tb-accent); text-decoration: none; font-weight: 500; }

/* Trust bar */
.tb-trustbar { background: #fff; padding: 20px 0; border-bottom: 1px solid var(--tb-line); }
.tb-trustbar__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.tb-trustbar__item { display: flex; gap: 12px; align-items: center; }
.tb-trustbar__icon { font-size: 22px; line-height: 1; }
.tb-trustbar__title { font-size: 12px; font-weight: 700; color: var(--tb-ink); }
.tb-trustbar__sub { font-size: 11px; color: var(--tb-gray); }

/* No-scrollbar helper */
.tb-no-scrollbar::-webkit-scrollbar { display: none; }
.tb-no-scrollbar { scrollbar-width: none; }

/* Mobile adjustments */
@media (max-width: 900px) {
    .tb-header__bar { padding: 10px 16px; gap: 12px; flex-wrap: wrap; }
    .tb-header__actions .tb-header__account { display: none; }
    .tb-header__cart-total { display: none; }
    .tb-nav { padding: 0 16px; overflow-x: auto; white-space: nowrap; }
    .tb-nav__item { padding: 10px 12px; font-size: 12px; }
    .tb-footer__grid { grid-template-columns: 1fr 1fr; gap: 24px; padding-bottom: 20px; }
}
@media (max-width: 768px) {
    .tb-footer { padding: 24px 18px 20px; }
    .tb-footer__brand { margin-bottom: 12px; }
    .tb-footer__brand-title { font-size: 22px; }

    /* Cada columna es un acordeón */
    .tb-footer__grid {
        display: none;
    }
    .tb-footer__accordion {
        display: block;
        border-bottom: none;
    }
    .tb-footer__col {
        border-top: 1px solid rgba(255,255,255,.1);
    }
    .tb-footer__col > summary { cursor: pointer; }
    .tb-footer__col-title {
        padding: 14px 2px; margin: 0;
        font-size: 13px; letter-spacing: .3px; text-transform: none;
        opacity: 1; font-weight: 600;
    }
    .tb-footer__col-chev {
        display: inline-block; transition: transform .2s ease; font-size: 22px;
    }
    .tb-footer__col[open] .tb-footer__col-chev { transform: rotate(45deg); }
    .tb-footer__col-txt {
        padding: 0 2px 12px; line-height: 2.2; font-size: 14px; opacity: .7;
    }

    .tb-footer__pay {
        padding-top: 14px; border-top: 1px solid rgba(255,255,255,.1);
        margin-top: 0; font-size: 10px; line-height: 1.5;
    }
    .tb-footer__bottom { font-size: 10px; margin-top: 10px; border-top: none; padding-top: 0; }
    .tb-trustbar__grid { grid-template-columns: 1fr 1fr; }
    .tb-section { padding: 28px 0; }
    .tb-section__title { font-size: 18px; }
}

/* ═══ FORM SYSTEM (Formularios.html — claude.ai/design) ═══════════════════ */

.tb-form { display: flex; flex-direction: column; gap: 18px; }
.tb-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.tb-row-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; }
@media (max-width: 640px) {
    .tb-row, .tb-row-3 { grid-template-columns: 1fr; }
}

.tb-field { display: flex; flex-direction: column; gap: 6px; position: relative; }
.tb-label { font-size: 13px; font-weight: 600; color: var(--tb-ink); letter-spacing: -.1px; display: flex; align-items: baseline; gap: 6px; }
.tb-label .tb-req { color: var(--tb-red); font-weight: 700; }
.tb-label .tb-opt { color: var(--tb-gray); font-weight: 500; font-size: 11px; letter-spacing: .2px; }
.tb-hint, .tb-help { font-size: 12px; color: var(--tb-gray); line-height: 1.4; display: flex; align-items: center; gap: 6px; }
.tb-error { font-size: 12px; color: var(--tb-red); line-height: 1.4; display: flex; align-items: center; gap: 6px; font-weight: 500; }
.tb-success { font-size: 12px; color: var(--tb-green); line-height: 1.4; display: flex; align-items: center; gap: 6px; font-weight: 500; }

.tb-input-wrap { position: relative; display: flex; align-items: center; }
.tb-input, .tb-select, .tb-textarea {
    width: 100%; font-family: inherit; font-size: 15px; line-height: 1.4; color: var(--tb-ink);
    background: var(--tb-card); border: 1.5px solid var(--tb-line); border-radius: var(--tb-radius);
    padding: 12px 14px; transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
    outline: none;
}
.tb-input::placeholder, .tb-textarea::placeholder { color: var(--tb-gray2); }
.tb-input:hover, .tb-select:hover, .tb-textarea:hover { border-color: var(--tb-line-strong); }
.tb-input:focus, .tb-select:focus, .tb-textarea:focus { border-color: var(--tb-accent); box-shadow: var(--tb-focus); background: #fff; }

.tb-input.has-icon-left { padding-left: 40px; }
.tb-input.has-icon-right { padding-right: 40px; }
.tb-input-icon { position: absolute; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--tb-gray); pointer-events: none; }
.tb-input-icon.left { left: 14px; }
.tb-input-icon.right { right: 14px; }
.tb-input-icon.right.clickable { pointer-events: auto; cursor: pointer; }
.tb-input-icon.right.clickable:hover { color: var(--tb-ink); }

.tb-input.error, .tb-select.error, .tb-textarea.error { border-color: var(--tb-red); }
.tb-input.error:focus, .tb-select.error:focus { box-shadow: 0 0 0 4px rgba(200, 55, 45, .15); }
.tb-input.success, .tb-select.success { border-color: var(--tb-green); }
.tb-input:disabled, .tb-select:disabled, .tb-textarea:disabled { background: var(--tb-line-soft); color: var(--tb-gray); cursor: not-allowed; }

.tb-select { appearance: none; -webkit-appearance: none; padding-right: 40px;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg width='12' height='8' viewBox='0 0 12 8' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M1 1.5l5 5 5-5' stroke='%236b6b70' stroke-width='1.8' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3e%3c/svg%3e");
    background-repeat: no-repeat; background-position: right 14px center; background-size: 12px;
}
.tb-textarea { resize: vertical; min-height: 96px; }

.tb-check, .tb-radio { display: flex; align-items: flex-start; gap: 10px; cursor: pointer; user-select: none; }
.tb-check input, .tb-radio input { position: absolute; opacity: 0; pointer-events: none; }
.tb-check-box, .tb-radio-box {
    flex-shrink: 0; width: 20px; height: 20px; border: 1.5px solid var(--tb-line-strong); background: #fff;
    display: grid; place-items: center; transition: .15s; margin-top: 1px;
}
.tb-check-box { border-radius: 4px; }
.tb-radio-box { border-radius: 50%; }
.tb-check input:focus-visible ~ .tb-check-box, .tb-radio input:focus-visible ~ .tb-radio-box { box-shadow: var(--tb-focus); border-color: var(--tb-accent); }
.tb-check input:checked ~ .tb-check-box { background: var(--tb-ink); border-color: var(--tb-ink); }
.tb-check input:checked ~ .tb-check-box::after { content: ""; width: 11px; height: 6px; border-left: 2px solid #fff; border-bottom: 2px solid #fff; transform: rotate(-45deg) translate(1px, -1px); }
.tb-radio input:checked ~ .tb-radio-box { border-color: var(--tb-ink); }
.tb-radio input:checked ~ .tb-radio-box::after { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--tb-ink); }
.tb-check-label { font-size: 14px; line-height: 1.45; color: var(--tb-ink2); }
.tb-check-label a { color: var(--tb-accent); text-decoration: underline; text-underline-offset: 2px; }

.tb-segment { display: inline-flex; border: 1.5px solid var(--tb-line); border-radius: var(--tb-radius); padding: 3px; background: var(--tb-line-soft); gap: 2px; }
.tb-segment button, .tb-segment label {
    font-family: inherit; font-size: 13px; font-weight: 600; padding: 8px 16px; border: none; background: transparent;
    border-radius: 5px; cursor: pointer; color: var(--tb-gray); transition: .15s; display: inline-flex; align-items: center; gap: 6px;
}
.tb-segment button:hover, .tb-segment label:hover { color: var(--tb-ink); }
.tb-segment button.active, .tb-segment label.active { background: #fff; color: var(--tb-ink); box-shadow: 0 1px 2px rgba(0, 0, 0, .08); }

.tb-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    font-family: inherit; font-size: 14px; font-weight: 700; letter-spacing: .1px;
    padding: 13px 22px; border-radius: var(--tb-radius); border: 1.5px solid transparent; cursor: pointer;
    transition: .15s; min-height: 48px; text-decoration: none;
}
.tb-btn:focus-visible { outline: none; box-shadow: var(--tb-focus); }
.tb-btn-primary { background: var(--tb-ink); color: #fff; }
.tb-btn-primary:hover { background: #000; color: #fff; }
.tb-btn-accent { background: var(--tb-accent); color: #fff; }
.tb-btn-accent:hover { background: #1638a3; color: #fff; }
.tb-btn-ghost { background: #fff; color: var(--tb-ink); border-color: var(--tb-line-strong); }
.tb-btn-ghost:hover { border-color: var(--tb-ink); background: var(--tb-line-soft); color: var(--tb-ink); }
.tb-btn-link { background: transparent; border-color: transparent; color: var(--tb-accent); padding: 10px 12px; font-weight: 600; min-height: 0; }
.tb-btn-link:hover { text-decoration: underline; color: var(--tb-accent); }
.tb-btn-full { width: 100%; }
.tb-btn-lg { min-height: 54px; font-size: 15px; padding: 15px 24px; }
.tb-btn:disabled { opacity: .5; cursor: not-allowed; }

.tb-card { background: #fff; border: 1px solid var(--tb-line); border-radius: var(--tb-radius-lg); padding: 28px; }
.tb-card-header { margin-bottom: 22px; padding-bottom: 18px; border-bottom: 1px solid var(--tb-line-soft); }
.tb-card-title { font-size: 18px; font-weight: 700; margin: 0 0 4px; letter-spacing: -.2px; display: flex; align-items: center; gap: 10px; }
.tb-card-title .tb-step { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 13px; background: var(--tb-ink); color: #fff; font-size: 12px; font-weight: 700; letter-spacing: 0; }
.tb-card-sub { font-size: 13px; color: var(--tb-gray); line-height: 1.5; margin: 0; }

.tb-alert { display: flex; gap: 10px; padding: 12px 14px; border-radius: var(--tb-radius); font-size: 13px; line-height: 1.5; border: 1px solid; }
.tb-alert-info { background: var(--tb-accent-soft); border-color: #d0dbf3; color: #1a3693; }
.tb-alert-warn { background: var(--tb-yellow-soft); border-color: #f5e4a1; color: #7a5a00; }
.tb-alert-error { background: var(--tb-red-soft); border-color: #f5c9c3; color: #a02a22; }
.tb-alert-success { background: var(--tb-green-soft); border-color: #c5e2d0; color: #065530; }
.tb-alert strong { display: block; margin-bottom: 2px; }

.tb-strength { display: flex; gap: 4px; margin-top: 6px; }
.tb-strength-bar { flex: 1; height: 4px; border-radius: 2px; background: var(--tb-line); }
.tb-strength-bar.on-1 { background: var(--tb-red); }
.tb-strength-bar.on-2 { background: var(--tb-yellow); }
.tb-strength-bar.on-3 { background: var(--tb-green); }

.tb-auth-wrap { background: var(--tb-bg); min-height: calc(100vh - 300px); padding: 48px 24px; display: grid; place-items: center; }
.tb-auth-card { width: 100%; max-width: 440px; }
.tb-stepper { display: flex; align-items: center; gap: 8px; font-size: 12px; }
.tb-stepper__item { display: flex; align-items: center; gap: 6px; color: var(--tb-gray); font-weight: 600; }
.tb-stepper__item.is-active { color: var(--tb-ink); font-weight: 700; }
.tb-stepper__num { width: 22px; height: 22px; border-radius: 11px; background: var(--tb-line); display: grid; place-items: center; font-size: 11px; }
.tb-stepper__item.is-active .tb-stepper__num { background: var(--tb-ink); color: #fff; }
.tb-stepper__sep { flex: 1; height: 1px; background: var(--tb-line); }

/* ═══ MOBILE CHROME (Mobile.html — claude.ai/design) ═══════════════════════ */

:root {
    --tbm-h: 56px;
    --tbm-tab-h: 64px;
    --tbm-ticker-h: 22px;
    --tbm-sab: env(safe-area-inset-bottom);
}

/* Por defecto (desktop) el chrome mobile queda oculto */
.tbm { display: none; }
body.tbm-locked { overflow: hidden; }

@media (max-width: 768px) {
    /* Ocultamos el header desktop; el menú horizontal/footer siguen */
    .tb-header { display: none !important; }

    /* Activamos el chrome mobile */
    .tbm { display: block; }

    /* Reservamos espacio para el header/tab bar fijos */
    body {
        padding-top: calc(var(--tbm-h) + var(--tbm-ticker-h));
        padding-bottom: calc(var(--tbm-tab-h) + var(--tbm-sab));
    }

    /* Hide tab bar en contextos con sticky CTA (PDP, Checkout) — se activa via body class */
    body.tbm-no-tabbar .tbm-tabbar { display: none; }
    body.tbm-no-tabbar { padding-bottom: 0; }
}

/* Ticker compacto una línea */
.tbm-ticker {
    position: fixed; top: 0; left: 0; right: 0; z-index: 100;
    background: #000; color: #fff;
    height: var(--tbm-ticker-h);
    overflow: hidden; white-space: nowrap;
    font-size: 12px; letter-spacing: 0;
    display: flex; align-items: center;
    text-transform: uppercase;
}
.tbm-ticker__track {
    display: inline-flex; justify-content: center; gap: 0;
    width: 100%;
    min-width: 100%;
}
.tbm-ticker__track span { flex-shrink: 0; }
.tbm-ticker__track span:not(:first-child) { display: none; }
@keyframes tbm-ticker {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* Header fijo */
.tbm-header {
    position: fixed; top: var(--tbm-ticker-h); left: 0; right: 0; z-index: 99;
    height: var(--tbm-h); background: #fff;
    border-bottom: 1px solid transparent;
    display: flex; align-items: center; padding: 0 6px; gap: 2px;
    transition: box-shadow .2s, border-color .2s;
}
.tbm-header.is-stuck {
    border-bottom-color: var(--tb-line);
    box-shadow: 0 2px 8px -4px rgba(0, 0, 0, .08);
}

.tbm-iconbtn {
    width: 44px; height: 44px; display: grid; place-items: center;
    border: none; background: none; color: var(--tb-ink); cursor: pointer;
    padding: 0; border-radius: 8px; position: relative; text-decoration: none;
}
.tbm-iconbtn:active { background: var(--tb-line-soft); }

.tbm-logo {
    flex: 1; text-align: center; text-decoration: none; color: var(--tb-ink);
    line-height: 1;
}
.tbm-logo__up {
    display: block; font-size: 9px; font-weight: 700; letter-spacing: .8px;
    color: var(--tb-gray);
}
.tbm-logo__main {
    display: block; font-size: 16px; font-weight: 800; letter-spacing: -.3px;
    margin-top: 1px;
}
.tbm-logo__sub { display: none; }

/* Carro badge */
.tbm-cart { position: relative; }
.tbm-cart__badge, .tbm-tab__badge {
    position: absolute; top: 6px; right: 4px;
    background: var(--tb-red); color: #fff;
    font-size: 9px; font-weight: 700;
    padding: 2px 5px; border-radius: 8px;
    min-width: 16px; text-align: center; line-height: 1;
}
.tbm-cart__badge.is-hidden, .tbm-tab__badge.is-hidden { display: none; }

/* Drawer lateral */
.tbm-drawer {
    position: fixed; inset: 0; z-index: 200;
    opacity: 0; pointer-events: none;
    transition: opacity .22s ease;
}
.tbm-drawer.is-open { opacity: 1; pointer-events: auto; }
.tbm-drawer__backdrop {
    position: absolute; inset: 0; background: rgba(0, 0, 0, .45);
}
.tbm-drawer__panel {
    position: absolute; top: 0; bottom: 0; left: 0; width: 86%; max-width: 360px;
    background: #fff; display: flex; flex-direction: column;
    transform: translateX(-100%); transition: transform .22s ease;
    will-change: transform;
}
.tbm-drawer.is-open .tbm-drawer__panel { transform: translateX(0); }

.tbm-drawer__head {
    padding: 14px 16px 12px;
    display: flex; justify-content: space-between; align-items: center;
    border-bottom: 1px solid var(--tb-line);
    gap: 10px;
}
.tbm-drawer__brand {
    display: flex; align-items: center; text-decoration: none; color: var(--tb-ink);
    flex: 1; min-width: 0;
}
.tbm-drawer__brand-img { height: 28px; max-width: 160px; object-fit: contain; }
.tbm-drawer__brand-text { flex-direction: column; line-height: 1; }
.tbm-drawer__brand-text .tbm-logo__up { font-size: 9px; font-weight: 700; letter-spacing: .8px; color: var(--tb-gray); }
.tbm-drawer__brand-text .tbm-logo__main { font-size: 18px; font-weight: 800; letter-spacing: -.3px; margin-top: 1px; }

.tbm-drawer__user {
    background: var(--tb-ink); color: #fff; padding: 14px 16px;
    display: flex; align-items: center; gap: 12px; text-decoration: none;
}
.tbm-drawer__avatar {
    width: 40px; height: 40px; background: #2a2a2d; border-radius: 999px;
    display: grid; place-items: center; color: #fff;
}
.tbm-drawer__user-info { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.tbm-drawer__user-hello { font-size: 13px; font-weight: 600; }
.tbm-drawer__user-email { font-size: 11px; opacity: .7; }
.tbm-drawer__user-chev { opacity: .5; }

.tbm-drawer__scroll { flex: 1; overflow-y: auto; overscroll-behavior: contain; }

.tbm-drawer__label {
    padding: 16px 16px 6px;
    font-size: 10px; letter-spacing: 1.2px; color: var(--tb-gray); font-weight: 700;
}
.tbm-drawer__row {
    padding: 13px 16px; display: flex; justify-content: space-between; align-items: center;
    border-bottom: 1px solid var(--tb-line2, #f2f2f4);
    font-size: 14px; color: var(--tb-ink); text-decoration: none;
    min-height: 44px;
}
.tbm-drawer__row:hover, .tbm-drawer__row:active { background: var(--tb-line-soft); }
.tbm-drawer__row svg { color: var(--tb-gray); transition: transform .18s ease; }

.tbm-drawer__cat { border-bottom: 1px solid var(--tb-line2, #f2f2f4); }
.tbm-drawer__cat > summary { list-style: none; cursor: pointer; border-bottom: none; }
.tbm-drawer__cat > summary::-webkit-details-marker { display: none; }
.tbm-drawer__cat[open] > summary .tbm-drawer__chev { transform: rotate(90deg); }
.tbm-drawer__cat[open] > summary { background: var(--tb-line-soft); }

.tbm-drawer__subrow {
    display: block; padding: 11px 16px 11px 32px;
    font-size: 13px; color: var(--tb-ink2); text-decoration: none;
    min-height: 40px;
}
.tbm-drawer__subrow:hover, .tbm-drawer__subrow:active { background: var(--tb-line-soft); }
.tbm-drawer__subrow--all { font-weight: 600; color: var(--tb-accent); }

.tbm-drawer__brands {
    padding: 8px 16px 8px;
    display: grid; grid-template-columns: 1fr 1fr; gap: 10px;
}
.tbm-drawer__brand {
    padding: 14px; border: 1px solid var(--tb-line); border-radius: 10px;
    font-size: 11px; font-weight: 800; letter-spacing: .5px;
    text-align: center; color: var(--tb-ink); text-decoration: none;
    min-height: 48px; display: grid; place-items: center;
}
.tbm-drawer__brand:active { background: var(--tb-line-soft); }

.tbm-drawer__trust {
    padding: 12px 16px; background: var(--tb-bg, #fafafa);
    border-top: 1px solid var(--tb-line);
    display: flex; gap: 14px; font-size: 11px; color: var(--tb-gray);
}

/* Search overlay */
.tbm-search {
    position: fixed; inset: 0; z-index: 200; background: #fff;
    opacity: 0; transform: translateY(8px); pointer-events: none;
    transition: opacity .18s ease, transform .18s ease;
    display: flex; flex-direction: column;
}
.tbm-search.is-open { opacity: 1; transform: translateY(0); pointer-events: auto; }
.tbm-search__bar {
    padding: 10px 8px; border-bottom: 1px solid var(--tb-line);
    display: flex; align-items: center; gap: 8px;
}
.tbm-search__input {
    flex: 1; background: var(--tb-line2, #f2f2f4); border-radius: 999px;
    padding: 10px 16px; display: flex; align-items: center; gap: 8px;
    color: var(--tb-gray);
}
.tbm-search__input input {
    flex: 1; border: none; background: none; outline: none;
    font-size: 14px; font-family: inherit; color: var(--tb-ink);
}
.tbm-search__body { flex: 1; overflow-y: auto; padding: 16px 14px; }
.tbm-search__label {
    font-size: 10px; letter-spacing: 1.2px; color: var(--tb-gray);
    font-weight: 700; margin-bottom: 10px;
}
.tbm-search__label:not(:first-child) { margin-top: 24px; }
.tbm-search__chips { display: flex; flex-wrap: wrap; gap: 8px; }
.tbm-search__chip {
    padding: 8px 14px; border: 1px solid var(--tb-line); border-radius: 999px;
    font-size: 12px; font-weight: 500; color: var(--tb-ink); text-decoration: none;
    min-height: 36px; display: inline-flex; align-items: center;
}
.tbm-search__results { display: flex; flex-direction: column; }
.tbm-search__result {
    padding: 10px 0; display: flex; align-items: center; gap: 12px;
    border-bottom: 1px solid var(--tb-line2, #f2f2f4); text-decoration: none;
    color: var(--tb-ink); min-height: 60px;
}
.tbm-search__thumb {
    width: 48px; height: 48px; background: var(--tb-line2, #f2f2f4);
    border-radius: 6px; display: grid; place-items: center;
    flex-shrink: 0; overflow: hidden; color: var(--tb-gray);
}
.tbm-search__thumb img { width: 100%; height: 100%; object-fit: cover; }
.tbm-search__meta { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.tbm-search__name { font-size: 13px; font-weight: 600; }
.tbm-search__price { font-size: 11px; color: var(--tb-green); font-weight: 600; }

/* Tab bar inferior */
.tbm-tabbar {
    position: fixed; bottom: 0; left: 0; right: 0; z-index: 95;
    height: calc(var(--tbm-tab-h) + var(--tbm-sab));
    padding-bottom: var(--tbm-sab);
    background: #fff; border-top: 1px solid var(--tb-line);
    display: grid; grid-template-columns: repeat(4, 1fr);
}
.tbm-tab {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 2px; min-height: 44px;
    color: var(--tb-gray); font-size: 10px; font-weight: 500;
    text-decoration: none; position: relative;
}
.tbm-tab.is-active {
    color: var(--tb-ink); font-weight: 700;
}
.tbm-tab.is-active::before {
    content: ""; position: absolute; top: 0; left: 50%;
    width: 30px; height: 3px; background: var(--tb-ink);
    transform: translateX(-50%);
}
.tbm-tab__icon { position: relative; display: inline-block; }
.tbm-tab svg { display: block; }

/* Auth tabs (Login / Registro) */
.tba-tabs {
    display: grid; grid-template-columns: 1fr 1fr; gap: 4px;
    background: var(--tb-line-soft); padding: 4px; border-radius: 10px;
    margin-bottom: 18px;
}
.tba-tab {
    padding: 11px; text-align: center;
    font-size: 13px; font-weight: 500; color: var(--tb-gray);
    text-decoration: none; border-radius: 8px; min-height: 44px;
    display: grid; place-items: center;
}
.tba-tab.is-active {
    background: #fff; color: var(--tb-ink); font-weight: 700;
    box-shadow: 0 1px 2px rgba(0,0,0,.06);
}

/* Perfil tab pills */
.tbu-tabs {
    display: flex; gap: 8px;
    padding: 10px 0; margin-bottom: 16px;
    overflow-x: auto; white-space: nowrap;
    scrollbar-width: none;
}
.tbu-tabs::-webkit-scrollbar { display: none; }
.tbu-tab {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 8px 14px; border-radius: 999px;
    border: 1px solid var(--tb-line); background: #fff;
    font-size: 12px; font-weight: 600; color: var(--tb-ink);
    text-decoration: none; flex-shrink: 0;
    min-height: 40px;
}
.tbu-tab:hover { border-color: var(--tb-ink); color: var(--tb-ink); }
.tbu-tab.is-active { background: var(--tb-ink); color: #fff; border-color: var(--tb-ink); }

/* PDP sticky CTA (mobile) */
.pdp-mcta { display: none; }
@media (max-width: 768px) {
    .pdp-mcta {
        display: flex; position: fixed; left: 0; right: 0;
        bottom: 0; z-index: 90;
        padding: 12px 14px calc(14px + var(--tbm-sab, 0px));
        background: #fff; border-top: 1px solid var(--tb-line);
        gap: 12px; align-items: center;
        box-shadow: 0 -6px 20px -10px rgba(0,0,0,.12);
    }
    body.tbm-no-tabbar { padding-bottom: 84px; }
    .pdp-mcta__price { flex-shrink: 0; display: flex; flex-direction: column; }
    .pdp-mcta__cuota-label { font-size: 10px; color: var(--tb-green); font-weight: 700; letter-spacing: .2px; }
    .pdp-mcta__cuota { font-size: 15px; font-weight: 800; line-height: 1; }
    .pdp-mcta__btn {
        flex: 1; background: var(--tb-ink); color: #fff;
        border: none; padding: 14px; border-radius: 10px;
        font-size: 14px; font-weight: 700; text-decoration: none; text-align: center;
        min-height: 48px; display: grid; place-items: center;
    }
    .pdp-mcta__btn:hover, .pdp-mcta__btn:active { background: #000; color: #fff; }
}

/* Flix Media fallback */
.tb-flix-fallback[hidden] { display: none !important; }
.tb-flix-fallback {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 24px 28px;
}
.tb-flix-fallback__shell {
    border: 1px solid var(--tb-line, #e7e7ea);
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
}
.tb-flix-fallback__header {
    padding: 20px 22px 16px;
    border-bottom: 1px solid var(--tb-line, #e7e7ea);
}
.tb-flix-fallback__eyebrow {
    font-size: 11px;
    font-weight: 700;
    color: var(--tb-gray, #777);
    text-transform: uppercase;
    letter-spacing: .6px;
    margin-bottom: 4px;
}
.tb-flix-fallback__header h2 {
    margin: 0;
    font-size: 24px;
    line-height: 1.2;
    font-weight: 800;
    color: var(--tb-ink, #111);
}
.tb-flix-fallback__features {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1px;
    background: var(--tb-line, #e7e7ea);
}
.tb-flix-fallback__feature {
    background: #fff;
    min-width: 0;
}
.tb-flix-fallback__feature img {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    background: #f6f6f7;
}
.tb-flix-fallback__feature div {
    padding: 16px 18px 18px;
}
.tb-flix-fallback__feature h3 {
    margin: 0 0 8px;
    font-size: 16px;
    line-height: 1.25;
    font-weight: 800;
    color: var(--tb-ink, #111);
}
.tb-flix-fallback__feature p {
    margin: 0;
    color: var(--tb-gray, #666);
    font-size: 13px;
    line-height: 1.45;
}
.tb-flix-fallback__feature small {
    display: block;
    margin-top: 10px;
    color: var(--tb-gray2, #888);
    font-size: 11px;
    line-height: 1.35;
}
.tb-flix-fallback__specs {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1px;
    background: var(--tb-line, #e7e7ea);
    border-top: 1px solid var(--tb-line, #e7e7ea);
}
.tb-flix-fallback__spec {
    background: #fafafa;
    padding: 14px 16px;
    min-width: 0;
}
.tb-flix-fallback__spec span {
    display: block;
    color: var(--tb-gray, #666);
    font-size: 11px;
    line-height: 1.3;
    margin-bottom: 4px;
}
.tb-flix-fallback__spec strong {
    display: block;
    color: var(--tb-ink, #111);
    font-size: 13px;
    line-height: 1.35;
    font-weight: 800;
}
@media (max-width: 900px) {
    .tb-flix-fallback__features { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .tb-flix-fallback__specs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 560px) {
    .tb-flix-fallback { padding: 0 14px 22px; }
    .tb-flix-fallback__header { padding: 16px; }
    .tb-flix-fallback__header h2 { font-size: 20px; }
    .tb-flix-fallback__features { grid-template-columns: 1fr; }
}
