/* The editorial treatment belongs to the four Kreluna homepages. */
body.premium-site.home-editorial {
  --home-blue: #0864ec;
  --home-red: #e2261b;
  --home-yellow: #f5ad00;
  --home-green: #008c3d;
  --home-spectrum: var(--home-blue) 0 25%, var(--home-red) 25% 50%,
    var(--home-yellow) 50% 75%, var(--home-green) 75% 100%;
}

body.premium-site.home-editorial .shell {
  width: min(1320px, calc(100% - 48px));
}

.home-editorial .premium-header .desktop-nav { gap: clamp(12px, 2vw, 28px); margin-inline: 0; }
.home-editorial .premium-header .header-inner { column-gap: clamp(10px, 1.25vw, 22px); }
.home-editorial .premium-header .header-contact { border-radius: 7px; min-height: 44px; }
.home-editorial .premium-brand { gap: 8px; }
.home-editorial .premium-brand > img { width: 36px; height: 36px; }
.home-editorial .premium-brand > span { font-size: 28px; }
.home-editorial .premium-brand small { margin-top: 6px; letter-spacing: 3px; }

body.premium-site.home-editorial .premium-hero {
  grid-template-columns: minmax(0, 1.03fr) minmax(0, 1fr);
  gap: clamp(28px, 5vw, 76px);
  padding-block: clamp(52px, 7vw, 108px) clamp(42px, 6vw, 88px);
}

body.premium-site.home-editorial .hero-copy h1 {
  font-size: clamp(46px, 6.1vw, 94px);
  font-weight: 800;
  line-height: .99;
  letter-spacing: -.064em;
  text-wrap: pretty;
}

.home-editorial .hero-copy .eyebrow { margin-bottom: 18px; font-size: 11px; letter-spacing: .14em; }
body.premium-site.home-editorial .hero-copy .eyebrow {
  display: flex;
  align-items: center;
  gap: 8px;
}

body.premium-site.home-editorial .hero-copy .eyebrow::before {
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
  content: "";
  background: linear-gradient(115deg, var(--home-spectrum));
  mask: url("/mask-icon.svg") center / 23px no-repeat;
}

.home-editorial .hero-lead { max-width: 45ch; font-size: clamp(16px, 1.45vw, 20px); line-height: 1.55; }
.home-editorial .hero-actions { gap: 14px 22px; }
.home-editorial .hero-actions .primary-link { border-radius: 7px; }
.home-editorial .hero-actions .text-link { font-weight: 700; }

body.premium-site.home-editorial .hero-project {
  position: relative;
  isolation: isolate;
  padding: clamp(15px, 2.5vw, 36px);
}

body.premium-site.home-editorial .hero-project::before,
body.premium-site.home-editorial .hero-project::after {
  position: absolute;
  z-index: -1;
  content: "";
  pointer-events: none;
}

