/* Content & Instagram: the home page, news, the editable pages, and the
   console's News / Pages / Home page / Instagram screens. Loaded after
   site.css (and admin.css in the console) through {% block head %}; it reuses
   their tokens and components and adds only what they do not cover. */

/* ------------------------------------------------------------ home: hero */
.home-hero { padding-top: clamp(12px, 4vw, 48px); }
.home-hero h1 { max-width: 15ch; }
.home-hero .lede { font-size: clamp(1.1rem, 1rem + .45vw, 1.3rem); }
.home-hero .btn-row .btn { flex: 1 1 auto; }
@media (min-width: 520px) { .home-hero .btn-row .btn { flex: 0 0 auto; } }
@media (max-width: 599px) { .home-hero .hero-photo { aspect-ratio: 1; } }

/* The drawn bouquet shown until a photo is uploaded. It sways a little;
   site.css stops every animation for prefers-reduced-motion. */
.hero-art {
  position: relative; display: block; width: 100%; height: 100%;
  background: radial-gradient(90% 70% at 30% 20%, var(--peony-soft) 0, transparent 60%), radial-gradient(90% 80% at 80% 95%, var(--green-soft) 0, transparent 65%), #fff;
}
/* Pinned inside the panel: a percentage height on a grid item would resolve against an auto row and crop the hand. */
.hero-art img { position: absolute; inset: 8%; width: 84%; height: 84%; object-fit: contain; transform-origin: 50% 95%; animation: sf-sway 9s ease-in-out infinite alternate; }
@keyframes sf-sway { from { transform: rotate(-1.3deg); } to { transform: rotate(1.3deg); } }
@keyframes sf-drift { from { transform: translate(0, 0) rotate(0deg); } to { transform: translate(-16px, 20px) rotate(50deg); } }

/* ------------------------------------------------------------ home: the three ways */
.ways { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
@media (min-width: 780px) { .ways { grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); gap: 16px; } }
.ways li {
  display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 2px 14px; align-content: start;
  padding: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
}
.ways-icon { grid-row: span 3; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--green-soft); color: var(--green); }
.ways-icon svg { width: 22px; height: 22px; }
.ways h2 { margin: 2px 0 0; font-size: 1.12rem; }
.ways p { margin: 0; color: var(--muted); font-size: .95rem; }
.ways a { justify-self: start; display: inline-flex; align-items: center; min-height: 36px; font-weight: 600; font-size: .95rem; }

