/*
Theme Name: Telegram Hub
Theme URI: https://tgstickers.su/
Author: Igor K.
Description: Каталог стикеров, эмодзи и ботов.
Version: 1.0
License: GPLv2 or later
Text Domain: telegram-hub
*/
/* ===== Open Sans Local ===== */
@font-face {
  font-family: 'Open Sans';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('assets/fonts/open-sans-cyrillic.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Open Sans';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('assets/fonts/open-sans-cyrillic.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Open Sans';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('assets/fonts/open-sans-cyrillic.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Open Sans';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('assets/fonts/open-sans-cyrillic.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Open Sans';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('assets/fonts/open-sans-latin-v44.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191,
    U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Open Sans';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('assets/fonts/open-sans-latin-v44.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191,
    U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Open Sans';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('assets/fonts/open-sans-latin-v44.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191,
    U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Open Sans';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('assets/fonts/open-sans-latin-v44.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191,
    U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

*{
	margin:0;
	padding:0;
}
/* ===== :ROOT VARIABLES ===== */
:root {
  --bg: #ffffff;
  --text: #222;
  --link: #0088cc;
  --card-bg: #fff;
  --card-shadow: rgba(0,0,0,0.08);
  --border: #ddd;
  --hover: rgba(0,0,0,0.05);
  --bg-overlay: rgba(58, 58, 58, 0.8);
  --container-width: 1000px;
  --gap: 20px;
  --transition-fast: 0.2s ease;
  --transition-medium: 0.3s ease;
	--glass-bg: rgba(255, 255, 255, 0.45);
    --glass-border: 1px solid rgba(0, 0, 0, 0.06);
	
}

[data-theme='dark'] {
  --bg: #121212;
  --text: #e0e0e0;
  --link: #5eb8ff;
  --card-bg: #1e1e1e;
  --card-shadow: rgba(0,0,0,0.4);
  --border: #333;
  --hover: rgba(255,255,255,0.08);
  --bg-overlay: rgba(255, 255, 255, 0.8);
	--glass-bg: rgba(20, 22, 30, 0.45);
    --glass-border: 1px solid rgba(255, 255, 255, 0.08);
}

/* ===== BODY ===== */
body {
  font-family: "Open Sans", "Segoe UI", Tahoma, Arial, sans-serif;
  color: var(--text);
  margin: 0;
  padding: 0;
  line-height: 1.5;
  min-height: 100vh;
  overflow-x: hidden;
	 
}

/* === СВЕТЛАЯ ТЕМА === */
[data-theme="light"] body {
  background-image: linear-gradient(to bottom right, rgba(245, 252, 188, 0.8), rgba(152, 228, 172, 0.7)), url('/wp-content/themes/telegram-hub/assets/img/space.webp');


}

/* === ТЁМНАЯ ТЕМА === */
[data-theme="dark"] body {
  background-image: linear-gradient(to bottom right, rgba(80, 70, 160, 0.6), rgba(30, 25, 60, 0.85)), url('/wp-content/themes/telegram-hub/assets/img/space.webp');

}


/* ===== HEADER ===== */
header {
  position: sticky;
  top: 0;
  width: 100%;
  z-index: 50;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s, box-shadow 0.3s, backdrop-filter 0.3s;
  border-bottom: var(--glass-border);
  background: var(--glass-bg);
  backdrop-filter: blur(12px) saturate(1.05);
  -webkit-backdrop-filter: blur(12px) saturate(1.05);
}

/* ===== HEADER INNER ===== */
.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  max-width: var(--container-width);
  padding: 0 var(--gap);
  box-sizing: border-box;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 20px;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.logo-icon {
  width: 28px;
  height: 28px;
  margin-right: 8px;
}

.logo-text {
  color: #4eb1ea;
  font-weight: 600;
  font-size: 1.1rem;
  font-family: inherit;
  letter-spacing: 0.02em;
  display: inline-flex;
  align-items: center;
  position: relative;
  width: 13ch;
  white-space: nowrap;
  overflow: visible;
  transition: opacity 0.28s ease;
}

.logo-main {
  color: #4eb1ea;
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
}

.logo-main.logo-main-split {
  display: inline-flex;
  align-items: center;
}

.logo-seg {
  display: inline-block;
  will-change: transform, opacity;
  transition: transform 0.9s cubic-bezier(0.22, 0.61, 0.36, 1), opacity 0.78s ease;
}

.logo-suffix {
  color: #111111;
  font-weight: 700;
  display: inline-block;
  opacity: 0;
  transform: translateX(-8px);
  will-change: transform, opacity;
  transition: transform 0.56s cubic-bezier(0.22, 0.61, 0.36, 1), opacity 0.56s ease;
}

[data-theme='dark'] .logo-suffix {
  color: #e6edf4;
}

.logo-text.is-animating {
  opacity: 1;
}

.logo-main.logo-main-split.is-collapsing .logo-seg-ele {
  transform: translateX(var(--logo-ele-out-shift, -18px));
  opacity: 0;
}

.logo-main.logo-main-split.is-collapsing .logo-seg-dash {
  transform: translateX(var(--logo-dash-out-shift, -14px));
  opacity: 0;
}

.logo-main.logo-main-split.is-collapsing .logo-seg-gram {
  transform: translateX(var(--logo-gram-shift, -34px));
}

.logo-main.logo-main-split.is-collapsing .logo-seg-hub {
  transform: translateX(var(--logo-hub-shift, -44px));
}

.logo-suffix.is-visible {
  transform: translateX(0);
  opacity: 1;
}

/* ===== NAV LINKS ===== */
.main-nav a {
  text-decoration: none;
  color: var(--text);
  font-weight: 500;
  font-size: 0.95rem;
  transition: color var(--transition-fast), background var(--transition-fast);
  padding: 6px 10px;
  border-radius: 8px;
}

.main-nav a:hover {
  color: var(--link);
  background: var(--hover);
}

/* ===== ICON BUTTONS ===== */
.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border: none;
  background: transparent;
  cursor: pointer;
  color: var(--text);
  border-radius: 8px;
  transition: color var(--transition-fast), background var(--transition-fast), opacity 0.2s ease;
}

.icon-btn:hover {
  color: var(--link);
  background: var(--hover);
  opacity: 0.8;
}

.icon-btn svg {
  width: 20px;
  height: 20px;
  display: block;
  stroke: currentColor;
}

/* ===== THEME DROPDOWN ===== */
.theme-dropdown {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.theme-menu {
  position: absolute;
  top: 120%;
  right: 0;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.15);
  display: flex;
  flex-direction: column;
  min-width: 180px;
  overflow: hidden;
  z-index: 100;
  max-height: 0;
  opacity: 0;
  transition: max-height 0.25s ease, opacity 0.25s ease;
}

.theme-dropdown.open .theme-menu {
  max-height: 500px;
  opacity: 1;
}

.theme-menu button {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: none;
  border: none;
  text-align: left;
  font-size: 0.95rem;
  cursor: pointer;
  transition: background var(--transition-fast), color var(--transition-fast);
  background-clip: padding-box;
  width: 100%;
}

.theme-menu button svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  stroke: currentColor;
}

[data-theme='light'] .theme-menu button {
  color: #222;
}

[data-theme='dark'] .theme-menu button {
  color: #fff;
}

[data-theme='light'] .theme-menu button:hover {
  background: rgba(0, 0, 0, 0.05);
  color: #0088cc;
}

[data-theme='dark'] .theme-menu button:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #5eb8ff;
}

/* ===== BURGER MENU ===== */
.burger-btn {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  padding: 6px;
  color: var(--text);
}

body.no-scroll,
body.search-open,
body.ths-modal-open {
  overflow: hidden;
  overscroll-behavior: none;
}

/* Search overlay styles moved to plugin module-search.php */
#search-overlay.search-input {
  display: none;
}

#search-overlay.search-input.show {
  display: flex;
}

/* ===== Related tags block ===== */
.related-tags {
    margin: 1rem 0;
    padding: 1rem;
}

/* ===== Tag list grid ===== */
.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    padding: 0;
    margin: 0;
    list-style: none;
}

