/* ============================================================
   home.css — homepage-only Apple/iOS-style enhancement.
   Loaded only on index.html via injected <link>.
   Removing this file or its <link> reverts the homepage alone.
   ============================================================ */

/* ---------- HERO BANNER ---------- */
.apl-hero {
  position: relative;
  width: 100%;
  height: clamp(440px, 72vh, 760px);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 0 56px;
  isolation: isolate;
}
.apl-hero-bg {
  position: absolute;
  inset: 0;
  background-image: url('/_modern/hero.jpg');
  background-size: cover;
  background-position: center center;
  animation: aplHeroPan 22s ease-in-out infinite alternate;
  transform: scale(1.06);
  z-index: 0;
}
@keyframes aplHeroPan {
  from { transform: scale(1.06) translate(-1%, -0.8%); }
  to   { transform: scale(1.12) translate(1%, 0.8%); }
}
.apl-hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(180deg, rgba(0,18,40,0.35) 0%, rgba(0,18,40,0.10) 32%, rgba(0,18,40,0.65) 100%),
    radial-gradient(at 50% 55%, rgba(0,0,0,0) 0%, rgba(0,0,0,0.35) 100%);
}
.apl-hero-inner {
  position: relative;
  z-index: 2;
  max-width: 920px;
  text-align: center;
  padding: 24px 24px;
  color: #fff;
}
.apl-hero-eyebrow {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(255,255,255,0.16);
  border: 1px solid rgba(255,255,255,0.26);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  color: rgba(255,255,255,0.95);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  margin-bottom: 18px;
  animation: aplHeroFade .9s cubic-bezier(0.16, 1, 0.3, 1) backwards;
}
.apl-hero-title {
  font-size: clamp(40px, 7.5vw, 86px) !important;
  font-weight: 800 !important;
  letter-spacing: -0.035em !important;
  line-height: 1.05 !important;
  color: #fff !important;
  margin: 0 0 18px !important;
  text-shadow: 0 2px 24px rgba(0,0,0,0.35);
  animation: aplHeroFade 1s cubic-bezier(0.16, 1, 0.3, 1) .05s backwards;
}
.apl-hero-subtitle {
  font-size: clamp(17px, 2.1vw, 24px) !important;
  font-weight: 400 !important;
  color: rgba(255,255,255,0.92) !important;
  margin: 0 0 36px !important;
  letter-spacing: -0.005em;
  max-width: 640px;
  margin-left: auto !important;
  margin-right: auto !important;
  animation: aplHeroFade 1s cubic-bezier(0.16, 1, 0.3, 1) .15s backwards;
}
.apl-hero-cta {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
  animation: aplHeroFade 1s cubic-bezier(0.16, 1, 0.3, 1) .25s backwards;
}
.apl-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 30px;
  border-radius: 980px;
  font-weight: 500;
  font-size: 17px;
  letter-spacing: -0.01em;
  text-decoration: none !important;
  transition: background .25s ease, transform .15s ease, box-shadow .25s ease, color .2s ease !important;
  cursor: pointer;
  border: none;
}
.apl-btn-primary {
  background: #007aff !important;
  color: #fff !important;
  box-shadow: 0 6px 20px rgba(0,122,255,0.45);
}
.apl-btn-primary:hover {
  background: #0058b8 !important;
  transform: translateY(-1px);
  box-shadow: 0 10px 28px rgba(0,122,255,0.55);
  color: #fff !important;
}
.apl-btn-ghost {
  background: rgba(255,255,255,0.18) !important;
  color: #fff !important;
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border: 1px solid rgba(255,255,255,0.30) !important;
}
.apl-btn-ghost:hover {
  background: rgba(255,255,255,0.28) !important;
  transform: translateY(-1px);
  color: #fff !important;
}
@keyframes aplHeroFade {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}
.apl-hero-scroll {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  width: 26px;
  height: 42px;
  border: 2px solid rgba(255,255,255,0.55);
  border-radius: 20px;
  z-index: 2;
}
.apl-hero-scroll::after {
  content: "";
  position: absolute;
  top: 8px;
  left: 50%;
  transform: translateX(-50%);
  width: 3px;
  height: 8px;
  border-radius: 2px;
  background: #fff;
  animation: aplScroll 2.4s ease-in-out infinite;
}
@keyframes aplScroll {
  0%   { transform: translate(-50%, 0); opacity: 1; }
  60%  { transform: translate(-50%, 12px); opacity: 0; }
  100% { transform: translate(-50%, 0); opacity: 0; }
}
/* Hero responsive: scale down on smaller laptops/tablets/phones */
@media (max-width: 1279px) {
  .apl-hero { height: clamp(420px, 64vh, 640px); margin-bottom: 48px; }
}
@media (max-width: 1023px) {
  .apl-hero { height: clamp(400px, 60vh, 560px); margin-bottom: 40px; }
  .apl-hero-inner { padding: 20px 20px; }
}
@media (max-width: 768px) {
  .apl-hero { height: clamp(360px, 56vh, 500px); margin-bottom: 32px; }
  .apl-btn { padding: 12px 22px; font-size: 16px; }
  .apl-hero-scroll { display: none; }
}
@media (max-width: 480px) {
  .apl-hero { height: clamp(320px, 52vh, 440px); }
  .apl-hero-cta { flex-direction: column; align-items: stretch; }
  .apl-btn { justify-content: center; }
}
@media (prefers-reduced-motion: reduce) {
  .apl-hero-bg { animation: none; transform: scale(1.05); }
  .apl-hero-eyebrow,
  .apl-hero-title,
  .apl-hero-subtitle,
  .apl-hero-cta { animation: none; }
  .apl-hero-scroll::after { animation: none; }
}

