/* Inner pages: about, service, news, article, contact, policy, 404.
   Geometry from the 1920px frames of Dine.fig (pages "about", "service", "news", "article", "contact", "policy", "404"):
   166px header strip, title 160px below it, 1400px container, text offset 329px, 440px three-column grid with 40px gaps.
   The Figma copy on these pages is placeholder text from a font specimen; real wording is an IMPLEMENTATION DECISION (see REVIEW.md). */

/* ---------- Header strip (cover 1920x166) ---------- */
.dn-pagehead {
  position: relative;
  height: 166px;
  background: var(--background-secondary) url("../img/cover-strip.jpg") center top / cover no-repeat;
}
.dn-pagehead::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, var(--overlay-shadow) 0%, rgba(0, 0, 0, 0.25) 100%);
}
.dn-pagehead .dn-header { z-index: 20; }

.dn-page { padding-top: 160px; padding-bottom: var(--section-space); }
.dn-page > .dn-container + .dn-container { margin-top: 120px; }
.dn-block { margin-top: 120px; }
.dn-block:first-child { margin-top: 0; }

.dn-lead { width: 800px; max-width: 100%; margin-top: 20px; line-height: 1.2; }
.dn-lead p + p { margin-top: 0; }
.dn-page__intro { display: flex; flex-direction: column; align-items: flex-start; }
.dn-page__intro .dn-button { margin-top: 40px; }
.dn-page__intro--offset { padding-left: var(--content-offset); }

/* ---------- Three-column grids: values, team, benefits ---------- */
.dn-cols {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 40px;
  margin-top: 40px;
}
.dn-cols__letter {
  display: block;
  font-size: 30px;
  font-style: italic;
  font-weight: 600;
  line-height: 0.85;
  letter-spacing: -1.2px;
}
.dn-cols__label {
  color: #ffbb00;   /* same yellow as the Services index label */
  display: block;
  margin-top: 20px;
  font-size: 24px;
  font-weight: 600;
  line-height: 1.2;
  text-transform: uppercase;
}
.dn-cols__text { margin-top: 20px; line-height: 1.2; }

.dn-card__image { display: block; width: 100%; object-fit: cover; }
.dn-card__image--square { aspect-ratio: 1 / 1; }
.dn-card__image--wide { aspect-ratio: 440 / 320; }
.dn-card__name { margin-top: 20px; font-size: 24px; font-weight: 600; line-height: 1.2; }
.dn-card__role { margin-top: 5px; font-size: 20px; font-style: italic; font-weight: 500; line-height: 1.2; }
.dn-card__text { margin-top: 20px; line-height: 1.2; }

/* ---------- Service page ---------- */
.dn-service-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 80px; }
.dn-service-top__text { width: 800px; max-width: 100%; display: flex; flex-direction: column; gap: 40px; }
.dn-service-top__text > .dn-heading { margin-bottom: 0; }
.dn-facts { display: flex; flex-direction: column; gap: 0; }
.dn-facts__lead { font-size: 20px; font-style: italic; font-weight: 500; line-height: 1.5; color: var(--typography-primary); }
.dn-facts p { margin-top: 20px; line-height: 1.2; }
.dn-service-top__image { flex: none; width: 490px; aspect-ratio: 490 / 522; object-fit: cover; }
.dn-service-top .dn-button { align-self: flex-start; }

/* ---------- News list ---------- */
.dn-listing { display: flex; gap: 93px; margin-top: 0; }
.dn-listing__body { display: flex; gap: 110px; flex: 1; min-width: 0; }
.dn-listing__main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 0; }
.dn-listing__main > .dn-heading { margin-bottom: 40px; }
.dn-filter a { display: flex; flex-direction: column; gap: 20px; color: inherit; }
.dn-filter .dn-services__label { text-decoration: underline; text-decoration-color: transparent; text-decoration-thickness: 3px; text-underline-offset: 8px; transition: text-decoration-color var(--transition); }
.dn-filter a:hover .dn-services__label,
.dn-filter a[aria-current="true"] .dn-services__label { text-decoration-color: var(--elements-primary); }
.dn-filter-item[hidden] { display: none; }