.tag-list .tag-item:hover{
	text-decoration:underline;
}

/* ===== Responsive ===== */
@media (max-width: 600px) {
    .related-tags {
        padding: 1rem;
    }
}

.skeleton-item {
    padding: 10px;
    border-radius: 12px;
    animation: pulse 1.6s infinite ease-in-out;
}
@keyframes pulse {
    0% { opacity: .7; }
    50% { opacity: 1; }
    100% { opacity: .7; }
}
.skeleton-thumb {
    width: 100%;
    height: 120px;
    background: rgba(255,255,255,0.08);
    border-radius: 12px;
    margin-bottom: 10px;
}
.skeleton-line {
    height: 12px;
    width: 80%;
    background: rgba(255,255,255,0.1);
    border-radius: 6px;
    margin-bottom: 6px;
}
.skeleton-line.short {
    width: 60%;
}



/* ===== NAVIGATION (MOBILE) ===== */
.nav-links {
  display: flex;
  gap: 10px;
  transition: max-height 0.3s ease;
  overflow: hidden;
  max-height: 1000px;
}

.glass {
  background: var(--glass-bg);
  backdrop-filter: blur(12px) saturate(1.05);
  -webkit-backdrop-filter: blur(12px) saturate(1.05);
	border: var(--glass-border);
  border-radius: 14px;
  transition: all var(--transition-medium);
}

