/*
Theme Name: Conexão Cosmópolis
Theme URI: https://conexaocosmopolis.com.br
Author: Conexão Cosmópolis
Author URI: https://conexaocosmopolis.com.br
Description: Portal de notícias com layout de rede social. 3 colunas responsivas: sidebar de navegação icônica à esquerda, feed principal ao centro e sidebar de destaques à direita.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 8.0
License: GPL v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: conexao-cosmopolis
Tags: news, social, responsive, three-columns, custom-menu, featured-images, widgets
*/

/* =====================================================
   RESET & BASE
   ===================================================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --cc-bg: #f0f2f5;
  --cc-sidebar-bg: #1a2236;
  --cc-sidebar-text: #8b9ab0;
  --cc-sidebar-active: #4f8ef7;
  --cc-header-bg: #ffffff;
  --cc-card-bg: #ffffff;
  --cc-border: #e4e6ea;
  --cc-text: #1c1e21;
  --cc-text-primary: #1c1e21;
  --cc-text-secondary: #444950;
  --cc-text-muted: #65676b;
  --cc-accent: #4f8ef7;
  --cc-badge-bg: #e8f0ff;
  --cc-badge-text: #4f8ef7;
  --cc-hero-overlay: rgba(10,15,30,0.65);
  --cc-sidebar-width: 70px;
  --cc-right-width: 260px;
  --cc-header-height: 60px;
  --cc-ticker-height: 36px;
  --cc-font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --cc-radius: 12px;
  --cc-radius-sm: 6px;
  --cc-shadow: 0 1px 4px rgba(0,0,0,0.08);
  --cc-shadow-md: 0 4px 16px rgba(0,0,0,0.10);
}

/* =====================================================
   NEWS TICKER
   ===================================================== */
.cc-ticker {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 210;
  height: var(--cc-ticker-height);
  background: var(--cc-accent);
  color: #fff;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.cc-ticker__label {
  flex-shrink: 0;
  background: rgba(0,0,0,0.22);
  padding: 0 14px;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  height: 100%;
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.cc-ticker__label .dashicons { font-size: 14px; width: 14px; height: 14px; }

.cc-ticker__track {
  flex: 1;
  overflow: hidden;
  position: relative;
  height: 100%;
  display: flex;
  align-items: center;
}

.cc-ticker__inner {
  display: flex;
  align-items: center;
  white-space: nowrap;
  /* Duration: 30s = medium speed. Increase for slower, decrease for faster. */
  animation: cc-ticker-scroll 30s linear infinite;
}

.cc-ticker__inner a {
  color: #fff;
  font-size: 13px;
  font-weight: 500;
  padding: 0 20px;
  text-decoration: none;
  display: inline-block;
  transition: opacity 0.15s;
}

.cc-ticker__inner a:hover { opacity: 0.8; text-decoration: underline; }

.cc-ticker__sep {
  color: rgba(255,255,255,0.45);
  font-size: 12px;
  padding: 0 4px;
  flex-shrink: 0;
}

@keyframes cc-ticker-scroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

html { font-size: 15px; }

body {
  font-family: var(--cc-font);
  background: var(--cc-bg);
  color: var(--cc-text);
  line-height: 1.5;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }
ul { list-style: none; }

/* =====================================================
   LAYOUT WRAPPER
   ===================================================== */
.cc-layout {
  display: flex;
  /* push content below fixed ticker + header */
  margin-top: calc(var(--cc-ticker-height) + var(--cc-header-height));
  min-height: calc(100vh - var(--cc-ticker-height) - var(--cc-header-height));
}

/* =====================================================
   LEFT SIDEBAR — ICON NAV
   ===================================================== */
.cc-sidebar {
  width: var(--cc-sidebar-width);
  background: var(--cc-sidebar-bg);
  position: fixed;
  /* start below ticker + header */
  top: calc(var(--cc-ticker-height) + var(--cc-header-height));
  left: 0;
  bottom: 0;
  z-index: 200; /* above cat-drawer (150) and cat-backdrop (149) */
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 0;
  gap: 4px;
  overflow-y: auto;
  overflow-x: hidden;
}

/* Logo removed from sidebar — kept only in header */
.cc-sidebar__logo { display: none; }

a.cc-nav__item,
button.cc-nav__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  width: 56px;
  padding: 8px 4px;
  border-radius: 10px;
  cursor: pointer;
  transition: background 0.15s ease;
  color: var(--cc-sidebar-text);
  /* reset button defaults */
  background: transparent;
  border: none;
  font-family: inherit;
  text-align: center;
}

a.cc-nav__item:hover,
a.cc-nav__item.is-active,
button.cc-nav__item:hover,
button.cc-nav__item.is-active {
  background: rgba(79,142,247,0.12);
  color: var(--cc-sidebar-active);
}

.cc-nav__item svg,
.cc-nav__item .dashicons {
  font-size: 20px;
  width: 22px;
  height: 22px;
}

.cc-nav__label {
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  line-height: 1;
}

/* =====================================================
   CATEGORY DRAWER (Temas)
   ===================================================== */
.cc-cat-backdrop {
  position: fixed;
  /* Only cover content below the sidebar — not the header */
  top: calc(var(--cc-ticker-height) + var(--cc-header-height));
  left: var(--cc-sidebar-width);
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.45);
  z-index: 149;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
}

.cc-cat-backdrop.is-open {
  opacity: 1;
  pointer-events: all;
}

.cc-cat-drawer {
  position: fixed;
  top: calc(var(--cc-ticker-height) + var(--cc-header-height));
  left: var(--cc-sidebar-width);
  width: 280px;
  height: calc(100vh - var(--cc-ticker-height) - var(--cc-header-height));
  background: var(--cc-sidebar-bg);
  z-index: 150;
  display: flex;
  flex-direction: column;
  transform: translateX(-110%);
  transition: transform 0.25s cubic-bezier(0.4,0,0.2,1);
  box-shadow: 4px 0 32px rgba(0,0,0,0.28);
  overflow: hidden;
}

.cc-cat-drawer.is-open {
  transform: translateX(0);
}

.cc-cat-drawer__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px 14px;
  border-bottom: 1px solid rgba(255,255,255,0.07);
  flex-shrink: 0;
}

.cc-cat-drawer__title {
  font-size: 15px;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.3px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.cc-cat-drawer__title .dashicons {
  color: var(--cc-accent);
  font-size: 18px;
  width: 18px;
  height: 18px;
}

.cc-cat-drawer__close {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: rgba(255,255,255,0.07);
  border: none;
  cursor: pointer;
  color: var(--cc-sidebar-text);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, color 0.15s;
}

.cc-cat-drawer__close:hover {
  background: rgba(255,255,255,0.14);
  color: #fff;
}

.cc-cat-drawer__close .dashicons { font-size: 16px; width: 16px; height: 16px; }

.cc-cat-drawer__body {
  flex: 1;
  overflow-y: auto;
  padding: 12px 12px 24px;
}

.cc-cat-drawer__body::-webkit-scrollbar { width: 4px; }
.cc-cat-drawer__body::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 2px; }

.cc-cat-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 12px;
  border-radius: 10px;
  cursor: pointer;
  text-decoration: none;
  color: var(--cc-sidebar-text);
  transition: background 0.15s, color 0.15s;
  margin-bottom: 2px;
}

.cc-cat-item:hover {
  background: rgba(79,142,247,0.12);
  color: #fff;
}

.cc-cat-item.is-current {
  background: rgba(79,142,247,0.18);
  color: var(--cc-accent);
}

.cc-cat-item__dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  background: var(--cc-accent);
}

.cc-cat-item__name {
  flex: 1;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.2;
}

.cc-cat-item__count {
  font-size: 11px;
  font-weight: 700;
  color: inherit;
  opacity: 0.5;
  background: rgba(255,255,255,0.07);
  padding: 2px 7px;
  border-radius: 10px;
}

/* Drawer search */
.cc-cat-drawer__search {
  position: relative;
  margin: 0 12px 12px;
}

.cc-cat-drawer__search input {
  width: 100%;
  padding: 9px 14px 9px 36px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  color: #fff;
  font-size: 13px;
  font-family: inherit;
  outline: none;
  transition: border-color 0.15s;
  box-sizing: border-box;
}

.cc-cat-drawer__search input::placeholder { color: var(--cc-sidebar-text); }
.cc-cat-drawer__search input:focus { border-color: var(--cc-accent); }

.cc-cat-drawer__search .dashicons {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--cc-sidebar-text);
  font-size: 15px;
  width: 15px;
  height: 15px;
  pointer-events: none;
}

/* Mobile: drawer becomes bottom sheet — backdrop starts below ticker+header */
@media (max-width: 768px) {
  .cc-cat-backdrop {
    left: 0;
    top: calc(var(--cc-ticker-height) + var(--cc-header-height));
  }
  .cc-cat-drawer {
    left: 0;
    top: auto;
    bottom: 56px;
    width: 100%;
    height: 70vh;
    border-radius: 20px 20px 0 0;
    transform: translateY(110%);
  }
  .cc-cat-drawer.is-open { transform: translateY(0); }
}

/* =====================================================
   MAIN WRAPPER (everything right of the sidebar)
   ===================================================== */
.cc-main-wrapper {
  margin-left: var(--cc-sidebar-width);
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: calc(100vh - var(--cc-ticker-height) - var(--cc-header-height));
}

/* =====================================================
   HEADER — full-width, fixed below ticker
   ===================================================== */
.cc-header {
  position: fixed;
  top: var(--cc-ticker-height);
  left: 0;
  right: 0;
  width: 100%;
  z-index: 95;
  background: var(--cc-header-bg);
  border-bottom: 1px solid var(--cc-border);
  height: var(--cc-header-height);
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 16px;
  box-shadow: var(--cc-shadow);
}

