.amg-container {
  width: min(1320px, 100%);
  margin-inline: auto;
  padding-inline: 24px;
}

.site-main {
  padding: 40px 0 72px;
}

.site-main--has-hero {
  padding: 0 0 72px;
}

.amg-wrap {
  display: grid;
  gap: 28px;
  padding: 16px 0 0;
}

.amg-wrap--after-hero {
  padding-top: 42px;
}

.amg-page-header {
  display: grid;
  gap: 12px;
}

.amg-content-hero {
  position: relative;
  padding: 148px 0 96px;
  color: rgba(255, 255, 255, 0.88);
  background:
    radial-gradient(1100px 680px at 34% 42%, rgba(78, 78, 78, 0.46), transparent 72%),
    radial-gradient(860px 520px at 72% 34%, rgba(42, 42, 42, 0.24), transparent 72%),
    linear-gradient(180deg, #1f1f20 0%, #141414 100%);
}

.amg-content-hero__inner {
  display: grid;
  gap: 14px;
  max-width: 760px;
}

.amg-content-hero__eyebrow {
  color: #88b910;
  font-size: 14px;
  font-weight: 600;
}

.amg-content-hero__title {
  margin: 0;
  color: #fff;
  font-size: clamp(40px, 4.2vw, 58px);
  line-height: 1.05;
}

.amg-content-hero__description {
  max-width: 60ch;
  color: rgba(255, 255, 255, 0.78);
  font-size: 16px;
  line-height: 1.75;
}

.amg-content-hero__description p {
  margin: 0;
}

.amg-content-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  padding-top: 4px;
}

.amg-content-hero__action {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  border-radius: 14px;
  font-size: 14px;
  font-weight: 700;
  transition: background-color 160ms ease, color 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.amg-content-hero__action--primary {
  background: var(--accent);
  color: #111827;
}

.amg-content-hero__action--primary:hover,
.amg-content-hero__action--primary:focus-visible {
  background: var(--accent-2);
  transform: translateY(-1px);
  box-shadow: 0 14px 26px rgba(166, 226, 46, 0.26);
}

.amg-content-hero__action--secondary {
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #fff;
  background: rgba(255, 255, 255, 0.04);
}

.amg-content-hero__action--secondary:hover,
.amg-content-hero__action--secondary:focus-visible {
  background: rgba(255, 255, 255, 0.1);
}

.amg-title {
  margin: 0;
  line-height: 1.1;
}

.amg-meta,
.amg-archive-desc {
  color: var(--muted);
  font-size: 15px;
}

.amg-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.amg-meta__sep {
  opacity: 0.45;
}

.amg-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.amg-card {
  display: flex;
  flex-direction: column;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--shadow-1);
}

.amg-card__thumb {
  display: block;
  margin: -18px -18px 18px;
  overflow: hidden;
  border-radius: 18px 18px 0 0;
}

.amg-card__thumb img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.amg-card__title {
  margin: 0 0 10px;
  font-size: 21px;
}

.amg-card__date {
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 14px;
}

.amg-card__excerpt {
  color: rgba(17, 24, 39, 0.84);
}

.amg-card__more {
  margin-top: auto;
  padding-top: 18px;
}

.amg-card__more a {
  color: #111827;
  font-weight: 700;
}

.amg-pagination {
  margin-top: 8px;
}

.amg-pagination .nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.amg-pagination .page-numbers {
  min-width: 42px;
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fff;
}

.amg-pagination .page-numbers.current {
  border-color: transparent;
  background: var(--accent);
  color: #111827;
}

.amg-article,
.amg-page,
.amg-shop-wrap {
  display: grid;
  gap: 24px;
}

.amg-featured img {
  width: 100%;
  height: auto;
  border-radius: 18px;
}

.entry-content {
  display: grid;
  gap: 18px;
}

.entry-content > * {
  margin: 0;
}

.entry-content ul,
.entry-content ol {
  padding-left: 22px;
}

.entry-content img {
  height: auto;
  border-radius: 16px;
}

.amg-post-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 22px;
  padding-top: 18px;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 15px;
}

.amg-post-nav {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-top: 8px;
  border-top: 1px solid var(--border);
}

.amg-post-nav a {
  font-weight: 700;
}

.amg-comments {
  margin-top: 16px;
}

.amg-empty {
  padding: 28px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--surface);
  display: grid;
  gap: 16px;
}

.amg-empty__title {
  margin: 0;
  font-size: 28px;
}

.amg-empty__text {
  margin: 0;
  color: var(--muted);
}

.amg-404 {
  display: grid;
  justify-items: center;
  gap: 18px;
  padding: 72px 0;
  text-align: center;
}

.amg-404__code {
  font-family: var(--font-heading);
  font-size: clamp(80px, 14vw, 140px);
  line-height: 0.9;
  color: rgba(17, 24, 39, 0.1);
}

.amg-404__text {
  max-width: 620px;
  color: var(--muted);
}

.amg-404__search {
  width: min(520px, 100%);
}

.amg-404__back {
  margin: 0;
}

.search-form {
  display: flex;
  gap: 10px;
}

.search-form label {
  flex: 1;
}

.search-form .search-field,
.search-form .search-submit {
  min-height: 46px;
  border-radius: 12px;
}

.search-form .search-field {
  width: 100%;
  padding: 0 14px;
  border: 1px solid var(--border);
  background: #fff;
}

.search-form .search-submit {
  padding: 0 18px;
  border: 0;
  background: var(--accent);
  color: #111827;
  font-weight: 700;
  cursor: pointer;
}

.widget {
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: #fff;
}

.widget-title {
  margin-bottom: 12px;
  font-size: 20px;
}

@media (max-width: 768px) {
  .site-main {
    padding: 28px 0 56px;
  }

  .site-main--has-hero {
    padding: 0 0 56px;
  }

  .amg-content-hero {
    padding: 128px 0 82px;
  }

  .amg-wrap--after-hero {
    padding-top: 34px;
  }

  .amg-content-hero__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .amg-content-hero__action {
    width: 100%;
  }

  .search-form {
    flex-direction: column;
  }

  .amg-post-nav {
    flex-direction: column;
  }
}

@media (max-width: 420px) {
  .amg-container {
    padding-inline: 16px;
  }
}
