/* ==========================================================================
Wired Home — scoped styles for #popup-wired-home
Derived from popup-access-control.css, but using `wh-` prefixes and `--wh-` variables
=========================================================================== */

#popup-wired-home{ display:none; }
#popup-wired-home.active{ display:flex; }

#popup-wired-home{
  --wh-bg:#2a2a2a;
  --wh-panel:#242424;
  --wh-text:#fff;
  --wh-muted:#ccc;
  --wh-border:rgba(255,255,255,.35);
  --wh-accent:#ff0000;
  --wh-accent-hover:#cc0000;
  --wh-radius:10px;
  --wh-gutter:12px;
}

#popup-wired-home .wh__overlay{
  position:fixed; inset:0; background:rgba(0,0,0,.6);
}

#popup-wired-home .wh__frame{
  position:relative;
  max-width:1080px;
  width:96%;
  margin:auto;
  border:2px solid var(--wh-border);
  background:var(--wh-bg);
  color:var(--wh-text);
  border-radius:12px;
  padding:24px;
}

#popup-wired-home .wh__close{
  position:absolute; top:10px; right:10px;
}

.wh__callwrap{ display:flex; justify-content:center; margin-bottom:10px; }
.wh-callbtn{
  display:inline-flex; align-items:center; gap:40px;
  background:var(--wh-accent); color:var(--wh-text);
  border:2px solid #fff; border-radius:10px;
  padding:12px 80px; font-size:28px; font-weight:600; cursor:pointer;
}
.wh-callbtn:hover{ background:var(--wh-accent-hover); }
.wh-callbtn__icon img{ width:64px; height:64px; object-fit:contain; }

.wh__section-title{
  text-align:center; font-size:36px; font-weight:600; margin:6px 0 14px 0;
}

.wh__grid{
  display:flex;
  flex-direction:column;
  gap: var(--wh-gutter);
  margin-bottom:16px;
}

.wh-card{
  background:var(--wh-panel);
  border:1px solid var(--wh-border);
  border-radius:8px;
  padding:0;
  display:flex; flex-direction:row; gap:12px;
  align-items:stretch;
  width:100%;
  box-sizing:border-box;
  overflow:hidden;
}
.wh-card__img{ width:100%; height:120px; object-fit:cover; border-radius:6px; border:3px solid var(--wh-accent); }
.wh-card__title{ font-size:25px !important; font-weight:700 !important; text-align:center; margin:0; line-height: 38px; }
.wh-card__list{ list-style:none; padding-top:10px; margin:0; color:var(--wh-text) !important; font-size:21px !important; display:flex; flex-direction:column; gap:6px; line-height: 38px; font-weight: 300;}
.wh-card__meta{ display:flex; flex-direction:column; align-items:center; gap:10px; margin-top:auto; }
.wh-card__price{ font-size:20px; font-weight:700; color:var(--wh-accent); }
.wh-card__price span{ font-size:14px; color:var(--wh-muted); }
.wh-card__buttons{ display:flex; flex-direction:column; gap:8px; width:100%; }
.wh-btn{ height:40px; padding:0 14px; border-radius:8px; border:1px solid var(--wh-border); background:transparent; background:var(--wh-text); color:var(--wh-accent); cursor:pointer; font-size:18px; width:100%; font-weight: 500}
.wh-btn:hover{ background:rgba(255,255,255,.1); }
.wh-btn--accent{ background:var(--wh-accent); border:none; color:var(--wh-text);} 
.wh-btn--accent:hover{ background:var(--wh-accent-hover); color:var(--wh-text);}

.wh-subcard{
  background:var(--wh-panel);
  border:1px solid var(--wh-border);
  border-radius:8px;
  padding:10px;
  display:flex; flex-direction:column; align-items:center; text-align:center;
  width:100%;
  box-sizing:border-box;
}
.wh-subcard__img{ width:100%; height:120px; object-fit:cover; border-radius:6px; margin-bottom:8px; }
.wh-subcard__title{ font-size:18px; margin:0; }

.wh__benefits{
  display:grid;
  grid-template-columns: repeat(6, 1fr);
  gap: var(--wh-gutter);
  width:100%;
  box-sizing:border-box;
}

#popup-wired-home .wh-card__thumb{ flex:0 0 240px; display:flex; align-items:stretch; }
#popup-wired-home .wh-card__thumb img{ width:240px; height:100%; object-fit:cover; border-radius:8px 0 0 8px; display:block; border:3px solid #fff; box-sizing:border-box; }

#popup-wired-home .wh-card__body{
  display:grid;
  grid-template-columns: 1fr 220px;
  gap:12px;
  align-items:start;
  flex:1 1 auto;
  padding:16px;
}