/* ---------- Kill the huge vh-based dead space on the homepage main rows ---------- */
.main-rows .uc-row > .row-container,
.main-rows .uc-row .column[style*="vh"] {
  padding-top: 56px !important;
  padding-bottom: 56px !important;
}
@media (max-width: 768px) {
  .main-rows .uc-row > .row-container { padding: 16px 0 !important; }
  .main-rows .uc-row .column[style*="vh"],
  .main-rows .uc-row .row .column { padding-top: 0 !important; padding-bottom: 0 !important; }
}
@media (max-width: 639px) {
  .main-rows .uc-row > .row-container { padding: 8px 0 !important; }
}

/* ---------- Hero band a bit more open ---------- */
body main, body .page-content { padding-top: 8px; }

/* ============================================================
   FEATURED 3-CARD ROW (Ползи / История / Цени) — Apple-clean v3
   Centered icon-on-top design, solid white, clear "Прочети повече" link,
   whole card clickable via overlay <a>.
   ============================================================ */

.row .column.col-sm-4 {
  display: flex;
  padding: 0 !important;
}

.row .column.col-sm-4 > .column-container {
  flex: 1;
  position: relative;
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 22px;
  padding: 40px 32px 36px !important;
  margin: 14px 10px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04),
              0 6px 24px rgba(0, 0, 0, 0.04);
  transition: transform .35s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow .35s ease,
              border-color .3s ease;
  display: flex !important;
  flex-direction: column;
  align-items: center;
  text-align: center;
  cursor: pointer;
  overflow: hidden;
}

.row .column.col-sm-4 > .column-container:hover {
  transform: translateY(-6px);
  border-color: rgba(0, 122, 255, 0.30);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06),
              0 24px 60px rgba(0, 0, 0, 0.09);
}

