:root {
  --white: #ffffff;
  --blue: #05167f;
  --cyan: #00c8ff;
  --yellow: #ffc928;
  --card-border: rgba(255, 255, 255, 0.72);
  --card-bg: rgba(255, 255, 255, 0.025);
  --card-hover: rgba(255, 255, 255, 0.28);
  --text-muted: rgba(255, 255, 255, 0.68);
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Raleway", sans-serif;
  font-variant-numeric: lining-nums;
  color: var(--white);
  background:
    linear-gradient(155.7deg, #010d8e 0%, #000428 104.1%);
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: url("img/back.png");
  background-repeat: no-repeat;
  background-position: center top;
  background-size: cover;
  opacity: 0.06;
  pointer-events: none;
  z-index: 0;
}
ul {
  margin: 0;
  padding: 0;
}
ul li {
  list-style: none;
}

.page {
  position: relative;
  z-index: 1;
  width: min(1328px, calc(100% - 48px));
  margin: 0 auto;
  padding: 50px 0 50px;
}

.hero {
  min-height: 260px;
}

.hero__content {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: start;
}

.hero__text {
  padding-left: 6px;
}

.hero h1 {
  margin: 0;
  font-size: clamp(54px, 5.1vw, 86px);
  line-height: 1.08;
  font-weight: 800;
  letter-spacing: -0.045em;
}

.hero p {
  margin: 34px 0 0;
  color: var(--text-muted);
  font-size: clamp(18px, 1.25vw, 22px);
  line-height: 1.45;
  font-weight: 400;
}

.hero__logo {
  width: 85px;
  height: auto;
  margin-top: 32px;
  margin-right: 54px;
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  width: min(800px, 100%);
  margin: 72px auto 84px;
  align-items: center;
}

.stat {
  position: relative;
  text-align: center;
  padding: 0 46px;
}

.stat--bordered {
  border-left: 2px solid rgba(255, 255, 255, 0.7);
  border-right: 2px solid rgba(255, 255, 255, 0.7);
}

.stat__number {
  font-size: clamp(58px, 5vw, 78px);
  line-height: 0.9;
  font-weight: 800;
  font-variant-numeric: oldstyle-nums;
}

.stat__label {
  margin-top: 12px;
  font-size: clamp(26px, 2vw, 34px);
  line-height: 1;
  font-weight: 700;
  letter-spacing: -0.04em;
}

.resources {
  display: grid;
  grid-template-columns: repeat(3, 30%);
  gap: 35px 40px;
}

.resource-card {
  position: relative;
  display: grid;
  grid-template-columns: 106px 1px 1fr 38px;
  align-items: center;
  min-height: 138px;
  padding: 18px 19px 18px 32px;
  color: var(--white);
  text-decoration: none;
  border: 1px solid var(--card-border);
  border-radius: 10px;
  background: var(--card-bg);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.015),
    0 14px 40px rgba(0, 0, 0, 0.08);
  transition:
    background-color 0.22s ease,
    transform 0.22s ease,
    border-color 0.22s ease,
    box-shadow 0.22s ease;
}

.card:hover {
  background: var(--card-hover);
  border-color: rgba(255, 255, 255, 0.9);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.04),
    0 18px 48px rgba(0, 0, 0, 0.18);
}

