/*
  tech01 — Aether
  Soft Swiss-modern tech magazine (ui-ux-pro-max + editorial grid)
*/

:root {
    --nl-bg: #f5f7fa;
    --nl-surface: #ffffff;
    --nl-ink: #0f172a;
    --nl-muted: #64748b;
    --nl-line: #e2e8f0;
    --nl-accent: #2563eb;
    --nl-accent-soft: #eff6ff;
    --nl-deep: #0b1220;
    --nl-radius: 10px;
    --nl-radius-lg: 18px;
    --nl-shadow: 0 16px 40px rgba(15, 23, 42, 0.08);
    --nl-shadow-sm: 0 6px 18px rgba(15, 23, 42, 0.06);
    --nl-font: 'Source Sans 3', system-ui, sans-serif;
    --nl-display: 'Sora', system-ui, sans-serif;
    --nl-container: 1320px;
    --nl-header-h: 4.5rem;
    --nl-ease: cubic-bezier(0.22, 1, 0.36, 1);
}

[data-bs-theme="dark"] {
    --nl-bg: #0b1220;
    --nl-surface: #121a2b;
    --nl-ink: #e8eef7;
    --nl-muted: #94a3b8;
    --nl-line: #243247;
    --nl-accent: #60a5fa;
    --nl-accent-soft: #172554;
    --nl-deep: #020617;
    --nl-shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
    --nl-shadow-sm: 0 6px 18px rgba(0, 0, 0, 0.25);
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

body,
.t1-shell {
    margin: 0;
    font-family: var(--nl-font);
    font-size: 1.05rem;
    line-height: 1.65;
    color: var(--nl-ink);
    background:
        radial-gradient(1200px 480px at 10% -10%, rgba(37, 99, 235, 0.08), transparent 55%),
        radial-gradient(900px 420px at 90% 0%, rgba(14, 165, 233, 0.06), transparent 50%),
        var(--nl-bg);
    -webkit-font-smoothing: antialiased;
}

a {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s var(--nl-ease);
    cursor: pointer;
}

a:hover { color: var(--nl-accent); }

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

.main-wrapper { min-height: 60vh; }

.container {
    max-width: var(--nl-container);
    margin: 0 auto;
    padding-left: 1.25rem;
    padding-right: 1.25rem;
}

h1, h2, h3, h4, h5, h6,
.section-title,
.post-title,
.t1-stage__title,
.t1-rail__title {
    font-family: var(--nl-display);
    font-weight: 600;
    line-height: 1.2;
    color: var(--nl-ink);
    letter-spacing: -0.03em;
}

.section-title {
    font-size: clamp(1.45rem, 2.4vw, 1.85rem);
    margin: 0;
    padding: 0;
    border: none;
    display: block;
}

.section-title::after { display: none; }

.section-label,
.t1-kicker {
    font-family: var(--nl-font);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--nl-accent);
    margin: 0 0 0.55rem;
}

.t1-kicker--light { color: #93c5fd; }

.t1-brand {
    font-family: var(--nl-display);
    font-weight: 700;
    font-size: clamp(2rem, 5vw, 3.25rem);
    letter-spacing: -0.04em;
    margin: 0 0 0.5rem;
    color: var(--nl-ink);
}

.t1-tagline {
    margin: 0;
    color: var(--nl-muted);
    font-size: 1.05rem;
    max-width: 40ch;
}

.t1-chip {
    display: inline-flex;
    align-items: center;
    padding: 0.28rem 0.65rem;
    border-radius: 999px;
    background: var(--nl-accent-soft);
    color: var(--nl-accent);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin-bottom: 0.75rem;
}

.t1-meta {
    font-size: 0.82rem;
    color: var(--nl-muted);
}

.btn-theme {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.85rem 1.4rem;
    background: var(--nl-accent);
    color: #fff !important;
    border: none;
    border-radius: 999px;
    font-family: var(--nl-display);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s var(--nl-ease), background 0.2s var(--nl-ease), box-shadow 0.2s var(--nl-ease);
}

.btn-theme:hover {
    background: #1d4ed8;
    color: #fff !important;
    transform: translateY(-1px);
    box-shadow: var(--nl-shadow-sm);
}

.text-color-50 { color: var(--nl-muted) !important; }
.bg-bg { background: transparent; }
.hr { margin: 2.5rem 0 1.5rem; }

.visually-hidden {
    position: absolute !important;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0, 0, 0, 0);
    white-space: nowrap; border: 0;
}

.posts-grid-row { display: grid; gap: 1.25rem; }

.two-columns-grid {
    display: grid;
    gap: 1rem;
}

@media (min-width: 576px) {
    .two-columns-grid { grid-template-columns: repeat(2, 1fr); }
}

.slide-post-columns-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
}

@media (max-width: 575px) {
    .slide-post-columns-grid { grid-template-columns: 1fr; }
}

/* Horizontal scroller — shell from shared nl-hscroll; track keeps item sizing */
.t1-horizontal-scroll {
    max-width: 100%;
    min-width: 0;
}

.t1-horizontal-scroll .t1-horizontal-scroll__track,
.t1-horizontal-scroll.nl-hscroll .nl-hscroll__track.t1-horizontal-scroll__track {
    display: flex;
    flex-wrap: nowrap;
    gap: 1rem;
    padding-inline: 0;
}

.t1-main1__item {
    flex: 0 0 auto;
    min-width: 220px;
    max-width: 220px;
}

@media (max-width: 575px) {
    .t1-main1__item {
        min-width: 180px;
        max-width: 180px;
    }
}

.post-item.v2 .post-wrapper-row {
    display: grid;
    gap: 0;
    background: var(--nl-surface);
    border: 1px solid var(--nl-line);
    border-radius: var(--nl-radius-lg);
    overflow: hidden;
    box-shadow: var(--nl-shadow-sm);
    transition: transform 0.25s var(--nl-ease), box-shadow 0.25s var(--nl-ease);
}

@media (min-width: 768px) {
    .post-item.v2 .post-wrapper-row {
        grid-template-columns: 280px 1fr;
    }
}

.post-item.v2 .post-wrapper-row:hover {
    transform: translateY(-3px);
    box-shadow: var(--nl-shadow);
}

.post-image-wrapper,
.post-image-wrapper-row,
.postImageWrapper {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 10;
    background: var(--nl-line);
}

.post-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.35s var(--nl-ease), transform 0.5s var(--nl-ease);
}

.post-image.loaded { opacity: 1; }
.post-wrapper-row:hover .post-image.loaded { transform: scale(1.04); }

.image-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(15, 23, 42, 0.55), transparent 55%);
    opacity: 0;
    display: flex;
    align-items: flex-end;
    padding: 1rem;
    transition: opacity 0.25s var(--nl-ease);
}

.post-image-link:hover .image-overlay { opacity: 1; }

.read-more {
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.post-content { padding: 1.25rem; }

.post-item.v2 .post-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 1.5rem 1.65rem;
}

.post-item.v2.v2--date-below .post-content {
    justify-content: flex-start;
    min-height: 100%;
}

.post-item.v2.v2--date-below .post-title {
    margin-bottom: 0;
}

.post-item.v2.v2--date-below .post-meta {
    margin-top: auto;
    margin-bottom: 0;
    padding-top: 0.65rem;
}

.post-meta {
    font-size: 0.8rem;
    color: var(--nl-muted);
    margin-bottom: 0.45rem;
}

.post-meta .post-date {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.post-meta .post-date i {
    margin: 0;
    flex-shrink: 0;
}

.post-title {
    font-size: clamp(1.1rem, 2vw, 1.4rem);
    margin: 0 0 0.55rem;
}

.post-excerpt {
    font-size: 0.95rem;
    color: var(--nl-muted);
    line-height: 1.6;
}

.post-item .post-wrapper {
    background: var(--nl-surface);
    border: 1px solid var(--nl-line);
    border-radius: var(--nl-radius);
    overflow: hidden;
    height: 100%;
    transition: box-shadow 0.2s var(--nl-ease), transform 0.2s var(--nl-ease);
}

.post-item .post-wrapper:hover {
    box-shadow: var(--nl-shadow-sm);
    transform: translateY(-2px);
}

.post-item .post-image-wrapper { aspect-ratio: 4 / 3; }
.post-item .post-content { padding: 0.9rem; }
.post-item .post-title { font-size: 0.95rem; margin: 0; }

.post-card {
    border: 1px solid var(--nl-line);
    border-radius: var(--nl-radius-lg);
    overflow: hidden;
    background: var(--nl-surface);
    box-shadow: var(--nl-shadow-sm);
    transition: box-shadow 0.2s var(--nl-ease);
}

.post-card:hover { box-shadow: var(--nl-shadow); }
.post-card .card-img-top { aspect-ratio: 16/10; object-fit: cover; }
.post-card .card-body { padding: 1rem; }
.post-card .card-title { font-size: 1rem; margin: 0; }

.home-main { padding: 0 0 4rem; }

/* Equal two-column split after hero strip (physical left/right) */
.t1-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem 2.5rem;
    direction: ltr;
    align-items: start;
}

.t1-split__left,
.t1-split__right {
    min-width: 0;
}

