/* Upshot Magazine — Astra child theme */

:root {
  --up-navy: #00123a;
  --up-red: #e54a42;
  --up-grey: #f6f7f8;
  --up-muted: #6b7280;
  --up-line: #e5e7eb;
}

body,
body.ast-separate-container,
body.ast-plain-container {
  background: #ffffff;
  color: var(--up-navy);
  font-family: 'Cairo', system-ui, -apple-system, 'Segoe UI', Arial, sans-serif;
}

h1, h2, h3, h4, h5, h6,
.site-title, .site-title a {
  font-family: 'Rakkas', Georgia, serif;
  font-weight: 400;
  color: var(--up-navy);
}

a { color: var(--up-navy); }
a:hover { color: var(--up-red); }

/* Astra opens its own flex container; make it a plain full-width wrapper. */
#content.site-content > .ast-container,
#content.site-content > .ast-container.ast-two-container {
  display: block !important;
  width: 100% !important;
  max-width: 100% !important;
  padding: 0 !important;
  margin: 0 !important;
}
#content.site-content { padding: 0 !important; }

.up-wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ------------------------------------------------------------ TOP BAR */
.up-topbar {
  background: #fff;
  border-bottom: 1px solid var(--up-line);
}
.up-topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 46px;
}
.up-social { display: flex; align-items: center; gap: 16px; }
.up-social a { color: var(--up-navy); display: inline-flex; line-height: 0; }
.up-social a:hover { color: var(--up-red); }
.up-toplinks {
  display: flex;
  align-items: center;
  gap: 20px;
  font-family: 'Cairo', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
}
.up-toplinks a { text-decoration: none; color: var(--up-navy); }
.up-sub { color: var(--up-red); }
.up-searchlink { display: inline-flex; line-height: 0; }

/* ------------------------------------------------------------- HEADER */
.site-header,
#masthead {
  background: #fff;
}
.ast-primary-header-bar {
  background: #fff !important;
  border-bottom: 1px solid var(--up-line) !important;
  min-height: 0 !important;
  padding: 6px 0 0 !important;
}
.ast-primary-header-bar .site-branding { text-align: center; }

/* Stack logo above the menu, both centred (like the demo). */
.ast-primary-header-bar .ast-builder-grid-row {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 2px;
}
.ast-primary-header-bar .site-header-primary-section-left,
.ast-primary-header-bar .site-header-primary-section-right {
  width: 100% !important;
  justify-content: center !important;
}
.ast-primary-header-bar .ast-builder-menu-1,
.ast-primary-header-bar .main-header-bar-navigation,
.ast-primary-header-bar .main-navigation {
  width: 100%;
  justify-content: center;
}
.ast-primary-header-bar .main-header-menu {
  justify-content: center;
  flex-wrap: wrap;
  row-gap: 0;
}

.site-title, .site-title a {
  font-family: 'Rakkas', Georgia, serif !important;
  font-size: 46px !important;
  line-height: 1.1 !important;
  letter-spacing: .5px;
  color: var(--up-navy) !important;
  text-transform: none;
}
.site-description, .site-tagline { display: none !important; }

.main-header-menu .menu-link,
.ast-builder-menu-1 .menu-item > .menu-link,
.ast-builder-menu .menu-link {
  font-family: 'Rakkas', Georgia, serif !important;
  font-size: 17px !important;
  letter-spacing: .2px;
  color: var(--up-navy) !important;
  text-transform: capitalize;
  padding: 8px 13px !important;
  white-space: nowrap;
}
.main-header-menu .current-menu-item > .menu-link,
.ast-builder-menu-1 .current-menu-item > .menu-link {
  color: var(--up-red) !important;
}
.main-header-menu .menu-link:hover { color: var(--up-red) !important; }

/* --------------------------------------------------------------- HERO */
.up-hero { padding: 26px 0 0; }
.up-hero-card {
  display: block;
  position: relative;
  height: 600px;
  background-color: var(--up-navy);
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  overflow: hidden;
  text-decoration: none;
}
.up-hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg,
    rgba(0, 18, 58, .18) 0%,
    rgba(0, 18, 58, .58) 52%,
    rgba(0, 18, 58, .93) 100%);
}
.up-hero-body {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: block;
  padding: 44px 46px;
  max-width: 940px;
}
.up-kicker,
.up-hero-body .up-kicker {
  display: inline-block;
  background: #fff;
  border: 1px solid var(--up-red);
  color: var(--up-red);
  font-family: 'Cairo', sans-serif;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
  padding: 6px 10px;
  line-height: 1;
}
.up-hero-title {
  display: block;
  font-family: 'Rakkas', Georgia, serif;
  font-size: 62px;
  line-height: 1.05;
  color: #fff;
  margin: 18px 0 10px;
}
.up-hero-ex {
  display: block;
  font-family: 'Cairo', sans-serif;
  font-size: 15px;
  line-height: 1.65;
  color: #e8ebf3;
  margin-top: 14px;
  max-width: 780px;
}
.up-meta {
  font-family: 'Cairo', sans-serif;
  font-size: 12px;
  color: var(--up-muted);
  line-height: 1.4;
}
.up-hero-body .up-meta { color: #c7cee0; }

/* ----------------------------------------------------------- SECTIONS */
.up-section { padding: 34px 0 26px; }
.up-section.up-grey { background: var(--up-grey); }
.up-rule {
  border-top: 3px solid var(--up-red);
  margin-bottom: 16px;
}
.up-heading {
  font-family: 'Rakkas', Georgia, serif;
  font-size: 54px;
  line-height: 1;
  color: var(--up-navy);
  margin: 0 0 26px;
}
.up-head-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
}
.up-viewall {
  font-family: 'Cairo', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--up-red);
  text-decoration: none;
  white-space: nowrap;
}