/* ----- Card title with centered icon above ----- */
.row .column.col-sm-4 .ModuleTitle h4 {
  margin: 88px 0 12px !important;
  padding: 0 !important;
  font-size: 26px !important;
  letter-spacing: -0.022em !important;
  font-weight: 700 !important;
  line-height: 1.18 !important;
  color: #1d1d1f !important;
  position: relative;
}
.row .column.col-sm-4 .ModuleTitle h4::before {
  content: "";
  position: absolute;
  left: 50%;
  top: -76px;
  transform: translateX(-50%);
  width: 64px;
  height: 64px;
  border-radius: 18px;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 32px 32px;
  transition: transform .35s cubic-bezier(0.16, 1, 0.3, 1);
}
.row .column.col-sm-4:hover .ModuleTitle h4::before {
  transform: translateX(-50%) scale(1.06);
}

/* Per-card icon tile colors */
.row .column.col-sm-4:nth-of-type(1) .ModuleTitle h4::before {
  background-color: rgba(52, 199, 89, 0.14);
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%2334c759'><path d='M12 21.35l-1.45-1.32C5.4 15.36 2 12.28 2 8.5 2 5.42 4.42 3 7.5 3c1.74 0 3.41.81 4.5 2.09C13.09 3.81 14.76 3 16.5 3 19.58 3 22 5.42 22 8.5c0 3.78-3.4 6.86-8.55 11.54L12 21.35z'/></svg>");
}
.row .column.col-sm-4:nth-of-type(2) .ModuleTitle h4::before {
  background-color: rgba(255, 149, 0, 0.14);
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23ff9500'><path d='M12 8a4 4 0 100 8 4 4 0 000-8zm0-6a10 10 0 110 20 10 10 0 010-20zm0 18a8 8 0 100-16 8 8 0 000 16zm1-13h-2v5h5v-2h-3z'/></svg>");
}
.row .column.col-sm-4:nth-of-type(3) .ModuleTitle h4::before {
  background-color: rgba(0, 122, 255, 0.14);
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23007aff'><path d='M11.8 10.9c-2.27-.59-3-1.2-3-2.15 0-1.09 1.01-1.85 2.7-1.85 1.78 0 2.44.85 2.5 2.1h2.21c-.07-1.72-1.12-3.3-3.21-3.81V3h-3v2.16c-1.94.42-3.5 1.68-3.5 3.61 0 2.31 1.91 3.46 4.7 4.13 2.5.6 3 1.48 3 2.41 0 .69-.49 1.79-2.7 1.79-2.06 0-2.87-.92-2.98-2.1h-2.2c.12 2.19 1.76 3.42 3.68 3.83V21h3v-2.15c1.95-.37 3.5-1.5 3.5-3.55 0-2.84-2.43-3.81-4.7-4.4z'/></svg>");
}

/* Hide divider */
.row .column.col-sm-4 .ModuleDivider { display: none !important; }

/* Body paragraph */
.row .column.col-sm-4 .ModuleParagraph .uc-content,
.row .column.col-sm-4 .ModuleParagraph p {
  color: #6e6e73 !important;
  font-size: 16px !important;
  line-height: 1.55 !important;
  margin: 0 0 20px !important;
  font-weight: 400 !important;
  flex: 1;
}

/* Reset internal module-container padding */
.row .column.col-sm-4 .module-container {
  padding: 0 !important;
  margin-bottom: 0 !important;
  width: 100%;
}

/* Visible "Прочети повече →" link button at the bottom of each card */
.row .column.col-sm-4 > .column-container::after {
  content: "Прочети повече →";
  display: inline-flex;
  align-items: center;
  margin-top: auto;
  padding: 8px 18px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.01em;
  background: rgba(0, 122, 255, 0.10);
  color: #007aff;
  transition: background .25s ease, transform .25s ease, color .2s ease;
}
.row .column.col-sm-4:nth-of-type(1) > .column-container::after {
  background: rgba(52, 199, 89, 0.12);
  color: #34c759;
}
.row .column.col-sm-4:nth-of-type(2) > .column-container::after {
  background: rgba(255, 149, 0, 0.12);
  color: #ff9500;
}
.row .column.col-sm-4:nth-of-type(3) > .column-container::after {
  background: rgba(0, 122, 255, 0.12);
  color: #007aff;
}
.row .column.col-sm-4:hover > .column-container::after {
  transform: translateX(3px);
  filter: brightness(0.96);
}