.wh-benefit{
  background:#1f1f1f; border:1px solid var(--wh-border);
  border-radius:10px; padding:10px; text-align:center;
  display:flex; flex-direction:column; gap:10px; align-items:center; justify-content:flex-start;
}
.wh-benefit__img{ width:150px; height:150px; object-fit:contain; }
.wh-benefit__text{ font-size: 17px !important; color:var(--wh-panel) !important; font-weight: 600 !important; }

@media (max-width: 1100px){
  .wh__benefits{ grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 800px){
  .wh__grid{ grid-template-columns: 1fr; }
  .wh__benefits{ grid-template-columns: repeat(2, 1fr); }
}

.wh-subcard--bg{
  position:relative;
  background-size:cover;
  background-position:center;
  overflow:hidden;
  height:170px;
  display:flex;
  align-items:center;
  justify-content:center;
}
.wh-subcard--bg::before{
  content:"";
  position:absolute; inset:0;
  background:rgba(0,0,0,.35);
}
.wh-subcard__title{
  position:relative; z-index:1; text-align:center;
}

.wh__benefits{
  display:flex;
  flex-wrap:nowrap;
  justify-content:space-between;
  align-items:stretch;
  gap:12px;
}
.wh-benefit{
  flex: 0 0 calc(16.66% - 10px);
}
.wh-benefit__img{
  width:120px; height:120px;
}

.wh__benefits{
  display: flex;
  flex-wrap: nowrap;
  justify-content: space-between;
  align-items: stretch;
  background: #ffffff;
  border: 2px solid var(--wh-accent);
  border-radius: 12px;
  padding: 16px 20px;
  gap: 10px;
  color: #000;
}

.wh-benefit{
  flex: 1;
  background: transparent;
  border: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  text-align: center;
  gap: 8px;
}

.wh-benefit__img{
  width: 110px;
  height: 110px;
  object-fit: contain;
}

.wh-benefit__text{ font-size: 14px;
  color: #000;
  font-weight: 500;
  line-height: 1.3;
}

.wh-card{
  position: relative;
  border: 2px solid var(--wh-border);
  border-radius: 8px;
  padding: 0;
  display: flex;
  flex-direction: row;
  align-items: stretch;
  color: var(--wh-text);
  overflow: hidden;
  min-height: 180px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}
.wh-card::before{
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.45);
  z-index: 1;
  pointer-events: none;
}
#popup-wired-home .wh-card__thumb{
  flex: 0 0 240px;
  display: flex;
  align-items: stretch;
  position: relative;
  z-index: 2;
}
#popup-wired-home .wh-card__thumb img{
  width: 240px;
  height: 100%;
  object-fit: cover;
  border-radius: 8px 0 0 8px;
  display: block;
  position: relative;
  z-index: 2;
  border: 3px solid #fff;
  box-sizing: border-box;
}
.wh-card__img{ display:none !important; }

.wh-card__body{
  /* Ensure the body stays a two-column grid (text | meta) and doesn't get overridden */
  display: grid !important;
  grid-template-columns: 1fr 220px;
  gap: 12px;
  align-items: start;
  padding: 16px;
  height: 100%;
  flex: 1 1 auto;
  position: relative;
  z-index: 2;
}
.wh-card__title, .wh-card__list, .wh-card__price, .wh-card__buttons, .wh-card__meta{
  position: relative;
  z-index: 2;
}
.wh-card__title{ margin-top: 4px; }
.wh-card__list{ text-align: left; line-height: 25px; }

.wh-card__meta{
  margin-top: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.wh-card__price{
  font-size: 22px;
  font-weight: 700;
  color: var(--wh-accent);
  margin-bottom: 8px;
}

.wh-card__price{
  display: inline-block;
  position: relative;
  font-size: 22px;
  font-weight: 700;
  color: #ffffff; /* белая цена */
  margin-bottom: 2px;
  padding-bottom: 6px; /* место под полоску */
  line-height: 1.1;
}
.wh-card__price::after{
  content: "";
  position: absolute;
  left: -5px;
  right: -5px;
  bottom: 0;
  height: 3px;
  background: var(--wh-accent);
  border-radius: 2px;
}
.wh-card__price span{
  font-size: 14px;
  color: #ffffffcc;
}
.wh-card__note{
  font-size: 14px;
  color: #ffffff;
  opacity: 0.9;
  margin-top: 0px;
  margin-bottom: 30px;
  text-align: center;
}
/* ==========================================================================
Проводной умный дом — popup-wired-home.css
Копия popup-access-control.css, инкапсулирована под #popup-wired-home
=========================================================================== */

#popup-wired-home{ display:none; }
#popup-wired-home.active{ display:flex; }

#popup-wired-home{
  --wh-bg:#2a2a2a;
  --wh-panel:#242424;
  --wh-text:#fff;
  --wh-muted:#ccc;
  --wh-border:rgba(255,255,255,.35);
  --wh-accent:#ff0000;
  --wh-accent-hover:#cc0000;
  --wh-radius:10px;
  --wh-gutter:12px;
}