.dn-news-row { padding-block: 48px; border-top: 1px solid var(--elements-lines); display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.dn-news-row__text { max-width: 690px; display: flex; flex-direction: column; align-items: flex-start; gap: 20px; }
.dn-news-row__date { font-size: 18px; font-style: italic; font-weight: 500; line-height: 1.2; }
.dn-news-row__title { font-size: 24px; font-weight: 600; line-height: 1.2; }
.dn-news-row__title a:hover { text-decoration: underline; text-underline-offset: 4px; }
.dn-news-row__excerpt { line-height: 1.2; }
.dn-news-row__image { flex: none; width: 360px; height: 300px; object-fit: cover; }

/* ---------- Article (one news story) ----------
   Stories are short (two or three sentences, an optional photo), so the page keeps the news list layout: tag menu, divider, main column.
   The featured image is NOT printed in the story (it is only the picture in news lists, sliders and link previews); photos are image blocks inside the text.
   Below: links to the earlier and the later story, then the Instagram slider (sections/gallery.css). */
.dn-article { display: flex; flex-direction: column; align-items: flex-start; gap: 24px; }
.dn-article__back { display: inline-flex; align-items: center; gap: 10px; font-size: 16px; }
.dn-article__back .dn-icon, .dn-article-nav__dir .dn-icon { width: 12px; height: 12px; }
.dn-icon--left { transform: rotate(90deg); }
.dn-article__title { max-width: 900px; margin-top: 8px; font-size: 64px; line-height: 0.9; }
.dn-article__content { width: 100%; max-width: var(--content-width); margin-top: 16px; display: flex; flex-direction: column; gap: 48px; }
.dn-article__text { max-width: 800px; padding-top: 4px; font-size: 22px; font-weight: 500; line-height: 1.45; }
.dn-article__text p + p { margin-top: 20px; }

.dn-article-nav { margin-top: 96px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 60px; }
.dn-article-nav__link { padding-top: 32px; border-top: 1px solid var(--elements-lines); display: flex; flex-direction: column; align-items: flex-start; gap: 12px; color: inherit; }
.dn-article-nav__link--next { grid-column: 2; align-items: flex-end; text-align: right; }
.dn-article-nav__dir { display: inline-flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; }
.dn-article-nav__title { font-size: 24px; font-weight: 600; line-height: 1.2; }
.dn-article-nav__link:hover .dn-article-nav__title, .dn-article-nav__link:focus-visible .dn-article-nav__title { text-decoration: underline; text-underline-offset: 4px; }
.dn-article-nav__link:hover .dn-article-nav__dir { color: var(--elements-hover); }
.dn-article-insta .dn-photos__text a { font-weight: 600; text-decoration: underline; text-underline-offset: 4px; }
.dn-article-insta .dn-photos__text a:hover { color: var(--elements-hover); }

/* ---------- Contact ---------- */
.dn-contact-page { display: flex; gap: 143px; align-items: flex-start; }
.dn-contact-page__form { flex: 1; min-width: 0; max-width: 971px; }
.dn-contact-page__form .dn-contact__form { margin-top: 0; width: 100%; }
.dn-contact-info { flex: none; width: 286px; display: flex; flex-direction: column; gap: 30px; margin-top: 0; }
.dn-contact-info li { display: flex; align-items: flex-start; gap: 36px; font-size: 20px; line-height: 1.2; }
.dn-contact-info svg { flex: none; width: 32px; height: 32px; fill: #9ca2a7; }
.dn-contact-info a:hover { text-decoration: underline; text-underline-offset: 4px; }
.dn-map { display: block; width: 100%; height: 400px; border: 0; background: var(--elements-lines); filter: grayscale(0.2); }

/* ---------- Policy ---------- */
.dn-policy { margin-top: 40px; display: flex; flex-direction: column; gap: 40px; max-width: 1100px; }
.dn-policy h2 { font-size: 24px; font-weight: 600; line-height: 1.2; }
.dn-policy p { margin-top: 20px; line-height: 1.2; }
.dn-policy p + p { margin-top: 12px; }

/* ---------- 404 ---------- */
.dn-notfound { display: flex; flex-direction: column; gap: 40px; }
.dn-notfound .dn-heading { line-height: 0.85; }
.dn-search { display: flex; flex-direction: column; align-items: flex-start; gap: 30px; width: 360px; max-width: 100%; margin-top: 0; }
.dn-search .dn-field-wrap { width: 100%; }
.dn-back { font-weight: 600; text-decoration: underline; text-underline-offset: 4px; }
.dn-back:hover { color: var(--elements-hover); }

/* Cookie banner on inner pages: pinned to the bottom of the viewport (on the homepage it overlaps the hero) */
.dn-cookie--fixed { position: fixed; top: auto; bottom: 24px; }

.dn-listing__main > .dn-heading + .dn-news-row { border-top-color: var(--elements-lines); }
.dn-listing__main > .dn-news-row:last-child { padding-bottom: 0; }

/* Info pages (free delivery, daily fuel, how it works): policy layout plus a call to action */
.dn-policy__cta { margin-top: 48px; }

/* News tags: story meta row, counts in the menu, the "showing" line and the empty state */
.dn-news-row__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; }
.dn-filter__count { margin-left: 4px; font-size: 14px; font-weight: 500; letter-spacing: 0; text-transform: none; opacity: 0.7; }
.dn-filter__status { margin: -16px 0 24px; font-size: 16px; line-height: 1.2; }
.dn-filter__status a { text-decoration: underline; text-underline-offset: 3px; }
.dn-filter__status a:hover { color: var(--elements-hover); }
.dn-filter__status[hidden], .dn-filter__empty[hidden] { display: none; }
.dn-filter__empty { padding-block: 48px; border-top: 1px solid var(--elements-lines); display: flex; flex-direction: column; align-items: flex-start; gap: 20px; }

/* News pagination: previous / numbers / next under the list (built by js/filter.js) */
.dn-pagination { margin-top: 48px; padding-top: 32px; border-top: 1px solid var(--elements-lines); }
.dn-pagination[hidden] { display: none; }
.dn-pagination__list { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.dn-pagelink {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  height: 44px;
  padding: 0 12px;
  border: var(--border-width) solid var(--elements-lines);
  border-radius: var(--radius);
  color: var(--typography-primary);
  font-size: 18px;
  font-weight: 500;
  line-height: 1;
  transition: border-color var(--transition), background-color var(--transition);
}
a.dn-pagelink:hover, a.dn-pagelink:focus-visible { border-color: var(--elements-hover); }
.dn-pagelink.is-current { background: var(--button-primary); border-color: var(--button-primary); }
.dn-pagelink.is-disabled { opacity: 0.4; }
.dn-pagelink--gap { border-color: transparent; min-width: 24px; padding: 0; }
.dn-pagelink__arrow { width: 14px; height: 14px; }
.dn-pagelink__arrow--prev { transform: rotate(90deg); }
.dn-pagelink__arrow--next { transform: rotate(-90deg); }