.cc-header__brand {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.cc-header__avatar {
  width: 36px;
  height: 36px;
  background: var(--cc-accent);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 13px;
  color: #fff;
}

.cc-header__brand-name {
  font-weight: 700;
  font-size: 15px;
  white-space: nowrap;
}

.cc-header__search {
  flex: 1;
  max-width: 400px;
  margin: 0 auto;
  position: relative;
}

/* Custom search form inside header */
.cc-search-form {
  display: flex;
  align-items: center;
  width: 100%;
  position: relative;
}

.cc-search-form input[type="search"],
.cc-header__search input[type="search"] {
  width: 100%;
  background: #f0f2f5;
  border: none;
  border-radius: 20px;
  padding: 8px 40px 8px 38px;
  font-size: 14px;
  outline: none;
  font-family: var(--cc-font);
  color: var(--cc-text);
  transition: background 0.15s;
  -webkit-appearance: none;
}

.cc-search-form input[type="search"]:focus,
.cc-header__search input[type="search"]:focus {
  background: #e4e6ea;
}

/* Submit button inside the form — positioned absolutely */
.cc-search-form button[type="submit"] {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  color: var(--cc-text-muted);
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.15s;
}

.cc-search-form button[type="submit"]:hover { color: var(--cc-accent); }
.cc-search-form button[type="submit"] .dashicons { font-size: 16px; width: 16px; height: 16px; }

.cc-header__search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--cc-text-muted);
  pointer-events: none;
  z-index: 1;
}

.cc-header__meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  color: var(--cc-text-muted);
  font-size: 13px;
}

.cc-header__time-weather {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 500;
  padding: 4px 10px;
  background: #f0f2f5;
  border-radius: 20px;
}

.cc-header__icon-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #f0f2f5;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cc-text-muted);
  transition: background 0.15s;
}

.cc-header__icon-btn:hover { background: #e4e6ea; color: var(--cc-text); }

.cc-header__user-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--cc-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 13px;
  color: #fff;
  cursor: pointer;
  overflow: hidden;
}

.cc-header__user-avatar img { width: 100%; height: 100%; object-fit: cover; }

/* =====================================================
   CONTENT AREA (main + right sidebar)
   ===================================================== */
.cc-content-area {
  display: flex;
  gap: 16px;
  padding: 16px;
  max-width: 100%;
  flex: 1;
}

.cc-feed-area {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* =====================================================
   HERO / FEATURED POST
   ===================================================== */
.cc-hero {
  position: relative;
  border-radius: var(--cc-radius);
  overflow: hidden;
  min-height: 200px;
  background: #1a2236;
  box-shadow: var(--cc-shadow-md);
}

.cc-hero__image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.55;
}

.cc-hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(10,15,30,0.85) 0%, rgba(10,15,30,0.20) 60%, transparent 100%);
}

.cc-hero__content {
  position: relative;
  z-index: 2;
  padding: 20px;
  min-height: 200px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  color: #fff;
}

.cc-hero__meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.cc-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  background: var(--cc-badge-bg);
  color: var(--cc-badge-text);
}

.cc-hero .cc-badge {
  background: rgba(79,142,247,0.85);
  color: #fff;
}

.cc-hero__date { font-size: 13px; opacity: 0.75; }

.cc-hero__title {
  font-size: clamp(20px, 3vw, 28px);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 12px;
}

.cc-hero__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.cc-hero__author {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.cc-hero__author-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--cc-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  color: #fff;
  overflow: hidden;
}

.cc-hero__author-avatar img { width: 100%; height: 100%; object-fit: cover; }

.cc-hero__stats {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  opacity: 0.85;
}

.cc-hero__stats span { display: flex; align-items: center; gap: 4px; }

/* =====================================================
   FILTER TABS
   ===================================================== */
.cc-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
  background: var(--cc-card-bg);
  border-radius: var(--cc-radius);
  padding: 6px;
  box-shadow: var(--cc-shadow);
  overflow-x: auto;
  scrollbar-width: none;
}

.cc-tabs::-webkit-scrollbar { display: none; }

.cc-tabs__tab {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: var(--cc-radius-sm);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  border: none;
  background: transparent;
  color: var(--cc-text-muted);
  transition: all 0.15s;
}

.cc-tabs__tab:hover { background: var(--cc-bg); color: var(--cc-text); }

.cc-tabs__tab.is-active {
  background: var(--cc-accent);
  color: #fff;
}

.cc-tabs__sort {
  margin-left: auto;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 6px 12px;
  border-radius: var(--cc-radius-sm);
  font-size: 13px;
  font-weight: 600;
  border: 1px solid var(--cc-border);
  background: var(--cc-card-bg);
  cursor: pointer;
  color: var(--cc-text-muted);
}

/* =====================================================
   POST CARD (TIMELINE)
   ===================================================== */
.cc-post-card {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.cc-post-card__date-col {
  flex-shrink: 0;
  width: 52px;
  text-align: center;
  padding-top: 4px;
  position: relative;
}

.cc-post-card__day {
  font-size: 22px;
  font-weight: 800;
  line-height: 1;
  color: var(--cc-text);
}

.cc-post-card__month {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--cc-text-muted);
}

.cc-post-card__time {
  font-size: 11px;
  color: var(--cc-text-muted);
  margin-top: 4px;
}

.cc-post-card__dot {
  width: 8px;
  height: 8px;
  background: var(--cc-accent);
  border-radius: 50%;
  margin: 6px auto 0;
}

.cc-post-card__body {
  flex: 1;
  background: var(--cc-card-bg);
  border-radius: var(--cc-radius);
  box-shadow: var(--cc-shadow);
  overflow: hidden;
  display: flex;
  transition: box-shadow 0.15s;
}

.cc-post-card__body:hover {
  box-shadow: var(--cc-shadow-md);
}

.cc-post-card__body > a {
  flex-shrink: 0;
  display: block;
  align-self: stretch;
  overflow: hidden;
}

.cc-post-card__thumb {
  width: 250px;
  height: 100%;
  flex-shrink: 0;
  object-fit: cover;
  background: var(--cc-bg);
  align-self: stretch;
}

.cc-post-card__info {
  flex: 1;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.cc-post-card__category { font-size: 11px; }

.cc-post-card__title {
  font-size: 15px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--cc-text);
}

.cc-post-card__excerpt {
  font-size: 13px;
  color: var(--cc-text-muted);
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  flex: 1;
}

.cc-post-card__footer {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: auto;
  padding-top: 8px;
  border-top: 1px solid var(--cc-border);
}

.cc-post-card__action {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: var(--cc-text-muted);
  cursor: pointer;
  background: none;
  border: none;
  padding: 2px 6px;
  border-radius: 4px;
  transition: all 0.15s;
}

.cc-post-card__action:hover { background: var(--cc-bg); color: var(--cc-accent); }

.cc-post-card__author {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--cc-text-muted);
}

.cc-post-card__author-avatar {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--cc-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 9px;
  font-weight: 700;
  color: #fff;
  overflow: hidden;
}

.cc-post-card__author-avatar img { width: 100%; height: 100%; object-fit: cover; }

/* =====================================================
   RIGHT SIDEBAR
   ===================================================== */
.cc-right-sidebar {
  width: var(--cc-right-width);
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.cc-widget {
  background: var(--cc-card-bg);
  border-radius: var(--cc-radius);
  box-shadow: var(--cc-shadow);
  overflow: hidden;
}

.cc-widget__header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--cc-border);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--cc-text-muted);
}

.cc-most-read__item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--cc-border);
  transition: background 0.15s;
  cursor: pointer;
}

.cc-most-read__item:last-child { border-bottom: none; }

.cc-most-read__item:hover { background: var(--cc-bg); }

.cc-most-read__rank {
  font-size: 20px;
  font-weight: 900;
  color: var(--cc-border);
  line-height: 1;
  flex-shrink: 0;
  width: 24px;
}

.cc-most-read__title {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.35;
  color: var(--cc-text);
}

.cc-most-read__views {
  font-size: 11px;
  color: var(--cc-text-muted);
  margin-top: 2px;
}

/* =====================================================
   SITE FOOTER (inside right sidebar)
   ===================================================== */
.cc-site-footer {
  padding: 16px;
  font-size: 12px;
  color: var(--cc-text-muted);
}

.cc-site-footer__name {
  font-weight: 700;
  color: var(--cc-text);
  margin-bottom: 6px;
}

.cc-site-footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 10px;
  margin-bottom: 8px;
}

.cc-site-footer__links a:hover { color: var(--cc-accent); }

.cc-site-footer__copyright { margin-top: 8px; }

/* =====================================================
   SINGLE POST
   ===================================================== */
.cc-single {
  background: var(--cc-card-bg);
  border-radius: var(--cc-radius);
  box-shadow: var(--cc-shadow-md);
  overflow: hidden;
}

.cc-single__hero {
  width: 100%;
  max-height: 400px;
  object-fit: cover;
}

.cc-single__content {
  padding: 24px;
}

.cc-single__category { margin-bottom: 8px; }

.cc-single__title {
  font-size: clamp(22px, 3.5vw, 32px);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 12px;
}

.cc-single__meta {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  color: var(--cc-text-muted);
  padding-bottom: 16px;
  border-bottom: 1px solid var(--cc-border);
  margin-bottom: 20px;
}

.cc-single__body {
  font-size: 16px;
  line-height: 1.7;
  color: var(--cc-text);
}

.cc-single__body p { margin-bottom: 1em; }

