/* Blog article detail. Tokens come from styles.css. */

.read-progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    z-index: 1001;
    width: 0;
    background: linear-gradient(90deg, var(--teal-ink), var(--teal));
    transition: width 0.1s linear;
}

.post-wrap {
    width: min(1180px, calc(100% - 48px));
    margin-inline: auto;
}

.reveal {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}
.reveal.revealed { opacity: 1; transform: none; }

.post-sheet { padding: 32px 0 72px; }
.post-main { min-width: 0; }
.post-head { padding-bottom: 8px; }
.post-head h1 {
    max-width: 18em;
    margin: 0 0 16px;
    font-size: clamp(1.7rem, 3.4vw, 2.5rem);
    font-weight: 650;
    letter-spacing: -0.04em;
    line-height: 1.18;
    color: var(--ink-strong);
    text-wrap: balance;
}
.post-shot {
    display: block;
    margin: 28px 0 8px;
    height: 240px;
    border-radius: 24px;
    overflow: hidden;
    background: #12202a;
    box-shadow: 0 16px 40px rgba(47, 56, 72, 0.1);
}
.post-shot img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.post-breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 24px;
    font-size: 13px;
    color: var(--muted);
}
.post-breadcrumb a {
    color: var(--muted);
    text-decoration: none;
}
.post-breadcrumb a:hover { color: var(--ink); }
.post-breadcrumb .bc-current { color: var(--ink); font-weight: 550; }

.post-meta-top {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.cat-chip {
    display: inline-flex;
    align-items: center;
    min-height: 22px;
    padding: 0 10px;
    border-radius: var(--pill);
    background: var(--orange-soft);
    color: var(--teal-ink);
    font-size: 11px;
    font-weight: 650;
    letter-spacing: 0.04em;
}

.post-date-inline {
    font-size: 13px;
    color: var(--muted);
}

.post-lead {
    max-width: 720px;
    margin: 0 0 24px;
    color: var(--muted);
    font-size: 1.05rem;
    line-height: 1.75;
}

.post-meta-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px;
    font-size: 13px;
    color: var(--muted);
}
.post-meta-bar .meta-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.post-meta-bar svg { flex-shrink: 0; opacity: 0.7; }

.tag-pill {
    display: inline-flex;
    padding: 3px 10px;
    border-radius: var(--pill);
    background: var(--soft);
    border: 1px solid var(--line);
    color: var(--muted);
    font-size: 11px;
}

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

@media (min-width: 1080px) {
    .post-layout {
        grid-template-columns: minmax(0, 1fr) 280px;
        gap: 48px;
    }
}

.article-content {
    min-width: 0;
    color: #3c4048;
    font-size: 1rem;
    line-height: 1.85;
    overflow-wrap: break-word;
}

.article-content > h2:first-child { margin-top: 20px; }
.article-content h2 {
    margin: 40px 0 14px;
    padding-left: 12px;
    border-left: 3px solid var(--orange);
    color: var(--ink);
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1.35;
}

.article-content h3 {
    margin: 28px 0 10px;
    color: var(--ink);
    font-size: 1.08rem;
    font-weight: 700;
}

.article-content p { margin: 0 0 16px; }
.article-content strong { color: var(--ink); font-weight: 650; }
.article-content a {
    color: var(--teal-ink);
    text-underline-offset: 3px;
}
.article-content a:hover { color: var(--ink); }
.article-content .btn-cta-primary,
.article-content .btn-cta-secondary,
.article-content .btn-cta,
.article-content .fc-btn {
    text-decoration: none !important;
}
.article-content .btn-cta-secondary {
    color: var(--teal-deep) !important;
}
.article-content .btn-cta-secondary:hover {
    color: var(--ink) !important;
}

.article-content code {
    padding: 1px 6px;
    border-radius: 6px;
    background: var(--soft);
    border: 1px solid var(--line);
    font-family: "SF Mono", "Fira Code", Consolas, monospace;
    font-size: 0.9em;
}