@media (max-width: 991px) {
    .t1-split {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

.home-sidebar {
    position: sticky;
    top: calc(var(--nl-header-h) + 1rem);
}

.sidebar-block {
    margin-top: 1.75rem;
    margin-bottom: 1.75rem;
    padding-bottom: 0.25rem;
}

.sidebar-block:first-child {
    margin-top: 0;
}

.sidebar-block:last-child {
    margin-bottom: 0;
}

.sidebar-block__lead {
    margin-bottom: 1rem;
}

.sidebar-block__lead .post-item .post-image-wrapper {
    aspect-ratio: 16 / 10;
}

.t1-block {
    margin-top: 2.75rem;
    margin-bottom: 1.5rem;
}

.t1-block.t1-block--first { margin-top: 0; }

.t1-main1 { margin-top: 1.75rem; padding-bottom: 1.25rem; }

.t1-feature-split {
    padding: 1.5rem 0 3rem;
}

.t1-feature-split__grid {
    display: grid;
    grid-template-columns: minmax(0, 7fr) minmax(0, 3fr);
    gap: 1.25rem 1.5rem;
    align-items: stretch;
    direction: ltr;
}

.t1-feature-split__lead {
    min-width: 0;
}

.t1-feature-lead {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 16 / 11;
    min-height: 280px;
    border-radius: var(--nl-radius-lg);
    overflow: hidden;
    background: var(--nl-line);
    color: #fff;
    text-decoration: none;
}

.t1-feature-lead:hover {
    color: #fff;
}

.t1-feature-lead__media {
    position: absolute;
    inset: 0;
}

.t1-feature-lead__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transform: scale(1);
    transition: transform 0.5s var(--nl-ease);
}

.t1-feature-lead:hover .t1-feature-lead__media img {
    transform: scale(1.04);
}

.t1-feature-lead__shade {
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(
        to top,
        rgba(15, 23, 42, 0.82) 0%,
        rgba(15, 23, 42, 0.35) 42%,
        transparent 70%
    );
}

.t1-feature-lead__copy {
    position: absolute;
    inset-inline: 0;
    bottom: 0;
    z-index: 2;
    padding: 1.35rem 1.5rem;
}

.t1-feature-lead__title {
    font-family: var(--nl-display);
    font-size: clamp(1.25rem, 2.2vw, 1.85rem);
    font-weight: 600;
    letter-spacing: -0.03em;
    line-height: 1.25;
    margin: 0 0 0.45rem;
    color: #fff;
}

.t1-feature-lead__date {
    display: block;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.78);
}

.t1-feature-split__side-wrap {
    position: relative;
    min-width: 0;
    min-height: 0;
}

.t1-feature-split__side {
    position: absolute;
    inset: 0;
    display: grid;
    gap: 1.15rem;
    align-content: start;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    padding-top: 0.15rem;
    padding-right: 0.25rem;
    scrollbar-width: thin;
}

.t1-feature-split__side .post-item .post-wrapper {
    display: grid;
    grid-template-columns: 20% 1fr;
    gap: 0.75rem;
    align-items: center;
    background: transparent;
    border: none;
    border-radius: 0;
    box-shadow: none;
    overflow: visible;
    height: auto;
}

.t1-feature-split__side .post-item .post-wrapper:hover {
    box-shadow: none;
    transform: none;
}

.t1-feature-split__side .post-item .post-image-wrapper {
    aspect-ratio: 1;
    border-radius: var(--nl-radius);
    overflow: hidden;
}

.t1-feature-split__side .post-item .post-content {
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.t1-feature-split__side .post-item .post-title {
    order: 1;
    font-size: 0.9rem;
    line-height: 1.35;
    margin: 0;
}

.t1-feature-split__side .post-item .post-meta {
    order: 2;
    margin: 0;
    font-size: 0.75rem;
}

.t1-feature-split__side::-webkit-scrollbar {
    width: 6px;
}

.t1-feature-split__side::-webkit-scrollbar-thumb {
    background: var(--nl-line);
    border-radius: 999px;
}

@media (max-width: 991px) {
    .t1-feature-split__grid {
        grid-template-columns: 1fr;
    }

    .t1-feature-split__side-wrap {
        position: static;
    }

    .t1-feature-split__side {
        position: static;
        overflow: visible;
        padding-right: 0;
    }
}

.t1-bottom-strip {
    margin-top: 0.5rem;
    padding-bottom: 2rem;
}

.t1-bottom-strip__item {
    flex: 0 0 auto;
    min-width: 220px;
    max-width: 220px;
}

@media (max-width: 575px) {
    .t1-bottom-strip__item {
        min-width: 180px;
        max-width: 180px;
    }
}

.t1-block__head { margin-bottom: 1.25rem; }

.breadcrumb {
    font-size: 0.85rem;
    background: transparent;
    padding: 0;
    margin: 0;
}

.breadcrumb-item + .breadcrumb-item::before { color: var(--nl-muted); }

.overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.4);
    z-index: 1035;
    backdrop-filter: blur(2px);
}

.overlay.active { display: block; }

.archive-page,
.search-page,
.static-page,
.contact-page {
    padding: 2.25rem 0 4rem;
}

.archive-header {
    margin-bottom: 2rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid var(--nl-line);
}

.archive-header h1 {
    font-size: clamp(2rem, 4.5vw, 3rem);
    margin: 0;
}

.contact-page__lead {
    color: var(--nl-muted);
    max-width: 42ch;
    margin: 0.75rem 0 0;
}

.contact-page__card {
    max-width: 640px;
    background: var(--nl-surface);
    border: 1px solid var(--nl-line);
    border-radius: var(--nl-radius-lg);
    padding: 1.75rem;
    box-shadow: var(--nl-shadow-sm);
}

.static-page__content {
    max-width: 720px;
    background: var(--nl-surface);
    border: 1px solid var(--nl-line);
    border-radius: var(--nl-radius-lg);
    padding: 2rem;
}

@keyframes t1-rise {
    from { opacity: 0; transform: translateY(14px); }
    to { opacity: 1; transform: translateY(0); }
}

.article-page { padding: 1.75rem 0 4rem; }

.article-header {
    max-width: 760px;
    margin: 0 0 1.75rem;
}

.article-header h1 {
    font-size: clamp(2rem, 4.8vw, 3.25rem);
    font-weight: 700;
    margin: 0 0 0.9rem;
    letter-spacing: -0.035em;
}

.article-header .lead {
    font-size: 1.15rem;
    color: var(--nl-muted);
    font-weight: 400;
    line-height: 1.6;
    margin: 0;
    max-width: 48ch;
}

.article-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem 1.15rem;
    margin-top: 1.2rem;
    font-size: 0.85rem;
    color: var(--nl-muted);
}

.article-cover {
    margin: 0 0 2.25rem;
    border-radius: var(--nl-radius-lg);
    overflow: hidden;
    border: 1px solid var(--nl-line);
    box-shadow: var(--nl-shadow-sm);
}

.article-cover img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain;
}

.article-content {
    background: var(--nl-surface);
    border: 1px solid var(--nl-line);
    border-radius: var(--nl-radius-lg);
    padding: 2rem 2.1rem;
    box-shadow: var(--nl-shadow-sm);
}

@media (max-width: 576px) {
    .article-content { padding: 1.25rem 1.1rem; }
    .article-page { overflow-x: hidden; }
}

.article-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem;
    padding-bottom: 1.15rem;
    margin-bottom: 1.4rem;
    border-bottom: 1px solid var(--nl-line);
    font-size: 0.85rem;
    color: var(--nl-muted);
}

.article-text {
    font-size: 1.08rem;
    line-height: 1.85;
}

.article-text img:not(.post-image) {
    margin: 1.5rem 0;
    max-width: 100%;
    border-radius: var(--nl-radius);
}

.article-text h2,
.article-text h3 {
    margin-top: 2rem;
    margin-bottom: 0.7rem;
}

.article-text a { color: var(--nl-accent); }

.article-text blockquote {
    margin: 1.6rem 0;
    padding: 1rem 1.2rem;
    border-left: 4px solid var(--nl-accent);
    background: var(--nl-accent-soft);
    border-radius: 0 var(--nl-radius) var(--nl-radius) 0;
    font-family: var(--nl-display);
    font-size: 1.15rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    line-height: 1.4;
}

.article-sidebar {
    position: sticky;
    top: calc(var(--nl-header-h) + 1rem);
    align-self: flex-start;
    z-index: 2;
}

/* Related posts — compact Aether rail */
.t1-related {
    background: var(--nl-surface);
    border: 1px solid var(--nl-line);
    border-radius: var(--nl-radius-lg);
    box-shadow: var(--nl-shadow-sm);
    overflow: hidden;
}

.t1-related__head {
    padding: 1.15rem 1.2rem 0.95rem;
    border-bottom: 1px solid var(--nl-line);
    background:
        linear-gradient(
            135deg,
            color-mix(in srgb, var(--nl-accent) 10%, transparent),
            transparent 70%
        );
}

.t1-related__head .t1-kicker {
    margin: 0;
    font-size: 0.95rem;
}

.t1-related__list {
    list-style: none;
    margin: 0;
    padding: 0.35rem 0;
}

.t1-related__list > li + li {
    border-top: 1px solid var(--nl-line);
}

.t1-related__item {
    display: grid;
    grid-template-columns: 2rem 4.25rem 1fr;
    gap: 0.75rem;
    align-items: center;
    padding: 0.85rem 1.1rem;
    color: inherit;
    text-decoration: none;
    transition: background 0.22s var(--nl-ease);
}

.t1-related__item:hover {
    background: var(--nl-accent-soft);
    color: inherit;
}

.t1-related__index {
    font-family: var(--nl-display);
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: var(--nl-accent);
    line-height: 1;
    text-align: center;
}

.t1-related__media {
    overflow: hidden;
    aspect-ratio: 1;
    border-radius: calc(var(--nl-radius) - 2px);
    background: var(--nl-line);
}

