/* Simple editorial pages — full-bleed green header */

.simple-page {
  --simple-display: "Outfit", var(--font-sans), ui-sans-serif, system-ui, sans-serif;
  --simple-shell: min(100% - 3rem, 80rem);
  --simple-measure: min(100%, 56rem);
}

html[lang="ar"] .simple-page {
  --simple-display: var(--font-arabic), "Noto Sans Arabic", ui-sans-serif, system-ui, sans-serif;
}

.simple-page-hero {
  width: 100%;
  background: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
  padding: 3rem 0 2.75rem;
}

@media (min-width: 768px) {
  .simple-page-hero {
    padding: 3.75rem 0 3.25rem;
  }
}

.simple-page-hero__inner {
  width: var(--simple-shell);
  margin-inline: auto;
}

.simple-page-hero__header {
  max-width: var(--simple-measure);
  text-align: left;
}

.simple-page[dir="rtl"] .simple-page-hero__header {
  text-align: right;
  margin-inline-start: auto;
}

.simple-page-hero__title {
  margin: 0;
  font-family: var(--simple-display);
  font-size: clamp(1.85rem, 4vw, 2.75rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: hsl(var(--primary-foreground));
}

html[lang="ar"] .simple-page-hero__title {
  letter-spacing: 0;
}

.simple-page-hero__lead {
  margin: 0.85rem 0 0;
  max-width: 40rem;
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  line-height: 1.55;
  color: hsl(var(--primary-foreground) / 0.9);
}

.simple-page[dir="rtl"] .simple-page-hero__lead {
  margin-inline-start: auto;
}

.simple-page-hero__meta {
  margin: 0.65rem 0 0;
  font-size: 0.875rem;
  line-height: 1.45;
  color: hsl(var(--primary-foreground) / 0.78);
}

.simple-page-hero__meta + .simple-page-hero__meta {
  margin-top: 0.35rem;
}

.simple-page-hero__meta strong {
  color: hsl(var(--primary-foreground));
  font-weight: 650;
}

/* Breadcrumbs sitting on the green hero */
.simple-page-hero nav[aria-label] {
  color: hsl(var(--primary-foreground) / 0.72);
}

.simple-page-hero nav[aria-label] a {
  color: hsl(var(--primary-foreground) / 0.88);
}

.simple-page-hero nav[aria-label] a:hover {
  color: hsl(var(--primary-foreground));
}

.simple-page-hero nav[aria-label] .text-foreground {
  color: hsl(var(--primary-foreground));
}

.simple-page-hero nav[aria-label] .text-border {
  color: hsl(var(--primary-foreground) / 0.35);
}

.simple-page-hero__eyebrow {
  margin: 0 0 0.75rem;
  font-size: 0.8rem;
  font-weight: 650;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: hsl(var(--primary-foreground) / 0.78);
}

.simple-page-hero__search {
  margin-top: 1.5rem;
  max-width: 36rem;
}

.simple-page-hero__search input {
  border-color: hsl(var(--primary-foreground) / 0.28);
  background: hsl(var(--background));
  color: hsl(var(--foreground));
}

.simple-page-hero__search input::placeholder {
  color: hsl(var(--muted-foreground));
}

.simple-page-hero__search button {
  background: hsl(var(--primary-foreground));
  color: hsl(var(--primary));
}

.simple-page-hero__search button:hover {
  background: hsl(var(--primary-foreground) / 0.92);
}

.simple-page-body {
  width: 100%;
  background: hsl(var(--background));
  padding: 2.75rem 0 4rem;
}

@media (min-width: 768px) {
  .simple-page-body {
    padding: 3.25rem 0 5rem;
  }
}

.simple-page-body__shell {
  width: var(--simple-shell);
  margin-inline: auto;
}

.simple-page-body__inner {
  max-width: var(--simple-measure);
  width: 100%;
}

.simple-page[dir="rtl"] .simple-page-body__inner {
  margin-inline-start: auto;
}

.simple-page[dir="rtl"] .simple-page-body {
  text-align: right;
}

.simple-page:not([dir="rtl"]) .simple-page-body {
  text-align: left;
}

.simple-page-body__inner.space-y-8 > * + * {
  margin-top: 2rem;
}

/* Guide comparison tables */
.simple-page-table-wrap {
  margin-top: 0.75rem;
  overflow-x: auto;
  border: 1px solid hsl(var(--border) / 0.9);
  border-radius: 0.75rem;
  background: hsl(var(--muted) / 0.28);
}

.simple-page-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
  line-height: 1.55;
}

.simple-page-table thead th {
  padding: 0.95rem 1.15rem;
  font-family: var(--simple-display);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: hsl(var(--primary));
  background: hsl(var(--primary) / 0.07);
  border-bottom: 1px solid hsl(var(--border));
  vertical-align: bottom;
}

