/* ============================================================
   Normiračun blog — public server-rendered pages (/blog, /blog/{slug}).
   Loaded only by Pages/Shared/_PublicLayout.cshtml. The header pill and footer
   repeat the landing page's rules (Landing.razor.css is component-scoped, so
   these Razor Pages can't reach it); keep the two in step when the nav changes.
   ============================================================ */

html, body { margin: 0; background: #1b1d24; }

.lp {
    --navy: #1b1d24;
    --mint: #a8ebc8;
    --mint-strong: #8cd9b3;
    --text: #fafafb;
    --muted: #a8acb5;
    --card: rgba(35, 38, 47, 0.85);
    --card-solid: #23262f;
    --border: rgba(255, 255, 255, 0.08);
    --border-strong: rgba(255, 255, 255, 0.16);
    --sans: 'Inter', sans-serif;
    --serif: 'Instrument Serif', Georgia, serif;

    width: 100%;
    min-height: 100vh;
    background: var(--navy);
    color: var(--text);
    font-family: var(--sans);
    overflow-x: clip;
    display: flex;
    flex-direction: column;
}
.lp *, .lp *::before, .lp *::after { box-sizing: border-box; }
.lp a { color: inherit; text-decoration: none; }
.lp img { display: block; }
.lp em { font-family: var(--serif); font-style: italic; font-weight: 400; color: var(--mint); }

/* ---------- header (copy of the landing pill) ---------- */
.lp-header { position: sticky; top: 0; z-index: 50; padding: 20px clamp(16px, 4vw, 60px) 0; }
.lp-nav {
    max-width: 1200px; margin: 0 auto;
    height: 54px;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 999px;
    display: flex; align-items: center; justify-content: space-between;
    padding: 9px 9px 9px 21px;
    backdrop-filter: blur(10px);
}
.lp-logo { display: flex; align-items: center; }
.lp-logo-img { display: block; width: auto; height: 40px; }
.lp-header .lp-logo-img { height: 58px; }
.lp-nav-links { display: flex; align-items: center; gap: 28px; }
.lp-nav-links a { font-size: 14px; line-height: 20px; color: var(--text); transition: color .2s ease; }
.lp-nav-links a:hover, .lp-nav-links a.is-active { color: var(--mint); }
.lp-nav-cta { display: flex; align-items: center; gap: 10px; }

.lp-btn-pill, .lp-btn-outline, .bl-btn {
    display: inline-flex; align-items: center; justify-content: center;
    padding: 8px 15px; border-radius: 999px;
    font-size: 14px; font-weight: 600; line-height: 20px; white-space: nowrap;
    transition: background-color .2s ease, color .2s ease;
}
.lp a.lp-btn-pill, .lp a.bl-btn { background: var(--mint); color: var(--navy); }
.lp a.lp-btn-outline { border: 2px solid var(--mint); color: var(--mint); }
.lp a.lp-btn-pill:hover, .lp a.bl-btn:hover { background: var(--mint-strong); }
.lp a.lp-btn-outline:hover { background: rgba(168, 235, 200, 0.12); }

/* ---------- footer (copy of the landing footer) ---------- */
.lp-footer { border-top: 1px solid var(--border); margin-top: auto; }
.lp-footer-inner {
    max-width: 1280px; margin: 0 auto;
    min-height: 121px; padding: 0 clamp(20px, 5vw, 80px);
    display: flex; align-items: center; justify-content: space-between; gap: 20px;
}
.lp-footer-meta {
    display: flex; align-items: center; gap: 8px;
    background: var(--card); border: 1px solid var(--border);
    border-radius: 999px; padding: 7px 15px;
    font-size: 12px; line-height: 16px; color: var(--muted);
}
.lp-footer-meta a { color: var(--muted); text-decoration: underline; transition: color .2s ease; }
.lp-footer-meta a:hover { color: var(--mint); }
.lp-footer-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--mint); opacity: .58; }

/* ============================================================
   BLOG
   ============================================================ */
.bl-main { width: 100%; max-width: 1200px; margin: 0 auto; padding: 64px clamp(20px, 5vw, 60px) 96px; }

.bl-eyebrow {
    display: block; font-size: 12px; font-weight: 600; line-height: 16px;
    letter-spacing: 2.4px; text-transform: uppercase; color: var(--mint);
}

/* ---------- grid page ---------- */
.bl-list-head { max-width: 720px; margin: 0 auto 40px; text-align: center; display: flex; flex-direction: column; gap: 16px; }
.bl-list-head h1 { margin: 0; font-size: clamp(36px, 5vw, 56px); font-weight: 600; line-height: 1.1; letter-spacing: -0.02em; }
.bl-list-head h1 em { font-size: 1.1em; }
.bl-lead { margin: 0; font-size: 18px; line-height: 1.6; color: var(--muted); }

.bl-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.bl-filter { justify-content: center; margin: 0 auto 40px; max-width: 900px; }
.bl-tag {
    display: inline-flex; align-items: center;
    padding: 6px 14px; border-radius: 999px;
    font-size: 13px; font-weight: 500; line-height: 18px;
    color: var(--muted); background: var(--card); border: 1px solid var(--border);
    transition: color .15s ease, border-color .15s ease;
}
.lp a.bl-tag:hover { color: var(--mint); border-color: rgba(168, 235, 200, 0.4); }
.lp a.bl-tag.is-active { color: var(--navy); background: var(--mint); border-color: var(--mint); }

.bl-empty { text-align: center; color: var(--muted); padding: 48px 0; font-size: 16px; }

.bl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 24px; }
.bl-card {
    display: flex; flex-direction: column; overflow: hidden;
    background: var(--card); border: 1px solid var(--border); border-radius: 24px;
    transition: border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}