.t1-related__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.45s var(--nl-ease);
}

.t1-related__item:hover .t1-related__media img {
    transform: scale(1.06);
}

.t1-related__copy {
    min-width: 0;
}

.t1-related__title {
    font-family: var(--nl-display);
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.3;
    letter-spacing: -0.02em;
    margin: 0 0 0.3rem;
    color: var(--nl-ink);
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    transition: color 0.2s var(--nl-ease);
}

.t1-related__item:hover .t1-related__title {
    color: var(--nl-accent);
}

.t1-related__date {
    font-size: 0.75rem;
    letter-spacing: 0.02em;
    color: var(--nl-muted);
}

@media (max-width: 991px) {
    .t1-related {
        margin-top: 0.25rem;
    }
}

.author-card {
    display: flex;
    gap: 1rem;
    padding: 1.25rem 0 0;
    border-top: 1px solid var(--nl-line);
    margin-top: 2rem;
}

.author-card img {
    flex-shrink: 0;
    width: 56px;
    height: 56px;
    object-fit: cover;
    border-radius: 50%;
}

.comment-section,
.comment-form {
    margin-top: 2.25rem;
}

.comment-section h4,
.comment-form h4 {
    font-family: var(--nl-display);
    margin-bottom: 1rem;
}

.comment-item {
    background: var(--nl-surface);
    border: 1px solid var(--nl-line);
    border-radius: var(--nl-radius);
    padding: 1rem 1.1rem;
    margin-bottom: 0.85rem;
}

.comment-form .form-control,
.comment-form textarea {
    border-radius: var(--nl-radius);
    border: 1px solid var(--nl-line);
    background: var(--nl-bg);
}

.comment-form .form-control:focus,
.comment-form textarea:focus {
    border-color: var(--nl-accent);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

@media (max-width: 991px) {
    .article-sidebar,
    .home-sidebar {
        position: static;
        align-self: stretch;
        margin-top: 2rem;
    }
}

.t1-header {
    position: sticky;
    top: 0;
    z-index: 1060;
    overflow: visible;
    background: rgba(245, 247, 250, 0.86);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--nl-line);
}

[data-bs-theme="dark"] .t1-header {
    background: rgba(11, 18, 32, 0.9);
}

.t1-header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.25rem;
    min-height: var(--nl-header-h);
    overflow: visible;
}

.t1-header__brand {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    min-width: 0;
}

.t1-header__brand img {
    height: 2.15rem;
    width: auto;
    flex-shrink: 0;
}

.t1-header__name {
    font-family: var(--nl-display);
    font-weight: 700;
    font-size: 1.1rem;
    letter-spacing: -0.03em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 28vw;
}

.t1-header__actions {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    flex-shrink: 0;
}

.t1-header__search {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 999px;
    border: 1px solid var(--nl-line);
    background: var(--nl-surface);
    color: var(--nl-ink);
    text-decoration: none;
    transition: border-color 0.2s, background 0.2s, color 0.2s;
}

.t1-header__search:hover,
.t1-header__search:focus-visible {
    border-color: var(--nl-accent);
    background: var(--nl-accent-soft);
    color: var(--nl-accent);
    text-decoration: none;
    outline: none;
}

.t1-nav--desktop {
    position: relative;
    z-index: 5;
    overflow: visible;
    flex: 1;
    display: flex;
    justify-content: center;
    min-width: 0;
}

.t1-nav--desktop > ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
    gap: 0.2rem 1.35rem;
    flex-wrap: nowrap;
    overflow: visible;
}

.t1-nav--desktop > ul > li {
    position: relative;
    overflow: visible;
}

.t1-nav--desktop > ul > li > a {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-family: var(--nl-display);
    font-size: 0.92rem;
    font-weight: 600;
    letter-spacing: -0.01em;
    padding: 0.55rem 0.15rem;
    color: var(--nl-ink);
}

.t1-nav--desktop > ul > li > a:hover,
.t1-nav--desktop > ul > li:focus-within > a {
    color: var(--nl-accent);
}

.t1-nav--desktop > ul > .has-submenu > a::after {
    content: "";
    width: 0;
    height: 0;
    border-left: 3.5px solid transparent;
    border-right: 3.5px solid transparent;
    border-top: 4.5px solid currentColor;
    opacity: 0.55;
    margin-top: 1px;
}

/* Desktop dropdown — opacity/visibility (avoid display hover gaps) */
.t1-nav--desktop .submenu {
    list-style: none;
    margin: 0;
    padding: 0.45rem 0;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 220px;
    background: var(--nl-surface);
    border: 1px solid var(--nl-line);
    border-radius: var(--nl-radius);
    box-shadow: var(--nl-shadow);
    z-index: 1300;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(6px);
    transition:
        opacity 0.2s var(--nl-ease),
        transform 0.2s var(--nl-ease),
        visibility 0.2s;
}

.t1-nav--desktop .submenu::before {
    content: "";
    position: absolute;
    top: -0.7rem;
    left: 0;
    right: 0;
    height: 0.7rem;
}

.t1-nav li { position: relative; }

@media (min-width: 992px) {
    .t1-nav--desktop .has-submenu:hover > .submenu,
    .t1-nav--desktop .has-submenu:focus-within > .submenu {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: translateY(0);
    }
}

.t1-nav--desktop .submenu a {
    display: block;
    padding: 0.55rem 1rem;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--nl-ink);
    white-space: nowrap;
    position: relative;
}

.t1-nav--desktop .submenu a:hover,
.t1-nav--desktop .submenu a:focus-visible {
    background: var(--nl-accent-soft);
    color: var(--nl-accent);
}

.t1-nav--desktop .submenu .submenu {
    top: 0;
    left: calc(100% + 2px);
    margin: 0;
    transform: translateX(6px);
}

.t1-nav--desktop .submenu .has-submenu:hover > .submenu,
.t1-nav--desktop .submenu .has-submenu:focus-within > .submenu {
    transform: translateX(0);
}

.t1-nav--desktop .has-submenu > .submenu > .has-submenu > a {
    padding-inline-end: 1.75rem;
}

.t1-nav--desktop .has-submenu > .submenu > .has-submenu > a::after {
    content: "";
    position: absolute;
    right: 0.85rem;
    top: 50%;
    width: 0;
    height: 0;
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
    border-left: 5px solid currentColor;
    transform: translateY(-50%);
    opacity: 0.55;
}

.t1-nav .submenu {
    list-style: none;
    margin: 0;
}

.t1-header__burger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 2.5rem;
    height: 2.5rem;
    padding: 0;
    border: 1px solid var(--nl-line);
    border-radius: 999px;
    background: var(--nl-surface);
    cursor: pointer;
    position: relative;
    z-index: 1070;
}

.t1-header__burger span {
    display: block;
    width: 16px;
    height: 2px;
    margin: 0 auto;
    background: var(--nl-ink);
    transition: transform 0.25s var(--nl-ease), opacity 0.2s var(--nl-ease);
}

.t1-header__burger.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.t1-header__burger.active span:nth-child(2) { opacity: 0; }
.t1-header__burger.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.t1-nav--drawer { display: none; }

.t1-nav__label {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--nl-muted);
    margin: 0 0 1rem;
}

@media (max-width: 991px) {
    .t1-nav--desktop { display: none; }
    .t1-header__burger { display: flex; }
    .t1-header__name { max-width: 46vw; }

    /* Don't let desktop hover rules fight the drawer accordion */
    .t1-nav--desktop .has-submenu:hover > .submenu,
    .t1-nav--desktop .has-submenu:focus-within > .submenu {
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
    }

    .t1-nav--drawer {
        display: block;
        position: fixed;
        top: 0;
        right: 0;
        width: min(320px, 88vw);
        height: 100vh;
        background: var(--nl-surface);
        padding: 5.25rem 1.35rem 2rem;
        transform: translate3d(100%, 0, 0);
        transition: transform 0.3s var(--nl-ease);
        overflow-y: auto;
        z-index: 1040;
        box-shadow: -12px 0 40px rgba(15, 23, 42, 0.12);
        border-left: 1px solid var(--nl-line);
    }

    .t1-nav--drawer.active {
        transform: translate3d(0, 0, 0);
    }

    .t1-nav--drawer ul {
        list-style: none;
        margin: 0;
        padding: 0;
        display: flex;
        flex-direction: column;
    }

    .t1-nav--drawer > ul > li > a {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 0.75rem;
        padding: 0.9rem 0;
        font-family: var(--nl-display);
        font-weight: 600;
        font-size: 1.1rem;
        border-bottom: 1px solid var(--nl-line);
    }

    .t1-nav--drawer .has-submenu > a::after {
        content: "";
        width: 0;
        height: 0;
        border-left: 4px solid transparent;
        border-right: 4px solid transparent;
        border-top: 5px solid currentColor;
        opacity: 0.5;
        flex-shrink: 0;
        transition: transform 0.2s var(--nl-ease);
    }

    .t1-nav--drawer .has-submenu.active > a::after {
        transform: rotate(180deg);
    }

    .t1-nav--drawer .submenu {
        position: static;
        display: none;
        border: none;
        box-shadow: none;
        border-radius: 0;
        background: transparent;
        padding: 0.25rem 0 0.75rem 0.75rem;
        min-width: 0;
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: none;
    }

    .t1-nav--drawer .has-submenu.active > .submenu {
        display: block;
    }

    .t1-nav--drawer .submenu .submenu {
        padding-inline-start: 0.75rem;
    }

    .t1-nav--drawer .submenu a {
        display: block;
        padding: 0.5rem 0;
        color: var(--nl-muted);
        border-bottom: 1px dashed var(--nl-line);
        font-size: 0.95rem;
    }
}