#breadcrumbs {    
    padding: 10px 15px;
    border-radius: 8px;
    display: block;
    font-weight: 500;
    color: var(--text);
    margin-bottom: 1em;
	font-size:.95rem;
}

/* Стили ссылок в хлебных крошках */
#breadcrumbs a {
    color: var(--text);
    transition: color 0.3s ease-in-out;
}

#breadcrumbs a:hover {
    color: var(--link);
}


@media (max-width: 900px) {
  header {
    position: fixed;
  }

  .header-left {
    gap: 5px;
  }

  .header-right {
    gap: 0;
  }

  main {
    padding-top: 80px !important;
  }

  .burger-btn {
    display: block;
  }

  .nav-links {
    position: absolute;
    top: 60px;
    left: 0;
    right: 0;
    background: var(--bg);
    flex-direction: column;
    gap: 0;
    border-bottom: 1px solid var(--border);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    z-index: 99;
  }

  .nav-links a {
    padding: 12px 20px;
    border-top: 1px solid var(--border);
    border-radius: 0;
  }

  .nav-links a:hover {
    background: var(--hover);
    color: var(--link);
  }
}

/* ===== MAIN CONTAINER ===== */
main { max-width: var(--container-width); margin: 0 auto; padding: var(--gap); box-sizing: border-box; position: relative; z-index: 1; min-height:100vh; }

/* ===== FOOTER ===== */
footer { background: var(--card-bg); color: var(--text); padding: 20px var(--gap); text-align: center; border-top: none; box-shadow: none; position: relative; z-index: 80; }
.site-footer { max-width:var(--container-width); margin: 0 auto;}
.disclaimer { width: 100%; display: block; }

.subscribe-banner-anchor {
  position: relative;
  width: 100%;
  min-height: 44px;
}

.subscribe-banner {
  position: relative;
  width: 100%;
  z-index: 1;
  padding: 0;
  transition: opacity 0.2s ease;
}

.subscribe-banner.is-fixed {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 120;
}

.subscribe-banner.is-relative {
  position: relative;
}

.subscribe-banner[hidden] {
  display: none !important;
}

.subscribe-banner.is-hidden {
  opacity: 0;
}

body.search-open #subscribe-banner-anchor,
body.search-open #subscribe-banner {
  display: none !important;
}

.subscribe-banner__inner {
  width: 100%;
  box-sizing: border-box;
  margin: 0;
  background: var(--glass-bg);
  backdrop-filter: blur(12px) saturate(1.05);
  -webkit-backdrop-filter: blur(12px) saturate(1.05);
  border: none;
  border-radius: 0;
  box-shadow: none;
  padding: 12px 52px 12px 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  pointer-events: auto;
}

.subscribe-banner__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: var(--text);
  text-decoration: none;
  text-align: center;
  width: auto;
  max-width: 100%;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.35;
  transition: color var(--transition-fast), opacity var(--transition-fast);
}

.subscribe-banner__link:hover {
  color: var(--link);
}

