/* ==========================================================================
   DAILY POSTS (Daily Work Link Collector) STYLES
   Pixel-close implementation based on Master Design Reference
   Scoped to #posts view
   ========================================================================== */

.daily-posts-container {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

/* 1. Page Header & Actions */
.daily-posts-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 22px;
  gap: 16px;
  flex-wrap: wrap;
}

.daily-posts-header .header-titles h1 {
  font-size: 1.65rem;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.daily-posts-header .header-titles p {
  font-size: 0.88rem;
  color: #64748b;
  margin-top: 4px;
}

.daily-posts-header .header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.btn-posts-sync {
  background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%) !important;
  color: #ffffff !important;
  border: none !important;
  padding: 10px 18px !important;
  border-radius: 12px !important;
  font-weight: 600 !important;
  font-size: 0.88rem !important;
  font-family: inherit !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  box-shadow: 0 4px 14px rgba(79, 70, 229, 0.28) !important;
  transition: all 0.2s ease !important;
}

.btn-posts-sync:hover {
  transform: translateY(-1px) !important;
  box-shadow: 0 6px 18px rgba(79, 70, 229, 0.35) !important;
}

.btn-posts-copy-day {
  background: #ffffff !important;
  color: #0f172a !important;
  border: 1px solid #cbd5e1 !important;
  padding: 10px 18px !important;
  border-radius: 12px !important;
  font-weight: 600 !important;
  font-size: 0.88rem !important;
  font-family: inherit !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04) !important;
  transition: all 0.2s ease !important;
}

.btn-posts-copy-day:hover {
  background: #f8fafc !important;
  border-color: #94a3b8 !important;
}

.btn-posts-add {
  background: #ffffff !important;
  color: #4f46e5 !important;
  border: 1.5px dashed #cbd5e1 !important;
  padding: 10px 16px !important;
  border-radius: 12px !important;
  font-weight: 600 !important;
  font-size: 0.88rem !important;
  font-family: inherit !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  transition: all 0.2s ease !important;
}

.btn-posts-add:hover {
  border-color: #6366f1 !important;
  background: #f5f3ff !important;
}

/* 2. Top Summary KPI Cards (5 Cards) */
/* ==========================================================================
   2. Summary KPI Bar (5 Cards - 3D Icons, Clean, No Dividers)
   ========================================================================== */
.posts-kpi-bar {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 20px;
  width: 100%;
}

.posts-kpi-item {
  background: #ffffff;
  border: 1px solid rgba(226, 232, 240, 0.85);
  border-radius: 22px;
  padding: 14px 18px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.025), 0 1px 3px rgba(0, 0, 0, 0.02);
  display: flex;
  align-items: center;
  gap: 16px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  box-sizing: border-box;
  min-height: 98px;
  position: relative;
}

.posts-kpi-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.04);
  border-color: #cbd5e1;
}

.posts-kpi-item--total {
  background: radial-gradient(circle at 18% 50%, rgba(99, 102, 241, 0.04), transparent 65%), #ffffff;
}

.posts-kpi-item--web {
  background: radial-gradient(circle at 18% 50%, rgba(37, 99, 235, 0.04), transparent 65%), #ffffff;
}

.posts-kpi-item--soc {
  background: radial-gradient(circle at 18% 50%, rgba(168, 85, 247, 0.04), transparent 65%), #ffffff;
}

.posts-kpi-item--active {
  background: radial-gradient(circle at 18% 50%, rgba(16, 185, 129, 0.04), transparent 65%), #ffffff;
}

.posts-kpi-item--empty {
  background: radial-gradient(circle at 18% 50%, rgba(249, 115, 22, 0.04), transparent 65%), #ffffff;
}

.posts-kpi-3d-img {
  width: 76px;
  height: 76px;
  max-width: 80px;
  max-height: 80px;
  object-fit: contain;
  flex-shrink: 0;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.05));
  user-select: none;
  pointer-events: none;
}

.posts-kpi-text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  gap: 2px;
}

.posts-kpi-num {
  font-size: 2.15rem;
  font-weight: 800;
  color: #0f172a;
  line-height: 1;
  letter-spacing: -0.02em;
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
}

.posts-kpi-label {
  font-size: 0.86rem;
  font-weight: 600;
  color: #64748b;
  margin-top: 5px;
  white-space: nowrap;
  letter-spacing: -0.01em;
}