.article-content pre {
    margin: 20px 0;
    padding: 18px 20px;
    overflow-x: auto;
    border-radius: 16px;
    background: #1b1d22;
}
.article-content pre code {
    padding: 0;
    border: 0;
    background: none;
    color: #ece8e1;
    font-size: 0.86rem;
    line-height: 1.7;
}

.article-content ul,
.article-content ol {
    margin: 12px 0 20px;
    padding-left: 1.4em;
}
.article-content li { margin-bottom: 6px; }

.callout {
    margin: 24px 0;
    padding: 16px 18px;
    border-radius: 0 16px 16px 0;
    border-left: 3px solid var(--orange);
    background: var(--orange-soft);
}
.callout.tip {
    border-left-color: var(--green);
    background: var(--green-soft);
}
.callout.warning {
    border-left-color: var(--red);
    background: var(--red-soft);
}
.callout-title {
    margin-bottom: 6px;
    color: var(--teal-ink);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}
.callout.tip .callout-title { color: var(--green); }
.callout.warning .callout-title { color: var(--red); }
.callout p { margin: 0; font-size: 0.94rem; }

.metric-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
    margin: 24px 0;
}
.metric-card {
    padding: 18px 14px;
    text-align: center;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 18px;
    box-shadow: var(--shadow-soft);
}
.metric-val,
.metric-card .m-value {
    display: block;
    color: var(--ink);
    font-size: 1.55rem;
    font-weight: 700;
    letter-spacing: -0.03em;
}
.metric-label,
.metric-card .m-label {
    display: block;
    margin-top: 6px;
    color: var(--muted);
    font-size: 12px;
}

.step-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 20px 0;
    padding: 0;
}
.step-item {
    display: flex;
    gap: 14px;
    padding: 16px 18px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 18px;
}
.step-num {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 10px;
    background: var(--orange);
    color: #fff;
    font-size: 12px;
    font-weight: 700;
}
.step-body { min-width: 0; }
.step-body strong {
    display: block;
    margin-bottom: 4px;
    color: var(--ink);
}
.step-body p { margin: 0; color: var(--muted); font-size: 0.92rem; }

.data-table-wrap {
    margin: 24px 0;
    overflow-x: auto;
    border: 1px solid var(--line);
    border-radius: 18px;
}
.data-table {
    width: 100%;
    min-width: 520px;
    border-collapse: collapse;
    font-size: 0.9rem;
}
.data-table thead tr { background: var(--ink); }
.data-table thead th {
    padding: 12px 16px;
    text-align: left;
    color: rgba(255, 255, 255, 0.72);
    font-size: 12px;
    font-weight: 650;
    letter-spacing: 0.03em;
    white-space: nowrap;
}
.data-table tbody tr { border-bottom: 1px solid var(--line); }
.data-table tbody tr:last-child { border-bottom: 0; }
.data-table tbody tr:nth-child(even) { background: var(--soft); }
.data-table tbody td {
    padding: 12px 16px;
    color: #444;
    vertical-align: top;
    line-height: 1.55;
}
.data-table .highlight-val {
    color: var(--ink);
    font-weight: 700;
}

