*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

html, body {
  width: 100%; min-height: 100vh;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  background: #f0f2f5; color: #1c1e21;
}

/* ═══════════════════════════════════════════
   HIDE ALL DESKTOP ELEMENTS (mobile-first)
═══════════════════════════════════════════ */
.fb-topbar,
.fb-mobile-header,
.fb-mobile-nav,
.fb-sidebar-left,
.fb-sidebar-right { display: none !important; }

/* ═══════════════════════════════════════════
   MAIN HEADER (mobile)
═══════════════════════════════════════════ */
.main-header {
  position: sticky; top: 0; z-index: 200;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 16px;
  border-bottom: 1px solid #e4e6ea;
}
.logo {
  font-size: 28px;
  font-weight: 900;
  color: #1877f2;
  letter-spacing: -1px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}
.header-actions { display: flex; gap: 8px; }
.header-btn {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: #e4e6eb;
  border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: 17px; color: #050505;
  transition: background 0.15s;
}
.header-btn:hover { background: #d8dadf; }

/* ═══════════════════════════════════════════
   PAGE BODY
═══════════════════════════════════════════ */
.fb-page-body { display: block !important; padding-top: 0 !important; width: 100%; }

/* ═══════════════════════════════════════════
   SIDEBARS
═══════════════════════════════════════════ */
.fb-sidebar-left, .fb-sidebar-right {
  width: 280px; min-width: 280px; flex-shrink: 0;
  padding: 16px 8px;
  height: calc(100vh - 56px);
  overflow-y: auto; overflow-x: hidden;
}
.fb-sidebar-left::-webkit-scrollbar,
.fb-sidebar-right::-webkit-scrollbar { width: 0; }
.fb-sidebar-profile {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px; border-radius: 8px; cursor: pointer;
  font-weight: 700; font-size: 15px; color: #1c1e21;
  transition: background 0.15s;
}
.fb-sidebar-profile:hover { background: #f0f2f5; }
.fb-sidebar-profile img { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; }
.fb-sidebar-item {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px; border-radius: 8px; cursor: pointer;
  transition: background 0.15s; color: #1c1e21;
  font-weight: 600; font-size: 15px;
}
.fb-sidebar-item:hover { background: #f0f2f5; }
.fb-sidebar-item i {
  font-size: 20px; width: 36px; height: 36px; border-radius: 50%;
  background: #e4e6eb; display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; color: #1c1e21;
}
.fb-sidebar-divider { height: 1px; background: #dadde1; margin: 8px 12px; }
.fb-sidebar-section { font-size: 17px; font-weight: 700; color: #1c1e21; padding: 8px 12px; margin-top: 8px; }

/* Contacts */
.fb-contacts-header { display: flex; justify-content: space-between; align-items: center; padding: 8px 12px 12px; }
.fb-contacts-title { font-size: 17px; font-weight: 700; color: #65676b; }
.fb-contacts-actions { display: flex; gap: 4px; }
.fb-contacts-action-btn {
  width: 32px; height: 32px; border-radius: 50%; background: none; border: none;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  color: #65676b; font-size: 16px; transition: background 0.15s;
}
.fb-contacts-action-btn:hover { background: #f0f2f5; }
.fb-contact-item {
  display: flex; align-items: center; gap: 12px;
  padding: 8px 12px; border-radius: 8px; cursor: pointer; transition: background 0.15s;
}
.fb-contact-item:hover { background: #f0f2f5; }
.fb-contact-avatar-wrap { position: relative; flex-shrink: 0; }
.fb-contact-avatar { width: 36px; height: 36px; border-radius: 50%; background: #e4e6eb; overflow: hidden; }
.fb-contact-avatar img { width: 100%; height: 100%; object-fit: cover; }
.fb-contact-online {
  position: absolute; bottom: 1px; right: 1px;
  width: 10px; height: 10px; border-radius: 50%;
  background: #31a24c; border: 2px solid #fff;
}
.fb-contact-name { font-size: 15px; font-weight: 600; color: #1c1e21; }

/* ═══════════════════════════════════════════
   FEED
═══════════════════════════════════════════ */
.fb-feed { width: 100% !important; max-width: 100% !important; padding: 0 !important; flex: none !important; }

/* ═══════════════════════════════════════════
   POST CONTAINER
═══════════════════════════════════════════ */
.fb-post-container {
  background: #fff;
  border: none !important;
  border-radius: 0 !important;
  margin-bottom: 0 !important;
}

/* ═══════════════════════════════════════════
   POST HEADER
═══════════════════════════════════════════ */
.fb-post-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 12px 16px 8px;
}
.fb-post-profile { display: flex; align-items: center; gap: 10px; }
.fb-avatar-wrap { position: relative; width: 46px; height: 46px; flex-shrink: 0; }
.fb-avatar-wrap img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }
.fb-post-author {
  font-weight: 700; font-size: 15px; color: #050505;
  display: flex; align-items: center; gap: 4px;
}
.fb-post-time {
  font-size: 13px; color: #65676b;
  display: flex; align-items: center; gap: 4px;
  margin-top: 2px;
}
.fb-post-time i { font-size: 12px; }
.fb-post-header-actions { display: flex; align-items: center; }
.fb-post-menu-btn {
  background: none; border: none;
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; border-radius: 50%;
}
.fb-post-menu-btn i { font-size: 20px; color: #65676b; }

/* ═══════════════════════════════════════════
   POST CONTENT
═══════════════════════════════════════════ */
.fb-post-content { padding: 4px 16px 12px; }
.fb-post-text { font-size: 15px; line-height: 1.5; color: #050505; margin-bottom: 4px; }

/* ═══════════════════════════════════════════
   ENGAGEMENT BAR
═══════════════════════════════════════════ */
.fb-engagement-bar {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 16px; border-bottom: 1px solid #e4e6ea;
  font-size: 15px; color: #65676b;
}
.fb-reactions-container { display: flex; align-items: center; gap: 2px; cursor: pointer; }
.fb-reaction-icon {
  width: 20px; height: 20px; border-radius: 50%;
  object-fit: cover; border: 2px solid #fff; margin-left: -4px;
}
.fb-reaction-icon:first-child { margin-left: 0; }
.fb-reaction-count { margin-left: 6px; font-weight: 500; }
.fb-engagement-stats { display: flex; gap: 16px; }
.fb-stat-item { cursor: pointer; font-weight: 500; }
.fb-stat-item:hover { text-decoration: underline; }

/* ═══════════════════════════════════════════
   POST ACTIONS
═══════════════════════════════════════════ */
.fb-post-actions {
  display: flex; padding: 4px 8px;
  border-top: 1px solid #e4e6ea;
}
.fb-action-btn {
  flex: 1; display: flex; align-items: center; justify-content: center;
  gap: 8px; padding: 8px 4px; border-radius: 6px;
  cursor: pointer; transition: background 0.2s;
  font-weight: 600; font-size: 15px; color: #65676b;
  background: none; border: none;
}
.fb-action-btn:hover { background: #f0f2f5; }
.fb-action-btn i { font-size: 20px; }
.fb-action-btn.liked { color: #1877f2; }

/* ═══════════════════════════════════════════
   ✅ CTA SECTION
═══════════════════════════════════════════ */
.cta-wrapper {
  padding: 20px 16px 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  background: #fff;
}

/* ── Urgency text above button ── */
.cta-urgency {
  width: 100%;
  max-width: 420px;
  text-align: center;
}

.cta-urgency-badge {
  display: inline-block;
  background: #dc2626;
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  padding: 5px 14px;
  border-radius: 99px;
  margin-bottom: 10px;
  animation: badgePop 1.8s infinite;
}

@keyframes badgePop {
  0%, 100% { transform: scale(1); }
  50%       { transform: scale(1.06); }
}

.cta-urgency-title {
  font-size: clamp(16px, 5vw, 20px);
  font-weight: 900;
  color: #111;
  line-height: 1.3;
  margin-bottom: 6px;
}

.cta-urgency-title span {
  color: #16a34a;
}

.cta-urgency-sub {
  font-size: 13px;
  color: #555;
  line-height: 1.5;
}

.cta-urgency-sub strong {
  color: #dc2626;
}

/* ── Button ── */
.cta-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 420px;
  padding: 20px 24px;
  border: 3px solid transparent;
  border-radius: 16px;
  background: linear-gradient(135deg, #15803d 0%, #22c55e 100%);
  color: #fff;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  gap: 4px;
  position: relative;
  /* layered animation: pulse scale + border glow + shake */
  animation: ctaScale 1.6s ease-in-out infinite,
             ctaBorderGlow 1.6s ease-in-out infinite,
             ctaShake 1.6s ease-in-out infinite;
  transition: transform 0.15s;
}

.cta-btn:hover {
  animation: none;
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 12px 40px rgba(34, 197, 94, 0.75);
  border-color: #fff;
}

.cta-btn:active {
  transform: scale(0.98);
}

/* Scale + shadow pulse */
@keyframes ctaScale {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 6px 24px rgba(34, 197, 94, 0.45);
  }
  50% {
    transform: scale(1.04);
    box-shadow: 0 10px 48px rgba(34, 197, 94, 0.85);
  }
}

/* Border color vibration: cycles green → yellow → white → green */
@keyframes ctaBorderGlow {
  0%   { border-color: rgba(34, 197, 94, 0.4);  outline: 3px solid rgba(34, 197, 94, 0.0); }
  25%  { border-color: #facc15;                  outline: 3px solid rgba(250, 204, 21, 0.4); }
  50%  { border-color: #fff;                     outline: 3px solid rgba(255, 255, 255, 0.5); }
  75%  { border-color: #facc15;                  outline: 3px solid rgba(250, 204, 21, 0.4); }
  100% { border-color: rgba(34, 197, 94, 0.4);  outline: 3px solid rgba(34, 197, 94, 0.0); }
}

/* Subtle horizontal shake */
@keyframes ctaShake {
  0%, 40%, 60%, 100% { translate: 0 0; }
  45%                 { translate: -3px 0; }
  50%                 { translate: 3px 0; }
  55%                 { translate: -2px 0; }
}

.cta-line1 {
  font-size: clamp(22px, 6.5vw, 30px);
  font-weight: 900;
  letter-spacing: 1.5px;
  line-height: 1.1;
  text-shadow: 0 2px 8px rgba(0,0,0,0.25);
}

.cta-line2 {
  font-size: clamp(13px, 4vw, 17px);
  font-weight: 700;
  opacity: 0.93;
  line-height: 1.3;
  letter-spacing: 0.3px;
}

/* ═══════════════════════════════════════════
   DELAY HELPER
═══════════════════════════════════════════ */
.esconder { display: none; }

/* ═══════════════════════════════════════════
   NOTIFICATION
═══════════════════════════════════════════ */
.fb-notification {
  position: fixed; right: 16px; bottom: -100px;
  background: #42b883; color: #fff;
  padding: 14px 18px; font-size: 14px;
  border-radius: 10px; box-shadow: 0 4px 20px rgba(0,0,0,0.25);
  max-width: 300px; z-index: 9999;
  transition: bottom 0.4s cubic-bezier(0.22,1,0.36,1); line-height: 1.5;
}
.fb-notification .bold { font-weight: 700; }
.fb-notification.show { bottom: 20px; }

/* ═══════════════════════════════════════════
   COMMENTS
═══════════════════════════════════════════ */
.fb-comments-section { background: #fff; padding-top: 4px; }
.fb-comments-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 8px 16px 4px;
}
.fb-comments-count { font-size: 15px; font-weight: 600; color: #65676b; cursor: pointer; }
.fb-comments-count:hover { text-decoration: underline; }
.fb-comments-sort { font-size: 14px; font-weight: 700; color: #1c1e21; cursor: pointer; display: flex; align-items: center; gap: 5px; }
.fb-comments-list { padding: 4px 16px; }

.fb-comment { display: flex; gap: 8px; padding: 6px 0; }
.fb-comment-profile-pic {
  width: 32px; height: 32px; border-radius: 50%; background: #e4e6eb;
  flex-shrink: 0; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
}
.fb-comment-profile-pic img { width: 100%; height: 100%; object-fit: cover; }
.fb-comment-profile-pic i { font-size: 14px; color: #65676b; }
.fb-comment-content { flex: 1; }
.fb-comment-bubble {
  background: #f0f2f5; border-radius: 18px;
  padding: 8px 12px; display: inline-block;
  max-width: 100%; margin-bottom: 4px;
}
.fb-comment-author { font-weight: 700; font-size: 13px; color: #1c1e21; display: block; margin-bottom: 2px; }
.fb-comment-text { font-size: 14px; line-height: 1.4; color: #1c1e21; margin: 0; }
.fb-comment-actions { display: flex; gap: 8px; align-items: center; padding-left: 4px; }
.fb-comment-action {
  font-size: 12px; font-weight: 700; color: #65676b;
  cursor: pointer; background: none; border: none;
  padding: 2px 0; transition: color 0.15s;
}
.fb-comment-action:hover, .fb-comment-action.liked-action { color: #1877f2; }
.fb-comment-time-small { font-size: 12px; color: #65676b; }
.fb-comment-reactions {
  font-size: 12px; color: #65676b; font-weight: 600;
  margin-left: auto; display: flex; align-items: center; gap: 3px;
}
.fb-reply-comment { margin-left: 36px; margin-top: 4px; }

.fb-add-comment { padding: 8px 16px 12px; }
.fb-comment-input-container { display: flex; align-items: center; gap: 8px; }
.fb-comment-input-wrapper {
  flex: 1; display: flex; align-items: center;
  background: #f0f2f5; border-radius: 20px;
  padding: 8px 12px; gap: 8px; transition: background 0.2s;
}
.fb-comment-input-wrapper:focus-within { background: #fff; box-shadow: 0 0 0 2px #1877f2; }
.fb-comment-input { flex: 1; border: none; background: transparent; font-size: 15px; color: #1c1e21; outline: none; }
.fb-comment-input::placeholder { color: #65676b; }
.fb-comment-input-actions { display: flex; gap: 2px; }
.fb-comment-icon-btn {
  width: 32px; height: 32px; border: none; border-radius: 50%;
  background: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  color: #65676b; font-size: 16px; transition: background 0.15s;
}
.fb-comment-icon-btn:hover { background: #e4e6eb; color: #1877f2; }
.fb-comment-send-btn {
  width: 34px; height: 34px; border: none; border-radius: 50%;
  background: #1877f2;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; flex-shrink: 0; color: #fff; font-size: 14px;
  opacity: 0.5; transition: opacity 0.2s, background 0.2s;
}
.fb-comment-send-btn:not([disabled]) { opacity: 1; }
.fb-comment-send-btn:not([disabled]):hover { background: #166fe5; }

.fb-new-comment { animation: fbSlideIn 0.3s ease-out; }
@keyframes fbSlideIn { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fbSpin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
.fb-spinner { animation: fbSpin 1s linear infinite; }

/* ═══════════════════════════════════════════
   DESKTOP 768px+
═══════════════════════════════════════════ */
@media (min-width: 768px) {
  .fb-topbar { display: flex; }
  .fb-mobile-header, .fb-mobile-nav { display: none; }
  .fb-page-body {
    display: flex !important;
    justify-content: center;
    align-items: flex-start;
    padding-top: 56px;
    width: 100%;
  }
  .fb-sidebar-left, .fb-sidebar-right { display: block !important; position: sticky; top: 56px; }
  .fb-feed { max-width: 500px; flex: 1 !important; padding: 16px 8px !important; min-width: 0; }
  .fb-post-container { border-radius: 8px; border: 1px solid #e4e6ea !important; margin-bottom: 16px !important; overflow: hidden; }
}

@media (min-width: 1100px) {
  .fb-feed { max-width: 590px; }
  .fb-sidebar-left, .fb-sidebar-right { width: 300px; }
}

@media (min-width: 1300px) {
  .fb-sidebar-left, .fb-sidebar-right { width: 360px; }
}