.up-grid { display: grid; gap: 32px; }
.up-grid-4 { grid-template-columns: repeat(4, 1fr); }
.up-grid-3 { grid-template-columns: repeat(3, 1fr); }

/* -------------------------------------------------------------- CARDS */
.up-card { display: flex; flex-direction: column; }
.up-card-img {
  display: block;
  overflow: hidden;
  margin-bottom: 14px;
  background: var(--up-grey);
}
.up-card-img img {
  display: block;
  width: 100%;
  height: 190px;
  object-fit: cover;
  transition: transform .35s ease;
}
.up-card-img:hover img { transform: scale(1.04); }
.up-noimg {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 190px;
  background: linear-gradient(135deg, #00123a 0%, #0a2a6b 100%);
  color: #ffffff;
  font-family: 'Cairo', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
  margin-bottom: 14px;
}
.up-card .up-kicker {
  background: none;
  border: 0;
  padding: 0;
  margin-bottom: 8px;
  color: var(--up-red);
  text-decoration: none;
}
.up-card-title {
  font-family: 'Rakkas', Georgia, serif;
  font-size: 25px;
  line-height: 1.15;
  margin: 0 0 8px;
}
.up-card-title a { color: var(--up-navy); text-decoration: none; }
.up-card-title a:hover { color: var(--up-red); }

/* ------------------------------------------------------------ CONNECT */
.up-connect {
  background: var(--up-navy);
  padding: 54px 0;
  margin-top: 20px;
}
.up-connect-title {
  font-family: 'Rakkas', Georgia, serif;
  font-size: 44px;
  color: #fff;
  margin: 0 0 16px;
}
.up-connect-links {
  display: flex;
  flex-wrap: wrap;
  gap: 26px;
  font-family: 'Cairo', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
}
.up-connect-links a { color: #fff; text-decoration: none; }
.up-connect-links a:hover { color: var(--up-red); }

/* --------------------------------------------------------------- MISC */
.site-footer, .ast-footer-copyright {
  font-family: 'Cairo', sans-serif;
  color: var(--up-muted);
}

@media (max-width: 1024px) {
  .up-grid-4 { grid-template-columns: repeat(2, 1fr); }
  .up-grid-3 { grid-template-columns: repeat(2, 1fr); }
  .up-hero-card { height: 480px; }
  .up-hero-title { font-size: 46px; }
  .up-heading { font-size: 42px; }
  .site-title, .site-title a { font-size: 38px !important; }
}

@media (max-width: 640px) {
  .up-grid-4, .up-grid-3 { grid-template-columns: 1fr; }
  .up-hero-card { height: 420px; }
  .up-hero-body { padding: 24px 22px; }
  .up-hero-title { font-size: 33px; }
  .up-heading { font-size: 34px; }
  .up-hero-ex { display: none; }
  .up-topbar-inner { justify-content: center; }
  .up-social { display: none; }
}

/* ------------------------------------------------------------ MOBILE HEADER */
@media (max-width: 921px) {
  #ast-mobile-header .ast-primary-header-bar .ast-builder-grid-row {
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    justify-content: space-between !important;
    align-items: center !important;
    padding: 0 16px;
  }
  #ast-mobile-header .site-header-primary-section-left,
  #ast-mobile-header .site-header-primary-section-right {
    width: auto !important;
    justify-content: flex-start !important;
  }
  #ast-mobile-header .site-title,
  #ast-mobile-header .site-title a {
    font-size: 30px !important;
    white-space: nowrap;
  }
  #ast-mobile-header .menu-toggle { padding: 8px; }
}
@media (max-width: 480px) {
  #ast-mobile-header .site-title,
  #ast-mobile-header .site-title a { font-size: 26px !important; letter-spacing: 0; }
  .up-hero-card { height: 390px; }
  .up-hero-title { font-size: 28px; }
  .up-heading { font-size: 32px; }
  .up-wrap { padding: 0 16px; }
}