.post-aside {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

@media (min-width: 1080px) {
    .post-aside { position: sticky; top: 88px; }
}

.panel-card {
    padding: 20px 18px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 18px;
    box-shadow: var(--shadow-soft);
}

.toc-title {
    margin-bottom: 12px;
    color: var(--teal-deep);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.toc-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin: 0;
    padding: 0;
}

.toc-link {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 8px 10px;
    border-radius: 10px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.45;
    text-decoration: none;
}
.toc-link:hover { background: var(--soft); color: var(--ink); }
.toc-link.active {
    background: var(--orange-soft);
    color: var(--ink);
    font-weight: 650;
}
.toc-num {
    flex-shrink: 0;
    min-width: 20px;
    color: var(--teal-deep);
    font-size: 11px;
    font-weight: 700;
}

.sidebar-cta {
    overflow: hidden;
    background: var(--ink);
    border-radius: 18px;
}
.sidebar-cta-inner { padding: 22px 20px; }
.sidebar-cta-badge {
    display: inline-flex;
    margin-bottom: 10px;
    color: #7ee8e8;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}
.sidebar-cta h3 {
    margin: 0 0 10px;
    color: #fff;
    font-size: 1.05rem;
    font-weight: 650;
    line-height: 1.4;
}
.sidebar-cta p {
    margin: 0 0 14px;
    color: rgba(255, 255, 255, 0.55);
    font-size: 13px;
    line-height: 1.65;
}
.sidebar-cta .feature-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 0 0 16px;
    padding: 0;
}
.sidebar-cta .feature-list li {
    display: flex;
    align-items: center;
    gap: 8px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 13px;
}
.feature-check {
    position: relative;
    flex-shrink: 0;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: rgba(70, 191, 191, 0.35);
}
.feature-check::after {
    content: "";
    position: absolute;
    top: 2px;
    left: 4px;
    width: 4px;
    height: 7px;
    border: solid #7ee8e8;
    border-width: 0 1.5px 1.5px 0;
    transform: rotate(45deg);
}
.price-row {
    display: flex;
    align-items: baseline;
    gap: 6px;
    margin-bottom: 14px;
}
.price-val {
    color: #fff;
    font-size: 1.7rem;
    font-weight: 700;
    letter-spacing: -0.03em;
}
.price-unit {
    color: rgba(255, 255, 255, 0.4);
    font-size: 12px;
}
.btn-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px 16px;
    border-radius: 999px;
    background: var(--orange);
    color: #fff;
    font-size: 14px;
    font-weight: 650;
    text-decoration: none;
}
.btn-cta:hover { background: var(--orange-hover); color: #fff; }

.article-cta-section {
    position: relative;
    margin-top: 48px;
    overflow: visible;
    background: none;
    border-radius: 0;
    border-top: 1px solid var(--line);
}
.article-cta-inner {
    position: relative;
    z-index: 1;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 32px;
    padding: 28px 0 8px;
}
.article-cta-inner > div:first-child { flex: 1; min-width: 240px; }

.article-cta-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
    color: var(--teal-deep);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}
.article-cta-eyebrow .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--orange);
    animation: pulse-dot 2s ease-in-out infinite;
}
@keyframes pulse-dot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.55; transform: scale(1.25); }
}

.article-cta-inner h2 {
    margin: 0 0 12px;
    padding: 0;
    border: 0;
    color: var(--ink-strong);
    font-size: clamp(1.3rem, 2.2vw, 1.7rem);
    line-height: 1.3;
}
.article-cta-inner > div:first-child > p {
    margin: 0 0 20px;
    color: var(--muted);
    font-size: 0.94rem;
    line-height: 1.75;
}
.cta-price-block {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 20px;
}
.cta-price-val {
    color: var(--price);
    font-size: 2rem;
    font-weight: 700;
    letter-spacing: -0.03em;
}
.cta-price-unit {
    color: var(--muted);
    font-size: 14px;
}
.cta-btn-group { display: flex; flex-wrap: wrap; gap: 10px; }

.btn-cta-primary {
    display: inline-flex;
    align-items: center;
    padding: 12px 22px;
    border-radius: 999px;
    background: var(--orange);
    color: #fff !important;
    font-size: 15px;
    font-weight: 650;
    text-decoration: none !important;
}
.btn-cta-primary:hover { background: var(--orange-hover); color: #fff !important; }

.btn-cta-secondary {
    display: inline-flex;
    align-items: center;
    padding: 12px 22px;
    border-radius: 999px;
    border: 1.5px solid var(--teal);
    background: var(--ice);
    color: var(--teal-deep);
    font-size: 15px;
    font-weight: 650;
    text-decoration: none;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}
.btn-cta-secondary:hover {
    background: #d5f1f1;
    border-color: var(--teal-ink);
    color: var(--ink-strong);
}

.cta-spec-card {
    min-width: 220px;
    padding: 20px 18px;
    border-radius: 16px;
    background: none;
    border: 0;
}
.cta-spec-card .spec-row {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 8px 0;
    border-bottom: 1px solid var(--line);
    font-size: 13px;
}
.cta-spec-card .spec-row:last-child { border-bottom: 0; }
.cta-spec-card .spec-label { color: var(--muted); }
.cta-spec-card .spec-val { color: var(--ink-strong); font-weight: 650; }
.cta-spec-card .spec-val.highlight { color: var(--price); }

.floating-cta {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 999;
    width: 260px;
    overflow: hidden;
    background: var(--ink);
    border-radius: 18px;
    box-shadow: var(--shadow);
    opacity: 0;
    transform: translateY(12px);
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease;
}
.floating-cta.visible {
    opacity: 1;
    transform: none;
    pointer-events: auto;
}
.floating-cta-close {
    position: absolute;
    top: 10px;
    right: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border: 0;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.55);
    font-size: 14px;
    cursor: pointer;
}
.floating-cta-inner { padding: 20px 18px; }
.floating-cta-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 10px;
    color: #7ee8e8;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}