.category-bar {
    position: relative;
    z-index: 1;
    border-top: 1px solid var(--nl-line, #e5e7eb);
    background: color-mix(in srgb, var(--nl-surface, #fff) 88%, transparent);
}

.category-bar__inner {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
}

.category-bar__list {
    display: flex;
    flex-wrap: nowrap;
    gap: 0.35rem 1.1rem;
    list-style: none;
    margin: 0;
    padding: 0.5rem 0;
    align-items: center;
}

.category-bar__link {
    display: inline-block;
    white-space: nowrap;
    font-size: 0.875rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    color: var(--nl-muted, #64748b);
    text-decoration: none;
    border-bottom: 2px solid transparent;
    padding-bottom: 0.1rem;
}

.category-bar__link:hover,
.category-bar__link.is-active {
    color: var(--nl-ink, #0f172a);
    border-bottom-color: var(--nl-accent, #2563eb);
}

.t1-footer {
    margin-top: 3.5rem;
}

.t1-footer__cta {
    background: linear-gradient(135deg, #0b1220 0%, #172554 55%, #1e3a8a 100%);
    color: #e8eef7;
    padding: 3.25rem 0;
}

.t1-footer__cta-grid {
    display: grid;
    gap: 2rem;
    align-items: end;
}

@media (min-width: 768px) {
    .t1-footer__cta-grid {
        grid-template-columns: 1.1fr 1fr;
        gap: 3rem;
    }
}

.t1-footer__cta-title {
    font-family: var(--nl-display);
    font-size: clamp(1.7rem, 3.4vw, 2.4rem);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.03em;
    margin: 0 0 0.75rem;
    color: #fff;
    max-width: 14ch;
}

.t1-footer__cta-desc {
    margin: 0;
    color: rgba(232, 238, 247, 0.72);
    max-width: 38ch;
}

.t1-footer__form-row {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

@media (min-width: 480px) {
    .t1-footer__form-row {
        flex-direction: row;
        align-items: stretch;
    }
}

.t1-footer__form .form-control {
    flex: 1;
    min-width: 0;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 999px;
    color: #fff;
    padding: 0.85rem 1.15rem;
}

.t1-footer__form .form-control::placeholder {
    color: rgba(255, 255, 255, 0.42);
}

.t1-footer__form .form-control:focus {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(147, 197, 253, 0.7);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.25);
    color: #fff;
}

.t1-footer__form .btn-theme {
    background: #fff;
    color: #0b1220 !important;
}

.t1-footer__form .btn-theme:hover {
    background: #93c5fd;
    color: #0b1220 !important;
}

.t1-footer__form-msg {
    margin-top: 0.75rem;
    font-size: 0.875rem;
    min-height: 1.25rem;
}

.t1-footer__main {
    background: var(--nl-surface);
    border-top: 1px solid var(--nl-line);
    padding: 3rem 0 2rem;
}

.t1-footer__grid {
    display: grid;
    gap: 2rem;
}

@media (min-width: 768px) {
    .t1-footer__grid {
        grid-template-columns: 1.4fr 1fr 1fr;
        gap: 2.5rem;
    }
}

.t1-footer__brand img {
    height: 2.1rem;
    width: auto;
    margin-bottom: 1rem;
}

.t1-footer__brand h3 {
    font-size: 1.15rem;
    margin: 0 0 0.55rem;
}

.t1-footer__brand p {
    color: var(--nl-muted);
    margin: 0;
}

.t1-footer__heading {
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin: 0 0 1rem;
    color: var(--nl-muted);
}

.t1-footer__links {
    list-style: none;
    margin: 0;
    padding: 0;
}

.t1-footer__links li + li { margin-top: 0.45rem; }

.t1-footer__links a {
    color: var(--nl-ink);
    font-weight: 500;
}

.t1-footer__links a:hover { color: var(--nl-accent); }

.t1-footer__social {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
}

.t1-footer__social a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.4rem;
    height: 2.4rem;
    border-radius: 999px;
    border: 1px solid var(--nl-line);
    color: var(--nl-ink);
    background: var(--nl-bg);
    transition: background 0.2s, border-color 0.2s, color 0.2s;
}

.t1-footer__social a:hover {
    background: var(--nl-accent-soft);
    border-color: var(--nl-accent);
    color: var(--nl-accent);
}

.t1-footer__bar {
    border-top: 1px solid var(--nl-line);
    background: var(--nl-bg);
    padding: 1rem 0;
}

.t1-footer__bar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.t1-footer__bar p {
    margin: 0;
    font-size: 0.85rem;
    color: var(--nl-muted);
}

.t1-footer__theme {
    width: 2.4rem;
    height: 2.4rem;
    border-radius: 999px;
    border: 1px solid var(--nl-line);
    background: var(--nl-surface);
    color: var(--nl-ink);
    cursor: pointer;
}

.t1-footer__theme:hover {
    background: var(--nl-accent-soft);
    color: var(--nl-accent);
}

.floating-newsletter-btn {
    position: fixed;
    right: 1.25rem;
    bottom: 1.25rem;
    z-index: 1020;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.05rem;
    background: var(--nl-accent);
    color: #fff;
    border: none;
    border-radius: 999px;
    box-shadow: var(--nl-shadow);
    cursor: pointer;
    font-family: var(--nl-display);
    font-size: 0.82rem;
    font-weight: 600;
}

.floating-newsletter-btn:hover {
    background: #1d4ed8;
}

@media (max-width: 576px) {
    .floating-btn-text { display: none; }
    .floating-newsletter-btn {
        width: 3rem;
        height: 3rem;
        justify-content: center;
        padding: 0;
    }
}

/* tech01 cinematic home hero — full-bleed stage + story rail */

.t1-hero {
    position: relative;
    margin: 0;
    padding: 0;
}

.t1-stage {
    position: relative;
    display: block;
    min-height: min(78vh, 720px);
    color: #f8fafc;
    overflow: hidden;
    background: #020617;
}

.t1-stage:hover,
.t1-stage:focus-visible {
    color: #f8fafc;
}

.t1-stage__media {
    position: absolute;
    inset: 0;
}

.t1-stage__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 30%;
    transform: scale(1.04);
    animation: t1-ken 18s var(--nl-ease) both;
    will-change: transform;
}

.t1-stage:hover .t1-stage__media img {
    transform: scale(1.08);
    transition: transform 1.1s var(--nl-ease);
}

.t1-stage__shade {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(2, 6, 23, 0.78) 0%, rgba(2, 6, 23, 0.42) 42%, rgba(2, 6, 23, 0.18) 68%, rgba(2, 6, 23, 0.35) 100%),
        linear-gradient(0deg, rgba(2, 6, 23, 0.88) 0%, rgba(2, 6, 23, 0.35) 42%, transparent 72%);
    pointer-events: none;
}

.t1-stage__copy {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    min-height: inherit;
    padding-top: 6rem;
    padding-bottom: clamp(2rem, 5vw, 3.5rem);
    max-width: var(--nl-container);
    animation: t1-rise 0.85s var(--nl-ease) both;
}

.t1-stage__title {
    font-family: var(--nl-display);
    font-size: clamp(2rem, 5.2vw, 3.75rem);
    font-weight: 700;
    line-height: 1.05;
    letter-spacing: -0.04em;
    color: #fff;
    margin: 0 0 1rem;
    max-width: 16ch;
    text-wrap: balance;
    text-shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
}

.t1-stage__excerpt {
    margin: 0 0 1.35rem;
    max-width: 38rem;
    font-size: clamp(1.05rem, 1.6vw, 1.25rem);
    line-height: 1.55;
    color: rgba(248, 250, 252, 0.86);
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    overflow: hidden;
}

.t1-stage__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.85rem 1.35rem;
    font-size: 0.95rem;
    color: rgba(248, 250, 252, 0.72);
}

.t1-stage__cta {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-family: var(--nl-display);
    font-weight: 600;
    font-size: 0.92rem;
    letter-spacing: 0.02em;
    color: #fff;
    border-bottom: 2px solid rgba(255, 255, 255, 0.55);
    padding-bottom: 0.12rem;
    transition: border-color 0.25s var(--nl-ease), transform 0.25s var(--nl-ease);
}

.t1-stage__cta::after {
    content: "→";
    transition: transform 0.25s var(--nl-ease);
}

.t1-stage:hover .t1-stage__cta {
    border-bottom-color: #fff;
}

.t1-stage:hover .t1-stage__cta::after {
    transform: translateX(4px);
}

/* Secondary stories rail under the stage */
.t1-rail {
    position: relative;
    z-index: 2;
    margin-top: -3.25rem;
    padding-bottom: 0.5rem;
}

.t1-rail__inner {
    display: grid;
    gap: 0.85rem;
    grid-template-columns: 1fr;
}

@media (min-width: 768px) {
    .t1-rail__inner {
        grid-template-columns: repeat(3, 1fr);
        gap: 1rem;
    }
}

.t1-rail__item {
    display: grid;
    grid-template-columns: 96px 1fr;
    gap: 0.95rem;
    align-items: center;
    padding: 0.85rem;
    background: color-mix(in srgb, var(--nl-surface) 92%, transparent);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid color-mix(in srgb, var(--nl-line) 80%, transparent);
    border-radius: var(--nl-radius-lg);
    box-shadow: var(--nl-shadow);
    animation: t1-rise 0.7s var(--nl-ease) both;
    transition: transform 0.3s var(--nl-ease), box-shadow 0.3s var(--nl-ease), border-color 0.3s var(--nl-ease);
}

.t1-rail__item:hover {
    transform: translateY(-4px);
    box-shadow: 0 22px 48px rgba(15, 23, 42, 0.14);
    border-color: color-mix(in srgb, var(--nl-accent) 35%, var(--nl-line));
    color: inherit;
}

.t1-rail__media {
    aspect-ratio: 1;
    border-radius: calc(var(--nl-radius-lg) - 4px);
    overflow: hidden;
    background: var(--nl-line);
}

.t1-rail__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.55s var(--nl-ease);
}

.t1-rail__item:hover .t1-rail__media img {
    transform: scale(1.06);
}

.t1-rail__body {
    min-width: 0;
}

.t1-rail__index {
    display: block;
    font-family: var(--nl-display);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    color: var(--nl-accent);
    margin-bottom: 0.25rem;
}

.t1-rail__title {
    font-size: 1.02rem;
    margin: 0 0 0.35rem;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    overflow: hidden;
}

@keyframes t1-ken {
    from { transform: scale(1.04); }
    to { transform: scale(1.1); }
}

@media (max-width: 767px) {
    .t1-stage {
        min-height: min(68vh, 560px);
    }

    .t1-stage__title {
        max-width: none;
    }

    .t1-rail {
        margin-top: -1.5rem;
    }

    .t1-rail__item {
        grid-template-columns: 80px 1fr;
    }
}

@media (prefers-reduced-motion: reduce) {
    .t1-stage__media img,
    .t1-stage:hover .t1-stage__media img,
    .t1-rail__media img {
        animation: none;
        transform: none;
        transition: none;
    }
}

/* tech01 product listing */
.t1-products {
  padding: 2.5rem 0 4rem;
}

.t1-products__header {
  margin-bottom: 2rem;
}

.t1-products__header h1 {
  margin: 0.35rem 0 0;
  font-size: clamp(1.75rem, 3vw, 2.4rem);
  letter-spacing: -0.02em;
}

.t1-products__grid {
  display: grid;
  grid-template-columns: repeat(1, minmax(0, 1fr));
  gap: 1.25rem;
}

@media (min-width: 640px) {
  .t1-products__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 900px) {
  .t1-products__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.35rem;
  }
}

@media (min-width: 1200px) {
  .t1-products__grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 1.25rem;
  }
}

