/* ==========================================================================
   Blog — Sam's Dock (SEO content engine, §25)
   Dark theme, cyan/magenta/yellow neon accents, Oswald headings + Lato body.
   Featured images are real photos with the headline styled OVER a dark gradient
   (how the site already renders heroes) — no baked-in text.
   ========================================================================== */

.blog-page { background: var(--bg-dark); color: var(--text-light); }

/* ---- Listing hero ------------------------------------------------------- */
.blog-hero {
    position: relative;
    padding: 5.5rem 1rem 4rem;
    text-align: center;
    background:
        linear-gradient(rgba(15,15,15,.72), rgba(15,15,15,.92)),
        url('/assets/images/fun-on-the-water.png') center/cover no-repeat;
    border-bottom: 1px solid var(--border-color);
}
.blog-hero h1 {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: clamp(2rem, 5vw, 3.2rem);
    letter-spacing: 1px;
    margin: 0 0 .75rem;
    text-transform: uppercase;
}
.blog-hero h1 .accent { color: var(--cta-cyan); }
.blog-hero p {
    font-family: var(--font-body);
    max-width: 640px;
    margin: 0 auto;
    color: #cfcfcf;
    font-size: 1.1rem;
    line-height: 1.6;
}

/* ---- Listing grid ------------------------------------------------------- */
.blog-list-wrap { max-width: 1160px; margin: 0 auto; padding: 3.5rem 1.25rem 4.5rem; }
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
}
.blog-card {
    display: flex;
    flex-direction: column;
    background: rgba(24,24,32,.96);
    border: 1px solid var(--border-color);
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 2px 24px rgba(0,0,0,.25);
    transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.blog-card:hover {
    transform: translateY(-4px);
    border-color: rgba(0,255,255,.45);
    box-shadow: 0 8px 32px rgba(0,0,0,.4);
}
.blog-card-media { position: relative; aspect-ratio: 16 / 9; overflow: hidden; }
.blog-card-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.blog-card-media::after {
    content: '';
    position: absolute; inset: 0;
    background: linear-gradient(180deg, rgba(15,15,15,0) 45%, rgba(15,15,15,.75) 100%);
}
.blog-card-kw {
    position: absolute; left: 12px; bottom: 12px; z-index: 2;
    font-family: var(--font-heading);
    font-size: .72rem; letter-spacing: 1px; text-transform: uppercase;
    color: var(--bg-dark); background: var(--cta-yellow);
    padding: 3px 10px; border-radius: 4px; font-weight: 700;
}
.blog-card-body { padding: 1.35rem 1.4rem 1.6rem; display: flex; flex-direction: column; flex: 1; }
.blog-card-body h2 {
    font-family: var(--font-heading);
    font-size: 1.3rem; line-height: 1.25; margin: 0 0 .6rem;
}
.blog-card-body h2 a { color: var(--text-light); text-decoration: none; }
.blog-card-body h2 a:hover { color: var(--cta-cyan); }
.blog-card-excerpt { color: #b9b9c2; font-size: .96rem; line-height: 1.55; margin: 0 0 1.1rem; flex: 1; }
.blog-card-foot { display: flex; align-items: center; justify-content: space-between; }
.blog-card-date { color: #8b8b96; font-size: .82rem; }
.blog-card-more { color: var(--cta-magenta); font-weight: 700; font-size: .9rem; text-decoration: none; }
.blog-card-more:hover { text-decoration: underline; }

.blog-empty { text-align: center; padding: 4rem 1rem; color: #b9b9c2; }

/* ---- Single post -------------------------------------------------------- */
.blog-post-hero {
    position: relative;
    min-height: 340px;
    display: flex; align-items: flex-end;
    background-size: cover; background-position: center;
    border-bottom: 1px solid var(--border-color);
}
.blog-post-hero::before {
    content: '';
    position: absolute; inset: 0;
    background: linear-gradient(180deg, rgba(15,15,15,.35) 0%, rgba(15,15,15,.55) 45%, rgba(15,15,15,.94) 100%);
}
.blog-post-hero-inner {
    position: relative; z-index: 2;
    /* Match the .blog-layout width/padding below so the title, breadcrumb and meta
       line up with the article's left edge instead of floating in a narrow box. */
    max-width: 1160px; margin: 0 auto; width: 100%;
    padding: 2.75rem 1.25rem 2.5rem;
}
/* Headline flows to the wider hero (aligned left with the article below). A high
   cap only prevents an absurdly long single line on ultra-wide monitors. */
.blog-post-hero h1 { max-width: 30ch; }
@media (min-width: 1100px) { .blog-post-hero h1 { font-size: 3.1rem; } }
.blog-post-hero .blog-crumbs { font-size: .85rem; color: #c9c9d2; margin: 0 0 .9rem; }
.blog-post-hero .blog-crumbs a { color: var(--cta-cyan); text-decoration: none; }
.blog-post-hero .blog-crumbs a:hover { text-decoration: underline; }
.blog-post-hero h1 {
    font-family: var(--font-heading); font-weight: 700;
    font-size: clamp(1.8rem, 4.5vw, 2.9rem); line-height: 1.14;
    text-transform: uppercase; margin: 0;
    text-shadow: 0 2px 18px rgba(0,0,0,.6);
}
.blog-post-meta { margin: .9rem 0 0; color: #c2c2cc; font-size: .9rem; }
.blog-post-meta .dot { color: var(--cta-magenta); margin: 0 .5rem; }

/* Article body */
.blog-article { max-width: 780px; margin: 0 auto; padding: 3rem 1.25rem 1rem; }
.blog-article .lede { font-size: 1.2rem; line-height: 1.7; color: #e8e8ee; font-weight: 400; }
.blog-article p { font-family: var(--font-body); font-size: 1.06rem; line-height: 1.8; color: #d9d9e0; margin: 0 0 1.3rem; }
.blog-article h2 {
    font-family: var(--font-heading); font-weight: 700;
    font-size: 1.7rem; margin: 2.6rem 0 1rem; color: var(--text-light);
    padding-bottom: .4rem; border-bottom: 2px solid rgba(0,255,255,.25);
}
.blog-article h3 { font-family: var(--font-heading); font-size: 1.3rem; margin: 1.8rem 0 .8rem; color: var(--cta-cyan); }
/* Anchor jumps from the "On This Page" TOC must clear the fixed header, or the
   heading scrolls up underneath it. Offset = header height + a little breathing room. */
.blog-article h2, .blog-article h3 { scroll-margin-top: calc(var(--header-height, 90px) + 1.5rem); }
.blog-article ul, .blog-article ol { margin: 0 0 1.4rem; padding-left: 1.4rem; }
.blog-article li { font-family: var(--font-body); font-size: 1.05rem; line-height: 1.7; color: #d9d9e0; margin-bottom: .55rem; }
.blog-article a { color: var(--cta-cyan); }
.blog-article strong { color: #fff; }
.blog-article figure { margin: 1.8rem 0; }
.blog-article figure img { width: 100%; border-radius: 12px; display: block; box-shadow: 0 2px 18px rgba(0,0,0,.35); }
.blog-article figcaption { font-size: .85rem; color: #9a9aa6; text-align: center; margin-top: .5rem; }

/* Fleet / comparison tables inside a post */
.blog-article table { width: 100%; border-collapse: collapse; margin: 1.5rem 0; font-family: var(--font-body); }
.blog-article table th, .blog-article table td {
    padding: .7rem .9rem; text-align: left; border-bottom: 1px solid var(--border-color); font-size: .98rem;
}
.blog-article table th {
    font-family: var(--font-heading); text-transform: uppercase; letter-spacing: .5px;
    color: var(--cta-yellow); font-size: .82rem; background: rgba(255,255,255,.03);
}
.blog-article table td { color: #d9d9e0; }
.blog-table-wrap { overflow-x: auto; }

/* FAQ (rendered from faq_json — same source as the schema) */
.blog-faq { max-width: 780px; margin: 2.5rem auto 0; padding: 0 1.25rem; }
.blog-faq h2 {
    font-family: var(--font-heading); font-weight: 700; font-size: 1.7rem;
    margin: 0 0 1.2rem; padding-bottom: .4rem; border-bottom: 2px solid rgba(255,0,255,.3);
}
.blog-faq-item { border: 1px solid var(--border-color); border-radius: 10px; margin-bottom: .8rem; background: rgba(24,24,32,.9); overflow: hidden; }
.blog-faq-item summary {
    cursor: pointer; list-style: none;
    padding: 1rem 1.2rem; font-family: var(--font-heading); font-size: 1.08rem;
    color: var(--text-light); position: relative; padding-right: 2.5rem;
}
.blog-faq-item summary::-webkit-details-marker { display: none; }
.blog-faq-item summary::after {
    content: '+'; position: absolute; right: 1.1rem; top: 50%; transform: translateY(-50%);
    color: var(--cta-cyan); font-size: 1.4rem; line-height: 1;
}
.blog-faq-item[open] summary::after { content: '\2212'; }
.blog-faq-item[open] summary { color: var(--cta-cyan); }
.blog-faq-answer { padding: 0 1.2rem 1.1rem; }
.blog-faq-answer p { margin: 0; color: #cfcfd6; line-height: 1.7; font-family: var(--font-body); }

/* Post CTA + back link */
.blog-post-cta {
    max-width: 780px; margin: 2.8rem auto 0; padding: 1.75rem 1.5rem;
    background: linear-gradient(135deg, rgba(200,0,161,.18), rgba(0,255,255,.10));
    border: 1px solid rgba(0,255,255,.35); border-radius: 14px; text-align: center;
}
.blog-post-cta h3 { font-family: var(--font-heading); font-size: 1.4rem; margin: 0 0 .6rem; }
.blog-post-cta p { color: #d9d9e0; margin: 0 0 1.2rem; }
.blog-back { display: block; max-width: 780px; margin: 2rem auto 0; padding: 0 1.25rem; }
.blog-back a { color: var(--cta-cyan); text-decoration: none; font-weight: 700; }
.blog-back a:hover { text-decoration: underline; }

/* ---- Post two-column layout + sidebar (§25) ----------------------------- */
.blog-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 2.5rem;
    max-width: 1160px;
    margin: 0 auto;
    padding: 0 1.25rem 1rem;
}
.blog-main { min-width: 0; }

/* Inside the grid the main column owns the width, so drop the article's own
   centering/max-width (it keeps those when used standalone). */
.blog-main .blog-article { max-width: none; margin: 0; padding: 2.5rem 0 1rem; }
.blog-main .blog-faq { max-width: none; margin: 2.5rem 0 0; padding: 0; }
.blog-main .blog-post-cta { max-width: none; margin: 2.8rem 0 0; }
.blog-main .blog-back { max-width: none; margin: 2rem 0 0; padding: 0; }

.blog-sidebar {
    align-self: start;
    position: sticky;
    top: calc(var(--header-height, 90px) + 1rem);
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    padding-top: 2.5rem;
}
.sb-card {
    background: rgba(24, 24, 32, .96);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.2rem 1.25rem;
}
.sb-card h3, .sb-card h4 { font-family: var(--font-heading); margin: 0 0 .85rem; }
.sb-card h4 {
    font-size: 1.02rem; text-transform: uppercase; letter-spacing: .5px;
    color: var(--cta-cyan); padding-bottom: .5rem;
    border-bottom: 1px solid rgba(255, 255, 255, .1);
}

/* Book CTA */
.sb-cta {
    background: linear-gradient(135deg, rgba(200, 0, 161, .22), rgba(0, 255, 255, .10));
    border-color: rgba(0, 255, 255, .35);
}
.sb-cta h3 { font-size: 1.3rem; color: #fff; }
.sb-cta p { color: #d9d9e0; font-size: .92rem; line-height: 1.5; margin: 0 0 1rem; }
.btn-block-sb { display: block; width: 100%; text-align: center; }
.sb-cta-alt { display: block; text-align: center; margin-top: .7rem; color: var(--cta-cyan); font-size: .85rem; text-decoration: none; }
.sb-cta-alt:hover { text-decoration: underline; }

/* On This Page */
.sb-toc ul { list-style: none; margin: 0; padding: 0; }
.sb-toc li { margin: 0 0 .35rem; }
.sb-toc a {
    display: block; color: #cfcfd6; text-decoration: none; font-size: .9rem; line-height: 1.4;
    border-left: 2px solid transparent; padding: .15rem 0 .15rem .7rem;
}
.sb-toc a:hover { color: var(--cta-cyan); border-left-color: var(--cta-cyan); }

/* Our Fleet */
.sb-fleet ul { list-style: none; margin: 0 0 .7rem; padding: 0; }
.sb-fleet li a {
    display: flex; justify-content: space-between; align-items: center; gap: .5rem;
    padding: .5rem 0; text-decoration: none; border-bottom: 1px solid rgba(255, 255, 255, .07);
}
.sb-fleet li:last-child a { border-bottom: 0; }
.sb-fleet-name { color: var(--text-light); font-size: .94rem; }
.sb-fleet li a:hover .sb-fleet-name { color: var(--cta-cyan); }
.sb-fleet-cap { color: #8b8b96; font-size: .8rem; white-space: nowrap; }
.sb-more { color: var(--cta-magenta); font-weight: 700; font-size: .88rem; text-decoration: none; }
.sb-more:hover { text-decoration: underline; }

/* Quick Facts */
.sb-facts ul { list-style: none; margin: 0; padding: 0; }
.sb-facts li { display: flex; gap: .65rem; align-items: flex-start; color: #d9d9e0; font-size: .92rem; line-height: 1.4; padding: .38rem 0; }
.sb-facts i { color: var(--cta-cyan); width: 18px; text-align: center; margin-top: .15rem; flex-shrink: 0; }

/* More Guides */
.sb-related ul { list-style: none; margin: 0; padding: 0; }
.sb-related li { margin-bottom: .85rem; }
.sb-related li:last-child { margin-bottom: 0; }
.sb-related li a { display: flex; gap: .7rem; align-items: center; text-decoration: none; }
.sb-related img { width: 66px; height: 50px; object-fit: cover; border-radius: 6px; flex-shrink: 0; }
.sb-related span { color: #cfcfd6; font-size: .9rem; line-height: 1.3; }
.sb-related li a:hover span { color: var(--cta-cyan); }

@media (max-width: 900px) {
    .blog-layout { grid-template-columns: 1fr; gap: 0; }
    .blog-sidebar { position: static; padding-top: 2rem; }
}

@media (max-width: 600px) {
    .blog-hero { padding: 4rem 1rem 3rem; }
    .blog-list-wrap { padding: 2.5rem 1rem 3rem; }
    .blog-article { padding-top: 2rem; }
}