.cc-single__body h2,
.cc-single__body h3 { margin: 1.5em 0 0.5em; font-weight: 700; }

/* =====================================================
   PAGINATION
   ===================================================== */
.cc-pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  padding: 8px 0;
}

.cc-pagination a,
.cc-pagination span {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--cc-radius-sm);
  font-size: 14px;
  font-weight: 600;
  border: 1px solid var(--cc-border);
  background: var(--cc-card-bg);
  color: var(--cc-text-muted);
  transition: all 0.15s;
}

.cc-pagination a:hover,
.cc-pagination .current {
  background: var(--cc-accent);
  color: #fff;
  border-color: var(--cc-accent);
}

/* =====================================================
   MOBILE BOTTOM NAV
   ===================================================== */
.cc-mobile-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--cc-sidebar-bg);
  z-index: 200;
  padding: 8px 0;
  box-shadow: 0 -2px 12px rgba(0,0,0,0.15);
}

.cc-mobile-nav ul {
  display: flex;
  justify-content: space-around;
  align-items: center;
}

.cc-mobile-nav li a,
.cc-mobile-nav li button {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  color: var(--cc-sidebar-text);
  font-size: 9px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 4px 8px;
  /* reset button defaults */
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  width: 100%;
  text-align: center;
}

.cc-mobile-nav li.current-menu-item a,
.cc-mobile-nav li.current-menu-item button { color: var(--cc-sidebar-active); }

.cc-mobile-nav li a .dashicons,
.cc-mobile-nav li button .dashicons { font-size: 20px; width: 20px; height: 20px; }

/* =====================================================
   RESPONSIVE
   ===================================================== */
@media (max-width: 1100px) {
  .cc-right-sidebar { display: none; }
}

@media (max-width: 768px) {
  .cc-sidebar { display: none; }
  .cc-main-wrapper { margin-left: 0; }
  .cc-mobile-nav { display: block; }
  body { padding-bottom: 72px; }
  .cc-content-area { padding: 12px; }
  .cc-header__brand-name { display: none; }
  .cc-header__time-weather { display: none; }
  .cc-post-card__date-col { width: 40px; }
  .cc-post-card__day { font-size: 18px; }
  .cc-post-card__thumb { width: 90px; }
}

@media (max-width: 480px) {
  .cc-post-card__date-col { display: none; }
  .cc-post-card__thumb { width: 80px; }
  .cc-header { padding: 0 12px; gap: 8px; }
  .cc-header__search { max-width: unset; }
}

/* =====================================================
   COLUNISTA — sidebar nav item highlight
   ===================================================== */
.cc-nav__item--colunista {
  background: rgba(79,142,247,0.08);
  border: 1px solid rgba(79,142,247,0.20);
  color: var(--cc-sidebar-active);
  margin-top: 8px;
}

.cc-nav__item--colunista:hover,
.cc-nav__item--colunista.is-active {
  background: rgba(79,142,247,0.22);
}

/* Colunista quick badge in header */
.cc-header__colunista-badge {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 4px 12px;
  background: var(--cc-accent);
  color: #fff;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.15s;
}

.cc-header__colunista-badge:hover { background: #3a7de0; }
.cc-header__colunista-badge .dashicons { font-size: 15px; width: 15px; height: 15px; }

@media (max-width: 768px) {
  .cc-header__colunista-badge span:last-child { display: none; }
}

/* =====================================================
   HERO SLIDER
   ===================================================== */
.cc-slider {
  position: relative;
  border-radius: var(--cc-radius);
  overflow: hidden;
  min-height: 220px;
  background: #1a2236;
  box-shadow: var(--cc-shadow-md);
}

.cc-slider__track {
  display: flex;
  transition: transform 0.5s cubic-bezier(0.4,0,0.2,1);
  height: 100%;
}

.cc-slider__slide {
  flex-shrink: 0;
  width: 100%;
  position: relative;
  min-height: 220px;
  cursor: pointer;
}

.cc-slider__slide-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.55;
}

.cc-slider__slide-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(10,15,30,0.88) 0%, rgba(10,15,30,0.22) 60%, transparent 100%);
}

.cc-slider__slide-content {
  position: relative;
  z-index: 2;
  padding: 20px;
  min-height: 220px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  color: #fff;
}

.cc-slider__slide-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.cc-slider__slide-title {
  font-size: clamp(18px, 3vw, 26px);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 12px;
}

.cc-slider__slide-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.cc-slider__slide-author {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.cc-slider__slide-author-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--cc-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  color: #fff;
  overflow: hidden;
}

.cc-slider__slide-author-avatar img { width: 100%; height: 100%; object-fit: cover; }

.cc-slider__slide-stats {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  opacity: 0.85;
}

.cc-slider__slide-stats span { display: flex; align-items: center; gap: 4px; }

.cc-slider__btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255,255,255,0.15);
  border: none;
  cursor: pointer;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
  backdrop-filter: blur(4px);
}

.cc-slider__btn:hover { background: rgba(255,255,255,0.30); }
.cc-slider__btn--prev { left: 12px; }
.cc-slider__btn--next { right: 12px; }

.cc-slider__dots {
  position: absolute;
  bottom: 14px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 10;
}

.cc-slider__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255,255,255,0.4);
  border: none;
  cursor: pointer;
  padding: 0;
  transition: all 0.2s;
}

.cc-slider__dot.is-active {
  background: #fff;
  width: 18px;
  border-radius: 3px;
}

/* =====================================================
   DISLIKE BUTTON
   ===================================================== */
.cc-post-card__action.is-liked    { color: #e03e3e; }
.cc-post-card__action.is-disliked { color: #f59e0b; }
.cc-post-card__action.is-saved    { color: var(--cc-accent); }

/* =====================================================
   COMMENTS SECTION — FACEBOOK STYLE
   ===================================================== */
.cc-comments {
  display: none;
  flex-direction: column;
  border-top: 1px solid var(--cc-border);
  background: var(--cc-card-bg);
}

.cc-comments.is-open { display: flex; }

.cc-comments__list {
  display: flex;
  flex-direction: column;
  gap: 0;
  max-height: 260px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--cc-border) transparent;
}

.cc-comment {
  display: flex;
  gap: 8px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--cc-border);
}

.cc-comment:last-child { border-bottom: none; }

.cc-comment__avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--cc-accent);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 700;
  color: #fff;
  overflow: hidden;
}

.cc-comment__avatar img { width: 100%; height: 100%; object-fit: cover; }

.cc-comment__bubble {
  background: var(--cc-bg);
  border-radius: 12px;
  padding: 7px 12px;
  flex: 1;
  min-width: 0;
}

.cc-comment__author {
  font-size: 12px;
  font-weight: 700;
  color: var(--cc-text);
  margin-bottom: 2px;
}

.cc-comment__author a { color: var(--cc-accent); }

.cc-comment__text {
  font-size: 13px;
  color: var(--cc-text);
  line-height: 1.4;
  word-break: break-word;
}

.cc-comment__text .cc-mention {
  color: var(--cc-accent);
  font-weight: 600;
}

.cc-comment__meta {
  font-size: 11px;
  color: var(--cc-text-muted);
  margin-top: 4px;
}

.cc-comments__more {
  padding: 8px 12px;
  font-size: 12px;
  font-weight: 600;
  color: var(--cc-accent);
  cursor: pointer;
  background: none;
  border: none;
  text-align: left;
}

.cc-comments__form {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  background: var(--cc-bg);
  position: relative;
}

.cc-comments__form-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--cc-accent);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 700;
  color: #fff;
  overflow: hidden;
}

.cc-comments__form-avatar img { width: 100%; height: 100%; object-fit: cover; }

.cc-comments__input-wrap {
  flex: 1;
  position: relative;
}

.cc-comments__input {
  width: 100%;
  background: var(--cc-card-bg);
  border: 1px solid var(--cc-border);
  border-radius: 20px;
  padding: 7px 40px 7px 14px;
  font-size: 13px;
  outline: none;
  resize: none;
  overflow: hidden;
  min-height: 34px;
  max-height: 100px;
  font-family: var(--cc-font);
  color: var(--cc-text);
  transition: border 0.15s;
  line-height: 1.4;
}

.cc-comments__input:focus { border-color: var(--cc-accent); }

.cc-comments__submit {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  color: var(--cc-accent);
  display: flex;
  align-items: center;
  padding: 2px;
  opacity: 0.5;
  transition: opacity 0.15s;
}

.cc-comments__submit.is-active { opacity: 1; }

.cc-comments__login-prompt {
  padding: 12px;
  text-align: center;
  font-size: 13px;
  color: var(--cc-text-muted);
  background: var(--cc-bg);
}

.cc-comments__login-prompt a {
  color: var(--cc-accent);
  font-weight: 600;
}

/* Mention autocomplete */
.cc-mention-dropdown {
  position: absolute;
  bottom: calc(100% + 4px);
  left: 0;
  right: 0;
  background: var(--cc-card-bg);
  border: 1px solid var(--cc-border);
  border-radius: var(--cc-radius-sm);
  box-shadow: var(--cc-shadow-md);
  z-index: 300;
  max-height: 160px;
  overflow-y: auto;
  display: none;
}

.cc-mention-dropdown.is-open { display: block; }

.cc-mention-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  cursor: pointer;
  font-size: 13px;
  transition: background 0.1s;
}

.cc-mention-item:hover { background: var(--cc-bg); }

.cc-mention-item__avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--cc-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 9px;
  font-weight: 700;
  color: #fff;
  overflow: hidden;
  flex-shrink: 0;
}

.cc-mention-item__avatar img { width: 100%; height: 100%; object-fit: cover; }

.cc-mention-item__name { font-weight: 600; color: var(--cc-text); }

