/* ===========================================================
   Docstocks Blog — shared stylesheet for blog/index.html and
   individual blog/<slug>.html post pages. Mirrors the design
   tokens and header/footer of the main landing page (index.html)
   so the blog reads as part of the same site.
   =========================================================== */

:root {
  --bg:        #fdf9fe;
  --bg-2:      #f6edfa;
  --bg-pink:   #fdf1f8;
  --card:      #ffffff;

  --ink:       #2c2440;
  --ink-soft:  #655c78;
  --ink-faint: #9a90ac;

  --lav-deep:  #8c63c4;
  --accent:    #cf5f9f;

  --grad:      linear-gradient(118deg, #9a73d8 0%, #c47fcf 52%, #e088b4 100%);
  --grad-soft: linear-gradient(120deg, #f1e7fb 0%, #fce9f3 100%);

  --line:      rgba(110, 70, 150, .13);
  --line-2:    rgba(110, 70, 150, .20);
  --shadow:    0 22px 60px -28px rgba(108, 60, 145, .45);
  --shadow-sm: 0 10px 30px -18px rgba(108, 60, 145, .40);

  --maxw:      1120px;
  --maxw-article: 760px;
  --ease:      cubic-bezier(.22,.61,.36,1);
}

* { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: 'Manrope', system-ui, -apple-system, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

.topline { height: 3px; background: var(--grad); }

body::before {
  content: "";
  position: fixed; inset: 0;
  background:
    radial-gradient(46% 36% at 100% 0%, rgba(224,136,180,.13), transparent 60%),
    radial-gradient(46% 38% at 0% 10%, rgba(154,115,216,.12), transparent 60%);
  pointer-events: none; z-index: 0;
}

::selection { background: rgba(207,95,159,.24); color: #4a2050; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }

.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 22px; position: relative; z-index: 1; }
.accent { color: var(--accent); }
.grad-text { background: var(--grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }

/* ============ HEADER (shared with main site) ============ */
header.site {
  position: sticky; top: 0; z-index: 20;
  background: rgba(253,249,254,.85);
  backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 70px; gap: 16px; }
.brand img { height: 40px; width: auto; }
.nav-links { display: flex; align-items: center; gap: 22px; font-weight: 700; font-size: .92rem; }
.nav-links a { color: var(--ink-soft); transition: color .2s var(--ease); }
.nav-links a:hover, .nav-links a.active { color: var(--accent); }

/* ============ MEDIA FRAME (shared) ============ */
.media {
  position: relative; overflow: hidden;
  border-radius: 16px; border: 1px solid var(--line);
  box-shadow: var(--shadow); background: var(--bg-2);
  aspect-ratio: 4 / 3;
}
.media img { width: 100%; height: 100%; object-fit: cover; object-position: center; filter: saturate(.95) contrast(1.03); }

/* ============ LABEL ============ */
.label {
  display: inline-flex; align-items: center; gap: 11px;
  font-size: .67rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--lav-deep);
  margin-bottom: 20px;
}
.label::before { content: ""; width: 22px; height: 2px; border-radius: 2px; background: var(--accent); }

/* ============ BLOG LISTING ============ */
.blog-hero { padding: 52px 0 8px; }
.blog-hero h1 {
  font-family: 'Fraunces', Georgia, serif; font-weight: 400;
  font-size: clamp(2rem, 7.5vw, 3.2rem); line-height: 1.1; letter-spacing: -.016em;
}
.blog-hero .sub { margin-top: 16px; font-size: clamp(1rem, 4vw, 1.1rem); color: var(--ink-soft); max-width: 560px; }

.post-grid { display: grid; grid-template-columns: 1fr; gap: 18px; margin-top: 40px; padding-bottom: 70px; }
.post-card {
  background: var(--card); border: 1px solid var(--line); border-radius: 18px; overflow: hidden;
  box-shadow: var(--shadow-sm); transition: transform .35s var(--ease), box-shadow .35s var(--ease);
  display: block;
}
.post-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.post-card .ph { position: relative; aspect-ratio: 16 / 9; overflow: hidden; }
.post-card .ph img { width: 100%; height: 100%; object-fit: cover; object-position: center; filter: saturate(.95) contrast(1.03); }
.post-card .pb { padding: 22px 22px 26px; }
.post-card .meta { font-size: .68rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--lav-deep); margin-bottom: 10px; }
.post-card h2 { font-family: 'Fraunces', serif; font-weight: 400; font-size: 1.4rem; line-height: 1.3; letter-spacing: -.01em; margin-bottom: 10px; }
.post-card p { font-size: .96rem; color: var(--ink-soft); }
.post-card .readmore { display: inline-flex; align-items: center; gap: 6px; margin-top: 16px; font-weight: 700; font-size: .88rem; color: var(--accent); }

@media (min-width: 720px) {
  .wrap { padding: 0 34px; }
  .post-grid { grid-template-columns: repeat(2, 1fr); gap: 22px; }
}
@media (min-width: 1040px) {
  .post-grid { grid-template-columns: repeat(3, 1fr); }
}

/* ============ ARTICLE (single post) ============ */
.article-hero { padding: 44px 0 0; }
.article-wrap { max-width: var(--maxw-article); margin: 0 auto; padding: 0 22px; position: relative; z-index: 1; }
.breadcrumb { font-size: .8rem; font-weight: 700; color: var(--ink-faint); margin-bottom: 22px; }
.breadcrumb a { color: var(--lav-deep); }

.article-meta { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 18px; }
.tag-chip {
  font-size: .64rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--lav-deep);
  border: 1px solid var(--line-2); background: #fff; padding: 6px 12px; border-radius: 100px;
}

article h1 {
  font-family: 'Fraunces', Georgia, serif; font-weight: 400;
  font-size: clamp(1.9rem, 6.5vw, 2.7rem); line-height: 1.14; letter-spacing: -.016em; margin-bottom: 14px;
}
.byline { color: var(--ink-faint); font-size: .88rem; margin-bottom: 30px; }
.byline strong { color: var(--ink-soft); }

.article-cover { margin: 0 0 36px; }

article .body { padding-bottom: 70px; }
article .body p { font-size: 1.05rem; color: var(--ink); margin-bottom: 20px; }
article .body h2 {
  font-family: 'Fraunces', Georgia, serif; font-weight: 500; font-size: clamp(1.35rem, 4.6vw, 1.7rem);
  letter-spacing: -.01em; margin: 42px 0 16px; color: var(--ink);
}
article .body h3 {
  font-size: 1.08rem; font-weight: 800; letter-spacing: -.005em; margin: 28px 0 12px; color: var(--ink);
}
article .body strong { color: var(--ink); font-weight: 700; }
article .body em { font-style: italic; color: var(--accent); }
article .body ul, article .body ol { margin: 0 0 20px 22px; }
article .body li { font-size: 1.02rem; margin-bottom: 10px; color: var(--ink); }
article .body .callout {
  margin: 32px 0; padding: 22px 24px; background: #fff; border: 1px solid var(--line);
  border-left: 3px solid var(--accent); border-radius: 12px;
}
article .body .callout p:last-child { margin-bottom: 0; }
article .body .callout strong { color: var(--ink); }

.article-footer-cta {
  margin-top: 10px; padding: 34px 26px; text-align: center; border-radius: 22px;
  background: var(--grad); color: #fff; box-shadow: var(--shadow);
}
.article-footer-cta h3 { font-family: 'Fraunces', serif; font-weight: 500; font-size: 1.3rem; margin-bottom: 10px; }
.article-footer-cta p { opacity: .94; margin-bottom: 20px; font-size: .96rem; }
.article-footer-cta a.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  min-height: 48px; padding: 0 24px; border-radius: 100px; font-weight: 700; font-size: .92rem;
  background: #fff; color: var(--lav-deep); box-shadow: 0 8px 20px -12px rgba(60,20,80,.5);
}

/* ============ FOOTER (shared with main site) ============ */
footer.site { border-top: 1px solid var(--line); padding: 30px 0 calc(30px + env(safe-area-inset-bottom)); background: var(--bg); }
.foot { display: flex; flex-direction: column; gap: 16px; align-items: center; text-align: center; color: var(--ink-faint); font-size: .8rem; }
.foot img { height: 26px; }
.foot-social { display: flex; gap: 12px; }
.foot-social a {
  width: 40px; height: 40px; display: flex; align-items: center; justify-content: center;
  border-radius: 50%; border: 1px solid var(--line-2); color: var(--lav-deep);
  transition: transform .2s var(--ease), background .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease);
}
.foot-social a svg { width: 18px; height: 18px; }
.foot-social a:hover { background: var(--grad); color: #fff; border-color: transparent; transform: translateY(-2px); }
.foot a.mail { color: var(--lav-deep); font-weight: 700; }