#popup-wired-home .ac__overlay{
  position:fixed; inset:0; background:rgba(0,0,0,.6);
}

#popup-wired-home .ac__frame{
  position:relative;
  max-width:1080px;
  width:96%;
  margin:auto;
  border:2px solid var(--wh-border);
  background:var(--wh-bg);
  color:var(--wh-text);
  border-radius:12px;
  padding:24px;
}

/* Узкий override: перебивает глобальный .popup-content из styles-vyborgskaya.css */
#popup-wired-home .popup-content.ac__frame,
#popup-wired-home .popup-content{
  max-width:1080px !important;
  width:96% !important;
  max-height:none !important;
  overflow:visible !important;
}

#popup-wired-home .ac__close{
  position:absolute; top:10px; right:10px;
}

.ac__callwrap{ display:flex; justify-content:center; margin-bottom:10px; }
.ac-callbtn{
  display:inline-flex; align-items:center; gap:40px;
  background:var(--wh-accent); color:var(--wh-text);
  border:2px solid #fff; border-radius:10px;
  padding:12px 80px; font-size:28px; font-weight:600; cursor:pointer;
}
.ac-callbtn:hover{ background:var(--wh-accent-hover); }
.ac-callbtn__icon img{ width:64px; height:64px; object-fit:contain; }

.ac__section-title{
  text-align:center; font-size:36px; font-weight:600; margin:6px 0 14px 0;
}

/* --- Основная сетка: вертикальный стек блоков (один под другим) --- */
.ac__grid{
  display:flex;
  flex-direction:column;
  gap: var(--wh-gutter);
  margin-bottom:16px;
}

/* Карточка комплекта (верхний ряд) */
.ac-card{
  background:var(--wh-panel);
  border:1px solid var(--wh-border);
  border-radius:8px;
  padding:0; /* removed outer padding as requested */
  display:flex; flex-direction:row; gap:12px; /* left thumb + content */
  align-items:stretch;
  width:100%;
  box-sizing:border-box;
  overflow:hidden;
}
.ac-card__img{ width:100%; height:120px; object-fit:cover; border-radius:6px; border:3px solid var(--wh-accent); }
.ac-card__title{ font-size:25px !important; font-weight:700 !important; text-align:center; margin:0; line-height: 38px; }
.ac-card__list{ list-style:none; padding-top:30px; margin:0; color:var(--wh-accent); font-size:21px !important; display:flex; flex-direction:column; gap:6px; line-height: 38px; font-weight: 300;}
.ac-card__meta{ display:flex; flex-direction:column; align-items:center; gap:10px; margin-top:auto; }
.ac-card__price{ font-size:20px; font-weight:700; color:var(--wh-accent); }
.ac-card__price span{ font-size:14px; color:var(--wh-muted); }
.ac-card__buttons{ display:flex; flex-direction:column; gap:8px; width:100%; }
.ac-btn{ height:40px; padding:0 14px; border-radius:8px; border:1px solid var(--wh-border); background:transparent; background:var(--wh-text); color:var(--wh-accent); cursor:pointer; font-size:18px; width:100%; font-weight: 500}
.ac-btn:hover{ background:rgba(255,255,255,.1); }
.ac-btn--accent{ background:var(--wh-accent); border:none; color:var(--wh-text);} 
.ac-btn--accent:hover{ background:var(--wh-accent-hover); color:var(--wh-text);}

/* Подписи/блоки под комплектами (нижний ряд) */
.ac-subcard{
  background:var(--wh-panel);
  border:1px solid var(--wh-border);
  border-radius:8px;
  padding:10px;
  display:flex; flex-direction:column; align-items:center; text-align:center;
  width:100%;
  box-sizing:border-box;
}
.ac-subcard__img{ width:100%; height:120px; object-fit:cover; border-radius:6px; margin-bottom:8px; }
.ac-subcard__title{ font-size:18px; margin:0; }

/* Блок преимуществ (6 штук) */
.ac__benefits{
  display:grid;
  grid-template-columns: repeat(6, 1fr);
  gap: var(--wh-gutter);
  width:100%;
  box-sizing:border-box;
}

/* Left thumbnail inside card */
#popup-wired-home .ac-card__thumb{ flex:0 0 240px; display:flex; align-items:stretch; }
#popup-wired-home .ac-card__thumb img{ width:240px; height:100%; object-fit:cover; border-radius:8px 0 0 8px; display:block; }

