/* ===================================================================
   LK Finance — Blog Post Styles
   Each article has a unique color via CSS variables on .blog-post
   =================================================================== */

/* ============ POST HERO ============ */
.blog-post {
  --accent: var(--teal-2);
  --accent-soft: rgba(46,164,160,0.10);
  --accent-strong: rgba(46,164,160,0.20);
}

/* Featured cover image — DNA: Clean 3D Isometric */
.post-cover {
  padding: 0 24px 40px;
  position: relative;
}
.post-cover-inner {
  max-width: 980px;
  margin: 0 auto;
}
.post-cover-image {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
  border-radius: 22px;
  border: 1px solid rgba(46, 164, 160, 0.14);
  background: linear-gradient(135deg, #FBF9F4 0%, #EDF7FB 100%);
  box-shadow:
    0 1px 2px rgba(10, 22, 40, 0.04),
    0 12px 28px rgba(46, 164, 160, 0.10),
    0 24px 56px rgba(10, 22, 40, 0.08);
}
@media (max-width: 720px) {
  .post-cover { padding: 0 16px 32px; }
  .post-cover-image { border-radius: 16px; }
}

.post-hero {
  padding: 40px 0 64px;
  position: relative;
  background: linear-gradient(180deg, var(--accent-soft) 0%, transparent 100%);
  border-bottom: 1px solid var(--accent-strong);
}
.post-hero .container { max-width: 820px; }

.post-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  font-family: var(--font-display);
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 18px;
}
.post-category {
  display: inline-block;
  padding: 6px 14px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.06em;
  border-radius: 100px;
  text-transform: uppercase;
}
.post-meta .dot { color: var(--hairline-2); }
.post-meta time,
.post-meta .read-time {
  font-weight: 600;
  color: var(--ink-2);
}

.post-title {
  font-family: var(--font-display);
  font-size: 48px;
  font-weight: 900;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 0 0 18px;
}
.post-title .accent { color: var(--accent); }

.post-lede {
  font-size: 20px;
  line-height: 1.6;
  color: var(--ink-2);
  font-weight: 500;
  margin: 0;
}

@media (max-width: 720px) {
  .post-hero { padding: 24px 0 40px; }
  .post-title { font-size: 32px; }
  .post-lede { font-size: 17px; }
}

/* ============ AI TOOLBAR ============ */
.post-toolbar {
  position: sticky;
  top: 72px;
  z-index: 50;
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--hairline-2);
  padding: 10px 0;
  margin-bottom: 32px;
}
.post-toolbar-inner {
  max-width: 820px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.post-tool {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  background: #fff;
  border: 1.5px solid var(--hairline-2);
  border-radius: 100px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 14px;
  color: var(--ink);
  cursor: pointer;
  transition: all .2s ease;
}
.post-tool:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-1px);
}
.post-tool.active {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.post-tool-icon {
  font-size: 16px;
  line-height: 1;
}
.post-tool.audio.playing {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  animation: pulse 1.4s ease infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 var(--accent-strong); }
  50% { box-shadow: 0 0 0 8px transparent; }
}

@media (max-width: 720px) {
  .post-toolbar-inner { gap: 6px; padding: 0 16px; }
  .post-tool { padding: 8px 12px; font-size: 13px; }
}

/* ============ SUMMARY PANEL ============ */
.post-summary {
  max-width: 820px;
  margin: 0 auto 32px;
  padding: 0 24px;
}
.post-summary[hidden] { display: none; }
.post-summary-inner {
  background: linear-gradient(135deg, var(--accent-soft), rgba(255,255,255,0.6));
  border: 1px solid var(--accent-strong);
  border-radius: 18px;
  padding: 24px 28px;
}
.post-summary h3 {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 800;
  color: var(--accent);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin: 0 0 12px;
}
.post-summary p {
  font-size: 16px;
  line-height: 1.7;
  color: var(--ink);
  margin: 0;
}
.post-summary ul {
  margin: 12px 0 0;
  padding-right: 20px;
}
.post-summary li {
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink);
  margin-bottom: 6px;
}