/* Subtle staggered fade-in on load */
@keyframes homeFadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}
.row .column.col-sm-4 > .column-container {
  animation: homeFadeUp .7s cubic-bezier(0.16, 1, 0.3, 1) backwards;
}
.row .column.col-sm-4:nth-of-type(1) > .column-container { animation-delay: .05s; }
.row .column.col-sm-4:nth-of-type(2) > .column-container { animation-delay: .15s; }
.row .column.col-sm-4:nth-of-type(3) > .column-container { animation-delay: .25s; }

/* ---------- Cards responsive ----------
   ≥1024: 3 cols (default col-sm-4)
   640-1023: 2 cols
   <640: 1 col
*/
@media (max-width: 1279px) {
  .row .column.col-sm-4 > .column-container {
    padding: 44px 30px 36px !important;
    margin: 12px 8px;
  }
  .row .column.col-sm-4 .ModuleTitle h4 { font-size: 26px !important; }
}
@media (max-width: 1023px) {
  .row .column.col-sm-4 {
    flex-basis: 50% !important;
    max-width: 50% !important;
  }
  .row .column.col-sm-4 > .column-container {
    margin: 8px;
    padding: 40px 28px 32px !important;
  }
}
@media (max-width: 639px) {
  /* Phone: flip card layout from "icon-on-top centered" to "icon-on-left compact". */
  .row .column.col-sm-4 {
    flex-basis: 100% !important;
    max-width: 100% !important;
  }
  .row .column.col-sm-4 > .column-container {
    margin: 5px 0;
    padding: 16px 18px 16px !important;
    border-radius: 18px;
    align-items: stretch !important;
    text-align: left !important;
  }
  /* Title: icon to the LEFT, vertically centered with the text — no big top margin */
  .row .column.col-sm-4 .ModuleTitle h4 {
    margin: 0 0 8px !important;
    padding: 0 0 0 48px !important;
    font-size: 19px !important;
    line-height: 1.25 !important;
    min-height: 38px;
    display: flex !important;
    align-items: center;
    position: relative;
    text-align: left;
  }
  .row .column.col-sm-4 .ModuleTitle h4::before {
    left: 0 !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    width: 38px !important;
    height: 38px !important;
    border-radius: 11px !important;
    background-size: 22px 22px !important;
  }
  .row .column.col-sm-4:hover .ModuleTitle h4::before {
    transform: translateY(-50%) scale(1.06) !important;
  }
  .row .column.col-sm-4 .ModuleParagraph p {
    font-size: 14.5px !important;
    line-height: 1.5 !important;
    margin: 0 0 12px !important;
    text-align: left;
  }
  /* "Прочети повече" pill: align left, compact */
  .row .column.col-sm-4 > .column-container::after {
    align-self: flex-start;
    margin-top: 0;
    padding: 6px 14px;
    font-size: 13px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .row .column.col-sm-4 > .column-container { animation: none; }
  .row .column.col-sm-4:hover > .column-container { transform: none; }
  .row .column.col-sm-4:hover .ModuleTitle h4::before { transform: none; }
  .row .column.col-sm-4:hover > .column-container::after { transform: none; }
}

/* ---------- Headings overall ---------- */
h1, .ModuleTitle h1, h2, .ModuleTitle h2 {
  letter-spacing: -0.028em !important;
}

/* ============================================================
   NEWS SECTION (homepage) — Apple/iOS card grid
   ============================================================ */
.apl-news {
  padding: 64px 24px 88px;
  max-width: 1280px;
  margin: 0 auto;
}
.apl-news-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 36px;
}
.apl-news-head-text { flex: 1; min-width: 0; }
.apl-news-eyebrow {
  display: block;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #007aff;
  margin-bottom: 10px;
}
.apl-news-title {
  font-size: clamp(28px, 4vw, 44px) !important;
  font-weight: 700 !important;
  letter-spacing: -0.028em !important;
  line-height: 1.1 !important;
  margin: 0 !important;
  color: #1d1d1f !important;
}
.apl-news-all {
  font-size: 15px;
  font-weight: 500;
  color: #007aff !important;
  text-decoration: none !important;
  white-space: nowrap;
  align-self: center;
}
.apl-news-all:hover { color: #0058b8 !important; }

.apl-news-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.apl-news-card {
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 20px;
  overflow: hidden;
  transition: transform .4s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow .4s ease,
              border-color .3s ease;
  display: flex;
  flex-direction: column;
  animation: aplNewsFade .7s cubic-bezier(0.16, 1, 0.3, 1) backwards;
}
.apl-news-card:nth-child(1) { animation-delay: .05s; }
.apl-news-card:nth-child(2) { animation-delay: .12s; }
.apl-news-card:nth-child(3) { animation-delay: .19s; }
.apl-news-card:nth-child(4) { animation-delay: .26s; }
.apl-news-card:hover {
  transform: translateY(-4px);
  border-color: rgba(0, 0, 0, 0.10);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04),
              0 16px 40px rgba(0, 0, 0, 0.08);
}
.apl-news-link {
  display: flex !important;
  flex-direction: column;
  height: 100%;
  text-decoration: none !important;
  color: inherit !important;
}
.apl-news-media {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #f5f5f7;
}
.apl-news-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 0 !important;
  transition: transform .6s cubic-bezier(0.16, 1, 0.3, 1);
}
.apl-news-card:hover .apl-news-media img { transform: scale(1.05); }