/* Card body becomes two columns: text | price+buttons */
#popup-wired-home .ac-card__body{
  display:grid;
  grid-template-columns: 1fr 220px;
  gap:12px;
  align-items:start;
  flex:1 1 auto; /* ensure body fills remaining space to the right of thumb */
  padding:16px; /* internal padding for content area */
}
.ac-benefit{
  background:#1f1f1f; border:1px solid var(--wh-border);
  border-radius:10px; padding:10px; text-align:center;
  display:flex; flex-direction:column; gap:10px; align-items:center; justify-content:flex-start;
}
.ac-benefit__img{ width:150px; height:150px; object-fit:contain; }
.ac-benefit__text{ font-size: 17px !important; color:var(--wh-panel) !important; font-weight: 600 !important; }

@media (max-width: 1100px){
  .ac__benefits{ grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 800px){
  .ac__grid{ grid-template-columns: 1fr; }
  .ac__benefits{ grid-template-columns: repeat(2, 1fr); }
}

/* Центровка подписи по центру блока и фоновая картинка */
.ac-subcard--bg{
  position:relative;
  background-size:cover;
  background-position:center;
  overflow:hidden;
  height:170px;
  display:flex;
  align-items:center;
  justify-content:center;
}
.ac-subcard--bg::before{
  content:"";
  position:absolute; inset:0;
  background:rgba(0,0,0,.35);
}
.ac-subcard__title{
  position:relative; z-index:1; text-align:center;
}

/* Преимущества в одну строку без переноса */
.ac__benefits{
  display:flex;
  flex-wrap:nowrap;
  justify-content:space-between;
  align-items:stretch;
  gap:12px;
}
.ac-benefit{
  flex: 0 0 calc(16.66% - 10px);
}
.ac-benefit__img{
  width:120px; height:120px;
}

/* === Единый белый блок преимуществ (в одну линию) === */
.ac__benefits{
  display: flex;
  flex-wrap: nowrap;
  justify-content: space-between;
  align-items: stretch;
  background: #ffffff;
  border: 2px solid var(--wh-accent);
  border-radius: 12px;
  padding: 16px 20px;
  gap: 10px;
  color: #000;
}

.ac-benefit{
  flex: 1;
  background: transparent;
  border: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  text-align: center;
  gap: 8px;
}

.ac-benefit__img{
  width: 110px;
  height: 110px;
  object-fit: contain;
}

.ac-benefit__text{ font-size: 14px;
  color: #000;
  font-weight: 500;
  line-height: 1.3;
}

/* === Комплекты с фоновым изображением, текст поверх === */
.ac-card{
  position: relative;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  border: 2px solid var(--wh-border);
  border-radius: 8px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: var(--wh-text);
  overflow: hidden;
  min-height: 260px;
}
.ac-card::before{
  content:"";
  position:absolute; inset:0;
  background: rgba(0,0,0,0.45);
  z-index:0;
}
.ac-card__body, .ac-card__title, .ac-card__list, .ac-card__price, .ac-card__buttons, .ac-card__meta{
  position: relative;
  z-index: 1;
}
.ac-card__title{ margin-top: 4px; }
.ac-card__list{ text-align:left; }
.ac-card__img{ display:none !important; }

/* === Ценник и кнопки прижаты к низу блока === */
.ac-card__body{
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}

.ac-card__meta{
  margin-top: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.ac-card__price{
  font-size: 22px;
  font-weight: 700;
  color: var(--wh-accent);
  margin-bottom: 8px;
}

/* === Цена: белый текст + красная полоса шире текста на 10px === */
.ac-card__price{
  display: inline-block;
  position: relative;
  font-size: 22px;
  font-weight: 700;
  color: #ffffff; /* белая цена */
  margin-bottom: 2px;
  padding-bottom: 6px; /* место под полоску */
  line-height: 1.1;
}
.ac-card__price::after{
  content: "";
  position: absolute;
  left: -5px;  /* расширяем на 5px слева */
  right: -5px; /* расширяем на 5px справа */
  bottom: 0;
  height: 3px;
  background: var(--wh-accent);
  border-radius: 2px;
}
.ac-card__price span{
  font-size: 14px;
  color: #ffffffcc; /* полупрозрачный белый для "от" */
}
/* Подпись под ценой */
.ac-card__note{
  font-size: 14px;
  color: #ffffff;
  opacity: 0.9;
  margin-top: 0px;
  margin-bottom: 30px;
  text-align: center;
}

.wh-card__list li:first-child::before {
  content: "";
  display: inline-block;
  width: 20px;
  height: 20px;
  margin-right: 7px;
  background-image: url('../wired-home/plus.webp');
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  vertical-align: middle;
}

.wh-card__list li:not(:first-child)::before {
  content: "";
  display: inline-block;
  width: 20px;
  height: 20px;
  margin-right: 7px;
  background-image: url('../wired-home/galka.webp');
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  vertical-align: middle;
}