/* ============ AUDIO INDICATOR ============ */
.post-audio-status {
  max-width: 820px;
  margin: 0 auto 24px;
  padding: 0 24px;
}
.post-audio-status[hidden] { display: none; }
.post-audio-status-inner {
  background: var(--accent-soft);
  border: 1px solid var(--accent-strong);
  border-radius: 12px;
  padding: 12px 18px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  color: var(--ink);
}
.post-audio-status-icon {
  display: inline-block;
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--accent);
  animation: pulse-dot 1.4s ease infinite;
}
@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.8); }
}

/* ============ POST CONTENT ============ */
.post-content {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 24px;
  font-family: var(--font-body);
  color: var(--ink);
  font-size: 18px;
  line-height: 1.8;
}
.post-content > * { margin-bottom: 20px; }
.post-content h2 {
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: 800;
  line-height: 1.25;
  margin: 48px 0 18px;
  color: var(--ink);
  letter-spacing: -0.01em;
}
.post-content h2::before {
  content: '';
  display: block;
  width: 36px;
  height: 4px;
  border-radius: 2px;
  background: var(--accent);
  margin-bottom: 14px;
}
.post-content h3 {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 800;
  margin: 32px 0 12px;
  color: var(--ink);
}
.post-content p { margin: 0 0 20px; }
.post-content strong { color: var(--accent); font-weight: 700; }
.post-content em { color: var(--ink-2); font-style: italic; }
.post-content blockquote {
  border-right: 4px solid var(--accent);
  padding: 12px 22px;
  background: var(--accent-soft);
  border-radius: 0 12px 12px 0;
  font-size: 19px;
  font-weight: 500;
  color: var(--ink);
  font-style: italic;
  margin: 28px 0;
}
.post-content ul,
.post-content ol {
  padding-right: 24px;
  margin: 0 0 24px;
}
.post-content li {
  margin-bottom: 10px;
  line-height: 1.75;
}
.post-content li::marker { color: var(--accent); }
.post-content code {
  background: var(--accent-soft);
  padding: 2px 8px;
  border-radius: 6px;
  font-family: 'SF Mono', Monaco, monospace;
  font-size: 0.92em;
  color: var(--accent);
  direction: ltr;
  display: inline-block;
}
.post-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 28px 0;
  font-size: 16px;
}
.post-content th {
  background: var(--accent-soft);
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 800;
  text-align: right;
  padding: 12px 14px;
  border-bottom: 2px solid var(--accent);
}
.post-content td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--hairline-2);
}
.post-content tr:hover { background: rgba(0,0,0,0.02); }

.post-content .callout {
  background: var(--accent-soft);
  border: 1px solid var(--accent-strong);
  border-radius: 16px;
  padding: 22px 26px;
  margin: 28px 0;
}
.post-content .callout h4 {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 800;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin: 0 0 8px;
}
.post-content .callout p:last-child { margin-bottom: 0; }

.post-content .key-stat {
  display: block;
  text-align: center;
  font-family: var(--font-display);
  font-size: 56px;
  font-weight: 900;
  color: var(--accent);
  line-height: 1;
  margin: 32px 0 12px;
  letter-spacing: -0.02em;
}
.post-content .key-stat-label {
  display: block;
  text-align: center;
  font-size: 14px;
  color: var(--muted);
  font-weight: 600;
  margin-bottom: 32px;
}

@media (max-width: 720px) {
  .post-content { font-size: 17px; }
  .post-content h2 { font-size: 24px; margin-top: 36px; }
  .post-content h3 { font-size: 19px; }
  .post-content blockquote { font-size: 17px; }
  .post-content .key-stat { font-size: 40px; }
}