/* =====================================================
   SHARE MODAL
   ===================================================== */
.cc-share-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 500;
  align-items: center;
  justify-content: center;
}

.cc-share-modal.is-open { display: flex; }

.cc-share-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.45);
}

.cc-share-modal__box {
  position: relative;
  z-index: 1;
  background: var(--cc-card-bg);
  border-radius: var(--cc-radius);
  padding: 24px;
  width: min(400px, 92vw);
  box-shadow: var(--cc-shadow-md);
}

.cc-share-modal__title {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 16px;
}

.cc-share-modal__url {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
}

.cc-share-modal__url input {
  flex: 1;
  background: var(--cc-bg);
  border: 1px solid var(--cc-border);
  border-radius: var(--cc-radius-sm);
  padding: 8px 12px;
  font-size: 13px;
  outline: none;
}

.cc-share-modal__url button {
  padding: 8px 14px;
  background: var(--cc-accent);
  color: #fff;
  border: none;
  border-radius: var(--cc-radius-sm);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.cc-share-modal__networks {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.cc-share-modal__net {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 10px 14px;
  border-radius: var(--cc-radius-sm);
  background: var(--cc-bg);
  cursor: pointer;
  font-size: 11px;
  font-weight: 600;
  color: var(--cc-text-muted);
  border: none;
  transition: background 0.15s;
  text-decoration: none;
}

.cc-share-modal__net:hover { background: var(--cc-border); }

.cc-share-modal__close {
  position: absolute;
  top: 12px;
  right: 12px;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--cc-text-muted);
  font-size: 18px;
}

/* =====================================================
   COMMUNITY PAGE
   ===================================================== */
.cc-community {
  padding: 0;
}

.cc-community__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  flex-wrap: wrap;
  gap: 8px;
}

.cc-community__title {
  font-size: 18px;
  font-weight: 800;
}

.cc-community__search {
  position: relative;
}

.cc-community__search input {
  background: var(--cc-card-bg);
  border: 1px solid var(--cc-border);
  border-radius: 20px;
  padding: 7px 14px 7px 34px;
  font-size: 13px;
  outline: none;
  width: 200px;
}

.cc-community__search .dashicons {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--cc-text-muted);
  font-size: 16px;
}

.cc-community__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 12px;
}

.cc-user-card {
  background: var(--cc-card-bg);
  border-radius: var(--cc-radius);
  box-shadow: var(--cc-shadow);
  padding: 20px 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  text-align: center;
  transition: box-shadow 0.15s;
}

.cc-user-card:hover { box-shadow: var(--cc-shadow-md); }

.cc-user-card__avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--cc-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 800;
  color: #fff;
  overflow: hidden;
  flex-shrink: 0;
}

.cc-user-card__avatar img { width: 100%; height: 100%; object-fit: cover; }

.cc-user-card__name {
  font-size: 14px;
  font-weight: 700;
  color: var(--cc-text);
  line-height: 1.2;
}

.cc-user-card__stats {
  font-size: 12px;
  color: var(--cc-text-muted);
}

.cc-follow-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 14px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  border: 2px solid var(--cc-accent);
  background: var(--cc-accent);
  color: #fff;
  transition: all 0.15s;
}

.cc-follow-btn.is-following {
  background: transparent;
  color: var(--cc-accent);
}

.cc-follow-btn:hover.is-following {
  background: #ffeaea;
  border-color: #e03e3e;
  color: #e03e3e;
}

/* =====================================================
   PROFILE PAGE (author.php)
   ===================================================== */
.cc-profile {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.cc-profile__card {
  background: var(--cc-card-bg);
  border-radius: var(--cc-radius);
  box-shadow: var(--cc-shadow-md);
  overflow: hidden;
}

.cc-profile__cover {
  height: 140px;
  background: linear-gradient(135deg, #0f1829 0%, #1a2236 45%, #4f8ef7 100%);
  position: relative;
  overflow: hidden;
}

/* subtle geometric texture on cover */
.cc-profile__cover::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle at 80% 50%, rgba(79,142,247,.25) 0%, transparent 60%),
                    radial-gradient(circle at 20% 80%, rgba(79,142,247,.15) 0%, transparent 40%);
}

/* Level badge on cover */
.cc-profile__level-badge {
  position: absolute;
  top: 14px;
  right: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(0,0,0,.45);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 24px;
  padding: 6px 14px 6px 10px;
  z-index: 2;
}

.cc-profile__level-icon { font-size: 20px; line-height: 1; }

.cc-profile__level-name {
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  letter-spacing: .02em;
}

.cc-profile__level-num {
  font-size: 11px;
  color: rgba(255,255,255,.6);
  margin-left: -4px;
}

.cc-profile__info {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  padding: 0 24px 22px;
  margin-top: -48px;
  position: relative;
  flex-wrap: wrap;
}

/* Avatar wrapper (holds avatar + badge pill) */
.cc-profile__avatar-wrap {
  position: relative;
  flex-shrink: 0;
}

.cc-profile__avatar {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  background: var(--cc-accent);
  border: 4px solid var(--cc-card-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  font-weight: 800;
  color: #fff;
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0,0,0,.2);
}

.cc-profile__avatar img { width: 100%; height: 100%; object-fit: cover; }

/* Conquistas pill sobreposta ao avatar */
.cc-profile__badge-pill {
  position: absolute;
  bottom: -4px;
  right: -4px;
  background: var(--cc-accent);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 12px;
  border: 2px solid var(--cc-card-bg);
  white-space: nowrap;
  cursor: default;
}

.cc-profile__details { flex: 1; min-width: 0; padding-top: 52px; }

.cc-profile__name {
  font-size: 22px;
  font-weight: 800;
  line-height: 1.2;
  color: var(--cc-text);
}

/* Role chip (Colunista) */
.cc-profile__role-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(79,142,247,.12);
  color: var(--cc-accent);
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  margin-top: 4px;
  letter-spacing: .03em;
}

.cc-profile__role-chip .dashicons { font-size: 13px; width: 13px; height: 13px; }

/* Member since */
.cc-profile__since {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: var(--cc-text-muted);
  margin-top: 6px;
}

.cc-profile__since .dashicons { font-size: 13px; width: 13px; height: 13px; }

/* Bio */
.cc-profile__bio {
  font-size: 13px;
  color: var(--cc-text-muted);
  margin-top: 6px;
  line-height: 1.5;
}

