/* Theme "bloom": a warm, image-forward lifestyle & culture identity —
   original design in the lifestyle-blog genre, built from scratch for this
   network. Warm-charcoal masthead + trending strip, cream/paper content
   sections, soft 16px-rounded cards, a terracotta accent by default
   (overridden per-site via --accent), and widget-dense sidebars (Top
   Posts, a photo-gallery strip, Popular Topics). Inter throughout (the only
   webfont this network loads globally, via documentShell). Same
   renderHome/renderCategory/renderPost/renderTag/renderSearch/renderAbout
   contract as every other theme (see functions/_themes/bloom.js). */

:root {
  --ink-900:#241a14; --ink-800:#382a22; --ink-700:#54423a; --ink-600:#786259;
  --ink-500:#9c887e; --ink-400:#bba99f; --ink-300:#dcd0c7; --ink-200:#ece2d9; --ink-100:#f4ece5;
  --paper:#faf6f1; --paper-raised:#ffffff;
  --dark-900:#221b16; --dark-800:#2e251e; --dark-700:#463830;
  --accent: #c9694a; /* overridden per-site by documentShell's inline :root style */
  --radius:16px;
  --shadow-sm:0 1px 2px rgba(36,26,20,.07), 0 1px 1px rgba(36,26,20,.05);
  --shadow-lg:0 20px 45px rgba(36,26,20,.16);
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; background: var(--paper); color: var(--ink-800); }
body { font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; line-height: 1.58; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
h1, h2, h3, h4, p { margin: 0; }
ul { list-style: none; margin: 0; padding: 0; }
.wrap { max-width: 1240px; margin: 0 auto; padding: 0 20px; }

/* ---- Placeholder image system: real <img> when a headline image exists,
   a CSS-only gradient card otherwise (zero external image dependency). ---- */
.ph {
  position: relative; display: flex; align-items: center; justify-content: center;
  width: 100%; object-fit: cover; overflow: hidden; border-radius: var(--radius);
  background: linear-gradient(135deg,#3a2c22,#5c4534 60%,#3a2c22); color: rgba(255,255,255,.35);
}
.ph.tone-blush { background: linear-gradient(135deg,#4a2b28,#6e4038 60%,#4a2b28); }
.ph.tone-sage { background: linear-gradient(135deg,#2c3626,#42533a 60%,#2c3626); }
.ph.tone-honey { background: linear-gradient(135deg,#4a3a1e,#6e5a2c 60%,#4a3a1e); }
.ph svg { width: 26%; }
img.ph { background: none; }
.ratio-16-9 { aspect-ratio: 16/9; }
.ratio-4-3 { aspect-ratio: 4/3; }
.ratio-1-1 { aspect-ratio: 1/1; }
.ratio-3-2 { aspect-ratio: 3/2; }

/* ---- Masthead ---- */
.masthead { background: var(--dark-900); color: #fff; }
.masthead-row { display: flex; align-items: center; gap: 28px; padding: 18px 20px; flex-wrap: wrap; }
.logo-group { display: flex; align-items: center; gap: 12px; }
.logo-box { width: 42px; height: 42px; border-radius: 12px; background: var(--accent); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 19px; flex-shrink: 0; }
.logo-img { height: 72px; width: auto; max-width: 420px; object-fit: contain; }
.site-name { font-weight: 800; font-size: 21px; letter-spacing: -0.01em; color: #fff; }
.site-tagline { font-size: 10.5px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-400); margin-top: 2px; }
.main-nav { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; margin-left: 8px; }
.main-nav a { padding: 8px 13px; border-radius: 999px; color: #ecdfd6; font-weight: 600; font-size: 13.5px; }
.main-nav a:hover, .main-nav a.home { background: var(--dark-700); color: #fff; }
.masthead-actions { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.icon-dot { width: 30px; height: 30px; border-radius: 50%; background: var(--dark-700); display: inline-flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 800; color: #fff; }
.icon-dot:hover { background: var(--accent); }
.btn-subscribe { background: var(--accent); color: #fff; font-weight: 700; font-size: 13px; padding: 9px 18px; border-radius: 999px; white-space: nowrap; }
.btn-subscribe:hover { filter: brightness(1.08); }

.trending-strip { background: var(--dark-800); border-top: 1px solid var(--dark-700); overflow: hidden; }
.trending-strip-row { display: flex; align-items: center; gap: 16px; padding: 10px 20px; }
.trending-label { flex-shrink: 0; font-size: 10.5px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--accent); }
.trending-pills { display: flex; gap: 10px; overflow-x: auto; scrollbar-width: none; }
.trending-pills::-webkit-scrollbar { display: none; }
.trending-pills a { flex-shrink: 0; background: var(--dark-700); color: #ecdfd6; font-size: 12.5px; font-weight: 600; padding: 6px 14px; border-radius: 999px; white-space: nowrap; }
.trending-pills a:hover { background: var(--accent); color: #fff; }

/* ---- Section headers & tags ---- */
.section { padding: 44px 0; }
.section-dark { background: var(--dark-900); color: #fff; }
.section-dark .section-title { color: #fff; }
.section-tint { background: var(--paper-raised); border-top: 1px solid var(--ink-200); border-bottom: 1px solid var(--ink-200); }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 22px; }
.section-title { font-size: 21px; font-weight: 800; color: var(--ink-900); display: flex; align-items: center; gap: 10px; }
.section-title .swatch { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.section-viewall { font-size: 12.5px; font-weight: 700; letter-spacing: .02em; color: var(--accent); white-space: nowrap; }
.section-viewall:hover { text-decoration: underline; }

.tag { display: inline-block; font-size: 10.5px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; padding: 4px 11px; border-radius: 999px; }
.meta-row { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; font-size: 12px; color: var(--ink-500); }
.meta-row .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--ink-400); }
.section-dark .meta-row, .section-dark .meta-row .dot { color: var(--ink-400); background: none; }

/* ---- Hero ---- */
.hero-section { padding-top: 34px; padding-bottom: 6px; background: var(--paper); }
.hero-grid { display: grid; grid-template-columns: 1.7fr 1fr; gap: 30px; }
.hero-lead { position: relative; display: block; }
.hero-lead-body { padding-top: 18px; }
.hero-lead-title { font-size: clamp(24px,3vw,36px); font-weight: 800; line-height: 1.16; color: var(--ink-900); margin: 10px 0; }
.hero-lead-title a:hover { text-decoration: underline; text-decoration-color: var(--accent); }
.hero-lead-dek { font-size: 15.5px; color: var(--ink-600); line-height: 1.6; margin-bottom: 12px; max-width: 62ch; }

.hero-side { display: flex; flex-direction: column; gap: 18px; }
.compact-item { display: grid; grid-template-columns: 84px 1fr; gap: 14px; padding-bottom: 18px; border-bottom: 1px solid var(--ink-200); }
.compact-item:last-child { border-bottom: none; padding-bottom: 0; }
.compact-item .ph, .compact-item img { border-radius: 10px; }
.compact-item h4 { font-weight: 700; font-size: 14.5px; line-height: 1.35; color: var(--ink-900); margin-bottom: 5px; }
.compact-item h4 a:hover { text-decoration: underline; }

/* ---- Explore categories tiles ---- */
.tiles-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px,1fr)); gap: 20px; }
.tile-card { position: relative; display: block; border-radius: var(--radius); overflow: hidden; aspect-ratio: 4/3; }
.tile-card .ph, .tile-card img { position: absolute; inset: 0; height: 100%; border-radius: var(--radius); }
.tile-card::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(18,12,9,.86), rgba(18,12,9,.05) 60%); }
.tile-card-body { position: absolute; left: 0; right: 0; bottom: 0; padding: 16px; z-index: 1; }
.tile-card-body h3 { color: #fff; font-size: 17px; font-weight: 800; margin-bottom: 4px; }
.tile-card-body span { color: rgba(255,255,255,.75); font-size: 12px; font-weight: 600; }

/* ---- Main grid: feed + sidebar ---- */
.main-grid { display: grid; grid-template-columns: 1fr 320px; gap: 38px; align-items: start; }
.feed-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px,1fr)); gap: 26px; }
.feed-grid-4 { grid-template-columns: repeat(auto-fill, minmax(210px,1fr)); }
.feed-card { display: flex; flex-direction: column; }
.feed-card-body { padding-top: 12px; }
.feed-card-body h3 { font-weight: 700; font-size: 16.5px; line-height: 1.32; color: var(--ink-900); margin: 8px 0 6px; }
.feed-card-body h3 a:hover { text-decoration: underline; }
.feed-card-body p { font-size: 13px; color: var(--ink-600); line-height: 1.55; margin-bottom: 8px; }

/* ---- Sidebar widgets ---- */
.widget { background: var(--paper-raised); border: 1px solid var(--ink-200); border-radius: var(--radius); padding: 22px; margin-bottom: 22px; }
.widget h3 { font-size: 15px; font-weight: 800; color: var(--ink-900); margin-bottom: 16px; }
.top-posts-list { display: flex; flex-direction: column; }
.top-post-item { display: grid; grid-template-columns: 24px 1fr; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--ink-200); }
.top-post-item:first-child { padding-top: 0; }
.top-post-item:last-child { border-bottom: none; padding-bottom: 0; }
.top-post-num { font-weight: 800; font-size: 15px; color: var(--accent); line-height: 1.5; }
.top-post-item h4 { font-size: 13.5px; font-weight: 700; line-height: 1.38; color: var(--ink-900); }
.top-post-item h4 a:hover { text-decoration: underline; }
.gallery-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.gallery-grid .ph, .gallery-grid img { border-radius: 8px; }
.newsletter-widget { background: var(--dark-900); border-color: var(--dark-900); color: #fff; }
.newsletter-widget h3 { color: #fff; }
.newsletter-widget p { font-size: 13px; color: var(--ink-300); line-height: 1.55; margin-bottom: 14px; }
.newsletter-form { display: flex; flex-direction: column; gap: 10px; }
.newsletter-form input { padding: 11px 14px; border-radius: 999px; border: 1px solid var(--dark-700); background: var(--dark-800); color: #fff; font-size: 13.5px; font-family: inherit; }
.newsletter-form input::placeholder { color: var(--ink-400); }
.newsletter-form button { background: var(--accent); color: #fff; padding: 11px; border-radius: 999px; font-weight: 700; font-size: 13.5px; cursor: pointer; border: none; }
.newsletter-form button:hover:not(:disabled) { filter: brightness(1.1); }
.newsletter-fine { font-size: 11px; color: var(--ink-400); margin-top: 10px; }
.tag-cloud { display: flex; flex-wrap: wrap; gap: 8px; }
.tag-cloud a { background: var(--paper); border: 1px solid var(--ink-200); border-radius: 999px; padding: 6px 14px; font-size: 12.5px; font-weight: 700; color: var(--ink-700); }
.tag-cloud a:hover { background: var(--dark-900); color: #fff; border-color: var(--dark-900); }
.ad-widget { border: 1px dashed var(--ink-300); background: transparent; border-radius: var(--radius); text-align: center; color: var(--ink-500); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; padding: 50px 10px; }

/* ---- Category / tag / search listing pages ---- */
.category-title { font-size: 28px; font-weight: 800; color: var(--ink-900); margin: 0 0 20px; }
.search-form { display: flex; gap: 10px; margin: 0 0 26px; max-width: 520px; }
.search-form input { flex: 1; padding: 12px 16px; border: 1px solid var(--ink-200); border-radius: 999px; font-size: 15px; font-family: inherit; }
.search-form input:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.search-form button { background: var(--accent); color: #fff; border: none; border-radius: 999px; padding: 0 24px; font-weight: 700; cursor: pointer; }
.pagination { display: flex; justify-content: space-between; margin-top: 40px; padding-top: 18px; border-top: 1px solid var(--ink-200); font-weight: 700; font-size: 13.5px; }
.pagination a { color: var(--accent); }
.empty-state { text-align: center; padding: 80px 20px; color: var(--ink-500); }
.empty-state h1 { color: var(--ink-900); font-size: 26px; margin-bottom: 8px; }
.btn { display: inline-block; margin-top: 14px; background: var(--accent); color: #fff; padding: 10px 22px; border-radius: 999px; font-weight: 700; font-size: 13.5px; }

/* ---- Single post ---- */
.single-post { max-width: 720px; margin: 0 auto; }
.breadcrumb { font-size: 12px; color: var(--ink-500); margin-bottom: 14px; }
.breadcrumb a { font-weight: 700; color: var(--ink-800); }
.single-post-header h1 { font-size: clamp(26px,4vw,38px); line-height: 1.22; margin: 10px 0 14px; color: var(--ink-900); font-weight: 800; }
.single-post-headline { width: 100%; max-height: 440px; object-fit: cover; margin: 22px 0 30px; border-radius: var(--radius); }
.single-post-content { font-size: 17px; }
.single-post-content p { margin: 0 0 22px; }
.single-post-content h2 { font-size: 23px; margin: 32px 0 14px; font-weight: 800; }
.single-post-content h3 { font-size: 19px; margin: 24px 0 12px; font-weight: 700; }
.single-post-content img { margin: 24px 0; width: 100%; border-radius: var(--radius); }
.single-post-content a { color: var(--accent); text-decoration: underline; }
.single-post-content blockquote { border-left: 3px solid var(--accent); margin: 26px 0; padding-left: 20px; font-style: italic; color: var(--ink-600); }

.post-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 30px; padding-top: 20px; border-top: 1px solid var(--ink-200); }
.tag-pill-link { background: var(--ink-100); color: var(--ink-700); font-size: 12.5px; font-weight: 700; padding: 6px 15px; border-radius: 999px; }
.tag-pill-link:hover { background: var(--accent); color: #fff; }

.related-posts { max-width: 720px; margin: 56px auto 0; border-top: 1px solid var(--ink-200); padding-top: 28px; }
.related-posts h2 { font-size: 18px; margin-bottom: 18px; font-weight: 800; }

/* ---- Layout wrapper for inner pages ---- */
.page-layout { max-width: 1240px; margin: 0 auto; padding: 36px 20px 60px; }

/* ---- Footer ---- */
.site-footer { background: var(--dark-900); color: var(--ink-400); padding: 46px 0 0; margin-top: 10px; }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1.2fr; gap: 30px; padding-bottom: 28px; border-bottom: 1px solid var(--dark-700); }
.footer-grid h4 { color: #fff; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; margin: 0 0 14px; }
.footer-grid p { font-size: 13px; color: var(--ink-500); line-height: 1.6; }
.footer-grid ul { display: flex; flex-direction: column; gap: 9px; }
.footer-grid li a:hover { color: #fff; }
.footer-logo { font-weight: 800; font-size: 21px; color: #fff; margin-bottom: 10px; }
.footer-social { display: flex; gap: 8px; margin-top: 14px; }
.footer-recent-item { display: grid; grid-template-columns: 46px 1fr; gap: 10px; margin-bottom: 12px; align-items: center; }
.footer-recent-item .ph, .footer-recent-item img { border-radius: 8px; }
.footer-recent-item h5 { font-size: 12.5px; font-weight: 600; line-height: 1.35; color: var(--ink-300); }
.footer-recent-item h5 a:hover { color: #fff; }
.footer-bottom { padding: 18px 0; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; font-size: 12px; color: var(--ink-600); }

@media (max-width: 1080px) {
  .main-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; }
  .main-nav { order: 3; width: 100%; justify-content: flex-start; }
}
@media (max-width: 640px) {
  .feed-grid, .feed-grid-4 { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .compact-item { grid-template-columns: 70px 1fr; }
  .masthead-actions { margin-left: 0; }
}
@media (max-width: 460px) {
  .feed-grid, .feed-grid-4 { grid-template-columns: 1fr; }
}
