:root{
  /* единая макс-ширина контента на десктопе */
  --content-max: 880px;
  --content-pad: 16px; /* боковые поля на мобилках */
  --muted: #d9d9d9;
}

/* ============ БАЗА ============ */
html, body {
  height: 100%;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}
body {
  font-family: "Georgia", "Times New Roman", serif;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 20px 0;
  background:#000;
  color: var(--muted);
}

/* Внешняя «рамка» на всю ширину, но без ограничения — фон и тень */
.frame {
  width: 100%;
  margin: 0;
  background: #000;
  box-shadow: 0 10px 50px rgba(0,0,0,0.75);
  padding: 24px 0; /* вертикальные отступы */
  box-sizing: border-box;
}

/* ЕДИНЫЙ КОНТЕЙНЕР ШИРИНЫ ДЛЯ ВСЕХ БЛОКОВ */
.container{
  width: min(100%, var(--content-max));
  padding-inline: var(--content-pad);
  margin: 0 auto;
  box-sizing: border-box;
  text-align: center;
}

/* ============ ЛОГО/ТАГЛАЙН ============ */
header .logo{
  position: relative;
  display: inline-block;
  overflow: hidden;
  margin-bottom: -30px;
}
header .logo img { max-width: 100%; height: auto; display: block; }
header .logo::after{
  content:"";
  position:absolute; inset:auto 0 0 0; height:70%;
  background: linear-gradient(to bottom, rgba(0,0,0,0) 0%, #000 100%);
  mix-blend-mode: destination-out; pointer-events:none;
}
.tagline{
  font-size: 15px; color:#e7e7e7; text-align:center;
  margin-top:-20px; position:relative; z-index:2;
}

/* Бренд — уникальный стиль, не переопределяется ниже */
.brand{
  font-family: Georgia, serif;
  font-weight:700;
  font-size:46px;
  letter-spacing:2px;
  color:#ff2f4b;
  text-shadow:0 12px 22px rgba(0,0,0,0.55);
  margin:0;
  line-height:0.9;
}

/* ============ ТИПОГРАФИКА ============ */
h1{color:#fff;text-align:center;font-size:26px;margin:50px 0 10px 0;}
h2{color:#fff;text-align:center;font-size:22px;margin:30px 0 10px 0;}
p.lead{color:#d9d9d9;text-align:center;margin:0 0 25px 0;font-size:16px}

.section-big-title{
  font-size:28px; font-weight:700; color:#fff; text-align:center; margin:30px 0 8px;
}
.links-section-title{
  margin:28px 0 12px; color:#fff; font-size:20px; font-weight:700; text-align:center;
}

/* ============ СПИСОК ГОРОДОВ ============ */
.cities{display:flex;flex-direction:column;gap:14px;margin-top:10px}
a.city{
  display:flex;align-items:center;gap:14px;
  text-decoration:none;color:var(--muted,#d9d9d9);
  background:linear-gradient(#232323, #1b1b1b);
  padding:16px 18px;border-radius:10px;border:3px solid rgba(255,255,255,0.12);
  box-shadow:0 6px 0 rgba(0,0,0,0.35) inset;
  transition:transform .12s ease, box-shadow .12s ease, border-color .12s ease;
}
a.city:hover{transform:translateY(-3px);border-color:rgba(255,255,255,0.32);}
.city .icon{
  width:48px;height:48px;border-radius:8px;flex:0 0 48px;
  background:linear-gradient(180deg,#2a2a2a,#151515);
  display:flex;align-items:center;justify-content:center;font-weight:700;color:#f6f6f6;
  border:1px solid rgba(255,255,255,0.05);
  box-shadow:0 2px 8px rgba(0,0,0,0.6);
}
.city .name{font-size:17px;color:#efefef}

/* ============ HERO (100% контейнера) ============ */
.hero-card{
  display:flex; gap:18px; align-items:stretch;
  width:100%;
  background: linear-gradient(180deg,#1f1f1f,#151515);
  border-radius:12px;
  border:3px solid rgba(255,255,255,0.85);
  overflow:hidden;
  text-decoration: none;
  color:#fff;
}
.hero-card .hero-img{
  flex:0 0 52%;
  display:flex; align-items:center; justify-content:center;
  border-right:1px solid rgba(255,255,255,0.08);
  background:#0e0e0e;
  aspect-ratio:16/9;
}
.hero-card .hero-img img{
  width:100%; height:100%; object-fit:contain; max-width:100%; max-height:100%;
  display:block;
}
.hero-card .hero-text{
  flex:1; padding:22px; display:flex; flex-direction:column; justify-content:center;
  background: rgba(0,0,0,0.45); color:#fff; text-align:center;
}
.hero-title{ font-size:clamp(18px, 3.2vw, 26px); font-weight:800; margin-bottom:6px; }
.hero-sub{ font-size:clamp(14px, 2.6vw, 18px); line-height:1.35; }

/* ============ СЕКЦИЯ ЧАТЫ (строго 100% контейнера) ============ */
/* ===== ЧАТЫ: заполняем всю ширину контейнера ===== */
.chats-grid{
  width:100%;
  max-width:none;
  margin:0 auto 10px;
  padding:0;
  display:grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap:10px;
  justify-items:stretch;
  align-items:stretch;
  box-sizing:border-box;
}

/* гарантируем, что каждая карточка занимает всю ячейку */
.chats-grid > .chat-tile{
  width:100%;
}

/* карточка */
.chat-tile{
  aspect-ratio: 4 / 3;
  border:2px solid rgba(255,255,255,0.75);
  border-radius:10px;
  overflow:hidden;
  background:#111;
  color:#fff;
  text-decoration:none;
  position:relative;
  display:block;
}

/* картинка внутри — заполняет карточку полностью */
.chat-tile .thumb{
  filter: brightness(0.35) contrast(0.9);
  width:100%;
  height:100%;
  background-size: cover;
  background-position: center;
}

/* отдельный мод для contain — он был только один раз, оставляем */
.chat-tile .thumb.is-contain{
  background-size: contain;
  background-repeat: no-repeat;
  background-color:#000;
}

/* подпись по центру */
.chat-tile .label{
  position:absolute; left:50%; top:50%;
  transform:translate(-50%,-50%);
  text-align:center; font-weight:700;
  font-size:12px; line-height:1.15;
  padding:3px 6px; text-transform:uppercase;
  text-shadow:0 1px 0 rgba(0,0,0,.6);
  max-width:90%;
  overflow-wrap:break-word;
  white-space:normal;
}

/* очень узкие экраны (если нужно ещё плотнее) */
@media (max-width:360px){
  .chats-grid{ gap:8px; }
  .chat-tile .label{ font-size:11px; }
}

/* ============ НИЖНИЙ СПИСОК (alist / ael) ============ */
.alist{
  width:100%;
  display:flex; flex-direction:column; gap:18px; margin:28px 0 8px;
  box-sizing:border-box;
}
.ael{
  display:flex; align-items:center; gap:14px;
  padding:10px 14px; min-height:72px;
  border:2px solid #fff; border-radius:12px;
  background:#1e1e1e; color:#fff; text-decoration:none;
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.08);
}
.ael > img{
  width:48px; height:48px; flex:0 0 48px; border-radius:8px; object-fit:cover;
}
.ael .text{
  display:flex; flex-direction:column; justify-content:center; gap:6px;
  min-width:0; max-width:100%; margin:0 auto; text-align:center;
}
.ael .name{
  font-family:"Merriweather", Georgia, serif;
  font-weight:800;
  font-size:clamp(16px, 2.4vw, 20px);
  line-height:1.15;
  overflow-wrap:anywhere;
}
.ael .desc{
  font-size:clamp(13px, 2vw, 15px);
  color:#e7e7e7; line-height:1.35; opacity:.95;
  overflow-wrap:anywhere; word-break:normal;
}
.ael:hover{
  border-color:#fff; box-shadow:inset 0 0 0 1px rgba(255,255,255,.18);
  transform:translateY(-1px); transition:.15s ease;
}

/* ============ КНОПКИ / ДЕЙСТВИЯ ============ */
.actions{
  width:100%;
  display:flex;
  flex-direction:column;
  gap:14px;
  margin-top:8px;
}

.big-btn{
  display:flex;
  align-items:center;
  gap:12px;
  width:100%;
  padding:14px 18px;
  border-radius:10px;
  background:linear-gradient(180deg,#111,#0b0b0b);
  color:#fff;
  text-decoration:none;
  border:2px solid rgba(255,255,255,0.9);
  box-shadow: 0 6px 0 rgba(0,0,0,0.45) inset;
  justify-content:center;
  font-weight:700;
  letter-spacing:0.6px;
  box-sizing: border-box;
}

.big-btn.secondary{
  background:linear-gradient(180deg,#232323,#131313);
  border:2px solid rgba(255,255,255,0.28);
  color:var(--muted);
}

.big-btn .emoji{font-size:20px}

.dashed-line {
  border-top: 2px dashed #333;
  margin: 20px 0;
}

/* ============ ФУТЕР ============ */
.footer-note{
  width:100%;
  margin-top:30px; padding:14px; border-radius:8px;
  border:1px solid rgba(255,255,255,0.06);
  font-size:13px; color:#bdbdbd;
  box-sizing:border-box;
  text-align:center;
}

/* ============ АДАПТИВ ============ */
@media (min-width: 821px) {
  .cities { align-items: center; }
  a.city { width: 70%; max-width: 700px; }
}

@media (max-width: 720px){
  .hero-card{ flex-direction:column; }
  .hero-card .hero-img{
    flex:0 0 auto; width:100%; aspect-ratio:16/10;
    border-right:none; border-bottom:1px solid rgba(255,255,255,0.08);
  }
  .hero-card .hero-text{ padding:16px; }
}

@media (max-width: 560px){
  .chats-grid{ gap:8px; }
  .alist{ gap:14px; }
  .ael{
    display:grid;
    grid-template-columns:56px 1fr;
    align-items:center;
    gap:10px 12px;
    padding:10px 12px;
    min-height:unset;
  }
  .ael > img{ width:56px; height:56px; grid-column:1; grid-row:1 / span 2; }
  .ael .text{ grid-column:2; grid-row:1 / span 2; align-items:flex-start; text-align:left; margin:0; }
  .ael .name{ font-size:16px; }
  .ael .desc{ font-size:13px; }
}

@media (max-width: 400px){
  .chats-grid{ gap:6px; }
  .chat-tile .label{ font-size:clamp(9px, 3.2vw, 11px); }
  .ael .name{ font-size:15px; }
  .ael .desc{ font-size:12px; }
}

@media (max-width:480px){
  .brand{font-size:32px}
  a.city{padding:12px}
  .city .name{font-size:15px}
  .tagline{ margin-top:-10px; }
}