.cc-profile__meta {
  font-size: 13px;
  color: var(--cc-text-muted);
  margin-top: 8px;
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.cc-profile__meta span { display: flex; align-items: center; gap: 4px; }

.cc-profile__actions {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  flex-wrap: wrap;
}

/* Tabs-only card (sem cover) */
.cc-profile__card--tabs-only { background: var(--cc-card-bg); border-radius: var(--cc-radius); box-shadow: var(--cc-shadow-md); }

.cc-profile__tabs {
  display: flex;
  gap: 2px;
  padding: 0 24px;
  border-top: 1px solid var(--cc-border);
  overflow-x: auto;
  scrollbar-width: none;
}

.cc-profile__tabs::-webkit-scrollbar { display: none; }

.cc-profile__tab {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 12px 16px;
  font-size: 13px;
  font-weight: 600;
  color: var(--cc-text-muted);
  border-bottom: 2px solid transparent;
  cursor: pointer;
  white-space: nowrap;
  text-decoration: none;
  transition: all 0.15s;
}

.cc-profile__tab:hover { color: var(--cc-text); }
.cc-profile__tab.is-active { color: var(--cc-accent); border-bottom-color: var(--cc-accent); }

.cc-profile__panel { display: none; }
.cc-profile__panel.is-active { display: flex; flex-direction: column; gap: 12px; }

/* ══════════════════════════════════════════════
   XP / GAMIFICATION CARD
   ══════════════════════════════════════════════ */
.cc-xp-card {
  background: var(--cc-card-bg);
  border-radius: var(--cc-radius);
  box-shadow: var(--cc-shadow-md);
  padding: 20px 24px 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Header: nível à esquerda, total XP à direita */
.cc-xp-card__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.cc-xp-card__level-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.cc-xp-card__level-icon { font-size: 32px; line-height: 1; }

.cc-xp-card__level-title {
  font-size: 16px;
  font-weight: 800;
  color: var(--cc-text);
}

.cc-xp-card__level-sub {
  font-size: 12px;
  color: var(--cc-text-muted);
  margin-top: 2px;
}

.cc-xp-card__xp-total {
  text-align: right;
}

.cc-xp-card__xp-num {
  display: block;
  font-size: 28px;
  font-weight: 900;
  color: var(--cc-accent);
  line-height: 1;
}

.cc-xp-card__xp-label {
  font-size: 11px;
  font-weight: 700;
  color: var(--cc-text-muted);
  letter-spacing: .08em;
  text-transform: uppercase;
}

/* Progress bar */
.cc-xp-bar {
  height: 10px;
  background: rgba(79,142,247,.12);
  border-radius: 99px;
  overflow: hidden;
}

.cc-xp-bar__fill {
  height: 100%;
  background: linear-gradient(90deg, #4f8ef7, #7eb8ff);
  border-radius: 99px;
  transition: width 0.6s cubic-bezier(0.4,0,0.2,1);
}

.cc-xp-bar__labels {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: var(--cc-text-muted);
  margin-top: -8px;
}

/* Activity stats */
.cc-xp-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.cc-xp-stat {
  background: var(--cc-bg);
  border: 1px solid var(--cc-border);
  border-radius: 10px;
  padding: 12px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  text-align: center;
}

.cc-xp-stat__emoji { font-size: 20px; line-height: 1; }

.cc-xp-stat__num {
  font-size: 22px;
  font-weight: 800;
  color: var(--cc-text);
  line-height: 1;
}

.cc-xp-stat__label {
  font-size: 11px;
  color: var(--cc-text-muted);
  line-height: 1.3;
}

.cc-xp-stat__xp {
  font-size: 10px;
  font-weight: 700;
  color: var(--cc-accent);
  background: rgba(79,142,247,.1);
  padding: 1px 6px;
  border-radius: 8px;
  margin-top: 2px;
}

/* Achievements / Badges */
.cc-achv {}

.cc-achv__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.cc-achv__title {
  font-size: 13px;
  font-weight: 700;
  color: var(--cc-text);
  text-transform: uppercase;
  letter-spacing: .06em;
}

.cc-achv__count {
  font-size: 12px;
  color: var(--cc-accent);
  font-weight: 700;
  background: rgba(79,142,247,.1);
  padding: 2px 8px;
  border-radius: 10px;
}

.cc-achv__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.cc-achv__badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 12px 6px 10px;
  border-radius: 12px;
  border: 1px solid var(--cc-border);
  text-align: center;
  position: relative;
  transition: transform 0.15s, box-shadow 0.15s;
  cursor: default;
}

.cc-achv__badge--earned {
  background: linear-gradient(135deg, rgba(79,142,247,.08), rgba(79,142,247,.03));
  border-color: rgba(79,142,247,.3);
}

.cc-achv__badge--earned:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(79,142,247,.18);
}

.cc-achv__badge--locked {
  background: var(--cc-bg);
  opacity: 0.45;
  filter: grayscale(0.6);
}

.cc-achv__badge-icon { font-size: 22px; line-height: 1; }

.cc-achv__badge-label {
  font-size: 10px;
  font-weight: 600;
  color: var(--cc-text);
  line-height: 1.3;
}

.cc-achv__badge-lock {
  position: absolute;
  top: 4px;
  right: 4px;
  font-size: 10px;
  opacity: 0.6;
}

/* ══ responsive ══ */
@media (max-width: 600px) {
  .cc-xp-stats { grid-template-columns: repeat(2, 1fr); }
  .cc-achv__grid { grid-template-columns: repeat(4, 1fr); }
}

@media (max-width: 380px) {
  .cc-achv__grid { grid-template-columns: repeat(2, 1fr); }
}

.cc-activity-empty {
  text-align: center;
  padding: 40px 16px;
  color: var(--cc-text-muted);
  font-size: 14px;
  background: var(--cc-card-bg);
  border-radius: var(--cc-radius);
  box-shadow: var(--cc-shadow);
}

.cc-activity-empty .dashicons {
  font-size: 36px;
  width: 36px;
  height: 36px;
  display: block;
  margin: 0 auto 8px;
}

/* =====================================================
   RESPONSIVE — NEW COMPONENTS
   ===================================================== */
@media (max-width: 768px) {
  .cc-community__grid { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); }
  .cc-slider__btn { display: none; }
  .cc-profile__info { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 480px) {
  .cc-community__grid { grid-template-columns: repeat(2, 1fr); }
  .cc-community__search input { width: 160px; }
}

/* =====================================================
   WORDPRESS ADMIN BAR OFFSET
   ===================================================== */
.admin-bar .cc-ticker { top: 32px; }
.admin-bar .cc-sidebar { top: calc(32px + var(--cc-ticker-height) + var(--cc-header-height)); }
.admin-bar .cc-header  { top: calc(32px + var(--cc-ticker-height)); }
.admin-bar .cc-cat-backdrop { top: calc(32px + var(--cc-ticker-height) + var(--cc-header-height)); }
.admin-bar .cc-cat-drawer   { top: calc(32px + var(--cc-ticker-height) + var(--cc-header-height)); height: calc(100vh - 32px - var(--cc-ticker-height) - var(--cc-header-height)); }
.admin-bar .cc-layout { margin-top: calc(32px + var(--cc-ticker-height) + var(--cc-header-height)); }

@media (max-width: 782px) {
  .admin-bar .cc-ticker { top: 46px; }
  .admin-bar .cc-sidebar { top: calc(46px + var(--cc-ticker-height) + var(--cc-header-height)); }
  .admin-bar .cc-header  { top: calc(46px + var(--cc-ticker-height)); }
  .admin-bar .cc-cat-backdrop { top: calc(46px + var(--cc-ticker-height) + var(--cc-header-height)); }
  .admin-bar .cc-cat-drawer   { top: calc(46px + var(--cc-ticker-height) + var(--cc-header-height)); height: calc(100vh - 46px - var(--cc-ticker-height) - var(--cc-header-height)); }
  .admin-bar .cc-layout { margin-top: calc(46px + var(--cc-ticker-height) + var(--cc-header-height)); }
}

/* =====================================================
   LOGIN / REGISTRO PAGE
   ===================================================== */
.cc-login-page {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 120px);
  padding: 32px 16px 64px;
}

/* Brand block */
.cc-login-brand {
  text-align: center;
  margin-bottom: 28px;
}

.cc-login-logo {
  width: 64px;
  height: 64px;
  border-radius: 18px;
  background: var(--cc-accent);
  color: #fff;
  font-size: 26px;
  font-weight: 900;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 12px;
  letter-spacing: -1px;
}

.cc-login-brand-name {
  font-size: 22px;
  font-weight: 800;
  color: var(--cc-text-primary);
  letter-spacing: -.5px;
}

.cc-login-tagline {
  font-size: 13px;
  color: var(--cc-text-muted);
  margin-top: 4px;
}

/* Card */
.cc-login-card {
  width: 100%;
  max-width: 420px;
  background: var(--cc-card-bg);
  border: 1px solid var(--cc-border);
  border-radius: var(--cc-radius);
  padding: 28px;
  box-shadow: 0 4px 24px rgba(0,0,0,.18);
}

/* Tabs */
.cc-login-tabs {
  display: flex;
  border-bottom: 1px solid var(--cc-border);
  margin-bottom: 24px;
  gap: 0;
}

.cc-login-tab {
  flex: 1;
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px 0;
  font-size: 15px;
  font-weight: 700;
  color: var(--cc-text-muted);
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: color .15s, border-color .15s;
}

.cc-login-tab.is-active {
  color: var(--cc-accent);
  border-bottom-color: var(--cc-accent);
}

/* Panels */
.cc-login-panel { display: none; }
.cc-login-panel.is-active { display: block; }

/* Form groups */
.cc-form-group {
  margin-bottom: 18px;
}

.cc-form-group label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  font-weight: 600;
  color: var(--cc-text-primary);
  margin-bottom: 6px;
}

.cc-form-label-link {
  font-weight: 400;
  color: var(--cc-accent);
  text-decoration: none;
  font-size: 12px;
}

.cc-form-label-link:hover { text-decoration: underline; }

.cc-form-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.cc-form-input-wrap .dashicons {
  position: absolute;
  left: 12px;
  color: var(--cc-text-muted);
  font-size: 16px;
  width: 16px;
  height: 16px;
  pointer-events: none;
}

.cc-form-input-wrap input {
  width: 100%;
  padding: 10px 40px 10px 38px;
  background: var(--cc-bg);
  border: 1px solid var(--cc-border);
  border-radius: 8px;
  color: var(--cc-text-primary);
  font-size: 14px;
  font-family: inherit;
  transition: border-color .15s, box-shadow .15s;
  box-sizing: border-box;
}

.cc-form-input-wrap input:focus {
  outline: none;
  border-color: var(--cc-accent);
  box-shadow: 0 0 0 3px rgba(79,142,247,.18);
}

.cc-form-input-wrap input::placeholder { color: var(--cc-text-muted); }

/* Password toggle */
.cc-toggle-pass {
  position: absolute;
  right: 10px;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--cc-text-muted);
  padding: 0;
  display: flex;
  align-items: center;
}

.cc-toggle-pass:hover { color: var(--cc-text-primary); }
.cc-toggle-pass .dashicons { font-size: 16px; width: 16px; height: 16px; }

/* Remember / check */
.cc-form-check {
  margin-bottom: 20px;
}

.cc-form-check label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--cc-text-secondary);
  cursor: pointer;
}

.cc-form-check input[type="checkbox"] {
  width: 15px;
  height: 15px;
  accent-color: var(--cc-accent);
}

/* Password strength indicator */
.cc-pass-strength {
  height: 4px;
  border-radius: 2px;
  margin-top: 6px;
  background: var(--cc-border);
  transition: background .3s, width .3s;
}