.apl-news-body {
  padding: 22px 22px 24px;
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 8px;
}
.apl-news-h {
  font-size: 18px !important;
  font-weight: 600 !important;
  letter-spacing: -0.015em !important;
  line-height: 1.3 !important;
  color: #1d1d1f !important;
  margin: 0 !important;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.apl-news-excerpt {
  font-size: 14.5px;
  color: #6e6e73;
  line-height: 1.5;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
}
.apl-news-cta {
  display: inline-block;
  font-size: 14px;
  font-weight: 500;
  color: #007aff;
  letter-spacing: -0.01em;
  margin-top: 6px;
  transition: transform .25s ease;
}
.apl-news-card:hover .apl-news-cta { transform: translateX(4px); }

@keyframes aplNewsFade {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ============================================================
   BENEFITS SECTION — 3 clean vertical tiles, links to /ползи.html
   Light gray section background to break the rhythm from cards/news.
   ============================================================ */
.apl-benefits {
  background: #f5f5f7;
  border-top: 1px solid rgba(0, 0, 0, 0.05);
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  padding: 64px 24px 72px;
}
.apl-benefits-inner {
  max-width: 1180px;
  margin: 0 auto;
}
.apl-benefits-head {
  text-align: center;
  margin: 0 auto 40px;
  max-width: 720px;
}
.apl-benefits-eyebrow {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #007aff;
  margin: 0 0 10px;
}
.apl-benefits-title {
  font-size: clamp(26px, 3.2vw, 38px) !important;
  font-weight: 700 !important;
  letter-spacing: -0.026em !important;
  line-height: 1.12 !important;
  margin: 0 !important;
  color: #1d1d1f !important;
}
.apl-benefits-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.apl-benefit-tile {
  position: relative;
  display: flex !important;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 32px 24px 28px;
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 20px;
  text-decoration: none !important;
  color: #1d1d1f !important;
  transition: transform .3s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow .3s ease,
              border-color .2s ease;
}
.apl-benefit-tile:hover {
  transform: translateY(-4px);
  border-color: rgba(0, 0, 0, 0.10);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.05),
              0 20px 48px rgba(0, 0, 0, 0.07);
}
.apl-benefit-icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  transition: transform .3s cubic-bezier(0.16, 1, 0.3, 1);
}
.apl-benefit-tile:hover .apl-benefit-icon { transform: scale(1.06); }
.apl-benefit-icon svg {
  width: 28px;
  height: 28px;
  display: block;
}
.apl-benefit-tile:nth-child(1) .apl-benefit-icon {
  background: rgba(52, 199, 89, 0.14);
}
.apl-benefit-tile:nth-child(1) .apl-benefit-icon svg { color: #34c759; fill: #34c759; }
.apl-benefit-tile:nth-child(2) .apl-benefit-icon {
  background: rgba(0, 122, 255, 0.14);
}
.apl-benefit-tile:nth-child(2) .apl-benefit-icon svg { color: #007aff; fill: #007aff; }
.apl-benefit-tile:nth-child(3) .apl-benefit-icon {
  background: rgba(255, 149, 0, 0.14);
}
.apl-benefit-tile:nth-child(3) .apl-benefit-icon svg { color: #ff9500; fill: #ff9500; }

.apl-benefit-h {
  font-size: 19px !important;
  font-weight: 600 !important;
  color: #1d1d1f !important;
  margin: 0 0 8px !important;
  letter-spacing: -0.018em !important;
  line-height: 1.25 !important;
}
.apl-benefit-d {
  font-size: 14.5px;
  color: #6e6e73;
  line-height: 1.5;
  margin: 0 0 16px;
}
.apl-benefit-cta {
  display: inline-block;
  margin-top: auto;
  font-size: 14px;
  font-weight: 500;
  color: #007aff;
  transition: transform .25s ease;
}
.apl-benefit-tile:hover .apl-benefit-cta { transform: translateX(4px); }

@media (max-width: 899px) {
  .apl-benefits-grid { grid-template-columns: repeat(2, 1fr); }
  .apl-benefits { padding: 52px 20px 56px; }
}
@media (max-width: 560px) {
  .apl-benefits-grid { grid-template-columns: 1fr; gap: 16px; }
  .apl-benefits-head { margin-bottom: 28px; }
  .apl-benefit-tile { padding: 28px 22px 24px; }
}

/* ============================================================
   Top 3 cards (Ползи / История / Цени) — make each clickable
   via an absolute-positioned overlay <a>.
   ============================================================ */
.apl-card-link {
  position: absolute !important;
  inset: 0 !important;
  z-index: 5 !important;
  border-radius: inherit;
  text-decoration: none !important;
  outline: none;
  cursor: pointer;
  display: block;
}
/* Card content sits below the overlay link */
.row .column.col-sm-4 > .column-container > *:not(.apl-card-link) {
  position: relative;
  z-index: 1;
  pointer-events: none;     /* let clicks fall through to the overlay link */
}
.apl-card-link:focus-visible {
  outline: 3px solid rgba(0, 122, 255, 0.5);
  outline-offset: 4px;
}

/* News grid responsive: 4 → 3 → 2 → 1 */
@media (max-width: 1279px) {
  .apl-news-grid { grid-template-columns: repeat(3, 1fr); }
  .apl-news { padding: 56px 22px 72px; }
}
@media (max-width: 899px) {
  .apl-news-grid { grid-template-columns: repeat(2, 1fr); gap: 20px; }
  .apl-news { padding: 48px 20px 64px; }
}
@media (max-width: 599px) {
  .apl-news-grid { grid-template-columns: 1fr; gap: 18px; }
  .apl-news { padding: 40px 16px 56px; }
  .apl-news-head { margin-bottom: 22px; }
  .apl-news-all { align-self: flex-start; }
  .apl-news-body { padding: 18px 18px 20px; }
}

@media (prefers-reduced-motion: reduce) {
  .apl-news-card { animation: none; }
  .apl-news-card:hover { transform: none; }
  .apl-news-card:hover .apl-news-media img { transform: none; }
  .apl-news-card:hover .apl-news-cta { transform: none; }
}
