/* ————— Home ————— */

.home-posts-section {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.home-posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
}

.home-post-card {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--surface-1);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-1);
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  transition: transform var(--dur) var(--ease), border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}

.home-post-card:hover {
  border-color: var(--border-bright);
  box-shadow: var(--shadow-2);
  transform: translateY(-2px);
}

.home-post-card__media {
  position: relative;
  width: 100%;
  height: 360px;
  background: var(--surface-2);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.home-post-card__img,
.home-post-card__video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 400ms var(--ease);
}

.home-post-card:hover .home-post-card__img,
.home-post-card:hover .home-post-card__video {
  transform: scale(1.04);
}

.home-post-card__placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: var(--text-3);
  padding: 24px;
}

.home-post-card__placeholder svg {
  width: 56px;
  height: 56px;
  opacity: 0.4;
}

.home-post-card__overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 24px;
  background: linear-gradient(180deg, rgba(11, 11, 13, 0.4) 0%, rgba(11, 11, 13, 0.15) 40%, rgba(11, 11, 13, 0.9) 100%);
  pointer-events: none;
}

.home-post-card__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  pointer-events: auto;
}

.home-post-card__badge {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  backdrop-filter: blur(8px);
}

.home-post-card__bottom {
  display: flex;
  flex-direction: column;
  gap: 12px;
  pointer-events: auto;
}

.home-post-card__title {
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  line-height: 1.3;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8);
  margin: 0;
}

.home-post-card__meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.8);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
}

.ov-grid {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.ov-card {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.ov-card__icon {
  width: 40px;
  height: 40px;
  flex: none;
  display: grid;
  place-items: center;
  border-radius: var(--radius-s);
  background: var(--accent-faint);
  border: 1px solid var(--accent-dim);
  color: var(--accent);
}

.ov-card__icon svg {
  width: 20px;
  height: 20px;
}

.ov-card__label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--text-3);
}

.ov-card__value {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  margin: 3px 0 2px;
  line-height: 1.3;
}

.ov-card__sub {
  font-size: 12.5px;
  color: var(--text-3);
}

.home-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border), transparent);
  margin: 4px 0;
}

/* ————— Quick access (dashboard) ————— */

.quick-grid {
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
}

.quick-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 18px 20px;
}

.quick-card__icon {
  width: 34px;
  height: 34px;
  flex: none;
  display: grid;
  place-items: center;
  border-radius: var(--radius-s);
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--accent);
  margin-bottom: 10px;
}

.quick-card__icon svg {
  width: 17px;
  height: 17px;
}

.quick-card h3 {
  font-size: 14px;
  font-weight: 600;
}

.quick-card p {
  font-size: 12.5px;
  color: var(--text-3);
}

.quick-card__go {
  margin-top: auto;
  padding-top: 8px;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  opacity: 0;
  transform: translateX(-4px);
  transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease);
}

.quick-card:hover .quick-card__go,
.quick-card:focus-within .quick-card__go {
  opacity: 1;
  transform: none;
}

.home-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* ————— Dashboard ————— */

.dash-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 16px;
}

.dash-meta-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.health-face {
  display: flex;
  align-items: center;
  gap: 12px;
}

.health-face__dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-dim), 0 0 18px var(--accent-glow);
  animation: pulseDot 2.6s ease-out infinite;
}

.health-face strong {
  font-size: 15px;
  font-weight: 650;
  letter-spacing: -0.01em;
}

.health-face small {
  display: block;
  font-size: 12px;
  color: var(--text-3);
}

/* ————— Bot control panel ————— */

.bot-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 16px;
}

.bot-rail {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.bot-rail .stat {
  padding: 14px 16px;
}

.bot-rail .stat__value {
  font-size: 18px;
}

.checks-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.check-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border-faint);
}

.check-row:last-child {
  border-bottom: 0;
}

.check-row__name {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13.5px;
  color: var(--text-2);
}

.check-row__name svg {
  width: 16px;
  height: 16px;
  color: var(--text-4);
}

.bot-welcome {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.bot-welcome p {
  font-size: 13px;
}

/* ————— Settings ————— */

.settings-title {
  margin-bottom: 2px;
}

.settings-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

/* ————— Responsive tuning ————— */

@media (max-width: 900px) {
  .dash-grid,
  .bot-grid {
    grid-template-columns: 1fr;
  }

  .bot-rail {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .bot-rail {
    grid-template-columns: 1fr;
  }
}