.subscribe-banner__link:active {
  opacity: 0.9;
}

.subscribe-banner__icon {
  width: 18px;
  height: 18px;
  color: #229ed9;
  flex: 0 0 auto;
}

.subscribe-banner__close {
  width: 1.35em;
  height: 1.35em;
  background: transparent;
  border: none;
  opacity: 0.75;
  position: absolute;
  top: 50%;
  right: 15px;
  transform: translateY(-50%);
  cursor: pointer;
  padding: 0;
  appearance: none;
  -webkit-appearance: none;
  z-index: 2;
}

.subscribe-banner__close::before,
.subscribe-banner__close::after {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  width: 2px;
  height: 100%;
  background: var(--text, #242424);
  transform-origin: center;
}

.subscribe-banner__close::before {
  transform: translateX(-50%) rotate(45deg);
}

.subscribe-banner__close::after {
  transform: translateX(-50%) rotate(-45deg);
}

.subscribe-banner__close:hover {
  opacity: 1;
}

.subscribe-banner__close:focus {
  outline: none;
  box-shadow: 0 0 0 0.125em rgba(50, 115, 220, 0.25);
  border-radius: 2px;
}

@media (max-width: 700px) {
  .subscribe-banner__inner {
    flex-wrap: wrap;
    gap: 8px;
    padding: 10px 50px 10px 12px;
  }

  .subscribe-banner__link {
    width: 100%;
    font-size: 0.9rem;
  }

  .subscribe-banner__close {
    right: 12px;
  }
}

/* ===== LINKS ===== */
a {
  color: var(--link);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--link);
}


/* Заголовки */
h1 { font-size: 1.25rem; font-weight: 600; margin-bottom: 0.8rem; line-height: 1.25; color: var(--link); }
h2 { font-size: 1.15rem; font-weight: 600; margin-bottom: 0.5rem; line-height: 1.25; color: var(--text); }
h3 { font-size: 1rem; font-weight: 500; margin-bottom: 0.3rem; line-height: 1.25; color: var(--text); }
h4 { font-size: 0.95rem; font-weight: 500; margin-bottom: 0.25rem; line-height: 1.25; color: var(--text); }
h5 { font-size: 0.9rem; font-weight: 500; margin-bottom: 0.2rem; line-height: 1.25; color: var(--text); }
h6 { font-size: 0.85rem; font-weight: 500; margin-bottom: 0.2rem; line-height: 1.2; color: var(--text); }

/* Абзацы и текст */
p { font-size: 0.95rem; line-height: 1.5; margin-bottom: 1em; color: var(--text); }

/* Ссылки внутри текста */
p a { color: var(--link); text-decoration: underline; transition: color var(--transition-fast); }
p a:hover { color: var(--link); }

/* Дополнительные текстовые классы */
.text-small { font-size: 0.75rem; color: var(--text); }
.text-medium { font-size: 0.85rem; color: var(--text); }
.text-large { font-size: 0.95rem; color: var(--text); }
.text-bold { font-weight: 600; }
.text-center { text-align: center; }
.text-right { text-align: right; }

/* ===== BLOCKQUOTES ===== */
blockquote {
  border-left: 3px solid var(--link);
  padding-left: 10px;
  color: var(--text);
  font-style: italic;
  margin: 0.6em 0;
  background: rgba(0, 136, 204, 0.05);
  border-radius: 5px;
}

/* ===== LISTS ===== */
ul, ol { padding-left: 1em; margin-bottom: 0.6em; color: var(--text); font-size:0.95rem}
ul li { list-style-type: disc; margin-bottom: 0.3em; }
ol li { list-style-type: decimal; margin-bottom: 0.3em; }

/* ===== HIGHLIGHTED TEXT ===== */
mark { background-color: rgba(255, 235, 59, 0.25); padding: 0 2px; border-radius: 3px; }

/* ===== HORIZONTAL RULE ===== */
hr { border: 0; height: 1px; background: var(--border); margin: 0.8em 0; }



/* ===== UTILITIES ===== */
.flex { display: flex; align-items: center; justify-content: center; }
.flex-between { display: flex; justify-content: space-between; align-items: center; }
.hidden { display: none !important; }
.visible { display: block !important; }