.card {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    border: 1px solid #adf2f7;
    border-image: linear-gradient(to left top,#adf2f7 10%,  transparent 30%, transparent 70%, #adf2f7 90%);
    border-radius: 17px;
    background: transparent;
    position: relative;
    padding: 20px;
    z-index: 2;
    transition: background-color 1s ease-in-out;
}

.card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 17px; /* Тот же радиус, что у родителя */
  padding: 1px; /* ТОЛЩИНА ОБВОДКИ */
  
  /* Градиент для обводки */
  background: linear-gradient(45deg, #fff, #3845DA); 
  
  /* Магия маскирования: вырезает внутреннюю часть */
  -webkit-mask: 
    linear-gradient(#fff 0 0) content-box, 
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
          
  /* pointer-events: none;  */
}

.resource-card__icon img {
  display: block;
  width: 68px;
  height: 68px;
  object-fit: contain;
  margin: 11px 0px 0 0;
    border-right: 1px solid #fff;
    padding: 0 16px 0 0;
}

.resource-card__divider {
  width: 1px;
  height: 100px;
  background: rgba(255, 255, 255, 0.82);
}

.resource-card__body {
  padding-left: 20px;
  padding-right: 8px;
  display: flex;
    flex-direction: column;
    justify-content: center;
}

.resource-card__body h2 {
  margin: 0;
  font-size: clamp(18px, 1.25vw, 20px);
  line-height: 1.08;
  font-weight: 700;

}
.card_link::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 100; /* Покрывает карточку, но оставляет доступ к другим кнопкам при правильном z-index */
}


.resource-card__body p {
  margin: 10px 0 0;
  color: var(--text-muted);
  font-size: clamp(14px, 0.95vw, 16px);
  line-height: 1.22;
  font-weight: 400;
}

.resource-card__arrow {
  justify-self: end;
  align-self: end;
  color: var(--white);
  font-size: 35px;
  line-height: 1;
  font-weight: 300;
  /* transform: translateY(-2px);
  transition: transform 0.22s ease; */
}
.card.bi::after {
  content: "2";
}
.card.wiki::after {
  content: "3";
}
.card.sap::after {
  content: "3";
}
.card.hub::after {
  content: "2";
}
.card.bi::after, .card.wiki::after, .card.sap::after, .card.hub::after {
position: absolute;
top: 15px;
    right: 15px;
    font-size: 15px;
    font-weight: 700;
    background-color: #fff;
    color: #000;
    border-radius: 50%;
    width: 25px;
    height: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
}
/* ==========================
   Modal
========================== */

.modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: .25s ease;
    z-index: 9999;
}
.modal-content {
  background: rgba(4, 34, 140, 0.81);
    padding: 35px;
    color: #fff;
    position: relative;
    border-radius: 25px;
    width: 550px;
}
.modal_title {
  display: flex;
    flex-direction: row;
    justify-content: flex-start;
    margin-bottom: 25px;
}
.resource_link {
  display: inline-flex;
    padding: 15px 15px;
    position: relative;
    align-items: center;
    width: 100%;
    color: #fff;
    text-decoration: none;
    background: rgba(69, 107, 196, 0.58);
    margin-bottom: 15px;
    border-radius: 19px;
    font-weight: 600;
    transition: background-color 1s ease-in-out;
}
.resource_link:hover {
    background: var(--card-hover);
    border-color: rgba(255, 255, 255, 0.9);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04), 0 18px 48px rgba(0, 0, 0, 0.18);
}
.knowledgebase::before {
content: "";
background-image: url('img/wiki2.svg');
background-size: contain;
background-repeat: no-repeat;
width: 40px;
height: 40px;
padding-right: 20px;
}
.resources_site::before {
content: "";
background-image: url('img/digital_resource.svg');
background-size: contain;
background-repeat: no-repeat;
width: 37px;
height: 30px;
padding-right: 20px;
}
.services::before {
  content: "";
  background-image: url('img/service_catalog.svg');
  background-size: contain;
  background-repeat: no-repeat;
  width: 35px;
  height: 32px;
  padding-right: 20px;
}
.bilink::before {
  content: "";
  background-image: url('img/powerbi.svg');
  background-size: contain;
  background-repeat: no-repeat;
  width: 40px;
  height: 40px;
  padding-right: 20px;
}
.saplink::before {
  content: "";
  background-image: url('img/sap.svg');
  background-size: contain;
  background-repeat: no-repeat;
  width: 43px;
  height: 40px;
  padding-right: 20px;
  margin-top: 4px;
}
.hublink::before {
  content: "";
  background-image: url('img/marketing-hub.svg');
  background-size: contain;
  background-repeat: no-repeat;
  width: 43px;
  height: 40px;
  padding-right: 20px;
  margin-top: 4px;
}

.modal_title .icons {
  margin: 0;
}

.modal.active {
    opacity: 1;
    display: flex;
    visibility: visible;
}

.modal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(3, 7, 30, 0.45);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.modal__dialog {
    position: relative;
    z-index: 2;
    width: min(750px, calc(100vw - 40px));
    min-height: 300px;
    background: rgba(255,255,255,.08);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255,255,255,.25);
    border-radius: 20px;
    padding: 40px;
    color: #fff;
    transform: translateY(20px);
    transition: .25s ease;
}

.modal.active .modal__dialog {
    transform: translateY(0);
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 50%;
    cursor: pointer;
    background: rgba(255,255,255,.15);
    color: #fff;
    font-size: 24px;
    line-height: 1;
}
.modal__close:hover {
    background: rgba(255,255,255,.25);
}

/* Tablet */
@media (max-width: 1180px) {
  .page {
    width: min(920px, calc(100% - 40px));
    padding-top: 96px;
    padding-bottom: 120px;
  }

  .hero__logo {
    margin-right: 10px;
  }

  .stats {
    margin-top: 82px;
    margin-bottom: 70px;
  }

  .resources {
    grid-template-columns: repeat(2, 1fr);
    gap: 28px;
  }
}

/* Mobile */
@media (max-width: 760px) {
  .page {
    width: min(100% - 28px, 520px);
    padding-top: 56px;
    padding-bottom: 80px;
  }

  .hero__content {
    grid-template-columns: 1fr;
  }

  .hero__logo {
    order: -1;
    width: 72px;
    margin: 0 0 48px auto;
  }

  .hero h1 {
    font-size: 48px;
  }

  .hero p {
    margin-top: 24px;
    font-size: 18px;
  }

  .stats {
    grid-template-columns: 1fr;
    gap: 34px;
    margin: 72px auto 58px;
  }

  .stat {
    padding: 0;
  }

  .stat--bordered {
    border-left: 0;
    border-right: 0;
    padding: 34px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.52);
    border-bottom: 1px solid rgba(255, 255, 255, 0.52);
  }

  .resources {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .resource-card {
    grid-template-columns: 76px 1px 1fr 32px;
    min-height: 118px;
    padding: 16px 15px 16px 20px;
  }

  .resource-card__icon {
    width: 56px;
    height: 56px;
  }

  .resource-card__icon img {
    width: 56px;
    height: 56px;
  }

  .resource-card__divider {
    height: 78px;
  }

  .resource-card__body {
    padding-left: 16px;
  }

  .resource-card__body h2 {
    font-size: 18px;
  }

  .resource-card__body p {
    font-size: 14px;
  }

  .resource-card__arrow {
    font-size: 34px;
  }
}

/* Small mobile */
@media (max-width: 420px) {
  .hero h1 {
    font-size: 40px;
  }

  .resource-card {
    grid-template-columns: 62px 1px 1fr 26px;
    padding-left: 14px;
  }

  .resource-card__icon img {
    width: 48px;
    height: 48px;
  }

  .resource-card__body h2 {
    font-size: 16px;
  }

  .resource-card__body p {
    font-size: 13px;
  }
}