.t1-product-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  text-decoration: none;
  color: inherit;
  background: var(--bs-body-bg, #fff);
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 1rem;
  overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.t1-product-card:hover,
.t1-product-card:focus-visible {
  transform: translateY(-3px);
  border-color: rgba(15, 23, 42, 0.16);
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
  color: inherit;
}

.t1-product-card__media {
  aspect-ratio: 3 / 4;
  background: #f3f4f6;
  overflow: hidden;
}

.t1-product-card__media img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  transition: transform 0.45s ease;
}

.t1-product-card:hover .t1-product-card__media img {
  transform: scale(1.04);
}

.t1-product-card__placeholder {
  width: 100%;
  height: 100%;
  background:
    linear-gradient(135deg, rgba(15, 23, 42, 0.06), rgba(15, 23, 42, 0.02));
}

.t1-product-card__body {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  padding: 1rem 1.1rem 1.2rem;
  flex: 1;
}

.t1-product-card__brand {
  margin: 0;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(15, 23, 42, 0.55);
}

.t1-product-card__title {
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.35;
  letter-spacing: -0.01em;
}

.t1-product-card__excerpt {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.45;
  color: rgba(15, 23, 42, 0.65);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.t1-product-card__price {
  margin: auto 0 0;
  padding-top: 0.55rem;
  font-size: 0.98rem;
  font-weight: 600;
}

.t1-product-card__price-label {
  font-weight: 500;
  color: rgba(15, 23, 42, 0.55);
}

.t1-product-detail {
  padding: 2rem 0 4rem;
}

.t1-product-detail__crumb {
  margin: 0 0 1.5rem;
}

.t1-product-detail__layout {
  display: grid;
  gap: 1.75rem;
  margin-bottom: 2.5rem;
}

@media (min-width: 900px) {
  .t1-product-detail__layout {
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
    gap: 2.5rem;
    align-items: start;
  }
}

.t1-product-detail__media {
  min-width: 0;
}

.t1-product-gallery__main {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 1rem;
  overflow: hidden;
  background: #f3f4f6;
  aspect-ratio: 4 / 3;
  cursor: zoom-in;
}

.t1-product-gallery__main:focus-visible {
  outline: 2px solid rgba(15, 23, 42, 0.45);
  outline-offset: 2px;
}

.t1-product-gallery__main img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  pointer-events: none;
}

.t1-product-gallery__thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 0.75rem;
}

.t1-product-gallery__thumb {
  width: 4.5rem;
  height: 3.375rem;
  padding: 0;
  border: 1px solid rgba(15, 23, 42, 0.12);
  border-radius: 0.65rem;
  overflow: hidden;
  background: #f3f4f6;
  cursor: pointer;
}

.t1-product-gallery__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.t1-product-gallery__thumb.is-active,
.t1-product-gallery__thumb:hover,
.t1-product-gallery__thumb:focus-visible {
  border-color: rgba(15, 23, 42, 0.45);
  outline: none;
}

.t1-product-detail__copy h1 {
  margin: 0.2rem 0 0.55rem;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  letter-spacing: -0.02em;
}

.t1-product-detail__type {
  margin: 0 0 0.85rem;
  font-size: 0.92rem;
  color: rgba(15, 23, 42, 0.55);
}

.t1-product-detail__price {
  margin: 0 0 1rem;
  font-size: 1.15rem;
  font-weight: 600;
}

.t1-product-detail__price span {
  font-weight: 500;
  color: rgba(15, 23, 42, 0.55);
}

.t1-product-detail__rating {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem 0.75rem;
  margin: 0 0 1rem;
  font-size: 0.92rem;
  color: rgba(15, 23, 42, 0.7);
}

.t1-product-detail__meta {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.35rem 1rem;
  margin: 0 0 1.1rem;
  font-size: 0.9rem;
}

.t1-product-detail__meta dt {
  margin: 0;
  color: rgba(15, 23, 42, 0.55);
}

.t1-product-detail__meta dd {
  margin: 0;
}

.t1-product-detail__excerpt {
  margin: 0;
  color: rgba(15, 23, 42, 0.7);
  line-height: 1.55;
}

.t1-product-detail__description {
  margin: 0 0 2.25rem;
  line-height: 1.65;
  color: rgba(15, 23, 42, 0.82);
  max-width: 48rem;
}