/* ============ POST FOOTER (SHARE + AUTHOR) ============ */
.post-footer {
  max-width: 820px;
  margin: 64px auto 0;
  padding: 48px 24px 24px;
  border-top: 2px solid var(--accent-strong);
}

.post-share-card {
  background: linear-gradient(135deg, var(--accent-soft), rgba(255,255,255,0.4));
  border: 1px solid var(--accent-strong);
  border-radius: 24px;
  padding: 32px;
  text-align: center;
}
.post-share-card h3 {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 800;
  color: var(--ink);
  margin: 0 0 8px;
}
.post-share-card p {
  color: var(--ink-2);
  margin: 0 0 22px;
  font-size: 16px;
}
.post-share-buttons {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}
.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 18px;
  background: #fff;
  border: 1.5px solid var(--hairline-2);
  border-radius: 100px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 14px;
  color: var(--ink);
  text-decoration: none;
  cursor: pointer;
  transition: all .2s ease;
  white-space: nowrap;
}
.share-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.08);
  border-color: var(--accent);
  color: var(--accent);
}
.share-btn.copied {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.share-btn-ico {
  font-size: 16px;
  line-height: 1;
}

/* Author block */
.post-author {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 36px;
  padding: 20px 24px;
  background: #fff;
  border: 1px solid var(--hairline-2);
  border-radius: 16px;
}
.post-author-img {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--accent);
  flex-shrink: 0;
}
.post-author-text {
  flex: 1;
}
.post-author-name {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 17px;
  color: var(--ink);
  margin: 0 0 2px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.post-author-logo {
  width: 56px; height: 56px;
  object-fit: contain;
  background: #ffffff;
  border-radius: 10px;
  padding: 4px;
  border: 1px solid var(--hairline-2);
  flex-shrink: 0;
}
.post-author-bio {
  font-size: 14px;
  color: var(--muted);
  margin: 0;
  line-height: 1.5;
}
.post-author-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: var(--accent);
  color: #fff;
  border-radius: 100px;
  text-decoration: none;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 13px;
  white-space: nowrap;
  transition: transform .2s;
}
.post-author-cta:hover { transform: translateY(-1px); }

@media (max-width: 540px) {
  .post-author { flex-direction: column; align-items: flex-start; }
  .post-share-card { padding: 22px 18px; }
  .post-share-card h3 { font-size: 22px; }
}

/* ============ TOAST (copy confirmation) ============ */
.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: var(--ink);
  color: #fff;
  padding: 12px 22px;
  border-radius: 100px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 14px;
  z-index: 1000;
  opacity: 0;
  transition: all .3s ease;
  box-shadow: 0 12px 32px rgba(0,0,0,0.2);
}
.toast.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

/* ============ BLOG INDEX CARDS ============ */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 22px;
  margin-top: 32px;
}
.blog-card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid var(--hairline-2);
  border-radius: 18px;
  overflow: hidden;
  transition: transform .25s, box-shadow .25s;
  text-decoration: none;
  color: inherit;
  border-top: 4px solid var(--card-accent, var(--teal-2));
}
.blog-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(0,0,0,0.08);
}
.blog-card-body {
  padding: 22px 24px 26px;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.blog-card-cat {
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 800;
  color: var(--card-accent, var(--teal-2));
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 10px;
}
.blog-card h3 {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 800;
  line-height: 1.3;
  color: var(--ink);
  margin: 0 0 10px;
  letter-spacing: -0.01em;
}
.blog-card p {
  font-size: 14px;
  color: var(--ink-2);
  line-height: 1.55;
  margin: 0 0 14px;
  flex: 1;
}
.blog-card-meta {
  font-size: 12px;
  color: var(--muted);
  font-weight: 600;
  display: flex;
  gap: 10px;
  align-items: center;
}

/* ============ CONTENT CITATION ============ */
.cite {
  display: inline-block;
  background: var(--accent-soft);
  color: var(--accent);
  padding: 1px 8px;
  border-radius: 6px;
  font-size: 0.85em;
  font-weight: 700;
}