.cc-pass-strength.weak   { background: #e53935; width: 33%; }
.cc-pass-strength.medium { background: #fb8c00; width: 66%; }
.cc-pass-strength.strong { background: #43a047; width: 100%; }

/* Submit button */
.cc-login-submit {
  width: 100%;
  padding: 12px;
  background: var(--cc-accent);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: background .15s, transform .1s;
  position: relative;
}

.cc-login-submit:hover:not(:disabled) { background: #3a7de0; }
.cc-login-submit:active:not(:disabled) { transform: scale(.99); }

.cc-login-submit:disabled {
  opacity: .6;
  cursor: not-allowed;
}

/* Spinner */
.cc-login-spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255,255,255,.35);
  border-top-color: #fff;
  border-radius: 50%;
  display: none;
  animation: cc-spin .65s linear infinite;
}

.cc-login-submit.is-loading .cc-login-spinner { display: block; }
.cc-login-submit.is-loading .cc-login-submit-text { opacity: 0; position: absolute; }

/* Message area */
.cc-login-msg {
  border-radius: 8px;
  padding: 0;
  font-size: 13px;
  margin-bottom: 0;
  max-height: 0;
  overflow: hidden;
  transition: max-height .2s, padding .2s, margin-bottom .2s;
}

.cc-login-msg.is-error {
  background: rgba(229,57,53,.12);
  border: 1px solid rgba(229,57,53,.35);
  color: #e53935;
  padding: 10px 14px;
  max-height: 80px;
  margin-bottom: 16px;
}

.cc-login-msg.is-success {
  background: rgba(67,160,71,.12);
  border: 1px solid rgba(67,160,71,.35);
  color: #43a047;
  padding: 10px 14px;
  max-height: 80px;
  margin-bottom: 16px;
}

/* Switch line */
.cc-login-switch {
  text-align: center;
  margin-top: 18px;
  font-size: 13px;
  color: var(--cc-text-muted);
}

.cc-login-switch-btn {
  background: none;
  border: none;
  color: var(--cc-accent);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  padding: 0;
  text-decoration: none;
}

.cc-login-switch-btn:hover { text-decoration: underline; }

/* Spin keyframe (shared) */
@keyframes cc-spin {
  to { transform: rotate(360deg); }
}

/* Responsive */
@media (max-width: 480px) {
  .cc-login-card { padding: 20px 16px; }
}

/* =====================================================
   AD BANNERS — feed & sidebar
   ===================================================== */
.cc-ad-banner {
  position: relative;
  width: 100%;
  background: var(--cc-card-bg);
  border-radius: var(--cc-radius);
  box-shadow: var(--cc-shadow);
  overflow: hidden;
  margin: 0;
  min-height: 90px;
  display: flex;
  align-items: stretch;
}

.cc-ad-banner__label {
  position: absolute;
  top: 5px;
  right: 8px;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cc-text-muted);
  background: rgba(240,242,245,0.9);
  padding: 2px 6px;
  border-radius: 4px;
  z-index: 2;
  pointer-events: none;
}

.cc-ad-banner__inner {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.35s ease;
  min-height: 90px;
}

/* Image ad */
.cc-ad-banner__inner a {
  display: block;
  width: 100%;
  line-height: 0;
}

.cc-ad-banner__inner img {
  width: 100%;
  height: auto;
  max-height: 130px;
  object-fit: cover;
  display: block;
}

/* Sidebar ad — taller */
.cc-right-sidebar .cc-ad-banner {
  margin-bottom: 16px;
  min-height: 120px;
}
.cc-right-sidebar .cc-ad-banner__inner img {
  max-height: 200px;
}

/* Shimmer placeholder while loading */
.cc-ad-banner__placeholder {
  width: 100%;
  min-height: 90px;
  background: linear-gradient(90deg, #f0f2f5 0%, #e4e6ea 50%, #f0f2f5 100%);
  background-size: 300% 100%;
  animation: cc-ad-shimmer 1.6s infinite ease-in-out;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cc-text-muted);
  font-size: 11px;
  letter-spacing: 0.05em;
}

@keyframes cc-ad-shimmer {
  0%   { background-position: 300% 0; }
  100% { background-position: -300% 0; }
}

/* Feed ad: full-width horizontal strip between cards */
.cc-ad-banner--feed {
  border-radius: var(--cc-radius);
  border: 1px solid var(--cc-border);
}

/* =====================================================
   FRONTEND COLUNISTA PANEL
   ===================================================== */
.cc-panel {
  background: var(--cc-card-bg);
  border-radius: var(--cc-radius);
  box-shadow: var(--cc-shadow);
  overflow: hidden;
  max-width: 960px;
  width: 100%;
}

/* Header */
.cc-panel__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 24px 24px 0;
  flex-wrap: wrap;
}

.cc-panel__header-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.cc-panel__avatar img {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
}