.pulse-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--orange);
    animation: pulse-dot 2s ease-in-out infinite;
}
.floating-cta h4 {
    margin: 0 0 10px;
    color: #fff;
    font-size: 0.95rem;
    font-weight: 650;
    line-height: 1.4;
}
.fc-price {
    display: flex;
    align-items: baseline;
    gap: 5px;
    margin-bottom: 12px;
}
.fc-price-val {
    color: #fff;
    font-size: 1.35rem;
    font-weight: 700;
}
.fc-price-unit {
    color: rgba(255, 255, 255, 0.4);
    font-size: 11px;
}
.fc-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 10px;
    padding: 10px 14px;
    border-radius: 999px;
    background: var(--orange);
    color: #fff !important;
    font-size: 13px;
    font-weight: 650;
    text-decoration: none !important;
}
.fc-btn:hover { background: var(--orange-hover); color: #fff !important; }
.fc-features { display: flex; flex-wrap: wrap; gap: 5px; }
.fc-feature-tag {
    padding: 3px 8px;
    border-radius: var(--pill);
    background: rgba(255, 255, 255, 0.07);
    color: rgba(255, 255, 255, 0.5);
    font-size: 10px;
    font-weight: 650;
}

.related-section {
    padding: 56px 0 80px;
    background: var(--cream);
    border-top: 1px solid var(--line);
}
.section-head {
    max-width: 560px;
    margin: 0 auto 32px;
    text-align: center;
}
.section-head .eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    color: var(--teal-deep);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}
.section-head .eyebrow .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--orange);
}
.section-head h2 {
    margin: 0 0 8px;
    color: var(--ink);
    font-size: 1.55rem;
    letter-spacing: -0.03em;
}
.section-head p {
    margin: 0;
    color: var(--muted);
    font-size: 0.95rem;
}

.related-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}
@media (min-width: 640px) {
    .related-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 960px) {
    .related-grid { grid-template-columns: repeat(3, 1fr); }
}

.clean-card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 18px;
    box-shadow: var(--shadow-soft);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.clean-card:hover { box-shadow: var(--shadow-hover); }

.related-card {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
}
.related-card-body {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 20px;
}
.related-card-body .cat-chip {
    align-self: flex-start;
    margin-bottom: 10px;
}
.related-card h3 {
    margin: 0 0 8px;
    color: var(--ink);
    font-size: 1rem;
    font-weight: 650;
    line-height: 1.4;
}
.related-card p {
    flex: 1;
    margin: 0;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.65;
}

@media (max-width: 860px) {
    .post-sheet { padding-top: 20px; }
    .post-shot { height: 180px; }
}
@media (max-width: 767px) {
    .post-wrap { width: min(1100px, calc(100% - 32px)); }
    .article-cta-inner { padding: 28px 22px; }
    .cta-spec-card { width: 100%; min-width: 0; }
    .floating-cta {
        right: 16px;
        bottom: 16px;
        width: calc(100vw - 32px);
    }
}

@media (prefers-reduced-motion: reduce) {
    .reveal { opacity: 1; transform: none; transition: none; }
    .pulse-dot, .article-cta-eyebrow .dot { animation: none; }
}