/* ==========================================================================
   3. Filter & Controls Toolbar (White Container, Rounded, No Extra Dividers)
   ========================================================================== */
.posts-toolbar {
  background: #ffffff;
  border: 1px solid rgba(226, 232, 240, 0.85);
  border-radius: 24px;
  padding: 10px 20px;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.02);
  box-sizing: border-box;
}

.toolbar-left {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.date-bar-label {
  font-size: 0.95rem;
  font-weight: 700;
  color: #1e293b;
  margin-right: 2px;
}

.date-pill {
  background: #f8fafc;
  color: #475569;
  border: 1px solid #e2e8f0;
  padding: 7px 20px;
  border-radius: 20px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  font-family: inherit;
}

.date-pill:hover {
  background: #f1f5f9;
  color: #0f172a;
  border-color: #cbd5e1;
}

.date-pill.active {
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  color: #ffffff;
  border: 1px solid transparent;
  box-shadow: 0 3px 10px rgba(99, 102, 241, 0.35);
}

.date-picker-dropdown {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  height: 40px;
  min-height: 40px;
  width: 100%;
  box-sizing: border-box;
  padding: 0 14px;
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
  transition: all 0.15s ease;
}

.date-picker-dropdown:hover {
  border-color: #94a3b8;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
}

.date-picker-text {
  font-size: 0.88rem;
  font-weight: 700;
  color: #1e293b;
  letter-spacing: 0.01em;
}

.date-picker-native-input {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}

.toolbar-middle {
  display: flex;
  align-items: center;
  gap: 8px;
}

.sync-timestamp-tag {
  font-size: 0.88rem;
  font-weight: 600;
  color: #10b981;
  display: flex;
  align-items: center;
  gap: 6px;
}

.sync-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #10b981;
  display: inline-block;
  box-shadow: 0 0 6px rgba(16, 185, 129, 0.4);
}

.toolbar-right {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-left: auto;
}

.search-input-wrap {
  display: flex;
  align-items: center;
  gap: 9px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 24px;
  padding: 8px 18px;
  width: 280px;
  box-sizing: border-box;
  transition: all 0.15s ease;
}

.search-input-wrap:focus-within {
  background: #ffffff;
  border-color: #818cf8;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.search-input-wrap input {
  border: none;
  background: transparent;
  outline: none;
  font-family: inherit;
  font-size: 0.86rem;
  color: #0f172a;
  width: 100%;
}