.t1-product-tabs {
  margin: 0 0 1.75rem;
  position: sticky;
  top: 0;
  z-index: 5;
  background: color-mix(in srgb, var(--bs-body-bg, #fff) 92%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}

.t1-product-tabs__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem 0.35rem;
}

.t1-product-tabs__link {
  display: inline-flex;
  align-items: center;
  padding: 0.85rem 0.95rem;
  color: rgba(15, 23, 42, 0.58);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  border-bottom: 2px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.t1-product-tabs__link:hover,
.t1-product-tabs__link:focus-visible {
  color: rgba(15, 23, 42, 0.92);
  outline: none;
}

.t1-product-tabs__link.is-active {
  color: rgba(15, 23, 42, 0.95);
  border-bottom-color: var(--bs-primary, #0d6efd);
}

.t1-product-variants,
.t1-product-specs,
.t1-product-offers,
.t1-product-reviews {
  margin: 0 0 2.25rem;
  scroll-margin-top: 4.5rem;
}

.t1-product-variants h2,
.t1-product-specs h2,
.t1-product-offers h2,
.t1-product-reviews h2 {
  margin: 0 0 1rem;
  font-size: 1.35rem;
  letter-spacing: -0.02em;
}

.t1-product-offers__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.75rem;
}

.t1-product-offer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 0.85rem 1rem;
  align-items: center;
  padding: 0.9rem 1rem;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 0.9rem;
  background: rgba(15, 23, 42, 0.015);
}

.t1-product-offer.is-featured {
  border-color: rgba(15, 23, 42, 0.18);
  background: rgba(15, 23, 42, 0.03);
}

.t1-product-offer__seller {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
}

.t1-product-offer__logo,
.t1-product-offer__logo-fallback {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.55rem;
  object-fit: contain;
  background: #fff;
  border: 1px solid rgba(15, 23, 42, 0.08);
  flex-shrink: 0;
}

.t1-product-offer__logo-fallback {
  background:
    linear-gradient(135deg, rgba(15, 23, 42, 0.08), rgba(15, 23, 42, 0.02));
}

.t1-product-offer__name {
  margin: 0;
  font-weight: 600;
  line-height: 1.3;
}

.t1-product-offer__rating {
  margin: 0.15rem 0 0;
  font-size: 0.82rem;
  color: rgba(15, 23, 42, 0.55);
}

.t1-product-offer__price {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.15rem;
  font-size: 1rem;
}

.t1-product-offer__compare {
  font-size: 0.82rem;
  color: rgba(15, 23, 42, 0.45);
  text-decoration: line-through;
}

.t1-product-offer__buy {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 5.5rem;
  padding: 0.55rem 0.9rem;
  border-radius: 0.65rem;
  background: var(--bs-primary, #0d6efd);
  color: #fff;
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
}

.t1-product-offer__buy:hover,
.t1-product-offer__buy:focus-visible {
  filter: brightness(0.95);
  color: #fff;
}

.t1-product-offer__buy.is-disabled {
  opacity: 0.45;
  pointer-events: none;
}

@media (max-width: 640px) {
  .t1-product-offer {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .t1-product-offer__buy {
    grid-column: 1 / -1;
  }
}

.t1-product-variants ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.65rem;
}

.t1-product-variants li {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.85rem;
  padding: 0.85rem 1rem;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 0.85rem;
  background: rgba(15, 23, 42, 0.02);
}

.t1-product-variants li span {
  color: rgba(15, 23, 42, 0.65);
}

.t1-product-specs__body {
  position: relative;
}

.t1-product-specs__body.is-collapsed {
  max-height: 22rem;
  overflow: hidden;
}

.t1-product-specs__body.is-collapsed::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 4.75rem;
  pointer-events: none;
  background: linear-gradient(
    to bottom,
    transparent,
    var(--bs-body-bg, #fff) 72%
  );
}

.t1-product-specs__toggle {
  display: flex;
  justify-content: center;
  margin-top: 0.85rem;
}

.t1-product-specs__toggle-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.65rem 1.15rem;
  border: 1px solid rgba(15, 23, 42, 0.14);
  border-radius: 0.75rem;
  background: #fff;
  color: rgba(15, 23, 42, 0.88);
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.2;
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.t1-product-specs__toggle-btn:hover {
  background: rgba(15, 23, 42, 0.04);
  border-color: rgba(15, 23, 42, 0.28);
  color: rgba(15, 23, 42, 0.95);
}

.t1-product-specs__toggle-btn:focus-visible {
  outline: 2px solid var(--bs-primary, #0d6efd);
  outline-offset: 2px;
}

.t1-product-specs__toggle-btn .fa {
  font-size: 0.72rem;
}

.t1-product-specs__group {
  margin: 0 0 1.35rem;
}

.t1-product-specs__group h3 {
  margin: 0 0 0.55rem;
  font-size: 1rem;
}

.t1-product-specs table {
  width: 100%;
  border-collapse: collapse;
}

.t1-product-specs th,
.t1-product-specs td {
  padding: 0.55rem 0.35rem;
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
  text-align: start;
  vertical-align: top;
  font-size: 0.92rem;
}

.t1-product-specs th {
  width: 38%;
  font-weight: 500;
  color: rgba(15, 23, 42, 0.6);
}

.t1-product-stars {
  display: inline-flex;
  align-items: center;
  gap: 0.12rem;
  color: #d4a017;
}

.t1-product-stars__star {
  display: inline-flex;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  line-height: 1;
}

button.t1-product-stars__star {
  cursor: pointer;
}

button.t1-product-stars__star:hover,
button.t1-product-stars__star:focus-visible {
  color: #b8860b;
  outline: none;
}

.t1-product-stars--sm {
  font-size: 0.82rem;
}

.t1-product-stars--lg {
  font-size: 1.2rem;
}

.t1-product-reviews__header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.75rem 1.25rem;
  margin-bottom: 1.15rem;
}

.t1-product-reviews__header h2 {
  margin: 0;
}

.t1-product-reviews__summary {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.t1-product-reviews__summary p {
  margin: 0;
  font-size: 0.92rem;
  color: rgba(15, 23, 42, 0.65);
}

.t1-product-reviews__list {
  list-style: none;
  margin: 0 0 1.75rem;
  padding: 0;
  display: grid;
  gap: 0.85rem;
}

.t1-product-review {
  padding: 1rem 1.1rem;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 0.9rem;
  background: rgba(15, 23, 42, 0.015);
}

.t1-product-review__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  margin-bottom: 0.45rem;
}

.t1-product-review__name {
  display: block;
  font-size: 0.98rem;
}

.t1-product-review__head time {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.8rem;
  color: rgba(15, 23, 42, 0.5);
}

.t1-product-review__title {
  margin: 0 0 0.35rem;
  font-size: 1rem;
}

.t1-product-review__body {
  margin: 0;
  line-height: 1.55;
  color: rgba(15, 23, 42, 0.8);
  white-space: pre-wrap;
}

.t1-product-reviews__form-wrap {
  margin-top: 1.5rem;
  padding-top: 1.35rem;
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}

.t1-product-reviews__form-wrap h3 {
  margin: 0 0 1rem;
  font-size: 1.1rem;
}

.t1-product-reviews__form {
  display: grid;
  gap: 0.85rem;
  max-width: 40rem;
}

.t1-product-reviews__honeypot {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.t1-product-reviews__rating-field {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem 0.85rem;
}

.t1-product-reviews__label {
  font-size: 0.92rem;
  color: rgba(15, 23, 42, 0.7);
}

.t1-product-reviews__grid {
  display: grid;
  gap: 0.85rem;
  align-items: start;
}

@media (min-width: 640px) {
  .t1-product-reviews__grid {
    grid-template-columns: 1fr 1fr;
  }
}

.t1-product-reviews__form label {
  display: grid;
  gap: 0.35rem;
  align-content: start;
  font-size: 0.9rem;
  color: rgba(15, 23, 42, 0.7);
}

.t1-product-reviews__hint {
  font-size: 0.8rem;
  color: rgba(15, 23, 42, 0.5);
  line-height: 1.35;
}

.t1-product-reviews__form input,
.t1-product-reviews__form textarea {
  width: 100%;
  box-sizing: border-box;
  padding: 0.65rem 0.75rem;
  border: 1px solid rgba(15, 23, 42, 0.14);
  border-radius: 0.65rem;
  background: var(--bs-body-bg, #fff);
  color: inherit;
  font: inherit;
  line-height: 1.4;
}

.t1-product-reviews__form input:focus,
.t1-product-reviews__form textarea:focus {
  outline: none;
  border-color: rgba(15, 23, 42, 0.35);
}

.t1-product-reviews__form button[type="submit"] {
  justify-self: start;
  padding: 0.65rem 1.15rem;
  border: 0;
  border-radius: 0.65rem;
  background: var(--bs-primary, #0d6efd);
  color: #fff;
  font-weight: 600;
  font-size: 0.92rem;
  cursor: pointer;
}

.t1-product-reviews__form button[type="submit"]:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

/* sellers */
.t1-sellers {
  padding: 2.5rem 0 4rem;
}

.t1-sellers__header {
  margin-bottom: 2rem;
}

.t1-sellers__header h1 {
  margin: 0.35rem 0 0;
  font-size: clamp(1.75rem, 3vw, 2.4rem);
  letter-spacing: -0.02em;
}

.t1-sellers__grid {
  display: grid;
  grid-template-columns: repeat(1, minmax(0, 1fr));
  gap: 1.25rem;
}

@media (min-width: 640px) {
  .t1-sellers__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 992px) {
  .t1-sellers__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.t1-seller-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  text-decoration: none;
  color: inherit;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 1rem;
  overflow: hidden;
  background: var(--bs-body-bg, #fff);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.t1-seller-card:hover,
.t1-seller-card:focus-visible {
  transform: translateY(-3px);
  border-color: rgba(15, 23, 42, 0.16);
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
  color: inherit;
}

.t1-seller-card__media {
  aspect-ratio: 16 / 9;
  background: #f3f4f6;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.t1-seller-card__media img {
  max-width: 70%;
  max-height: 4.5rem;
  object-fit: contain;
}

.t1-seller-card__placeholder {
  width: 3rem;
  height: 3rem;
  border-radius: 0.75rem;
  background:
    linear-gradient(135deg, rgba(15, 23, 42, 0.08), rgba(15, 23, 42, 0.02));
}

.t1-seller-card__body {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 1rem 1.1rem 1.2rem;
  flex: 1;
}

.t1-seller-card__title {
  margin: 0;
  font-size: 1.05rem;
}

.t1-seller-card__meta,
.t1-seller-card__rating {
  margin: 0;
  font-size: 0.85rem;
  color: rgba(15, 23, 42, 0.55);
}

.t1-seller-card__excerpt {
  margin: 0.25rem 0 0;
  font-size: 0.9rem;
  color: rgba(15, 23, 42, 0.65);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.t1-seller-detail {
  padding: 2rem 0 4rem;
}

.t1-seller-detail__crumb {
  margin: 0 0 1.5rem;
}

.t1-seller-detail__header {
  display: grid;
  gap: 1.25rem;
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}

@media (min-width: 768px) {
  .t1-seller-detail__header {
    grid-template-columns: 8.5rem minmax(0, 1fr);
    gap: 1.75rem;
    align-items: start;
  }
}

.t1-seller-detail__logo {
  width: 8.5rem;
  height: 8.5rem;
  border-radius: 1rem;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: #f8fafc;
  display: grid;
  place-items: center;
  overflow: hidden;
}

.t1-seller-detail__logo img {
  max-width: 80%;
  max-height: 80%;
  object-fit: contain;
}

.t1-seller-detail__intro h1 {
  margin: 0.2rem 0 0.7rem;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  letter-spacing: -0.02em;
}

.t1-seller-detail__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 0.85rem;
}

.t1-seller-detail__badge {
  display: inline-flex;
  align-items: center;
  padding: 0.28rem 0.65rem;
  border-radius: 0.55rem;
  background: rgba(15, 23, 42, 0.05);
  font-size: 0.82rem;
  color: rgba(15, 23, 42, 0.7);
}

.t1-seller-detail__lead {
  margin: 0 0 0.85rem;
  max-width: 42rem;
  color: rgba(15, 23, 42, 0.72);
  line-height: 1.55;
}

.t1-seller-detail__cta {
  margin: 0;
}

.t1-seller-detail__website {
  display: inline-flex;
  align-items: center;
  padding: 0.55rem 0.95rem;
  border-radius: 0.65rem;
  background: var(--bs-primary, #0d6efd);
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.92rem;
}

.t1-seller-detail__website:hover,
.t1-seller-detail__website:focus-visible {
  color: #fff;
  filter: brightness(0.96);
}

.t1-seller-profile {
  display: grid;
  gap: 1rem;
  margin-bottom: 2.5rem;
}

@media (min-width: 768px) {
  .t1-seller-profile {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1100px) {
  .t1-seller-profile {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .t1-seller-profile__about {
    grid-column: 1 / -1;
  }
}

.t1-seller-profile__card {
  padding: 1.1rem 1.15rem 1.2rem;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 1rem;
  background: rgba(15, 23, 42, 0.015);
}

.t1-seller-profile__card h2 {
  margin: 0 0 0.85rem;
  font-size: 1.05rem;
  letter-spacing: -0.01em;
}

.t1-seller-profile__text {
  margin: 0 0 1rem;
  line-height: 1.6;
  color: rgba(15, 23, 42, 0.8);
  white-space: pre-wrap;
}

.t1-seller-profile__muted {
  margin: 0;
  color: rgba(15, 23, 42, 0.5);
  font-size: 0.92rem;
}

.t1-seller-profile__list,
.t1-seller-profile__meta {
  display: grid;
  gap: 0.55rem 0;
  margin: 0;
}

.t1-seller-profile__row {
  display: grid;
  grid-template-columns: minmax(6.5rem, 34%) minmax(0, 1fr);
  gap: 0.35rem 0.85rem;
  align-items: start;
}

.t1-seller-profile__row dt {
  margin: 0;
  color: rgba(15, 23, 42, 0.55);
  font-size: 0.9rem;
}

.t1-seller-profile__row dd {
  margin: 0;
  word-break: break-word;
}

.t1-seller-profile__hours,
.t1-seller-profile__social {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.45rem;
}

.t1-seller-profile__hours li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  font-size: 0.92rem;
  padding-bottom: 0.35rem;
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
}

.t1-seller-profile__hours li.is-empty strong {
  font-weight: 500;
  color: rgba(15, 23, 42, 0.4);
}

.t1-seller-profile__social a {
  text-decoration: none;
  font-weight: 500;
}

.t1-seller-detail__products {
  margin-top: 0.5rem;
}

.t1-seller-detail__products h2 {
  margin: 0 0 1rem;
  font-size: 1.35rem;
  letter-spacing: -0.02em;
}

body { direction: ltr; text-align: left; }

.newPagination {
    margin-top: 2rem;
}

.newPagination .pagination {
    gap: 0.25rem;
}

.newPagination .page-item .page-link {
    border-radius: 0.5rem;
    min-width: 2.5rem;
    text-align: center;
}

.newPagination .page-item.active .page-link {
    font-weight: 600;
}

.newPagination .page-item.page-ellipsis span {
    display: inline-block;
    padding: 0.375rem 0.5rem;
    color: var(--text-color-light, #6c757d);
}

.newPagination .page-item.disabled .page-link {
    opacity: 0.5;
    pointer-events: none;
}

/* Shared homepage category strip — used by all themes including custom01/CMS */
.category-bar {
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  background: rgba(255, 255, 255, 0.72);
}

[data-bs-theme="dark"] .category-bar {
  border-top-color: rgba(255, 255, 255, 0.12);
  background: rgba(0, 0, 0, 0.28);
}

.category-bar__inner {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}

.category-bar__list {
  display: flex;
  flex-wrap: nowrap;
  gap: 0.35rem 1.2rem;
  list-style: none;
  margin: 0;
  padding: 0.55rem 0;
  min-height: 2.5rem;
  align-items: center;
}

.category-bar__item {
  margin: 0;
  padding: 0;
}

.category-bar__link {
  display: inline-block;
  white-space: nowrap;
  font-size: 0.9rem;
  font-weight: 600;
  color: #5c5c5c;
  text-decoration: none;
  border-bottom: 2px solid transparent;
  padding-bottom: 0.15rem;
}

.category-bar__link:hover,
.category-bar__link.is-active {
  color: #111;
  border-bottom-color: currentColor;
}

/* Shared horizontal post rail — keeps content inside page width + prev/next controls */

.nl-hscroll {
  --nl-hscroll-btn-size: 2.5rem;
  position: relative;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
  overflow: hidden;
}

.nl-hscroll__viewport {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  overscroll-behavior-x: contain;
}

.nl-hscroll__viewport::-webkit-scrollbar {
  display: none;
}

.nl-hscroll__track {
  display: flex;
  flex-wrap: nowrap;
  align-items: stretch;
  gap: 1rem;
  width: max-content;
  max-width: none;
  min-width: 100%;
  box-sizing: border-box;
  padding-block: 0.15rem 0.5rem;
  padding-inline: 0;
}

.nl-hscroll__track > * {
  flex: 0 0 auto;
  min-width: 0;
}

.nl-hscroll__btn {
  position: absolute;
  top: 50%;
  z-index: 3;
  width: var(--nl-hscroll-btn-size);
  height: var(--nl-hscroll-btn-size);
  margin: 0;
  padding: 0;
  border: 1px solid rgba(15, 23, 42, 0.12);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: #0f172a;
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.12);
  transform: translateY(-50%);
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: opacity 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nl-hscroll__btn:hover:not(:disabled) {
  background: #fff;
  transform: translateY(-50%) scale(1.04);
}

.nl-hscroll__btn:disabled {
  opacity: 0;
  pointer-events: none;
}

.nl-hscroll__btn--prev {
  inset-inline-start: 0.35rem;
}

.nl-hscroll__btn--next {
  inset-inline-end: 0.35rem;
}

.nl-hscroll__chevron {
  display: block;
  width: 0.55rem;
  height: 0.55rem;
  border-inline-end: 2px solid currentColor;
  border-block-end: 2px solid currentColor;
}

.nl-hscroll__chevron--prev {
  transform: rotate(135deg);
  margin-inline-start: 0.15rem;
}

.nl-hscroll__chevron--next {
  transform: rotate(-45deg);
  margin-inline-end: 0.15rem;
}

[data-bs-theme="dark"] .nl-hscroll__btn,
:root[data-bs-theme="dark"] .nl-hscroll__btn {
  background: rgba(33, 37, 41, 0.92);
  border-color: rgba(255, 255, 255, 0.12);
  color: #f8f9fa;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
}

@media (max-width: 575.98px) {
  .nl-hscroll {
    --nl-hscroll-btn-size: 2.15rem;
  }

  .nl-hscroll__btn--prev {
    inset-inline-start: 0.15rem;
  }

  .nl-hscroll__btn--next {
    inset-inline-end: 0.15rem;
  }
}

/* Post body image lightbox — shared across all themes */

.article-text img:not(.post-image) {
    cursor: zoom-in;
}

.article-popup-image {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background: rgba(0, 0, 0, 0.92);
    cursor: zoom-out;
    -webkit-tap-highlight-color: transparent;
}

.article-popup-image.is-open {
    display: flex;
}

.article-popup-image-img {
    max-width: min(92vw, 1200px);
    max-height: 90vh;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 4px;
    box-shadow: 0 12px 48px rgba(0, 0, 0, 0.45);
    cursor: default;
    user-select: none;
}

.article-popup-image-close {
    position: absolute;
    top: 0.75rem;
    inset-inline-end: 0.75rem;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.75rem;
    height: 2.75rem;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    font-size: 1.35rem;
    line-height: 1;
    cursor: pointer;
}

.article-popup-image-close:hover,
.article-popup-image-close:focus-visible {
    background: rgba(255, 255, 255, 0.22);
    outline: none;
}

.article-popup-image-prev,
.article-popup-image-next {
    position: absolute;
    top: 50%;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.75rem;
    height: 2.75rem;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    font-size: 1.25rem;
    line-height: 1;
    cursor: pointer;
    transform: translateY(-50%);
}

.article-popup-image-prev {
    inset-inline-start: 0.75rem;
}

.article-popup-image-next {
    inset-inline-end: 0.75rem;
}

.article-popup-image-prev:hover,
.article-popup-image-next:hover,
.article-popup-image-prev:focus-visible,
.article-popup-image-next:focus-visible {
    background: rgba(255, 255, 255, 0.22);
    outline: none;
}

.article-popup-image-counter {
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.45);
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.85rem;
    letter-spacing: 0.02em;
    pointer-events: none;
    user-select: none;
}

@media (max-width: 575px) {
    .article-popup-image {
        padding: 0.75rem;
    }

    .article-popup-image-prev,
    .article-popup-image-next {
        width: 2.4rem;
        height: 2.4rem;
        font-size: 1.1rem;
    }
}

/* Full layout: title, cover, white content box, and body images use full width */
.article-layout-full .article-header,
.article-layout-full .article-header .lead,
.article-layout-full .article-cover,
.article-layout-full .article-content,
.article-layout-full .article-text,
.article-layout-full .t2-article__hero-inner,
.article-layout-full .t2-article__head,
.article-layout-full .t2-article__title,
.article-layout-full .t2-article__lead,
.article-layout-full .t2-article__cover,
.article-layout-full .t2-article__content,
.article-layout-full .t2-article__text,
.article-layout-full .t2-article__main,
.article-layout-full .am-post__intro,
.article-layout-full .am-post__intro h1,
.article-layout-full .am-post__deck,
.article-layout-full .am-post__cover,
.article-layout-full .am-post__body,
.article-layout-full .am-post__text,
.article-layout-full .am-post__main,
.article-layout-full .content-wrapper {
    max-width: 100% !important;
    width: 100%;
}

.article-layout-full .article-header {
    margin-left: 0;
    margin-right: 0;
    text-align: start;
}

.article-layout-full .article-meta {
    justify-content: flex-start;
}

.article-layout-full .article-cover {
    margin-left: 0;
    margin-right: 0;
}

.article-layout-full .article-content {
    margin-left: 0;
    margin-right: 0;
}

.article-layout-full .article-text figure,
.article-layout-full .article-text img:not(.post-image) {
    width: 100% !important;
    max-width: 100% !important;
}

.article-layout-full .article-text img:not(.post-image) {
    height: auto !important;
}

/* Full layout: article column + related sidebar stack so related sits below */
.article-layout-full .row > .col-lg-8,
.article-layout-full .row > .col-lg-4 {
    flex: 0 0 100%;
    max-width: 100%;
    width: 100%;
}

@media (min-width: 992px) {
    .article-layout-full .t2-article__layout,
    .article-layout-full .am-post__layout {
        grid-template-columns: 1fr;
    }

    .article-layout-full .t2-article__aside,
    .article-layout-full .am-post__aside,
    .article-layout-full .article-sidebar {
        position: static;
    }
}

/* Inline + popup related posts (fc_related_post) — shared across themes */

.post-item-related {
  background: var(--bs-body-bg, var(--nl-surface, #fff));
  overflow: hidden;
  padding: 10px;
  width: 100%;
  border-radius: 16px;
}

.post-item-related .post-wrapper-row {
  display: flex;
  gap: 12px;
  align-items: stretch;
}

.post-item-related-title {
  margin-bottom: 5px;
  font-style: italic;
  padding-left: 5px;
  color: var(--text-color-light, var(--nl-muted, #6c757d));
  font-weight: 300;
}

.post-image-wrapper-related {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  flex-basis: 30%;
  flex-grow: 0;
  flex-shrink: 0;
  border-radius: 10px;
  min-width: 110px;
}

.post-image-wrapper-related .post-image-link {
  display: block;
  position: relative;
  width: 100%;
  height: 100%;
}

.post-image-wrapper-related .post-image {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover;
  opacity: 1;
}

/* Related cards are injected inside .article-text; do not inherit body-image rules. */
.article-text .post-item-related .post-image,
.article-text .post-image-wrapper-related .post-image,
.am-post__text .post-item-related .post-image,
.t2-article__text .post-item-related .post-image {
  margin: 0 !important;
  max-width: none !important;
  max-height: none !important;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover;
  border-radius: 0;
  cursor: default;
  display: block;
}

.post-item-related .post-content {
  flex: 1;
  min-width: 0;
  padding: 0 6px;
}

.post-item-related .post-title {
  margin: 0 0 6px;
  font-size: 1.05rem;
  line-height: 1.35;
  font-weight: 700;
}

.post-item-related .post-title a {
  color: inherit;
  text-decoration: none;
}

.post-item-related .post-excerpt a {
  color: var(--text-color, inherit);
  text-decoration: none;
}

@media (max-width: 576px) {
  .post-item-related .post-wrapper-row {
    flex-direction: column;
  }

  .post-image-wrapper-related {
    flex-basis: auto;
    width: 100%;
  }
}

/* Popup variants */
.post-item-related.popup {
  position: fixed;
  z-index: 1050;
  max-width: min(420px, calc(100vw - 24px));
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

.post-item-related.popup.show {
  opacity: 1;
  pointer-events: auto;
}

.post-item-related.popup.center-bottom {
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
}

.post-item-related.popup.center-middle {
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
}

.post-item-related.popup.center-top {
  left: 50%;
  top: 16px;
  transform: translateX(-50%);
}

.post-item-related.popup.left-bottom {
  left: 16px;
  bottom: 16px;
}

.post-item-related.popup.left-middle {
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
}

.post-item-related.popup.left-top {
  left: 16px;
  top: 16px;
}

.post-item-related.popup.right-bottom {
  right: 16px;
  bottom: 16px;
}

.post-item-related.popup.right-middle {
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
}

.post-item-related.popup.right-top {
  right: 16px;
  top: 16px;
}

.post-item-related.popup .fa-times {
  cursor: pointer;
  padding: 4px;
}

/* Bottom related section (full layout) */
.article-related-bottom {
  clear: both;
  width: 100%;
  max-width: 100%;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--nl-line, rgba(0, 0, 0, 0.08));
}

.article-related-bottom__title {
  margin: 0 0 1.15rem;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.3;
}

.article-related-bottom__list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  width: 100%;
}

@media (min-width: 768px) {
  .article-layout-full .article-related-bottom__list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.25rem;
  }
}

@media (min-width: 1200px) {
  .article-layout-full .article-related-bottom__list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.article-layout-full .article-related-bottom .post-item-related {
  height: 100%;
  margin: 0;
}

.article-layout-full .article-related-bottom .post-wrapper-row {
  flex-direction: column;
}

.article-layout-full .article-related-bottom .post-image-wrapper-related {
  flex-basis: auto;
  width: 100%;
  min-width: 0;
}

.article-layout-full .article-related-bottom .post-image-wrapper-related .post-image {
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
}

.author-profile {
  padding: 2rem 0 4rem;
}

.author-profile__hero {
  display: flex;
  gap: 1.5rem;
  align-items: flex-start;
  padding: 1.5rem 1.75rem;
  margin-bottom: 2.5rem;
  background: var(--nl-surface, #fff);
  border: 1px solid var(--nl-line, #e6e2d8);
  border-radius: var(--nl-radius-lg, 12px);
}

.author-profile__photo {
  width: 96px;
  height: 96px;
  object-fit: cover;
  border-radius: 50%;
  flex-shrink: 0;
  background: var(--nl-accent-soft, #f3f0e8);
}

.author-profile__photo--fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  font-weight: 600;
  color: var(--nl-ink, #121212);
}

.author-profile__info {
  min-width: 0;
  flex: 1;
}

.author-profile__name {
  margin: 0 0 0.5rem;
  font-size: clamp(1.5rem, 3vw, 2rem);
  line-height: 1.2;
}

.author-profile__bio {
  margin: 0 0 1.25rem;
  color: var(--nl-muted, #5f5a52);
  line-height: 1.6;
}

.author-profile__stats {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem 2rem;
  margin: 0;
}

.author-profile__stats dt {
  margin: 0 0 0.2rem;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--nl-muted, #5f5a52);
}

.author-profile__stats dd {
  margin: 0;
  font-weight: 600;
}

.author-profile__posts-title {
  margin: 0 0 1.25rem;
  font-size: 1.25rem;
}

@media (max-width: 575.98px) {
  .author-profile__hero {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .author-profile__stats {
    justify-content: center;
  }
}

.post-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}

.post-date-meta {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.post-author {
  font-weight: 600;
}

.post-comments {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  white-space: nowrap;
}

.post-comments i {
  font-size: 0.85em;
}

.post-review-rating {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem 0.55rem;
  margin: 0.65rem 0 0;
  padding: 0.45rem 0.75rem;
  border-radius: 0.5rem;
  background: color-mix(in srgb, var(--theme-color, #0d6efd) 10%, transparent);
  border: 1px solid color-mix(in srgb, var(--theme-color, #0d6efd) 22%, transparent);
  color: inherit;
  font-size: 0.95rem;
  line-height: 1.3;
}

.post-review-rating__label {
  font-weight: 600;
  font-size: 0.82rem;
  opacity: 0.85;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.post-review-rating__stars {
  display: inline-flex;
  align-items: center;
  gap: 0.12rem;
  color: #e6a817;
}

.post-review-rating__stars i {
  font-size: 0.95em;
}

.post-review-rating__score {
  font-variant-numeric: tabular-nums;
  font-size: 1.05em;
}

.post-review-rating__of {
  opacity: 0.7;
  font-size: 0.9em;
}

.post-review-rating__item {
  width: 100%;
  font-size: 0.88em;
  opacity: 0.85;
}

.post-review-rating--light {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.28);
  color: #fff;
}

.post-review-rating--light .post-review-rating__stars {
  color: #ffd666;
}

.post-review-rating--light .post-review-rating__of,
.post-review-rating--light .post-review-rating__item,
.post-review-rating--light .post-review-rating__label {
  opacity: 0.9;
}

/* Admin tools bar — only rendered when Yii backend identity cookie is valid */

.admin-frontend-bar {
  position: sticky;
  top: 0;
  z-index: 1080;
  background: #1c1f24;
  color: #f3f4f6;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.8125rem;
  line-height: 1.2;
}

.admin-frontend-bar__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 1rem;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0.45rem 1rem;
}

.admin-frontend-bar__brand {
  font-weight: 600;
  letter-spacing: 0.02em;
  opacity: 0.85;
  margin-inline-end: 0.25rem;
}

.admin-frontend-bar__tools {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 1rem;
}

.admin-frontend-bar__link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: #e8eaed;
  text-decoration: none;
  padding: 0.2rem 0.35rem;
  border-radius: 0.25rem;
}

.admin-frontend-bar__link:hover,
.admin-frontend-bar__link:focus-visible {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
  text-decoration: none;
}

.admin-frontend-bar__link i {
  font-size: 0.85em;
  opacity: 0.9;
}

.admin-frontend-bar__stat {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: #c5c9d0;
  padding: 0.2rem 0.35rem;
  white-space: nowrap;
}

.admin-frontend-bar__stat i {
  font-size: 0.85em;
  opacity: 0.85;
}

[dir="rtl"] .admin-frontend-bar__brand {
  margin-inline-end: 0.25rem;
}