/* ------------------------------------------------------------ home: next workshop */
.event-feature { display: grid; gap: clamp(20px, 4vw, 48px); align-items: center; }
@media (min-width: 900px) { .event-feature { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
.event-feature-photo { box-shadow: var(--shadow-soft); }
.event-feature h2 a { color: inherit; text-decoration: none; }
.event-feature h2 a:hover { color: var(--green); }
.event-feature-body .event-meta { margin: 0 0 6px; }
.event-feature-body .lede { margin-top: 14px; }

/* ------------------------------------------------------------ home: news feed */
.feed { display: grid; gap: clamp(14px, 2.4vw, 28px) clamp(12px, 2vw, 24px); grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 900px) { .feed { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.feed-tile { display: grid; align-content: start; gap: 10px; min-width: 0; color: inherit; text-decoration: none; }
a.feed-tile:hover { color: inherit; }
.feed-tile .photo img { transition: transform .6s var(--ease); }
a.feed-tile:hover .photo img { transform: scale(1.035); }
.feed-glyph {
  position: absolute; top: 10px; right: 10px; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(255, 255, 255, .92); color: var(--peony-dark); box-shadow: var(--shadow-soft);
}
.feed-glyph svg { width: 18px; height: 18px; }
.feed-body { display: grid; gap: 3px; min-width: 0; }
.feed-kind { font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--peony); }
.feed-tile.news .feed-kind { color: var(--green); }
.feed-title, .feed-text { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; overflow-wrap: anywhere; }
.feed-title { font-family: var(--font-display); font-size: 1.12rem; line-height: 1.25; }
a.feed-tile:hover .feed-title { color: var(--green-dark); }
.feed-text { font-size: .95rem; line-height: 1.45; }
.feed-date { font-size: .85rem; color: var(--muted); font-variant-numeric: tabular-nums; }
@media (max-width: 520px) {
  .feed-title { font-size: 1rem; }
  .feed-text { font-size: .875rem; -webkit-line-clamp: 2; }
}

/* ------------------------------------------------------------ home: follow on Instagram */
.ig-follow {
  display: grid; gap: 16px; align-items: center; padding: clamp(20px, 4vw, 32px); border-radius: var(--radius-lg);
  background: linear-gradient(135deg, var(--peony-soft), #fff 58%, var(--green-soft)); border: 1px solid var(--peony-line);
}
@media (min-width: 760px) { .ig-follow { grid-template-columns: auto minmax(0, 1fr) auto; } }
.ig-follow-icon { width: 56px; height: 56px; border-radius: 18px; display: grid; place-items: center; background: var(--peony); color: #fff; }
.ig-follow-icon svg { width: 28px; height: 28px; }
.ig-follow h2 { font-size: clamp(1.3rem, 1.15rem + .6vw, 1.6rem); margin-bottom: 4px; }
.ig-follow p { color: var(--muted); overflow-wrap: anywhere; }

/* ------------------------------------------------------------ news */
.news-grid { display: grid; gap: clamp(22px, 3vw, 32px); grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); }
@media (min-width: 900px) { .news-grid.has-lead .news-card.lead { grid-column: span 2; } }
.news-card .card-body { gap: 4px; }
.news-card .card-title { font-size: 1.3rem; }
.news-card.lead .card-title { font-size: clamp(1.45rem, 1.2rem + 1vw, 1.95rem); }
.news-card .photo-card:hover .card-title { color: var(--green-dark); }
.news-blurb { color: var(--muted); display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; }
.pager { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: clamp(28px, 5vw, 48px); }

.news-article .page-title { padding-top: 8px; }
.news-photo { margin: 4px 0 clamp(24px, 4vw, 40px); border-radius: var(--radius-lg); overflow: hidden; background: var(--green-soft); }
.news-photo img { width: 100%; height: auto; }

/* ------------------------------------------------------------ the editable pages */
.content-page .page-title { border-bottom: 1px solid var(--line); margin-bottom: clamp(20px, 3vw, 32px); padding-bottom: clamp(16px, 3vw, 24px); }
.delivery-areas h2 { display: flex; align-items: center; gap: 10px; font-size: 1.35rem; }
.delivery-areas h2 svg { color: var(--peony); }
.area-list { list-style: none; margin: 0 0 14px; padding: 0; display: grid; }
.area-list li { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.area-list li:first-child { padding-top: 0; }
.area-name { display: grid; gap: 2px; min-width: 0; overflow-wrap: anywhere; }
.page-cta { display: grid; gap: 16px; padding: clamp(20px, 4vw, 28px); background: var(--green-soft); border-radius: var(--radius-lg); }
@media (min-width: 700px) { .page-cta { grid-template-columns: minmax(0, 1fr) auto; align-items: center; } }
.page-cta h2 { margin-bottom: 4px; }

/* ------------------------------------------------------------ console */
.news-rows .row-title { white-space: normal; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.editor-text { line-height: 1.6; }
.editor-help { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 16px; }
.editor-help code { background: var(--green-soft); padding: 1px 6px; border-radius: 6px; font-size: .85em; white-space: nowrap; }
.input-prefix { display: flex; align-items: stretch; font-weight: 400; }
.input-prefix > span { display: grid; place-items: center; padding: 0 12px; border: 1px solid var(--line-strong); border-right: 0; border-radius: 12px 0 0 12px; background: var(--surface-2); color: var(--muted); font-weight: 600; }
.input-prefix input { border-radius: 0 12px 12px 0; min-width: 0; }
.hero-preview { max-width: 320px; box-shadow: var(--shadow-soft); }
.plain-rows { border: 0; border-radius: 0; background: none; }
.plain-rows .row-item { padding-inline: 0; }
.plain-rows .row-item > svg { color: var(--muted); }

.ig-account { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.ig-account > span:last-child { display: grid; }
.ig-avatar { width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; background: linear-gradient(135deg, var(--peony), #e58fb3); color: #fff; flex-shrink: 0; }
.ig-avatar svg { width: 24px; height: 24px; }
.ig-tiles { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px 12px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 112px), 1fr)); }
.ig-tile { display: grid; gap: 6px; align-content: start; }
.ig-tile .photo .badge { position: absolute; top: 6px; left: 6px; }
.ig-tile.is-hidden .photo img { opacity: .4; filter: grayscale(.7); }
.ig-tile-date { text-align: center; font-variant-numeric: tabular-nums; }
.ig-tile .btn { min-height: 40px; }

.guide-steps { counter-reset: step; list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; }
.guide-steps li { counter-increment: step; position: relative; padding-left: 44px; font-size: .95rem; overflow-wrap: anywhere; }
.guide-steps li::before {
  content: counter(step); position: absolute; left: 0; top: -2px; width: 30px; height: 30px; border-radius: 50%;
  display: grid; place-items: center; background: var(--green); color: #fff; font-weight: 700; font-size: .9rem;
}
.guide-steps strong { display: block; margin-bottom: 2px; }
.copy-line { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 8px 0 4px; }
.copy-line .secret { flex: 1 1 200px; }