@media (max-width: 1280px) {
  .posts-kpi-bar {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .posts-kpi-bar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .toolbar-middle {
    order: 3;
    width: 100%;
  }
  .toolbar-right {
    width: 100%;
    margin-left: 0;
  }
  .search-input-wrap {
    width: 100%;
  }
}

/* 4. Section Container Blocks */
.posts-section-block {
  background: #ffffff;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: 24px;
  padding: 22px 24px;
  margin-bottom: 28px;
  box-shadow: 0 4px 20px rgba(99, 102, 241, 0.04);
}

.section-header-row {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  margin-bottom: 22px;
  gap: 16px;
  width: 100%;
}

.section-header-left {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
}

.section-icon-box {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.section-icon-box--blue { background: #dbeafe; color: #2563eb; }
.section-icon-box--purple { background: #ede9fe; color: #7c3aed; }

.section-title-wrap h2 {
  font-size: 1.25rem;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.2;
}

.section-title-wrap p {
  font-size: 0.84rem;
  color: #64748b;
  margin-top: 3px;
}

.control-row,
.section-control-row,
.website-control-row,
.social-control-row {
  display: grid;
  grid-template-columns:
    72px
    82px
    160px
    minmax(220px, 1fr)
    minmax(220px, 1fr)
    170px
    220px;
  gap: 10px;
  width: 100%;
  align-items: center;
  box-sizing: border-box;
}

/* Every control fills its grid cell 100% */
.control-row .date-pill,
.control-row .date-picker-dropdown,
.control-row .section-badge-pill,
.control-row .section-sync-time,
.control-row .btn-section-sync,
.control-row .btn-section-copy,
.date-pill,
.section-badge-pill,
.btn-section-copy,
.section-sync-time,
.btn-section-sync {
  width: 100%;
  height: 40px;
  min-height: 40px;
  box-sizing: border-box;
  padding: 0 14px;
  border-radius: 12px;
  white-space: nowrap;
}

/* Today & Yesterday Pills */
.date-pill {
  font-size: 0.84rem;
  font-weight: 600;
  font-family: inherit;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
  color: #475569;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}

.date-pill:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
}

/* Website section date active pill */
.posts-section-block--website .date-pill.active {
  background: #2563eb;
  color: #ffffff;
  border-color: #2563eb;
  box-shadow: 0 1px 3px rgba(37, 99, 235, 0.2);
}

/* Social section date active pill */
.posts-section-block--social .date-pill.active {
  background: #6366f1;
  color: #ffffff;
  border-color: #6366f1;
  box-shadow: 0 1px 3px rgba(99, 102, 241, 0.2);
}

/* Summary Badge */
.section-badge-pill {
  background: #f1f5f9;
  color: #475569;
  font-size: 0.82rem;
  font-weight: 600;
  border: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.section-badge-pill--purple {
  background: #f5f3ff;
  color: #7c3aed;
  border: 1px solid #ede9fe;
}

/* Last Sync Time */
.section-sync-time {
  font-size: 0.82rem;
  font-weight: 600;
  color: #059669;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
}

.section-sync-time .sync-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 6px rgba(16, 185, 129, 0.4);
  flex-shrink: 0;
}

/* Sync Button */
.btn-section-sync {
  background: #eff6ff;
  color: #2563eb;
  border: 1px solid #bfdbfe;
  font-size: 0.84rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  transition: all 0.2s ease;
}

.btn-section-sync:hover {
  background: #dbeafe;
  border-color: #93c5fd;
  color: #1d4ed8;
}

.btn-section-sync:disabled {
  opacity: 0.65;
  cursor: not-allowed;
  pointer-events: none;
}

/* Copy All Button */
.btn-section-copy {
  background: #f8fafc;
  color: #0f172a;
  border: 1px solid #cbd5e1;
  font-size: 0.84rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  transition: all 0.2s ease;
}

.btn-section-copy:hover {
  background: #f1f5f9;
  border-color: #94a3b8;
  color: #020617;
}

@media (max-width: 1200px) {
  .control-row,
  .section-control-row,
  .website-control-row,
  .social-control-row {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  }
}

@keyframes spin {
  100% {
    transform: rotate(360deg);
  }
}

.spin {
  animation: spin 0.8s linear infinite;
}

@media (max-width: 1280px) {
  .section-header-right,
  .section-control-row,
  .website-control-row,
  .social-control-row {
    flex-wrap: wrap;
    row-gap: 12px;
  }
}

/* Social Table Layout (Collapsed State) */
.social-table-container {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

.social-table-header-row {
  display: grid;
  grid-template-columns: 240px 160px 160px 1fr 220px;
  align-items: center;
  padding: 14px 24px;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  font-size: 0.8rem;
  font-weight: 600;
  color: #64748b;
}

.social-table-header-row .col-platform { text-align: left; }
.social-table-header-row .col-accounts { text-align: left; }
.social-table-header-row .col-links { text-align: left; }
.social-table-header-row .col-time { text-align: left; }
.social-table-header-row .col-actions { text-align: right; }

.social-table-row {
  display: grid;
  grid-template-columns: 240px 160px 160px 1fr 220px;
  align-items: center;
  padding: 10px 24px;
  border-bottom: 1px solid #f1f5f9;
  background: #ffffff;
  transition: background 0.15s ease, border-color 0.15s ease;
  cursor: pointer;
  user-select: none;
}

.social-table-row:hover {
  background: #f8fafc;
}

.social-table-row.is-active {
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
}

.social-table-row.is-active:hover {
  background: #f1f5f9;
}

.social-table-row .col-platform {
  display: flex;
  align-items: center;
  gap: 12px;
}

.social-table-icon {
  width: 36px;
  height: 36px;
  min-width: 36px;
  min-height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  flex-shrink: 0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
  position: relative;
  overflow: hidden;
  transition: transform 0.15s ease;
}

.social-table-icon::after {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 38%;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.18) 0%, rgba(255, 255, 255, 0) 100%);
  pointer-events: none;
  border-radius: 10px 10px 0 0;
}

.social-table-icon.platform--telegram { border-radius: 10px; background: linear-gradient(180deg, #2ea5e4 0%, #2294d1 100%); }
.social-table-icon.platform--facebook { border-radius: 10px; background: linear-gradient(180deg, #187bf5 0%, #0866ff 100%); }
.social-table-icon.platform--x { border-radius: 10px; background: #0f172a; }
.social-table-icon.platform--instagram { border-radius: 10px; background: linear-gradient(135deg, #4f5bd5 0%, #962fbf 30%, #d62976 60%, #fa7e1e 90%, #feda75 100%); }
.social-table-icon.platform--youtube { border-radius: 10px; background: linear-gradient(180deg, #ff1a1a 0%, #e60000 100%); }
.social-table-icon.platform--bluesky { border-radius: 10px; background: linear-gradient(180deg, #148aff 0%, #0070eb 100%); }
.social-table-icon.platform--redgif { border-radius: 10px; background: linear-gradient(180deg, #ea264e 0%, #d4173d 100%); }

.social-table-name {
  font-size: 0.95rem;
  font-weight: 700;
  color: #0f172a;
}

.social-table-count {
  font-size: 0.88rem;
  font-weight: 500;
  color: #475569;
}

.social-table-links-pill {
  background: #eff6ff;
  color: #2563eb;
  border: 1px solid #dbeafe;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.social-table-links-pill .pill-dot {
  color: #3b82f6;
  font-size: 0.75rem;
}

.social-table-time {
  font-size: 0.85rem;
  font-weight: 500;
  color: #64748b;
}

.social-table-row .col-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.btn-table-copy {
  background: #ffffff;
  color: #2563eb;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  padding: 6px 14px;
  font-size: 0.8rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.15s ease;
}

.btn-table-copy:hover {
  background: #eff6ff;
  border-color: #bfdbfe;
}

.btn-table-toggle {
  background: #ffffff;
  color: #334155;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-table-toggle:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
}

.toggle-arrow-icon {
  transition: transform 0.22s cubic-bezier(0.4, 0, 0.2, 1);
  display: block;
}

.toggle-arrow-icon.is-rotated {
  transform: rotate(180deg);
}

.social-table-row.is-active .btn-table-toggle {
  background: #f1f5f9;
  border-color: #cbd5e1;
  color: #1e293b;
}

/* Expanded panel inside accordion item */
.social-platform-expanded-panel {
  padding: 16px 24px 20px 24px;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  animation: fadeInPanel 0.2s ease;
}

@keyframes fadeInPanel {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

.social-accordion-item:last-child .social-table-row:not(.is-active) {
  border-bottom: none;
}

.social-accordion-item:last-child .social-platform-expanded-panel {
  border-bottom: none;
}

/* 5. Website Cards Grid (4 Columns on Desktop) */
.website-cards-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.web-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 18px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
  transition: all 0.2s ease;
  min-height: 250px;
}

.web-card:hover {
  border-color: #cbd5e1;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.04);
}

.web-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.web-brand-group {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.web-logo-box {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.1rem;
  color: #ffffff;
  flex-shrink: 0;
}

.web-brand-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.web-brand-name {
  font-size: 0.95rem;
  font-weight: 700;
  color: #0f172a;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
}

.web-brand-domain {
  font-size: 0.74rem;
  color: #64748b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 1px;
}

.count-pill-blue {
  background: #eff6ff;
  color: #2563eb;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 12px;
  white-space: nowrap;
}

/* Links List */
.links-list-container {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 14px;
  flex-grow: 1;
}

.post-link-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 8px;
  border-radius: 8px;
  background: #f8fafc;
  gap: 8px;
  transition: background 0.15s ease;
}

.post-link-item:hover {
  background: #f1f5f9;
}

.post-link-meta {
  font-size: 0.74rem;
  color: #64748b;
  white-space: nowrap;
  font-weight: 500;
}

.post-link-url-box {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  flex: 1;
}

.post-link-url-box svg {
  color: #3b82f6;
  flex-shrink: 0;
}

.post-link-anchor {
  font-size: 0.8rem;
  font-weight: 600;
  color: #0f172a;
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.post-link-anchor:hover {
  color: #2563eb;
  text-decoration: underline;
}

.post-copy-btn {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
  background: #ffffff;
  color: #475569;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.15s ease;
}

.post-copy-btn:hover {
  background: #e0e7ff;
  border-color: #6366f1;
  color: #4f46e5;
}

.btn-web-copy-all {
  width: 100%;
  background: #eff6ff;
  color: #2563eb;
  border: 1px solid #bfdbfe;
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 0.82rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.2s ease;
}

.btn-web-copy-all:hover {
  background: #dbeafe;
  border-color: #93c5fd;
}

/* 6. Social Platforms Grid (5 Columns on 1920 Desktop) */
.social-platforms-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 16px;
}

.platform-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 20px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.02);
  min-height: 480px;
}

.platform-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid #f1f5f9;
}

.platform-header-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.platform-icon-box {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  flex-shrink: 0;
}

.platform-icon--telegram { background: #229ED9; }
.platform-icon--facebook { background: #1877F2; }
.platform-icon--instagram { background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%); }
.platform-icon--youtube { background: #FF0000; }
.platform-icon--x { background: #000000; }
.platform-icon--bluesky { background: #0285FF; }
.platform-icon--redgifs { background: #E32B5B; }

.platform-title-group h3 {
  font-size: 0.95rem;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.2;
}

.platform-title-group span {
  font-size: 0.74rem;
  color: #64748b;
}

.platform-accounts-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 16px;
  flex-grow: 1;
}

/* Account Sub-card */
.account-sub-card {
  background: #ffffff;
  border: 1px solid #f1f5f9;
  border-radius: 14px;
  padding: 10px 12px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.02);
  transition: all 0.15s ease;
}

.account-sub-card:hover {
  border-color: #e2e8f0;
  background: #fafafa;
}

.account-sub-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  cursor: pointer;
}

.account-sub-left {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.acc-avatar {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-weight: 700;
  font-size: 0.75rem;
  flex-shrink: 0;
}

.acc-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.acc-name {
  font-size: 0.84rem;
  font-weight: 700;
  color: #0f172a;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
}

.acc-handle {
  font-size: 0.7rem;
  color: #64748b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.account-sub-right {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.status-badge-connected {
  background: #ecfdf5;
  color: #10b981;
  font-size: 0.68rem;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.status-badge-disconnected {
  background: #fff1f2;
  color: #ef4444;
  font-size: 0.68rem;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 8px;
}

.link-count-pill {
  background: #eff6ff;
  color: #2563eb;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 8px;
}

.toggle-arrow {
  color: #94a3b8;
  transition: transform 0.2s ease;
}

.toggle-arrow.expanded {
  transform: rotate(180deg);
}

.acc-links-container {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px dashed #e2e8f0;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.acc-link-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  background: #f8fafc;
  padding: 4px 6px;
  border-radius: 6px;
}

.acc-link-time {
  font-size: 0.68rem;
  color: #64748b;
  white-space: nowrap;
}

.acc-link-url-box {
  display: flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
  flex: 1;
}

.acc-link-url-box svg {
  color: #3b82f6;
  flex-shrink: 0;
}

.acc-link-anchor {
  font-size: 0.74rem;
  font-weight: 600;
  color: #0f172a;
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.acc-link-anchor:hover {
  text-decoration: underline;
  color: #2563eb;
}

.zero-posts-box {
  background: #f8fafc;
  border-radius: 10px;
  height: 70px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 0.8rem;
  color: #94a3b8;
  font-weight: 500;
  box-sizing: border-box;
}

.btn-platform-copy-all {
  width: 100%;
  border: none;
  color: #ffffff;
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 0.84rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.2s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.btn-platform-copy-all:hover {
  opacity: 0.92;
  transform: translateY(-1px);
}

.btn-platform--telegram { background: #229ED9; }
.btn-platform--facebook { background: #1877F2; }
.btn-platform--instagram { background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888); }
.btn-platform--youtube { background: #FF0000; }
.btn-platform--x { background: #0f172a; }
.btn-platform--bluesky { background: #0285FF; }
.btn-platform--redgifs { background: #E32B5B; }

/* 7. Empty State for Full Day */
.empty-posts-state {
  text-align: center;
  padding: 60px 20px;
  background: #ffffff;
  border: 1px dashed #cbd5e1;
  border-radius: 20px;
  margin: 20px 0;
}

.empty-posts-icon {
  width: 60px;
  height: 60px;
  border-radius: 16px;
  background: #f1f5f9;
  color: #94a3b8;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
}

.empty-posts-state h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: #334155;
  margin-bottom: 6px;
}

.empty-posts-state p {
  font-size: 0.85rem;
  color: #64748b;
}

/* Responsive Grid Breakpoints */
@media (max-width: 1600px) {
  .social-platforms-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .website-cards-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .posts-kpi-bar { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 1100px) {
  .social-platforms-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .website-cards-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .posts-kpi-bar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 700px) {
  .social-platforms-grid { grid-template-columns: 1fr; }
  .website-cards-grid { grid-template-columns: 1fr; }
  .posts-kpi-bar { grid-template-columns: 1fr; }
}


/* Website Name Link (Clickable, Strictly No Underline on ANY state) */
.website-name-link,
a.website-name-link,
.web-brand-name,
a.web-brand-name,
.website-name-link:hover,
a.website-name-link:hover,
.website-name-link:visited,
a.website-name-link:visited,
.website-name-link:focus,
a.website-name-link:focus,
.website-name-link:active,
a.website-name-link:active {
  text-decoration: none !important;
}

.website-name-link,
a.website-name-link {
  color: #0f172a !important;
  font-weight: 700 !important;
  font-size: 0.95rem !important;
  line-height: 1.2 !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  cursor: pointer !important;
  display: block !important;
  outline: none !important;
  transition: opacity 0.15s ease, color 0.15s ease !important;
}

.website-name-link:hover,
a.website-name-link:hover {
  opacity: 0.8 !important;
  color: #020617 !important;
}

.post-link-time-box {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.post-item-icon-calendar {
  color: #64748b;
  flex-shrink: 0;
}

.post-item-icon-link {
  color: #3b82f6;
  flex-shrink: 0;
}


/* ==========================================================================
   NEW REDESIGNED SOCIAL SECTION
   Vertical Stack of Platform Panels, 2-Column Account Cards
   ========================================================================== */

.social-platforms-vertical-list {
  display: flex;
  flex-direction: column;
  gap: 18px;
  width: 100%;
}

.social-platform-panel {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 18px;
  padding: 18px 20px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
  transition: all 0.2s ease;
  width: 100%;
  box-sizing: border-box;
}

.social-platform-panel:hover {
  border-color: #cbd5e1;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.04);
}

.platform-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
  gap: 16px;
  flex-wrap: wrap;
}

.platform-panel-header-left {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.platform-brand-icon-box {
  width: 32px;
  height: 32px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  flex-shrink: 0;
}

.platform-brand-icon-box.platform--telegram { background: #229ED9; }
.platform-brand-icon-box.platform--facebook { background: #1877F2; }
.platform-brand-icon-box.platform--x { background: #000000; }
.platform-brand-icon-box.platform--instagram { background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%); }
.platform-brand-icon-box.platform--youtube { background: #FF0000; }
.platform-brand-icon-box.platform--bluesky { background: #0285FF; }
.platform-brand-icon-box.platform--redgif { background: #D92546; }

.platform-panel-name {
  font-size: 1.15rem;
  font-weight: 800;
  color: #0f172a;
  line-height: 1;
}

.platform-panel-count-pill {
  background: #f1f5f9;
  color: #475569;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 12px;
}

.platform-panel-links-pill {
  background: #eff6ff;
  color: #2563eb;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 12px;
}

.platform-panel-header-right {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.platform-sync-time {
  font-size: 0.78rem;
  color: #64748b;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.btn-platform-copy-all {
  background: #ffffff;
  color: #334155;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  padding: 6px 14px;
  font-size: 0.8rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
  transition: all 0.15s ease;
}

.btn-platform-copy-all:hover {
  background: #f8fafc;
  border-color: #94a3b8;
  color: #0f172a;
}

.platform-toggle-collapse-btn {
  background: #f8fafc;
  color: #64748b;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
  padding: 0;
}

.platform-toggle-collapse-btn:hover {
  background: #f1f5f9;
  color: #0f172a;
}

/* 2 Column Accounts Grid */
.platform-accounts-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  width: 100%;
}

.social-account-card {
  background: #ffffff;
  border: 1px solid #eef2f6;
  border-radius: 14px;
  padding: 12px 14px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.02);
  transition: all 0.15s ease;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
}

.social-account-card:hover {
  border-color: #cbd5e1;
}

.account-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  cursor: pointer;
  user-select: none;
}

.account-header-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1;
}

.account-brand-icon {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  flex-shrink: 0;
  position: relative;
  overflow: hidden;
}

.account-brand-icon::after {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 38%;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.18) 0%, rgba(255, 255, 255, 0) 100%);
  pointer-events: none;
  border-radius: 8px 8px 0 0;
}

.account-brand-icon svg {
  max-width: 17px;
  max-height: 17px;
}

.account-brand-icon.platform--telegram { background: linear-gradient(180deg, #2ea5e4 0%, #2294d1 100%); }
.account-brand-icon.platform--facebook { background: linear-gradient(180deg, #187bf5 0%, #0866ff 100%); }
.account-brand-icon.platform--x { background: #0f172a; }
.account-brand-icon.platform--instagram { background: linear-gradient(135deg, #4f5bd5 0%, #962fbf 30%, #d62976 60%, #fa7e1e 90%, #feda75 100%); }
.account-brand-icon.platform--youtube { background: linear-gradient(180deg, #ff1a1a 0%, #e60000 100%); }
.account-brand-icon.platform--bluesky { background: linear-gradient(180deg, #148aff 0%, #0070eb 100%); }
.account-brand-icon.platform--redgif { background: linear-gradient(180deg, #ea264e 0%, #d4173d 100%); }
.account-brand-icon .icon-rg-img { width: 16px !important; }

.account-text-wrap {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1;
}

.account-card-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: #0f172a;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.25;
}

.account-source-link {
  font-size: 0.74rem;
  color: #64748b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-decoration: none !important;
  margin-top: 2px;
  display: inline-block;
  max-width: 100%;
  transition: color 0.15s ease;
}

.account-source-link:hover,
.account-source-link:focus,
.account-source-link:visited {
  text-decoration: none !important;
}

.account-source-link:hover {
  color: #2563eb;
}

.account-header-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.acc-sync-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.72rem;
  font-weight: 600;
  color: #059669;
  background: #ecfdf5;
  padding: 2px 8px;
  border-radius: 10px;
  white-space: nowrap;
}

.acc-sync-badge .sync-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #10b981;
  display: inline-block;
}

.acc-link-badge {
  font-size: 0.74rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 10px;
  white-space: nowrap;
}

.acc-link-badge--active {
  background: #eff6ff;
  color: #2563eb;
}

.acc-link-badge--zero {
  background: #f1f5f9;
  color: #94a3b8;
}

.acc-toggle-chevron-btn {
  background: transparent;
  border: none;
  color: #94a3b8;
  cursor: pointer;
  padding: 2px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: color 0.15s ease;
}

.acc-toggle-chevron-btn:hover {
  color: #0f172a;
}

.account-card-body {
  margin-top: 10px;
  border-top: 1px solid #f1f5f9;
  padding-top: 10px;
}

.acc-posts-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.acc-post-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 10px;
  border-radius: 8px;
  background: #f8fafc;
  gap: 8px;
  transition: background 0.15s ease;
  min-height: 32px;
  box-sizing: border-box;
}

.acc-post-row:hover {
  background: #f1f5f9;
}

.acc-post-time-box {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.post-item-icon-clock {
  color: #64748b;
  flex-shrink: 0;
}

.acc-post-time {
  font-size: 0.74rem;
  color: #475569;
  font-weight: 500;
  white-space: nowrap;
}

.acc-post-url-box {
  display: flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
  flex: 1;
}

.acc-post-anchor {
  font-size: 0.78rem;
  font-weight: 500;
  color: #2563eb;
  text-decoration: none !important;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
  max-width: 100%;
}

.acc-post-anchor:hover {
  color: #1d4ed8;
  text-decoration: underline !important;
}

.acc-empty-box {
  background: #f8fafc;
  border: 1px dashed #e2e8f0;
  border-radius: 8px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 0.78rem;
  color: #94a3b8;
  font-weight: 500;
}

.acc-card-footer-action {
  display: flex;
  justify-content: flex-end;
  margin-top: 8px;
  padding-top: 6px;
  border-top: 1px dashed #f1f5f9;
}

.btn-acc-copy-all {
  background: transparent;
  border: none;
  color: #4f46e5;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  border-radius: 6px;
  transition: all 0.15s ease;
}

.btn-acc-copy-all:hover {
  background: #eef2ff;
  color: #4338ca;
}

@media (max-width: 900px) {
  .platform-accounts-grid {
    grid-template-columns: 1fr;
  }
}