.lp a.bl-card:hover { border-color: rgba(168, 235, 200, 0.35); transform: translateY(-2px); box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35); }
.bl-card-cover { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; background: var(--card-solid); }
.bl-card-cover--empty {
    background:
        radial-gradient(ellipse at 30% 20%, rgba(168, 235, 200, 0.22), transparent 60%),
        radial-gradient(ellipse at 80% 90%, rgba(212, 181, 232, 0.14), transparent 55%),
        var(--card-solid);
}
.bl-card-body { padding: 20px 22px 24px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.bl-card-body time { font-size: 12px; color: var(--muted); letter-spacing: .02em; }
.bl-card-body h2, .bl-card-body h3 { margin: 0; font-size: 20px; font-weight: 600; line-height: 1.3; color: var(--text); }
.bl-card-body p { margin: 0; font-size: 14px; line-height: 1.55; color: var(--muted); }
.bl-card-more { margin-top: auto; padding-top: 6px; font-size: 14px; font-weight: 600; color: var(--mint); }

/* ---------- post page ---------- */
.bl-article { max-width: 760px; margin: 0 auto; }
.bl-crumbs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 20px; font-size: 13px; color: var(--muted); }
.lp .bl-crumbs a { color: var(--muted); }
.lp .bl-crumbs a:hover { color: var(--mint); }
.bl-article-head h1 { margin: 0 0 14px; font-size: clamp(32px, 4.4vw, 48px); font-weight: 600; line-height: 1.12; letter-spacing: -0.02em; }
.bl-article-meta { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 13px; color: var(--muted); margin-bottom: 16px; }
.lp .bl-article-meta a { color: var(--mint); }
.bl-article-tags { margin-bottom: 20px; }
.bl-article-lead { margin: 0 0 28px; font-size: 20px; line-height: 1.6; color: var(--text); opacity: .86; }
.bl-article-cover { width: 100%; border-radius: 24px; margin-bottom: 36px; border: 1px solid var(--border); }

/* Quill output (wrapped in .ql-snow .ql-editor). Override quill.snow.css's light-theme defaults. */
.lp .ql-snow .ql-editor.bl-article-body {
    padding: 0; height: auto; overflow: visible;
    font-family: var(--sans); font-size: 17px; line-height: 1.75; color: #e6e7ea;
}
.lp .bl-article-body h2 { margin: 40px 0 14px; font-size: 28px; font-weight: 600; line-height: 1.25; color: var(--text); }
.lp .bl-article-body h3 { margin: 28px 0 10px; font-size: 21px; font-weight: 600; line-height: 1.3; color: var(--text); }
.lp .bl-article-body p { margin: 0 0 18px; }
.lp .bl-article-body li { margin-bottom: 6px; }
.lp .bl-article-body strong { color: var(--text); }
.lp .bl-article-body img { max-width: 100%; height: auto; border-radius: 16px; margin: 12px 0; }
.lp .bl-article-body a { color: var(--mint); text-decoration: underline; text-underline-offset: 3px; overflow-wrap: anywhere; }
.lp .bl-article-body blockquote {
    margin: 24px 0; padding: 4px 0 4px 20px; border-left: 3px solid var(--mint);
    color: var(--muted); font-style: italic;
}
.lp .ql-snow .bl-article-body pre.ql-syntax { background: #111318; color: #e6e7ea; border-radius: 12px; padding: 14px 16px; }
.lp .ql-snow .bl-article-body code { background: rgba(255, 255, 255, 0.08); color: var(--text); border-radius: 6px; padding: 1px 6px; }

.bl-article-cta {
    margin: 48px 0 0; padding: 32px; text-align: center;
    border-radius: 24px; border: 1px solid rgba(168, 235, 200, 0.3);
    background: radial-gradient(ellipse at 50% 0%, rgba(168, 235, 200, 0.16), transparent 70%), var(--card);
    display: flex; flex-direction: column; align-items: center; gap: 16px;
}
.bl-article-cta p { margin: 0; font-size: 20px; line-height: 1.45; font-weight: 500; }
.lp a.bl-btn { padding: 13px 26px; font-size: 15px; }

.bl-related { margin-top: 64px; padding-top: 40px; border-top: 1px solid var(--border); }
.bl-related h2 { margin: 0 0 24px; font-size: 28px; font-weight: 600; }
.bl-related .bl-grid { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
    .lp-nav-links { display: none; }
    .lp-footer-inner { flex-direction: column; justify-content: center; padding-top: 28px; padding-bottom: 28px; }
}
@media (max-width: 600px) {
    .bl-main { padding-top: 40px; }
    .bl-grid { grid-template-columns: 1fr; }
    .lp-footer-meta { flex-wrap: wrap; justify-content: center; }
    .lp-nav { padding: 6px 6px 6px 14px; gap: 10px; }
    .lp-nav-cta { flex: none; gap: 8px; }
    .lp-nav-cta .lp-btn-outline, .lp-nav-cta .lp-btn-pill { padding: 7px 12px; font-size: 13px; }
    .lp-logo { flex: 0 1 auto; min-width: 0; }
    .lp-header .lp-logo-img { height: 44px; max-width: 100%; object-fit: contain; }
    .bl-article-cta { padding: 24px 20px; }
}
@media (max-width: 420px) {
    .lp-nav { padding: 6px 6px 6px 12px; gap: 8px; }
    .lp-nav-cta { gap: 6px; }
    .lp-nav-cta .lp-btn-outline, .lp-nav-cta .lp-btn-pill { padding: 7px 10px; font-size: 12px; }
    .lp-header .lp-logo-img { height: 38px; }
}