.pagination { display: flex; justify-content: center; margin: 1em 0 .5em 0; gap: 5px;}
.pagination a, .pagination span { display: flex; align-items: center; justify-content: center; min-width: 30px; height: 30px; font-size: 15px; color: var(--text); background-color: var(--card-bg); border: 1px solid var(--border); border-radius: 6px; text-decoration: none; transition: all 0.3s ease; white-space: nowrap; box-shadow: 0 2px 4px var(--card-shadow); }
.pagination a:hover { background-color: var(--link); border-color: var(--link); color: #fff; }
.pagination .current { font-weight: 600; color: #fff; background-color: var(--link); border: 1px solid var(--link); }
.pagination .dots { width: auto; height: 30px; color: var(--text); background: transparent; border: none; box-shadow:none; padding: 0 10px; }

/* === OFFCANVAS === */
#offcanvas-toggle{ display:none; }
#offcanvas-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: var(--bg-overlay); z-index: 9998; display: none; transition: opacity 0.3s ease; cursor: pointer; }
#offcanvas-overlay.active { display: block; opacity: 1; }
#offcanvas-menu { position: fixed; top: 0; left: -400px; width: 400px; height: 100%; background: var(--bg); color: var(--text); box-sizing: border-box; z-index: 9999; transition: left 0.3s ease; display: flex; flex-direction: column; max-width: 100%; }
#offcanvas-menu.open { left: 0; }
.offcanvas-header {	display: flex; justify-content: space-between; align-items: center; padding: 1rem 1.25rem; border-bottom: 1px solid var(--border); }
.offcanvas-title { margin: 0; font-size: 1.25rem; font-weight: 600; }
.btn-close { width: 1.35em; height: 1.35em; background: transparent; border: none; opacity: 0.7; position: relative; cursor: pointer; }
.btn-close::before, .btn-close::after { content: ''; position: absolute; top: 0; left: 50%;	width: 2px;	height: 100%; background: var(--text); transform-origin: center; }
.btn-close::before { transform: rotate(45deg); }
.btn-close::after {	transform: rotate(-45deg); }
.btn-close:hover { opacity: 1; }
.offcanvas-body { flex: 1; overflow-y: auto; }
.offcanvas-nav { margin: 0;	padding: 0; }
.offcanvas-nav li {	list-style: none; margin: 0; }
.offcanvas-nav a { display: block; padding: 1rem 1.5rem; color: var(--text); text-decoration: none;	border-bottom: 1px solid var(--border); transition: background-color 0.2s, color 0.2s; }
.offcanvas-nav a:hover { background-color: var(--border); color: var(--link); }
.offcanvas-footer { padding: 1rem 1.25rem; border-top: 1px solid var(--border);	background: var(--bg-card-color); text-align: center; }
.offcanvas-footer a { display: inline-block; padding: 0.5rem 1rem; color: var(--link); text-decoration: none; font-size: 0.95rem; }
.offcanvas-footer a:hover {	background-color: var(--accent-hover, #0b5ed7); }
@media (max-width: 768px) { #offcanvas-menu { width: 100%; left: -100%; } #offcanvas-toggle{ display:block;	} }



/* === Archive Filter === */
#archive-filter {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

#archive-filter select {
  padding: 4px 8px;
  border-radius: 6px;
}

#archive-filter .count {
  font-size: 0.8em;
  color: var(--text);
}

/* === Category Container (Glass Style) === */
.category-container {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  width: 100%;
  box-sizing: border-box;
  gap: 1rem;
  margin: 1rem 0;
  padding: 10px 14px;
  max-width: 100%;
  color: var(--text);
}

/* === Filter Icon === */
.category-container .filter-icon {
  width: 20px;
  height: 20px;
}

html[data-theme='dark'] .filter-icon {
  filter: invert(1) brightness(2);
}

/* === Category List Links === */
.category-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
}

.category-link {
  text-decoration: none;
  color: inherit;
  font-size: 0.9rem;
  transition: all var(--transition-fast);
  padding: 3px 6px;
  border-radius: 6px;
}

.category-link:hover {
  color: var(--link);
}

.category-link.active {
  color: var(--link);
  font-weight: 600;
}

/* === Select Elements in Category Filter === */
.category-container select {
  background: var(--bg, 0.05);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 3px 7px;
  font-size: 0.95rem;
  color: var(--text);
  cursor: pointer;
  transition: all var(--transition-medium);
  min-width: 160px;
}

[data-theme='dark'] .category-container select {
  background: var(--bg, 0.05);
  border: 1px solid var(--border, 0.1);
  color: var(--text);
}

.category-container select:hover,
.category-container select:focus {
  background: var(--bg, 0.05);
  border-color: var(--link);
  outline: none;
}

/* === Stickers Grid === */
.stickers-grid{ display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 1rem; align-items: stretch; margin-bottom: 1.5rem; }
.sticker-item { display: flex; flex-direction: column; text-decoration: none; color: var(--text); background: var(--card-bg); border: 1px solid var(--border); border-radius: 16px; padding: 1rem; transition: all var(--transition-medium); box-shadow: 0 2px 6px var(--card-shadow); }
.sticker-item:hover { box-shadow: 0 4px 16px var(--card-shadow); text-decoration: none; }
.sticker-item h2 { font-size: 0.95rem; margin-top: 0.5rem; font-weight: 600; transition: color var(--transition-fast); word-wrap: break-word; }
.sticker-item:hover h2 { color: var(--link); }

/* === Sticker Preview === */
.sticker-preview { width: 100%; aspect-ratio: 1 / 1; display: flex; align-items: center; justify-content: center; background: var(--hover); border-radius: 12px; overflow: hidden; margin-bottom: 0.5rem; position: relative; }
.sticker-preview img, .sticker-preview video { max-width: 80%; max-height: 80%; object-fit: contain; display:block; transition: transform var(--transition-medium); }

[data-theme='light'] .sticker-item{
  background:#fff;
  border-color:#d9dde5;
  box-shadow:0 2px 10px rgba(15,23,42,.08);
}
[data-theme='light'] .sticker-preview{
  background:#f3f6fa;
}
[data-theme='dark'] .sticker-item{
  background:#1c1f24;
  border-color:#323844;
  box-shadow:0 3px 12px rgba(0,0,0,.35);
}
[data-theme='dark'] .sticker-preview{
  background:#252a33;
}

/* === Sticker Type Icons === */
.sticker-type-icon { position: absolute; top: 6px; right: 6px; width: 24px; height: 24px; background-size: contain; background-repeat: no-repeat; background-position: center; opacity: 0.9; z-index: 2; }
.sticker-type-icon.static { background-image: url('/wp-content/themes/telegram-hub/assets/img/icons/static.svg'); }
.sticker-type-icon.animated { background-image: url('/wp-content/themes/telegram-hub/assets/img/icons/animated.svg'); }
.sticker-type-icon.video { background-image: url('/wp-content/themes/telegram-hub/assets/img/icons/video.svg'); }


.box {
  background: var(--glass-bg);
  backdrop-filter: blur(12px) saturate(1.05);
  -webkit-backdrop-filter: blur(12px) saturate(1.05);
  border: var(--glass-border);
  border-radius: 12px;
  padding: 1em;
  margin-bottom: 1em;
  box-shadow: 0 10px 24px -14px rgba(15, 23, 42, 0.28);
  transition: background-color var(--transition-fast), box-shadow var(--transition-fast), border-color var(--transition-fast);
}

[data-theme='dark'] .box {
  box-shadow: 0 12px 28px -14px rgba(0, 0, 0, 0.6);
}

main > .box:first-of-type {
  box-shadow: 0 6px 14px -12px rgba(15, 23, 42, 0.3);
}

[data-theme='dark'] main > .box:first-of-type {
  box-shadow: 0 8px 16px -12px rgba(0, 0, 0, 0.62);
}

.btn { display: inline-block; font-size: 16px; font-weight: 500; padding: 12px 24px; border-radius: 5px; text-decoration: none; text-align: center; cursor: pointer; border: 0; margin: 20px auto; transition: background-color var(--transition-fast), transform var(--transition-fast), color var(--transition-fast); background-color: #0088cc; color: #fff; }
.btn:hover { text-decoration: none; background-color: #0078b0; color: #fff; }
.btn:active { transform: scale(0.98); }
.btn .btn-arrow { display: inline-block; font-size: 15px; line-height: 1; transform: translateY(1px); transition: transform var(--transition-fast); }


.btn-tg-icon {
  filter: invert(100%) sepia(100%) saturate(0%) hue-rotate(0deg);
  width: 15px;
  height: 15px;
  position: relative;
  right: 5px;
  top: 2px;
  display: inline-block;
}

a.btn {
  display: inline-block;
}

/* Теги */
.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.tag,
.cat-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 11px;
  border-radius: 5px;
  font-size: 12px;
  font-weight: 500;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  color: var(--text);
  background: rgba(255, 255, 255, 0.28);
  border: 1px solid rgba(0, 0, 0, 0.12);
  transition: color var(--transition-fast), background-color var(--transition-fast), border-color var(--transition-fast);
}

.tag:hover,
.cat-badge:hover {
  background: rgba(0, 136, 204, 0.12);
  border-color: rgba(0, 136, 204, 0.4);
  color: var(--link);
  text-decoration: none;
}

.tag:focus-visible,
.cat-badge:focus-visible {
  outline: 2px solid rgba(0, 136, 204, 0.35);
  outline-offset: 1px;
}

[data-theme='dark'] .tag,
[data-theme='dark'] .cat-badge {
  color: #d3dbe6;
  background: rgba(24, 28, 35, 0.45);
  border-color: rgba(255, 255, 255, 0.16);
}

[data-theme='dark'] .tag:hover,
[data-theme='dark'] .cat-badge:hover {
  color: #8fd6ff;
  background: rgba(94, 184, 255, 0.12);
  border-color: rgba(94, 184, 255, 0.4);
}

/* Главная */
.home-hero-simple {
  text-align: center;
  padding: clamp(20px, 4vw, 34px) 16px;
}

.home-main-title {
  margin: 0;
  font-size: 25px;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.home-main-counter {
  margin: 12px 0 0;
  font-size: 14px;
}

.home-main-counter strong {
  color: #0088cc;
  font-weight: 700;
}

.home-section-title {
  margin: 0 0 12px;
  text-align: center;
  font-size: 20px;
  line-height: 1.2;
}

.home-benefits-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.home-benefit-card {
  text-align: center;
  border-radius: 10px;
  padding: 14px 12px;
  border: 1px solid #e4e7ed;
  background: #ffffff;
}

.home-benefit-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 10px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  background: linear-gradient(180deg, rgba(0, 136, 204, 0.18), rgba(0, 136, 204, 0.08));
  border: 1px solid rgba(0, 136, 204, 0.25);
}

.home-benefit-title {
  margin: 0 0 8px;
  font-size: 16px;
  line-height: 1.2;
  color: #0088cc;
}

.home-benefit-text {
  margin: 0;
  font-size: 13px;
  line-height: 1.45;
  opacity: 0.9;
}

[data-theme='dark'] .home-benefit-card {
  border-color: rgba(255, 255, 255, 0.14);
  background: rgba(24, 28, 35, 1);
  color: #e3ebf6;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.28);
}

[data-theme='dark'] .home-benefit-icon {
  background: linear-gradient(180deg, rgba(94, 184, 255, 0.22), rgba(94, 184, 255, 0.08));
  border-color: rgba(94, 184, 255, 0.32);
}

[data-theme='dark'] .home-benefit-title {
  color: #8fd6ff;
}

.home-trends .ths-shortcode-wrap[data-type="sticker"] .ths-shortcode-grid,
.home-trends .ths-shortcode-wrap[data-type="emoji"] .ths-shortcode-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

@media (max-width: 980px) {
  .home-benefits-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .home-trends .ths-shortcode-wrap[data-type="sticker"] .ths-shortcode-grid,
  .home-trends .ths-shortcode-wrap[data-type="emoji"] .ths-shortcode-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .home-benefits-grid {
    grid-template-columns: 1fr;
  }
}

/* === Responsive === */

@media (max-width: 768px) {
  .stickers-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
		#archive-filter select {
			width:100%;
		}
	#archive-filter img.filter-icon, 
	#archive-filter .count{
		display:none;
	}
}
