/* Ad size guide pages (/ad-sizes/, Stage J). Builds on base.css, landing.css
   and tools.css. The pages are written by seo/build_pages.py. */

.guide-page h1 {
  max-width: 22ch;
}

.guide-page h1 .accent {
  color: var(--brand);
}

.guide-crumbs {
  margin-bottom: 14px;
  font-size: 14px;
  color: var(--ink-muted);
}

.guide-crumbs a {
  color: var(--ink-muted);
  text-decoration: none;
}

.guide-crumbs a:hover {
  color: var(--ink);
  text-decoration: underline;
}

.guide-crumbs [aria-current] {
  color: var(--ink-soft);
}

/* The answer first: the size, its shape, file types and limit, and a picture to scale */
.guide-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 32px 56px;
  align-items: center;
  margin-top: 28px;
}

.guide-hero > div > * {
  margin: 0;
}

.guide-answer {
  font-size: clamp(2.4rem, 6vw, 3.6rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1;
}

.guide-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px !important;
}

.guide-chips span {
  padding: 5px 12px;
  border-radius: 999px;
  background: var(--surface);
  font-family: var(--font-mono);
  font-size: 14px;
}

.guide-hero .lede {
  margin-top: 18px !important;
}

.guide-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 24px 0 10px !important;
}

.guide-figure {
  margin: 0;
  justify-self: center;
  text-align: center;
}

.guide-frame {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 0 auto;
}

.guide-figure figcaption {
  margin-top: 10px;
  font-size: 13px;
  color: var(--ink-muted);
}

.guide-pick {
  max-width: 64ch;
  margin-top: 20px;
  padding: 16px 20px;
  border-radius: 14px;
  background: var(--brand-light, #e5f5f2);
  color: var(--ink);
}

/* Sections */
.guide-section {
  margin-top: 56px;
}

.guide-section h2 {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.guide-section h2 a {
  color: inherit;
}

.guide-specs {
  display: grid;
  margin: 16px 0 0;
  border-top: 1px solid var(--hairline);
}

.guide-specs > div {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--hairline);
}

.guide-specs dt {
  color: var(--ink-soft);
}

.guide-specs dd {
  margin: 0;
  font-weight: 600;
}

.guide-table {
  width: 100%;
  min-width: 520px;
  margin-top: 16px;
  border-collapse: collapse;
  font-size: 15px;
}

.guide-table th,
.guide-table td {
  padding: 12px 14px 12px 0;
  border-bottom: 1px solid var(--hairline);
  text-align: left;
  vertical-align: top;
}

.guide-table thead th {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-soft);
}

.guide-table tbody th {
  font-weight: 600;
}

.guide-table .mono {
  font-family: var(--font-mono);
  white-space: nowrap;
}

.guide-tips {
  display: grid;
  gap: 10px;
  max-width: 70ch;
  margin-top: 14px;
  padding-left: 22px;
}

/* Other sizes, as cards with a small frame drawn to scale */
.guide-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 14px;
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
}

.guide-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  height: 100%;
  padding: 16px;
  border: 1px solid var(--hairline);
  border-radius: 14px;
  background: var(--paper);
  color: var(--ink);
  text-decoration: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.guide-card:hover {
  border-color: var(--hairline-strong);
  box-shadow: var(--shadow-sm);
}

.guide-card .guide-figure {
  display: flex;
  align-items: flex-end;
  height: 100px;
  margin: 0;
}

.guide-card-name {
  font-weight: 600;
  line-height: 1.3;
}

.guide-card-size {
  font-size: 13px;
  color: var(--ink-muted);
}

.guide-faq {
  max-width: 72ch;
  margin: 16px 0 0;
}

.guide-faq dt {
  margin-top: 22px;
  font-weight: 600;
}

.guide-faq dd {
  margin: 6px 0 0;
  color: var(--ink-soft);
}

.guide-sources {
  margin-top: 40px;
}

@media (max-width: 760px) {
  .guide-hero {
    grid-template-columns: minmax(0, 1fr);
  }

  .guide-specs > div {
    grid-template-columns: minmax(0, 1fr);
    gap: 2px;
  }
}