.cc-panel__title {
  font-size: 20px;
  font-weight: 800;
  color: var(--cc-text-primary);
  margin: 0 0 2px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.cc-panel__title .dashicons { color: var(--cc-accent); }

.cc-panel__subtitle {
  font-size: 13px;
  color: var(--cc-text-muted);
  margin: 0;
}

.cc-panel__new-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--cc-accent);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  padding: 9px 18px;
  border-radius: 20px;
  text-decoration: none;
  white-space: nowrap;
  transition: opacity 0.15s;
}
.cc-panel__new-btn:hover { opacity: 0.88; color: #fff; }

/* Feedback message */
.cc-panel__msg {
  margin: 14px 24px 0;
  padding: 10px 14px;
  border-radius: var(--cc-radius-sm);
  font-size: 13px;
  font-weight: 500;
}
.cc-panel__msg.is-success { background: #e6f4ea; color: #1e7e34; }
.cc-panel__msg.is-error   { background: #fdecea; color: #c62828; }

/* Category chips */
.cc-panel__cats-info {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  padding: 12px 24px 0;
  font-size: 13px;
  color: var(--cc-text-secondary);
}
.cc-panel__cats-info .dashicons { color: var(--cc-accent); font-size: 16px; width: 16px; height: 16px; }

/* Stats row */
.cc-panel__stats {
  display: flex;
  gap: 0;
  padding: 20px 24px 0;
}

.cc-panel__stat {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 14px 8px;
  background: #f7f9fb;
  border-radius: var(--cc-radius);
  margin-right: 10px;
}
.cc-panel__stat:last-child { margin-right: 0; }

.cc-panel__stat-num {
  font-size: 26px;
  font-weight: 900;
  color: var(--cc-accent);
  line-height: 1;
}

.cc-panel__stat-label {
  font-size: 11px;
  color: var(--cc-text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Status tabs */
.cc-panel__tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  padding: 20px 24px 0;
  border-bottom: 2px solid var(--cc-border);
}

.cc-panel__tab {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 600;
  color: var(--cc-text-muted);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: color 0.15s, border-color 0.15s;
  white-space: nowrap;
}
.cc-panel__tab:hover { color: var(--cc-text); }
.cc-panel__tab.is-active { color: var(--cc-accent); border-bottom-color: var(--cc-accent); }

.cc-panel__tab-count {
  font-size: 11px;
  background: var(--cc-bg);
  border-radius: 10px;
  padding: 1px 6px;
  color: var(--cc-text-muted);
  font-weight: 700;
}
.cc-panel__tab.is-active .cc-panel__tab-count { background: var(--cc-badge-bg); color: var(--cc-accent); }

/* Table */
.cc-panel__table-wrap {
  overflow-x: auto;
  padding: 0 0 24px;
}

.cc-panel__table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.cc-panel__table thead tr {
  background: #f7f9fb;
}

.cc-panel__table th,
.cc-panel__table td {
  padding: 10px 14px;
  text-align: left;
  border-bottom: 1px solid var(--cc-border);
  vertical-align: middle;
  white-space: nowrap;
}

.cc-panel__table th {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--cc-text-muted);
}

.cc-panel__th--img    { width: 68px; }
.cc-panel__th--cat    { width: 120px; }
.cc-panel__th--status { width: 100px; }
.cc-panel__th--num    { width: 66px; text-align: center; }
.cc-panel__th--date   { width: 90px; }
.cc-panel__th--actions { width: 200px; }

.cc-panel__td--num   { text-align: center; color: var(--cc-text-secondary); }
.cc-panel__td--cat   { color: var(--cc-text-secondary); font-size: 12px; }
.cc-panel__td--date  { color: var(--cc-text-muted); font-size: 12px; }

.cc-panel__row:hover { background: #f7f9fb; }

.cc-panel__thumb {
  width: 60px;
  height: 45px;
  object-fit: cover;
  border-radius: 6px;
  display: block;
}

.cc-panel__thumb-placeholder {
  width: 60px;
  height: 45px;
  background: var(--cc-bg);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cc-border);
}

.cc-panel__post-title {
  font-weight: 600;
  color: var(--cc-text-primary);
  text-decoration: none;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  white-space: normal;
  max-width: 280px;
  font-size: 13px;
}
.cc-panel__post-title:hover { color: var(--cc-accent); }

/* Action buttons */
.cc-panel__actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.cc-panel__action-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 600;
  padding: 5px 9px;
  border-radius: 6px;
  border: 1px solid var(--cc-border);
  background: var(--cc-card-bg);
  color: var(--cc-text-secondary);
  cursor: pointer;
  text-decoration: none;
  font-family: var(--cc-font);
  transition: background 0.12s, color 0.12s, border-color 0.12s;
  white-space: nowrap;
  line-height: 1;
}
.cc-panel__action-btn .dashicons { font-size: 13px; width: 13px; height: 13px; }
.cc-panel__action-btn:hover { background: var(--cc-bg); }

.cc-panel__action-btn--edit:hover  { color: var(--cc-accent); border-color: var(--cc-accent); }
.cc-panel__action-btn--trash:hover { color: #c62828; border-color: #c62828; }
.cc-panel__action-btn--delete      { color: #c62828; border-color: #fbbdbd; }
.cc-panel__action-btn--delete:hover{ background: #fdecea; }
.cc-panel__action-btn--restore:hover { color: #2e7d32; border-color: #2e7d32; }

.cc-panel__action-label { display: inline; }

/* Empty state */
.cc-panel__empty {
  padding: 60px 24px;
  text-align: center;
  color: var(--cc-text-muted);
}
.cc-panel__empty .dashicons { font-size: 52px; width: 52px; height: 52px; display: block; margin: 0 auto 16px; color: var(--cc-border); }
.cc-panel__empty p { font-size: 15px; margin: 0 0 8px; }

/* Responsive panel */
@media (max-width: 768px) {
  .cc-panel__header { padding: 16px 16px 0; }
  .cc-panel__stats  { padding: 16px 16px 0; flex-wrap: wrap; gap: 8px; }
  .cc-panel__stat   { flex: 0 0 calc(50% - 4px); margin-right: 0; }
  .cc-panel__tabs   { padding: 16px 16px 0; }
  .cc-panel__cats-info { padding: 10px 16px 0; }
  .cc-panel__table th,
  .cc-panel__table td { padding: 8px 10px; }
  .cc-panel__th--cat,
  .cc-panel__th--num,
  .cc-panel__th--date { display: none; }
  .cc-panel__td--cat,
  .cc-panel__td--num,
  .cc-panel__td--date { display: none; }
  .cc-panel__action-label { display: none; }
  .cc-panel__action-btn { padding: 6px 8px; }
}

/* ──────────────────────────────────────────────────────────────
 * Comments section (comments.php)
 * ────────────────────────────────────────────────────────────── */
.cc-comments-section {
  max-width: 780px;
  margin: 40px auto;
  padding: 0 16px;
}

.cc-comments-title,
.cc-comment-reply-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--cc-text);
  margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--cc-accent);
}

.cc-comment-list {
  list-style: none;
  padding: 0;
  margin: 0 0 32px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.cc-comment {
  background: var(--cc-card-bg);
  border: 1px solid var(--cc-border);
  border-radius: 10px;
  padding: 16px;
}

.cc-comment__body {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.cc-comment__avatar img {
  border-radius: 50%;
  display: block;
}

.cc-comment__content { flex: 1; }

.cc-comment__meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}

.cc-comment__author a,
.cc-comment__author {
  font-weight: 600;
  color: var(--cc-accent);
  text-decoration: none;
  font-size: 0.9rem;
}

.cc-comment__date {
  font-size: 0.78rem;
  color: var(--cc-text-muted, #8b9ab0);
}

.cc-comment__pending {
  font-size: 0.75rem;
  color: #e6a817;
  background: rgba(230,168,23,0.12);
  padding: 2px 8px;
  border-radius: 4px;
}

.cc-comment__text { font-size: 0.92rem; line-height: 1.65; color: var(--cc-text); }
.cc-comment__text p:last-child { margin-bottom: 0; }

.cc-comment__footer { margin-top: 10px; }

.cc-comment__reply a {
  font-size: 0.8rem;
  color: var(--cc-accent);
  text-decoration: none;
  opacity: 0.8;
  transition: opacity 0.15s;
}
.cc-comment__reply a:hover { opacity: 1; }

.cc-comments-closed {
  font-size: 0.88rem;
  color: var(--cc-text-muted, #8b9ab0);
  text-align: center;
  padding: 16px;
  background: var(--cc-card-bg);
  border-radius: 8px;
  border: 1px solid var(--cc-border);
  margin-bottom: 24px;
}

/* Comment form */
.cc-comments-section .comment-form label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--cc-text);
  margin-bottom: 6px;
}

.cc-comments-section .comment-form input[type="text"],
.cc-comments-section .comment-form input[type="email"],
.cc-comments-section .comment-form input[type="url"],
.cc-comments-section .comment-form textarea {
  width: 100%;
  box-sizing: border-box;
  background: var(--cc-card-bg);
  border: 1px solid var(--cc-border);
  border-radius: 8px;
  padding: 10px 14px;
  color: var(--cc-text);
  font-size: 0.9rem;
  transition: border-color 0.2s;
}

.cc-comments-section .comment-form input:focus,
.cc-comments-section .comment-form textarea:focus {
  outline: none;
  border-color: var(--cc-accent);
}

.cc-comments-section .comment-form textarea { min-height: 120px; resize: vertical; }

.cc-comments-section .comment-form p { margin-bottom: 16px; }

.cc-btn--primary {
  background: var(--cc-accent);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 10px 24px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.15s;
}
.cc-btn--primary:hover { opacity: 0.88; }

/* =====================================================
   RESPONSIVO MELHORADO — REFATORAÇÃO MOBILE
   Versão corrigida: cards, header, footer, layout geral
   ===================================================== */

/* ──────────────────────────────────────────────────────
   UTILITÁRIOS BASE
   ────────────────────────────────────────────────────── */
/* Garante que nenhuma imagem vaze para fora do container */
img { max-width: 100%; height: auto; }

/* ──────────────────────────────────────────────────────
   HEADER — Correção do overflow em telas pequenas
   Problema: itens de meta (ícones, avatar, badge) empurravam
   a busca para fora da tela em < 480px
   ────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .cc-header {
    padding: 0 12px;
    gap: 8px;
  }

  /* Colunista badge: só ícone em mobile */
  .cc-header__colunista-badge {
    padding: 4px 8px;
  }

  /* Botões de ícone menores */
  .cc-header__icon-btn {
    width: 32px;
    height: 32px;
  }

  .cc-header__user-avatar {
    width: 32px;
    height: 32px;
    font-size: 12px;
    flex-shrink: 0;
  }
}

/* Em telas muito pequenas: esconder botões secundários, manter busca visível */
@media (max-width: 480px) {
  .cc-header {
    padding: 0 10px;
    gap: 6px;
  }

  /* Esconde ícones não-essenciais (notificação, mensagens) */
  .cc-header__icon-btn {
    display: none;
  }

  /* Badge colunista: só ícone */
  .cc-header__colunista-badge {
    padding: 4px 8px;
    gap: 0;
    min-width: 30px;
    justify-content: center;
  }

  /* Busca ocupa todo o espaço disponível */
  .cc-header__search {
    flex: 1;
    min-width: 0;
    max-width: unset;
    margin: 0;
  }

  .cc-header__meta {
    gap: 5px;
    flex-shrink: 0;
  }

  .cc-header__user-avatar {
    width: 30px;
    height: 30px;
    flex-shrink: 0;
  }
}

/* Telas muito estreitas (320px) */
@media (max-width: 360px) {
  .cc-header {
    padding: 0 8px;
    gap: 4px;
  }

  .cc-header__brand .cc-header__avatar {
    width: 30px;
    height: 30px;
    font-size: 11px;
    border-radius: 8px;
  }

  /* Esconde badge colunista em telas muito pequenas */
  .cc-header__colunista-badge {
    display: none;
  }

  .cc-search-form input[type="search"] {
    font-size: 13px;
    padding: 7px 34px 7px 32px;
  }
}

/* ──────────────────────────────────────────────────────
   CARDS DE POST — Correção do layout horizontal travado
   Problema: .cc-post-card__thumb com width fixo + flex-shrink:0
   causava transbordamento em telas pequenas
   ────────────────────────────────────────────────────── */

/* Em tablets/mobile médio: imagem mais compacta */
@media (max-width: 768px) {
  .cc-post-card__body {
    overflow: hidden; /* garante que a imagem não vaze */
  }

  .cc-post-card__thumb {
    width: 110px;
    object-fit: cover;
    flex-shrink: 0;
    align-self: stretch;
  }

  .cc-post-card__info {
    padding: 10px;
  }

  .cc-post-card__title {
    font-size: 14px;
  }

  .cc-post-card__excerpt {
    -webkit-line-clamp: 2;
    font-size: 12px;
  }

  /* Footer actions: permite quebra de linha */
  .cc-post-card__footer {
    flex-wrap: wrap;
    gap: 4px;
    padding-top: 6px;
  }

  /* Author empurra para nova linha */
  .cc-post-card__author {
    margin-left: 0;
    width: 100%;
    padding-top: 4px;
    border-top: 1px solid var(--cc-border);
    font-size: 11px;
  }
}

/* Em mobile: empilha imagem acima do conteúdo */
@media (max-width: 540px) {
  .cc-post-card {
    gap: 0; /* sem gap lateral, o card ocupa a largura toda */
  }

  /* Coluna de data fica inline acima do card */
  .cc-post-card__date-col {
    display: none; /* já oculto em < 480px, antecipamos para 540px */
  }

  /* Card body: imagem topo, conteúdo abaixo */
  .cc-post-card__body {
    flex-direction: column;
    width: 100%;
  }

  /* Link wrapper da imagem: 100% de largura */
  .cc-post-card__body > a {
    width: 100%;
    height: 160px;
    align-self: auto;
    overflow: hidden;
    display: block;
    flex-shrink: unset;
  }

  /* Imagem: full-width com altura fixa */
  .cc-post-card__thumb {
    width: 100% !important;
    height: 160px;
    object-fit: cover;
    align-self: auto;
  }

  /* Info: padding normal horizontal */
  .cc-post-card__info {
    padding: 12px;
    flex: unset;
  }

  .cc-post-card__title {
    font-size: 15px;
  }

  .cc-post-card__excerpt {
    -webkit-line-clamp: 2;
    font-size: 13px;
  }

  /* Footer actions ficam em linha com wrap */
  .cc-post-card__footer {
    flex-wrap: wrap;
    gap: 6px;
    padding-top: 8px;
  }

  .cc-post-card__author {
    margin-left: 0;
    width: 100%;
    padding-top: 6px;
    border-top: 1px solid var(--cc-border);
  }
}

/* ──────────────────────────────────────────────────────
   CONTENT AREA E FEED
   ────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .cc-content-area {
    padding: 10px;
    gap: 10px;
  }

  .cc-feed-area {
    gap: 10px;
    min-width: 0; /* impede overflow do flex item */
    width: 100%;
  }
}

@media (max-width: 480px) {
  .cc-content-area {
    padding: 8px;
    gap: 8px;
  }

  .cc-feed-area {
    gap: 8px;
  }
}

/* ──────────────────────────────────────────────────────
   TABS DE FILTRO — overflow horizontal controlado
   ────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .cc-tabs {
    padding: 4px;
    gap: 2px;
    -webkit-overflow-scrolling: touch;
  }

  .cc-tabs__tab {
    padding: 6px 10px;
    font-size: 12px;
    gap: 4px;
  }

  .cc-tabs__sort {
    padding: 5px 8px;
    font-size: 12px;
  }
}

/* ──────────────────────────────────────────────────────
   HERO SLIDER — ajustes mobile
   ────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .cc-slider {
    min-height: 200px;
    border-radius: var(--cc-radius-sm);
  }

  .cc-slider__slide {
    min-height: 200px;
  }

  .cc-slider__slide-content {
    min-height: 200px;
    padding: 14px;
  }

  /* Footer do slide: empilha em mobile */
  .cc-slider__slide-footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }

  .cc-slider__slide-title {
    font-size: clamp(16px, 4vw, 22px);
    margin-bottom: 8px;
  }

  .cc-slider__slide-stats {
    font-size: 12px;
  }
}

