.ocf-wrap {
  margin-top: 1.5rem;
}

.ocf-title {
  margin: 0 0 1rem;
  font-size: 2rem;
  color: #0f172a;
}

.ocf-section {
  display: grid;
  gap: 0.3rem;
  margin-top: 1.25rem;
}

.ocf-section-title {
  margin: 0 0 0.05rem;
  font-size: 1.34rem;
  color: #0f172a;
  font-family: inherit;
  font-weight: 700;
  letter-spacing: normal;
  line-height: 1.15;
}

.ocf-list {
  display: grid;
  gap: 0;
  padding-top: 0.05rem;
  border: 1px solid #dbe3ee;
  border-radius: 0.8rem;
  background: #ffffff;
  overflow: hidden;
}

.ocf-link-card {
  text-decoration: none;
}

.ocf-offer-block {
  display: block;
  background: #ffffff;
}

.ocf-offer-block + .ocf-offer-block {
  border-top: 1px solid #e6edf5;
}

.ocf-row {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) max-content;
  gap: 0.65rem;
  align-items: center;
  padding: 0.58rem 0.85rem;
}

.ocf-row--almost {
  grid-template-columns: minmax(0, 1fr) max-content;
  padding-right: 1.15rem;
}

.ocf-col--check {
  display: flex;
  align-items: center;
  justify-content: center;
}

.ocf-check {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-direction: row;
  gap: 0.22rem;
}

