/* Реквизиты компании: кнопка у калькулятора ремонта (construction.html) открывает модальное окно
   с двусторонней «банковской картой». Лицевая сторона — организация, оборот — банк и QR (ГОСТ Р 56042).
   Стили кнопки — отдельно, css/company-card-button.css (дизайн Дизайнера). 10.11.2026, v20261110ccm. */
.cc { min-width: 0; max-width: 100%; box-sizing: border-box; }
.cc *, .cc *::before, .cc *::after { box-sizing: border-box; }
.cc-heading { margin: 0 44px 4px 0; font-size: clamp(20px, 4.4vw, 26px); letter-spacing: -.02em; color: var(--navy, #0b1f33); }
.cc-sub { margin: 0 0 12px; font-size: 14px; color: var(--muted, #5b6b78); }

.cc-stage { container-type: inline-size; min-width: 0; max-width: 100%; }
.cc-inner { display: grid; gap: 14px; min-width: 0; }
.cc-face {
  position: relative; min-width: 0; overflow: hidden;
  border-radius: 22px; padding: 20px 20px 18px; color: #fff;
  background:
    radial-gradient(120% 90% at 100% 0%, rgba(217,119,6,.38), rgba(217,119,6,0) 55%),
    radial-gradient(90% 70% at 0% 100%, rgba(15,118,110,.30), rgba(15,118,110,0) 60%),
    linear-gradient(135deg, #0b1f33 0%, #1c3a52 58%, #24506f 100%);
  box-shadow: 0 18px 44px rgba(11,31,51,.28), inset 0 1px 0 rgba(255,255,255,.12);
}
.cc-face::after { /* блик, следует за курсором на компьютере */
  content: ""; position: absolute; inset: 0; pointer-events: none; border-radius: inherit;
  background: radial-gradient(420px circle at var(--mx, 18%) var(--my, 0%), rgba(255,255,255,.13), rgba(255,255,255,0) 60%);
}
.cc-face::before { /* тонкая «гильош»-сетка */
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .07;
  background: repeating-linear-gradient(115deg, #fff 0 1px, transparent 1px 14px);
}
.cc-face > * { position: relative; z-index: 1; }

.cc-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.cc-logo { display: inline-flex; align-items: center; gap: 8px; font-weight: 800; font-size: 14px; letter-spacing: .02em; color: #e8eef3; }
.cc-mark {
  display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 8px;
  background: var(--amber, #d97706); color: #fff; font-weight: 800;
}
.cc-chip {
  flex: none; width: 46px; height: 34px; border-radius: 7px;
  background:
    linear-gradient(90deg, transparent 31%, rgba(90,60,10,.45) 31% 33%, transparent 33% 67%, rgba(90,60,10,.45) 67% 69%, transparent 69%),
    linear-gradient(0deg, transparent 47%, rgba(90,60,10,.45) 47% 53%, transparent 53%),
    linear-gradient(135deg, #f6d58a, #d9a441 55%, #f3cf7a);
  box-shadow: inset 0 0 0 1px rgba(90,60,10,.35);
}
.cc-brand { margin: 14px 0 12px; font-size: clamp(20px, 4.6vw, 26px); font-weight: 800; letter-spacing: -.02em; line-height: 1.15; color: #fff; }
.cc-brand-sm { margin-top: 8px; font-size: clamp(18px, 4vw, 22px); }
.cc-stripe { height: 38px; margin: -20px -20px 0; background: linear-gradient(90deg, #050e17, #10273b 50%, #050e17); }

.cc-list { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px 16px; margin: 0; }
@container (min-width: 430px) {
  .cc-list { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .cc-wide { grid-column: 1 / -1; }
}
.cc-row { min-width: 0; padding-top: 8px; border-top: 1px solid rgba(255,255,255,.14); }
.cc-row dt { font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #b9c9d6; margin: 0 0 3px; }
.cc-row dd { margin: 0; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 10px; min-width: 0; }
.cc-val { min-width: 0; flex: 1 1 auto; font-size: 15px; font-weight: 700; line-height: 1.35; overflow-wrap: anywhere; color: #fff; }
.cc-num { font-variant-numeric: tabular-nums; letter-spacing: .05em; font-size: 16px; }
.cc-copy {
  flex: none; display: inline-flex; align-items: center; gap: 4px;
  min-height: 32px; padding: 5px 11px; border-radius: 999px; cursor: pointer;
  font: inherit; font-size: 12px; font-weight: 700; white-space: nowrap;
  color: #fff; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.32);
  transition: background .15s, border-color .15s;
}
.cc-copy:hover { background: rgba(255,255,255,.22); }
.cc-copy.is-done { background: var(--ok, #0f766e); border-color: #5eead4; }
.cc-copy:focus-visible, .cc-actions .btn:focus-visible { outline: 3px solid #fbbf24; outline-offset: 2px; }

.cc-back-grid { display: grid; gap: 14px; min-width: 0; }
.cc-qr { margin: 0; display: flex; gap: 14px; align-items: center; min-width: 0;
  padding: 12px; border-radius: 16px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.16); }
.cc-qr img { flex: none; width: 132px; height: 132px; padding: 6px; border-radius: 12px; background: #fff; image-rendering: pixelated; }
.cc-qr figcaption { min-width: 0; font-size: 13px; line-height: 1.4; color: #dbe5ee; }
@container (max-width: 300px) {
  .cc-qr { flex-direction: column; text-align: center; }
  .cc-qr img { width: 160px; height: 160px; }
}

.cc-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.cc-actions .btn { flex: 1 1 auto; text-align: center; min-width: 0; white-space: normal; }
.cc-actions .btn-ghost { background: #fff; color: var(--navy, #0b1f33); }
.cc-toast {
  position: fixed; left: 50%; bottom: 22px; z-index: 10; margin: 0;
  transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
  max-width: calc(100vw - 32px); padding: 10px 18px; border-radius: 999px;
  background: var(--navy, #0b1f33); color: #fff; font-weight: 700; font-size: 14px;
  box-shadow: 0 10px 30px rgba(11,31,51,.3); transition: opacity .2s, transform .2s;
}
.cc-toast.is-on { opacity: 1; transform: translate(-50%, 0); }
.cc-toast:empty { display: none; }

/* Переворот — только когда JS готов */
.cc.cc-ready .cc-stage { perspective: 1800px; padding: 4px 0 8px; }
.cc.cc-ready .cc-inner { gap: 0; transform-style: preserve-3d; transition: transform .75s cubic-bezier(.2,.75,.2,1); }
.cc.cc-ready .cc-face { grid-area: 1 / 1; -webkit-backface-visibility: hidden; backface-visibility: hidden; transition: visibility 0s linear .37s; }
.cc.cc-ready .cc-back { transform: rotateY(180deg); visibility: hidden; }
.cc.cc-ready.is-flipped .cc-inner { transform: rotateY(180deg); }
.cc.cc-ready.is-flipped .cc-front { visibility: hidden; }
.cc.cc-ready.is-flipped .cc-back { visibility: visible; }
@media (prefers-reduced-motion: reduce) {
  .cc.cc-ready .cc-inner, .cc.cc-ready .cc-face { transition: none; }
}
@media print {
  .cc.cc-ready .cc-inner { transform: none !important; display: block; }
  .cc.cc-ready .cc-face { visibility: visible !important; transform: none !important; margin-bottom: 12px; }
  .cc-actions, .cc-copy, .cc-toast { display: none !important; }
}
.cc.cc-ready .cc-front { display: flex; flex-direction: column; }
.cc-foot { margin: 14px 0 0; padding-top: 10px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 12px;
  font-size: 12px; font-weight: 700; letter-spacing: .06em; color: #b9c9d6; }
.cc.cc-ready .cc-foot { margin-top: auto; }
.cc:not(.cc-ready) .cc-foot span + span { display: none; }

/* ---------- Модальное окно ---------- */
html.cc-lock, html.cc-lock body { overflow: hidden; }
.cc-modal {
  position: fixed; inset: 0; width: 100%; height: 100%; max-width: none; max-height: none;
  margin: 0; padding: 16px; border: 0; box-sizing: border-box; overflow: hidden;
  background: rgba(8, 23, 42, .66); color: var(--ink, #14202b);
  opacity: 0; transition: opacity .22s ease;
}
.cc-modal[open] { display: flex; align-items: center; justify-content: center; }
.cc-modal::backdrop { background: transparent; }
.cc-modal.is-open { opacity: 1; }
.cc-modal-box {
  position: relative; width: 100%; max-width: 640px; max-height: 100%;
  overflow-y: auto; overflow-x: hidden; overscroll-behavior: contain; -webkit-overflow-scrolling: touch;
  box-sizing: border-box; padding: 20px 20px 18px; border-radius: 22px;
  background: var(--paper, #fbf8f3); box-shadow: 0 30px 80px rgba(0, 0, 0, .35);
  transform: translateY(18px) scale(.97); transition: transform .26s cubic-bezier(.2, .75, .2, 1);
}
.cc-modal.is-open .cc-modal-box { transform: none; }
.cc-close {
  position: absolute; top: 12px; right: 12px; z-index: 3;
  width: 40px; height: 40px; border-radius: 50%; cursor: pointer;
  border: 1px solid var(--line, #e4ddd2); background: #fff; color: var(--navy, #0b1f33);
  font: 700 18px/1 "Manrope", system-ui, sans-serif;
}
.cc-close:hover { background: var(--sand, #f4efe6); }
.cc-close:focus-visible, .cc-share-menu a:focus-visible, .cc-share-menu button:focus-visible { outline: 3px solid #fbbf24; outline-offset: 2px; }
@media (max-width: 480px) {
  .cc-modal { padding: 8px; }
  .cc-modal-box { padding: 16px 12px 14px; border-radius: 18px; }
  .cc-face { padding: 18px 14px 16px; }
  .cc-stripe { margin: -18px -14px 0; }
}
@media (prefers-reduced-motion: reduce) {
  .cc-modal, .cc-modal-box { transition: none; }
}

/* ---------- Меню «Поделиться» (стиль как у общей кнопки js/share.js) ---------- */
.cc-share-menu {
  margin-top: 8px; padding: 6px; min-width: 200px; font-size: 15px;
  background: #fff; border: 1px solid #ddd; border-radius: 10px; box-shadow: 0 6px 24px rgba(0,0,0,.18);
}
.cc-share-menu[hidden] { display: none; }
.cc-share-menu a, .cc-share-menu button {
  display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; padding: 9px 12px; color: #222; text-decoration: none;
  border: 0; background: none; font: inherit; cursor: pointer; border-radius: 6px; box-sizing: border-box;
}
.cc-share-menu .si { flex: 0 0 auto; display: block; }
.cc-share-menu span { flex: 1 1 auto; }
.cc-share-menu a:hover, .cc-share-menu button:hover { background: #f4efe6; }
.cc-actions .cc-share { background: #e8a33d; color: #1b1b1b; border: 0; }

.cc-share-backdrop {
  position: fixed; inset: 0; z-index: 40;
  background: rgba(0,0,0,.45);
}
.cc-share-menu.is-sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
  margin: 0; min-width: 0; width: 100%; max-width: 100vw;
  max-height: 85vh; overflow: auto; box-sizing: border-box;
  border-radius: 16px 16px 0 0; border: 0;
  padding: 10px 10px calc(12px + env(safe-area-inset-bottom, 0px));
  box-shadow: 0 -8px 28px rgba(0,0,0,.2);
  font-size: 16px;
}
.cc-share-menu.is-sheet a, .cc-share-menu.is-sheet button {
  min-height: 48px; padding: 12px 14px; font-size: 16px;
}
.cc-share-menu .share-close-btn {
  justify-content: center; font-weight: 700; margin-top: 4px;
}