/* ──────────────────────────────────────────────────────
   MAIN WRAPPER — garante que não vaze
   ────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .cc-main-wrapper {
    margin-left: 0;
    min-width: 0;
    max-width: 100%;
    overflow-x: hidden;
  }

  .cc-layout {
    overflow-x: hidden;
  }
}

/* ──────────────────────────────────────────────────────
   MOBILE BOTTOM NAV — ajustes para 5-6 itens
   Problema: muitos itens em telas estreitas ocupam mais
   espaço do que a largura disponível
   ────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .cc-mobile-nav {
    padding: 6px 0;
  }

  .cc-mobile-nav ul {
    justify-content: space-around;
    padding: 0 4px;
    gap: 0;
  }

  .cc-mobile-nav li a,
  .cc-mobile-nav li button {
    padding: 4px 6px;
    font-size: 9px;
    min-width: 48px;
  }

  .cc-mobile-nav li a .dashicons,
  .cc-mobile-nav li button .dashicons {
    font-size: 19px;
    width: 19px;
    height: 19px;
  }
}

/* Em telas muito estreitas, labels menores */
@media (max-width: 360px) {
  .cc-mobile-nav ul {
    padding: 0 2px;
  }

  .cc-mobile-nav li a,
  .cc-mobile-nav li button {
    padding: 3px 4px;
    font-size: 8px;
    min-width: 40px;
  }

  .cc-mobile-nav li a .dashicons,
  .cc-mobile-nav li button .dashicons {
    font-size: 18px;
    width: 18px;
    height: 18px;
  }
}

/* ──────────────────────────────────────────────────────
   SINGLE POST — leitura confortável em mobile
   ────────────────────────────────────────────────────── */
@media (max-width: 600px) {
  .cc-single__content {
    padding: 16px;
  }

  .cc-single__title {
    font-size: clamp(18px, 5vw, 26px);
  }

  .cc-single__body {
    font-size: 15px;
    line-height: 1.65;
  }

  .cc-single__meta {
    flex-wrap: wrap;
    gap: 8px;
    font-size: 12px;
  }

  .cc-single__hero {
    max-height: 240px;
  }
}

/* ──────────────────────────────────────────────────────
   PERFIL / AUTHOR — layout mobile
   ────────────────────────────────────────────────────── */
@media (max-width: 600px) {
  .cc-profile__cover {
    height: 110px;
  }

  .cc-profile__info {
    padding: 0 16px 18px;
    margin-top: -40px;
    gap: 12px;
  }

  .cc-profile__avatar {
    width: 76px;
    height: 76px;
    font-size: 26px;
    border-width: 3px;
  }

  .cc-profile__details {
    padding-top: 44px;
    width: 100%;
  }

  .cc-profile__name {
    font-size: 18px;
  }

  .cc-profile__meta {
    flex-wrap: wrap;
    gap: 8px;
  }

  .cc-profile__actions {
    flex-wrap: wrap;
  }

  .cc-profile__tabs {
    padding: 0 12px;
  }

  .cc-profile__tab {
    padding: 10px 10px;
    font-size: 12px;
    gap: 4px;
  }

  /* XP card compacto */
  .cc-xp-card {
    padding: 16px;
    gap: 12px;
  }

  .cc-xp-card__level-icon { font-size: 26px; }
  .cc-xp-card__level-title { font-size: 14px; }
  .cc-xp-card__xp-num { font-size: 22px; }

  .cc-xp-stats {
    grid-template-columns: repeat(2, 1fr);
    gap: 6px;
  }

  .cc-xp-stat { padding: 10px 6px; }
  .cc-xp-stat__num { font-size: 18px; }
  .cc-xp-stat__label { font-size: 10px; }

  .cc-achv__grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 6px;
  }
}

@media (max-width: 380px) {
  .cc-achv__grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ──────────────────────────────────────────────────────
   COMMUNITY — grid responsivo
   ────────────────────────────────────────────────────── */
@media (max-width: 480px) {
  .cc-community__header {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .cc-community__search {
    width: 100%;
  }

  .cc-community__search input {
    width: 100%;
    box-sizing: border-box;
  }

  .cc-community__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }
}

/* ──────────────────────────────────────────────────────
   WIDGETS (sidebar direita)
   ────────────────────────────────────────────────────── */
@media (max-width: 1100px) {
  /* Sidebar já está oculta via display:none, mas garante
     que os widgets não causem overflow quando visíveis */
  .cc-widget {
    max-width: 100%;
    overflow: hidden;
  }

  .cc-most-read__title {
    word-break: break-word;
  }
}

/* ──────────────────────────────────────────────────────
   PAINEL COLUNISTA — tabela responsiva
   ────────────────────────────────────────────────────── */
@media (max-width: 600px) {
  .cc-panel {
    border-radius: var(--cc-radius-sm);
  }

  .cc-panel__header {
    padding: 14px 14px 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .cc-panel__header-left {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .cc-panel__new-btn {
    align-self: flex-start;
  }

  .cc-panel__stats {
    padding: 14px 14px 0;
    flex-wrap: wrap;
    gap: 8px;
  }

  .cc-panel__stat {
    flex: 1 1 calc(50% - 4px);
    margin-right: 0;
    padding: 10px 6px;
  }

  .cc-panel__stat-num { font-size: 20px; }

  .cc-panel__tabs {
    padding: 14px 14px 0;
    overflow-x: auto;
    flex-wrap: nowrap;
    scrollbar-width: none;
  }

  .cc-panel__tabs::-webkit-scrollbar { display: none; }

  .cc-panel__table th,
  .cc-panel__table td {
    padding: 7px 8px;
    font-size: 12px;
  }
}

/* ──────────────────────────────────────────────────────
   TICKER — sem overflow horizontal
   ────────────────────────────────────────────────────── */
.cc-ticker {
  max-width: 100vw;
  overflow: hidden;
}

/* Reduce ticker label no mobile */
@media (max-width: 480px) {
  .cc-ticker__label {
    padding: 0 10px;
    font-size: 10px;
    gap: 4px;
  }

  .cc-ticker__inner a {
    font-size: 12px;
    padding: 0 14px;
  }
}

/* ──────────────────────────────────────────────────────
   PAGINATION
   ────────────────────────────────────────────────────── */
@media (max-width: 480px) {
  .cc-pagination {
    gap: 4px;
    flex-wrap: wrap;
    justify-content: center;
    padding: 8px 4px;
  }

  .cc-pagination a,
  .cc-pagination span {
    width: 32px;
    height: 32px;
    font-size: 13px;
  }
}

/* ──────────────────────────────────────────────────────
   SHARE MODAL — ocupa mais espaço em mobile
   ────────────────────────────────────────────────────── */
@media (max-width: 480px) {
  .cc-share-modal__box {
    width: 96vw;
    padding: 18px 16px;
  }

  .cc-share-modal__networks {
    gap: 8px;
  }

  .cc-share-modal__net {
    padding: 8px 10px;
    font-size: 10px;
  }
}

/* ──────────────────────────────────────────────────────
   COMMENTS — seção de comentários mobile
   ────────────────────────────────────────────────────── */
@media (max-width: 540px) {
  .cc-comments__form {
    padding: 8px 10px;
  }

  .cc-comment {
    padding: 8px 10px;
    gap: 6px;
  }
}

/* ──────────────────────────────────────────────────────
   SECTION DE COMENTÁRIOS (comments.php)
   ────────────────────────────────────────────────────── */
@media (max-width: 600px) {
  .cc-comments-section {
    padding: 0 8px;
    margin: 24px auto;
  }

  .cc-comment__body {
    gap: 10px;
  }

  .cc-comment {
    padding: 12px;
  }
}

/* ──────────────────────────────────────────────────────
   CATEGORY DRAWER — bottom sheet mobile
   ────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  /* Drawer já vira bottom sheet, mas garante que não vaze */
  .cc-cat-drawer {
    max-width: 100vw;
    left: 0;
    right: 0;
  }

  .cc-cat-item {
    padding: 10px 12px;
  }

  .cc-cat-item__name {
    font-size: 13px;
  }
}

/* ──────────────────────────────────────────────────────
   BUSCA (search.php / resultados)
   ────────────────────────────────────────────────────── */
@media (max-width: 480px) {
  .cc-search-form input[type="search"] {
    font-size: 14px;
    -webkit-appearance: none; /* remove estilo nativo iOS */
  }
}

/* ──────────────────────────────────────────────────────
   PREVENÇÃO DE OVERFLOW GLOBAL
   Evita que qualquer elemento quebre o layout horizontal
   ────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .cc-layout,
  .cc-main-wrapper,
  .cc-content-area,
  .cc-feed-area {
    max-width: 100vw;
    overflow-x: hidden;
    box-sizing: border-box;
  }

  /* Garante que tabelas não forcem overflow no body */
  .cc-panel__table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
}