.simple-page-table tbody td {
  padding: 1.05rem 1.15rem;
  vertical-align: top;
  border-bottom: 1px solid hsl(var(--border) / 0.7);
  color: hsl(var(--foreground));
}

.simple-page-table tbody tr:last-child td {
  border-bottom: 0;
}

.simple-page-table tbody tr:nth-child(even) td {
  background: hsl(var(--background) / 0.65);
}

.simple-page-table tbody td:first-child {
  font-weight: 600;
  color: hsl(var(--foreground));
  width: 42%;
}

.simple-page-table tbody td:last-child {
  color: hsl(var(--muted-foreground));
}

.simple-page[dir="rtl"] .simple-page-table thead th,
.simple-page[dir="rtl"] .simple-page-table tbody td {
  text-align: right;
}

@media (min-width: 640px) {
  .simple-page-table thead th,
  .simple-page-table tbody td {
    padding: 1.15rem 1.35rem;
  }
}

/* Food index hub cards — icon / flag beside title */
.food-hub-card {
  border-radius: 0.5rem;
}

.food-hub-card__heading {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
}

.food-hub-card__mark {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  background: none;
  box-shadow: none;
}

.food-hub-card__mark--flag {
  width: 2.35rem;
  height: 1.75rem;
}

.food-hub-card__flag {
  display: block;
  width: 2.35rem;
  height: 1.75rem;
  object-fit: cover;
  border-radius: 0.25rem;
  box-shadow: 0 0 0 1px hsl(var(--border) / 0.7);
}

.food-hub-card__mark--icon {
  color: hsl(var(--primary));
}

.food-hub-card__mark--icon svg {
  width: 2.25rem;
  height: 2.25rem;
}

.food-hub-card__intro {
  flex: 1 1 auto;
}

.food-hub-card__cta {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  align-self: flex-start;
  margin-top: 1.35rem;
  padding: 0.55rem 0.9rem;
  border-radius: 0.55rem;
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1.2;
  color: hsl(var(--primary));
  background: hsl(var(--primary) / 0.1);
  box-shadow: inset 0 0 0 1px hsl(var(--primary) / 0.18);
  transition: background 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.food-hub-card__cta-arrow {
  font-size: 1.05em;
  transition: transform 0.15s ease;
}

.food-hub-card:hover .food-hub-card__cta {
  background: hsl(var(--primary) / 0.16);
  box-shadow: inset 0 0 0 1px hsl(var(--primary) / 0.28);
}

.food-hub-card:hover .food-hub-card__cta-arrow {
  transform: translateX(2px);
}

[dir="rtl"] .food-hub-card:hover .food-hub-card__cta-arrow {
  transform: translateX(-2px);
}

/* Hub card scroll focus — grow in view, ease back past */
.food-hub-card-list {
  overflow: visible;
}

.food-hub-card-list > li {
  overflow: visible;
}

@media (prefers-reduced-motion: no-preference) {
  .food-hub-card {
    transform-origin: center center;
    will-change: transform;
    transition:
      transform 0.35s ease,
      box-shadow 0.35s ease,
      border-color 0.2s ease,
      background 0.15s ease;
  }

  .food-hub-card.is-focus {
    transform: scale(1.045);
    z-index: 2;
    border-color: hsl(var(--primary) / 0.42);
    box-shadow: 0 16px 40px rgba(15, 23, 42, 0.1);
  }

  @supports (animation-timeline: view()) {
    .food-hub-card-list--timeline .food-hub-card {
      animation: food-hub-card-focus linear both;
      animation-timeline: view();
      animation-range: entry 0% exit 100%;
      transition: border-color 0.2s ease, background 0.15s ease;
    }

    .food-hub-card-list--timeline .food-hub-card.is-focus {
      transform: none;
      box-shadow: none;
    }
  }
}

@keyframes food-hub-card-focus {
  0% {
    transform: scale(0.985);
    box-shadow: 0 0 0 transparent;
  }
  30%,
  70% {
    transform: scale(1.05);
    box-shadow: 0 16px 40px rgba(15, 23, 42, 0.1);
    border-color: hsl(var(--primary) / 0.4);
  }
  100% {
    transform: scale(0.985);
    box-shadow: 0 0 0 transparent;
  }
}

@media (prefers-reduced-motion: reduce) {
  .food-hub-card {
    animation: none !important;
    transform: none !important;
  }
}

.blog-index-category + .blog-index-category {
  padding-top: 1.5rem;
  border-top: 1px solid hsl(var(--border) / 0.55);
}

.blog-card img {
  display: block;
}