.ocf-check input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.ocf-check-ui {
  width: 20px;
  height: 20px;
  border-radius: 0.42rem;
  border: 1px solid #c9d7ea;
  background: linear-gradient(180deg, #ffffff 0%, #eef4fb 100%);
  box-shadow: 0 8px 16px rgba(15, 23, 42, 0.08);
  transition: transform 0.14s ease, border-color 0.14s ease, box-shadow 0.14s ease, background 0.14s ease;
}

.ocf-check input:checked + .ocf-check-ui {
  border-color: #2f6df6;
  background: linear-gradient(180deg, #3b82f6 0%, #2563eb 100%);
  box-shadow: 0 10px 20px rgba(47, 109, 246, 0.25);
}

.ocf-check input:checked + .ocf-check-ui::after {
  content: "";
  position: absolute;
  width: 6px;
  height: 10px;
  border: solid #ffffff;
  border-width: 0 2px 2px 0;
  transform: translate(6px, 3px) rotate(45deg);
}

.ocf-check:hover .ocf-check-ui {
  transform: translateY(-1px);
  border-color: #9fb8e6;
}

.ocf-check-hint {
  font-size: 0.72rem;
  line-height: 1;
  opacity: 0.82;
  transform: translateY(0);
  order: -1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 16px;
  min-height: 16px;
  padding: 0.05rem;
  border-radius: 999px;
  background: #eef4ff;
}

.ocf-check input:checked ~ .ocf-check-hint {
  opacity: 1;
  background: #dbeafe;
}

.ocf-col--ghost {
  visibility: hidden;
}

.ocf-gift-options {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  justify-content: flex-start;
}

.ocf-gift-option {
  display: block;
  cursor: pointer;
}

.ocf-gift-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.ocf-gift-option-box {
  display: grid;
  grid-template-columns: 68px minmax(0, 1fr);
  gap: 0.58rem;
  align-items: center;
  min-width: 220px;
  max-width: 260px;
  padding: 0.34rem 0.4rem;
  border-radius: 0.72rem;
  background: #ffffff;
  border: 1px solid #d7e3f4;
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease, background 0.16s ease;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.04);
}

.ocf-gift-option:hover .ocf-gift-option-box {
  border-color: #b7caea;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
}

.ocf-gift-option.is-selected .ocf-gift-option-box,
.ocf-gift-option input:checked + .ocf-gift-option-box {
  border-color: #c9d7ea;
  background: #ffffff;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.05);
}

.ocf-offer-block.is-offer-active .ocf-gift-option.is-selected .ocf-gift-option-box,
.ocf-gift-option.is-active .ocf-gift-option-box {
  border-color: #2f6df6;
  box-shadow: 0 12px 24px rgba(47, 109, 246, 0.18);
}

.ocf-offer-block:not(.is-offer-active) .ocf-gift-option.is-selected .ocf-gift-option-box,
.ocf-gift-option.is-selected:not(.is-active) .ocf-gift-option-box {
  border-color: #d7e3f4 !important;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.04) !important;
  opacity: 1;
}

.ocf-gift-option.is-single .ocf-gift-option-box {
  min-width: 220px;
  width: auto;
}

.ocf-gift-option-visual {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 74px;
  border-radius: 0.62rem;
  background: #ffffff;
}

.ocf-gift-thumb {
  width: 70px;
  height: 70px;
  object-fit: contain;
  padding: 0.08rem;
}

.ocf-gift-option-text {
  display: grid;
  gap: 0.16rem;
  min-width: 0;
}

.ocf-gift-option-label {
  color: #334155;
  display: -webkit-box;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.15;
  max-width: 170px;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ocf-gift-option-price-line {
  display: flex;
  align-items: baseline;
  gap: 0.34rem;
  flex-wrap: nowrap;
}

.ocf-gift-option-price {
  font-size: 1.15rem;
  font-weight: 800;
  line-height: 1.05;
  white-space: nowrap;
}

.ocf-gift-option-price.is-free {
  color: #2E7D4D;
}

.ocf-gift-option-price.is-promo {
  color: #C0392B;
}

.ocf-gift-option-ref-price {
  color: #8E44B8;
  font-size: 1.02rem;
  font-weight: 700;
  white-space: nowrap;
}

.ocf-col--details {
  display: grid;
  gap: 0.1rem;
  min-width: 0;
  justify-content: start;
  align-content: center;
  text-align: left;
}

.ocf-col--gift {
  justify-self: end;
  padding-right: 0.35rem;
}

.ocf-offer-name {
  color: #0f172a;
  font-size: 1.04rem;
  font-weight: 700;
  line-height: 1.2;
}

.ocf-almost-label {
  color: #d97706;
  font-weight: 700;
  line-height: 1.3;
  font-size: 0.9rem;
}

.ocf-link-label {
  color: #1d4ed8;
  text-decoration: underline;
  font-size: 0.9rem;
  display: inline-block;
}

.ocf-row--almost .ocf-col--details {
  align-content: start;
}

.ocf-row--almost .ocf-col--gift {
  padding-right: 0.2rem;
}

.ocf-row--almost .ocf-offer-name {
  margin-bottom: 0.18rem;
}

@media (max-width: 900px) {
  .ocf-row {
    grid-template-columns: 28px 1fr;
    gap: 0.55rem;
    align-items: start;
  }

  .ocf-col--check {
    grid-row: 1 / span 2;
    align-self: center;
  }

  .ocf-col--gift,
  .ocf-col--details {
    grid-column: 2;
  }

  .ocf-col--gift {
    justify-self: start;
    padding-right: 0;
  }

  .ocf-row--almost {
    grid-template-columns: 1fr;
    padding-right: 0.85rem;
  }

  .ocf-row--almost .ocf-col--gift,
  .ocf-row--almost .ocf-col--details {
    grid-column: auto;
  }

  .ocf-col--gift {
    grid-row: 1;
  }

  .ocf-col--details {
    grid-row: 2;
    margin-top: -0.1rem;
  }

  .ocf-gift-option-box {
    min-width: 206px;
    max-width: 246px;
  }
}

@media (max-width: 640px) {
  .ocf-title {
    font-size: 1.65rem;
  }

  .ocf-section-title {
    font-size: 1.28rem;
  }

  .ocf-row {
    grid-template-columns: 28px 1fr;
    gap: 0.45rem;
    padding: 0.58rem 0.62rem;
    align-items: start;
  }

  .ocf-col--details {
    grid-column: 1 / -1;
    grid-row: 1;
    margin-top: 0;
    margin-bottom: 0.2rem;
    padding-left: 0;
  }

  .ocf-col--gift,
  .ocf-col--check {
    grid-column: 2;
  }

  .ocf-col--check {
    grid-column: 1;
    grid-row: 2;
  }

  .ocf-col--gift {
    grid-row: 2;
    grid-column: 2;
  }

  .ocf-gift-options {
    gap: 0.35rem;
    width: auto;
    flex-wrap: wrap;
  }

  .ocf-gift-option-box {
    grid-template-columns: 66px minmax(0, 1fr);
    min-width: 218px;
    max-width: 252px;
    width: auto;
    padding: 0.3rem 0.34rem;
  }

  .ocf-gift-option,
  .ocf-gift-option.is-single {
    width: auto;
  }

  .ocf-row--almost {
    grid-template-columns: 1fr;
  }

  .ocf-row--almost .ocf-col--almost-aside,
  .ocf-row--almost .ocf-col--gift,
  .ocf-row--almost .ocf-col--details {
    grid-column: auto;
    grid-row: auto;
  }

  .ocf-row--almost .ocf-col--details {
    margin-top: 0;
    margin-bottom: 0;
  }

  .ocf-row--almost .ocf-col--gift {
    justify-self: start;
    padding-right: 0;
  }

  .ocf-almost-side {
    max-width: none;
  }

  .ocf-gift-option-visual {
    min-height: 66px;
  }

  .ocf-gift-thumb {
    width: 62px;
    height: 62px;
  }

  .ocf-offer-name {
    font-size: 0.98rem;
  }

  .ocf-almost-label,
  .ocf-link-label {
    font-size: 0.86rem;
  }

  .ocf-gift-option-label {
    max-width: 156px;
    font-size: 0.96rem;
  }

  .ocf-gift-option-price {
    font-size: 1.16rem;
  }

  .ocf-gift-option-ref-price {
    font-size: 0.94rem;
  }
}
