:root {
  --primary-color: #27204a;
  --secondary-color: #3d365c;
}

[hidden] { display: none !important; }
button { font: inherit; color: inherit; cursor: pointer; }
button:focus-visible, summary:focus-visible {
  outline: 2px solid #5295ff;
  outline-offset: 4px;
}

#home_bg {
  background: linear-gradient(119deg, #27204a 0%, #27204a 31%, #3d365c 100%);
}

.neo-wordmark {
  display: inline-flex;
  width: min(100%, 200px);
  min-height: 60px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  vertical-align: middle;
  color: var(--primary-color);
  line-height: 1;
}

.neo-wordmark-name {
  font-size: 36px;
  font-weight: 700;
  font-style: italic;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.neo-wordmark-tv {
  display: flex;
  width: 104px;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.2em;
}

.neo-wordmark-tv::before, .neo-wordmark-tv::after {
  content: "";
  flex: 1;
  height: 1px;
  background: currentColor;
}

header .lang_box #lang_hndlr {
  display: block;
  width: 100%;
  border: 0;
  background: transparent;
}

.bw-flag {
  display: inline-block;
  width: 17px;
  height: 11px;
  background: linear-gradient(#75aadb 36%, white 36% 42%, #111 42% 58%, white 58% 64%, #75aadb 64%);
  vertical-align: 1px;
}

header .lang_box .lang_box_1 #lang-menu:not([hidden]) {
  display: block;
  min-width: 170px;
  overflow: visible;
  left: auto;
  right: 0;
  transform: none;
  border: 1px solid #ccc;
}

#lang-menu button {
  display: block;
  width: 100%;
  padding: 8px;
  border: 0;
  background: transparent;
  color: #27204a;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}

#lang-menu button:hover { background-color: #eeeef5; }

.home-download-buttons { width: 100%; }
.home-direct-download {
  min-height: 44px;
  border: 0;
  background: linear-gradient(135deg, #3d365c 0%, #27204a 100%);
}

.home-direct-download svg { flex: 0 0 auto; }
.download-badge {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  margin-right: 6px;
  border-radius: 7px;
  font: 700 18px/1 Arial, sans-serif;
  color: #fff;
}

.badge-android { background: #32734e; }
.badge-apk { background: #174a99; }
.badge-info { background: #773a69; }
.highlight-live { background: linear-gradient(135deg, #3e82ff 0%, #64e3e8 100%); }
.highlight-films { background: linear-gradient(135deg, #38cbdb 0%, #45c657 100%); }
.highlight-anywhere { background: linear-gradient(135deg, #4fd353 0%, #f1b926 100%); }
.highlight-films img, .highlight-anywhere img { clip-path: inset(0 4%); }

.faqs_box summary { cursor: pointer; list-style: none; }
.faqs_box summary::-webkit-details-marker { display: none; }
.faqs_box summary > span:first-child { flex-shrink: 0; }

.recent-posts-section {
  padding: 50px 0;
  background: #f9f9f9;
}

.recent-posts-section .section-title {
  margin-bottom: 30px;
  text-align: center;
  color: #27204a;
  font-size: 28px;
  font-weight: 600;
}

.posts-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 25px;
}

.post-card {
  overflow: hidden;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 2px 10px #00000014;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.post-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 20px #0000001f;
}

.post-thumbnail img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
}

.post-content { padding: 20px; }
.post-title {
  margin: 0 0 10px;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.4;
}

.post-excerpt {
  margin: 0 0 15px;
  color: #666;
  font-size: 14px;
  line-height: 1.6;
}

.read-more {
  padding: 0;
  border: 0;
  background: transparent;
  color: #27204a;
  font-size: 14px;
  font-weight: 500;
}

.read-more:hover, .footer_pages button:hover { text-decoration: underline; }
.footer_top { background: linear-gradient(135deg, #3d365c 0%, #27204a 100%); }
.footer_pages button {
  margin: 4px 7px;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font-size: var(--font-size-small);
}

#info-dialog {
  position: fixed;
  width: min(520px, calc(100vw - 32px));
  max-height: 85vh;
  margin: auto;
  padding: 30px;
  border: 0;
  border-radius: 16px;
  background: #fff;
  color: #27204a;
  box-shadow: 0 20px 80px #0005;
  font-family: Montserrat, Arial, sans-serif;
}

#info-dialog::backdrop { background: #1410279e; }
#info-dialog h2 {
  margin: 0 25px 16px 0;
  font-size: 22px;
  line-height: 1.4;
}

#info-dialog p, #info-dialog li {
  margin-bottom: 10px;
  color: #555;
  font-size: 15px;
  line-height: 1.65;
}

#info-dialog ol {
  padding-left: 22px;
  list-style: decimal;
}

.dialog-close {
  position: absolute;
  top: 8px;
  right: 10px;
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  font-size: 26px;
}

.dialog-done {
  min-height: 44px;
  margin-top: 10px;
  padding: 8px 20px;
  border: 0;
  border-radius: 7px;
  background: #27204a;
  color: #fff;
  font-size: 15px;
}

@media (min-width: 1201px) {
  header .lang_box #lang_hndlr .lang-desktop { color: white; }
}

@media (max-width: 992px) {
  .posts-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .home-direct-download {
    padding: 14px 20px !important;
    font-size: 15px !important;
  }
}

@media (max-width: 768px) {
  header .container {
    display: flex !important;
    align-items: center;
    flex-wrap: nowrap;
    min-height: 60px;
    padding: 10px 15px;
  }

  header .logo_wrap {
    width: auto !important;
    margin: 0 !important;
    float: none !important;
  }

  .neo-wordmark { width: 150px; min-height: 43px; }
  .neo-wordmark-name { font-size: 28px; }
  .neo-wordmark-tv { width: 80px; font-size: 9px; }

  header .lang_box {
    position: relative !important;
    inset: auto !important;
    width: 84px !important;
    height: 30px !important;
    margin: 0 0 0 auto !important;
    flex: 0 0 auto;
  }

  header .lang_box #lang_hndlr {
    height: 28px;
    padding: 0 5px;
    font-size: 12px;
    line-height: 28px;
  }

  header .lang_box .lang_box_1 #lang-menu { top: 28px; }
  .home-direct-download {
    width: 100%;
    padding: 12px 15px !important;
    font-size: 14px !important;
    line-height: 1.4;
    white-space: normal !important;
  }

  .home_banner .hb_txt .security_info ul li { justify-content: center; }
}

@media (max-width: 600px) {
  .posts-grid { grid-template-columns: 1fr; }
  .recent-posts-section { padding: 30px 0; }
  .recent-posts-section .section-title { font-size: 22px; }
}

@media (prefers-reduced-motion: reduce) {
  .post-card { transition: none; }
}