body.premium-site.home-editorial .hero-project::before {
  inset: 0;
  border: 1px solid var(--premium-line);
  border-radius: 16px;
  background:
    linear-gradient(90deg, var(--home-spectrum)) center top / 100% 4px no-repeat,
    radial-gradient(ellipse at 92% 12%, #dceaff, transparent 50%),
    radial-gradient(ellipse at 14% 16%, #fce5e2, transparent 44%),
    radial-gradient(ellipse at 8% 90%, #fff1cd, transparent 52%),
    radial-gradient(ellipse at 90% 92%, #e0f3e7, transparent 47%),
    #f8faff;
}

body.premium-site.home-editorial .hero-project::after {
  right: 0;
  top: 0;
  width: 44%;
  aspect-ratio: 1;
  background: linear-gradient(135deg, var(--home-spectrum));
  opacity: .26;
  mask: url("/mask-icon.svg") center / 100% no-repeat;
}

body.premium-site.home-editorial .hero-project .project-cover {
  padding: 0 9% 4% 0;
  position: relative;
  background: none;
  box-shadow: none;
  border: 0;
}

body.premium-site.home-editorial .hero-project .project-visual {
  border: 1px solid #302d2b;
  border-radius: 10px;
  box-shadow: 0 18px 32px #352b2326;
  overflow: hidden;
}

.home-editorial .home-hero-phone {
  position: absolute;
  z-index: 1;
  right: 0;
  bottom: 0;
  width: 24%;
  height: auto;
  border: 3px solid #302d2b;
  border-radius: clamp(8px, 1.3vw, 16px);
  box-shadow: 0 9px 20px #352b2340;
}

body.premium-site.home-editorial .hero-project figcaption {
  margin-top: 14px;
  gap: 8px 14px;
  font-size: 12px;
  letter-spacing: 0;
  flex-wrap: wrap;
}

body.premium-site.home-editorial .portfolio-home {
  border-top: 1px solid var(--premium-line);
  background: linear-gradient(90deg, var(--home-spectrum)) left top / 112px 4px no-repeat;
  padding-block: clamp(26px, 4.5vw, 62px);
}

body.premium-site.home-editorial .portfolio [data-portfolio-group="real"] {
  display: block;
  padding: 0;
  margin: 0;
  background: transparent;
  box-shadow: none;
  border: 0;
}

body.premium-site.home-editorial .portfolio-intro {
  margin: 0 0 24px;
  padding: 0;
  border: 0;
}

body.premium-site.home-editorial .portfolio [data-portfolio-group="real"] .portfolio-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-auto-rows: auto;
  gap: clamp(12px, 1.5vw, 22px);
}

body.premium-site.home-editorial .portfolio [data-portfolio-group="real"] .portfolio-card {
  position: relative;
  min-width: 0;
  border-color: var(--premium-line);
  background: var(--dark-surface);
  border-radius: 12px;
}

body.premium-site.home-editorial .portfolio [data-portfolio-group="real"] .portfolio-grid > .portfolio-card {
  border-top: 4px solid var(--project-accent, var(--home-blue));
}

.home-editorial .portfolio-grid > .portfolio-card:nth-child(4n + 2) { --project-accent: var(--home-red); }
.home-editorial .portfolio-grid > .portfolio-card:nth-child(4n + 3) { --project-accent: var(--home-yellow); }
.home-editorial .portfolio-grid > .portfolio-card:nth-child(4n) { --project-accent: var(--home-green); }

body.premium-site.home-editorial .portfolio [data-portfolio-group="real"] .portfolio-cover {
  height: auto;
  min-height: 0;
  aspect-ratio: 16 / 9;
}

/* The homepage is a selection. The project directory retains the full portfolio. */
body.premium-site.home-editorial .portfolio-grid > .portfolio-card:nth-child(n + 9) {
  display: none;
}

body.premium-site.home-editorial .portfolio [data-portfolio-group="real"] .portfolio-card-body {
  padding: 12px;
}

body.premium-site.home-editorial .portfolio [data-portfolio-group="real"] .portfolio-card-body h3 {
  color: var(--premium-ink);
  font-size: clamp(16px, 1.5vw, 21px);
}

body.premium-site.home-editorial .portfolio [data-portfolio-group="real"] .portfolio-meta {
  color: var(--premium-muted);
  margin-bottom: 6px;
}

.home-editorial .home-project-link {
  display: inline-block;
  text-decoration: none;
}

.home-editorial .home-project-link::after {
  position: absolute;
  inset: 0;
  content: "";
}

.home-editorial .portfolio-card:hover .home-project-link,
.home-editorial .home-project-link:focus-visible {
  color: var(--site-link);
  text-decoration: underline;
}

body.premium-site.home-editorial .portfolio [data-portfolio-group="real"] .portfolio-badge.is-online {
  background: var(--premium-lime);
  border-color: var(--premium-lime);
  color: var(--site-link);
}

body.premium-site.home-editorial .premium-footer,
body.premium-site.home-editorial .studio-section { box-shadow: none; }

@media (max-width: 1020px) {
  body.premium-site.home-editorial .portfolio [data-portfolio-group="real"] .portfolio-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
  body.premium-site.home-editorial .premium-hero { grid-template-columns: minmax(0, 1fr); }
  body.premium-site.home-editorial .hero-copy h1 { font-size: clamp(42px, 8.7vw, 70px); }
  body.premium-site.home-editorial .hero-project { width: min(100%, 650px); }
}

@media (max-width: 620px) {
  body.premium-site.home-editorial .shell { width: calc(100% - 36px); }
  body.premium-site.home-editorial .premium-hero { padding-block: 36px 38px; gap: 26px; }
  body.premium-site.home-editorial .hero-copy h1 { font-size: clamp(34px, 10.5vw, 56px); }
  body.premium-site.home-editorial .hero-lead { margin-top: 16px !important; }
  body.premium-site.home-editorial .hero-actions { margin-top: 20px; }
  body.premium-site.home-editorial .hero-actions .primary-link { width: 100%; }
  body.premium-site.home-editorial .portfolio [data-portfolio-group="real"] .portfolio-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  body.premium-site.home-editorial .portfolio [data-portfolio-group="real"] .portfolio-card-body { padding: 9px; }
  body.premium-site.home-editorial .portfolio [data-portfolio-group="real"] .portfolio-badge.is-online { display: none; }
}

@media (max-width: 350px) {
  body.premium-site.home-editorial .portfolio [data-portfolio-group="real"] .portfolio-grid { grid-template-columns: minmax(0, 1fr); }
}
