/* ============================================================
   CommentCraft — Stylesheet
   ============================================================ */

/* ----- Variables ----- */
:root {
  --primary:       #7C3AED;
  --primary-light: #8B5CF6;
  --primary-dark:  #6D28D9;
  --secondary:     #EC4899;
  --accent:        #F97316;

  --bg:         #0D0D1A;
  --bg-card:    #16162A;
  --bg-card-2:  #1E1E35;
  --bg-input:   #0F0F22;
  --border:     rgba(255,255,255,0.08);
  --border-focus: rgba(124,58,237,0.6);

  --text-1: #F1F1F8;
  --text-2: #9B9BB8;
  --text-3: #6B6B88;

  --shadow-sm: 0 2px 8px rgba(0,0,0,0.25);
  --shadow-md: 0 8px 32px rgba(0,0,0,0.35);
  --shadow-lg: 0 20px 60px rgba(0,0,0,0.5);

  --radius-sm: 8px;
  --radius:    14px;
  --radius-lg: 22px;
  --radius-xl: 32px;

  --transition: 0.2s ease;

  --font: 'Inter', system-ui, -apple-system, sans-serif;

  /* Platform colors */
  --tiktok-bg:    #121212;
  --facebook-bg:  #F0F2F5;
  --instagram-bg: #FFFFFF;
  --whatsapp-bg:  #E5DDD5;
  --whatsapp-dark-bg: #0D1117;
}

/* ----- Reset ----- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text-1);
  min-height: 100vh;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button { cursor: pointer; font-family: var(--font); border: none; background: none; }
input, textarea, select { font-family: var(--font); }

.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ============================================================
   HEADER
   ============================================================ */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(13,13,26,0.9);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  padding-top: env(safe-area-inset-top);
}

.nav {
  display: flex;
  align-items: center;
  gap: 24px;
  height: 64px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.logo img { border-radius: 8px; }
.logo-text {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-1);
  letter-spacing: -0.02em;
}
.logo-accent { color: var(--primary-light); }

.nav-links {
  display: flex;
  gap: 8px;
  margin-left: auto;
}
.nav-link {
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-2);
  transition: color var(--transition), background var(--transition);
}
.nav-link:hover { color: var(--text-1); background: rgba(255,255,255,0.06); }

.nav-actions { display: flex; align-items: center; gap: 8px; }

.btn-nav-refresh {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  color: var(--text-3);
  transition: color var(--transition), background var(--transition), transform 0.35s ease;
  flex-shrink: 0;
}
.btn-nav-refresh:hover {
  color: var(--text-1);
  background: rgba(255,255,255,0.06);
}
.btn-nav-refresh:active { transform: rotate(180deg); }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-weight: 600;
  transition: opacity var(--transition), transform var(--transition), box-shadow var(--transition);
  box-shadow: 0 4px 20px rgba(124,58,237,0.4);
}
.btn-primary:hover  { opacity: 0.9; transform: translateY(-1px); box-shadow: 0 6px 28px rgba(124,58,237,0.5); }
.btn-primary:active { transform: translateY(0); opacity: 1; }

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  background: var(--bg-card-2);
  border: 1px solid var(--border);
  color: var(--text-1);
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 500;
  transition: background var(--transition), border-color var(--transition);
}
.btn-secondary:hover { background: rgba(255,255,255,0.08); border-color: rgba(255,255,255,0.15); }

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-2);
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 500;
  transition: all var(--transition);
}
.btn-ghost:hover { background: rgba(255,255,255,0.06); color: var(--text-1); }
.btn-sm { padding: 6px 12px; font-size: 0.8rem; }

.btn-download {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
  border-radius: var(--radius);
  font-size: 1rem;
  font-weight: 700;
  width: 100%;
  justify-content: center;
  transition: all var(--transition);
  box-shadow: 0 4px 20px rgba(124,58,237,0.4);
}
.btn-download:hover:not(:disabled) { opacity: 0.9; transform: translateY(-1px); box-shadow: 0 8px 30px rgba(124,58,237,0.5); }
.btn-download:disabled { opacity: 0.4; cursor: not-allowed; transform: none; }

.btn-copy {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: var(--bg-card-2);
  border: 1px solid var(--border);
  color: var(--text-1);
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 500;
  transition: all var(--transition);
}
.btn-copy:hover:not(:disabled) { background: rgba(255,255,255,0.08); }
.btn-copy:disabled { opacity: 0.4; cursor: not-allowed; }

.btn-share {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: linear-gradient(135deg, #128C7E, #25D366);
  color: #fff;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 600;
  transition: all var(--transition);
  flex: 1;
}
.btn-share:hover:not(:disabled) { opacity: 0.88; transform: translateY(-1px); }
.btn-share:disabled { opacity: 0.4; cursor: not-allowed; transform: none; }

/* ============================================================
   HERO
   ============================================================ */
.hero {
  padding: 80px 0 60px;
  text-align: center;
  background: radial-gradient(ellipse 80% 60% at 50% -10%, rgba(124,58,237,0.2) 0%, transparent 70%);
}
.hero-inner { display: flex; flex-direction: column; align-items: center; gap: 20px; }

.hero-badge {
  display: inline-flex;
  align-items: center;
  padding: 6px 16px;
  background: rgba(124,58,237,0.15);
  border: 1px solid rgba(124,58,237,0.3);
  border-radius: 100px;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--primary-light);
}

.hero-title {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: var(--text-1);
}
.gradient-text {
  background: linear-gradient(135deg, var(--primary-light), var(--secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 1.1rem;
  color: var(--text-2);
  max-width: 560px;
  line-height: 1.7;
}

.hero-platforms {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}
.platform-badge {
  padding: 5px 14px;
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.tiktok-badge    { background: rgba(0,0,0,0.5); border: 1px solid #333; color: #fff; }
.facebook-badge  { background: rgba(24,119,242,0.15); border: 1px solid rgba(24,119,242,0.3); color: #4A9EF5; }
.instagram-badge { background: rgba(228,64,95,0.15); border: 1px solid rgba(228,64,95,0.3); color: #F45B78; }
.whatsapp-badge  { background: rgba(37,211,102,0.12); border: 1px solid rgba(37,211,102,0.3); color: #25D366; }
.youtube-badge   { background: rgba(255,0,0,0.12);   border: 1px solid rgba(255,0,0,0.3);   color: #FF4444; }
.twitter-badge   { background: rgba(255,255,255,0.08); border: 1px solid #333; color: #fff; }
.threads-badge   { background: rgba(255,255,255,0.06); border: 1px solid #444; color: #aaa; }
.linkedin-badge  { background: rgba(10,102,194,0.15); border: 1px solid rgba(10,102,194,0.3); color: #4A9EF5; }
.reddit-badge    { background: rgba(255,69,0,0.12); border: 1px solid rgba(255,69,0,0.3); color: #FF6534; }

.btn-hero { padding: 14px 36px; font-size: 1.05rem; border-radius: var(--radius-lg); }

/* ============================================================
   ADS
   ============================================================ */
.ad-container { margin: 20px auto; }
.ad-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-card);
  border: 1px dashed rgba(255,255,255,0.1);
  border-radius: var(--radius);
  color: var(--text-3);
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.ad-label { pointer-events: none; }
.ad-top   { height: 90px; max-width: 728px; }
.ad-wide  { height: 90px; }
.ad-sidebar { height: 250px; min-width: 160px; width: 160px; flex-shrink: 0; }

/* ============================================================
   PLATFORM TABS
   ============================================================ */
.platform-tabs {
  display: flex;
  gap: 6px;
  margin: 40px 0 24px;
  background: var(--bg-card);
  padding: 6px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  overflow-x: auto;
  scrollbar-width: none;
}
.platform-tabs::-webkit-scrollbar { display: none; }

.tab-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-2);
  transition: all var(--transition);
  white-space: nowrap;
  flex: 1;
  justify-content: center;
}
.tab-btn:hover { color: var(--text-1); background: rgba(255,255,255,0.06); }
.tab-btn.active {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
  box-shadow: 0 4px 16px rgba(124,58,237,0.35);
}
.tab-icon { width: 18px; height: 18px; flex-shrink: 0; }

/* Platform active states */
.tab-btn[data-platform="tiktok"].active    { background: linear-gradient(135deg, #010101, #69C9D0); }
.tab-btn[data-platform="facebook"].active  { background: linear-gradient(135deg, #1877F2, #42A5F5); }
.tab-btn[data-platform="instagram"].active { background: linear-gradient(135deg, #833AB4, #FD1D1D, #FCB045); }
.tab-btn[data-platform="whatsapp"].active  { background: linear-gradient(135deg, #128C7E, #25D366); }
.tab-btn[data-platform="youtube"].active   { background: linear-gradient(135deg, #CC0000, #FF4444); }
.tab-btn[data-platform="twitter"].active   { background: linear-gradient(135deg, #000000, #14171A); box-shadow: 0 4px 16px rgba(0,0,0,0.5); }
.tab-btn[data-platform="threads"].active   { background: linear-gradient(135deg, #101010, #383838); box-shadow: 0 4px 16px rgba(0,0,0,0.5); }
.tab-btn[data-platform="linkedin"].active  { background: linear-gradient(135deg, #0A66C2, #0077B5); box-shadow: 0 4px 16px rgba(10,102,194,0.4); }
.tab-btn[data-platform="reddit"].active    { background: linear-gradient(135deg, #FF4500, #FF6534); box-shadow: 0 4px 16px rgba(255,69,0,0.4); }

/* ============================================================
   EDITOR GRID
   ============================================================ */
.editor-grid {
  display: grid;
  grid-template-columns: 420px 1fr;
  gap: 24px;
  align-items: start;
  margin-bottom: 60px;
}

/* ============================================================
   CARD
   ============================================================ */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
}

/* ============================================================
   FORM
   ============================================================ */
.panel-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-1);
  margin-bottom: 24px;
  letter-spacing: -0.01em;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 16px;
}
.form-group.center-v {
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.form-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-2);
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.form-input {
  padding: 10px 14px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-1);
  font-size: 0.9rem;
  transition: border-color var(--transition), box-shadow var(--transition);
  width: 100%;
}
.form-input:focus {
  outline: none;
  border-color: var(--primary-light);
  box-shadow: 0 0 0 3px rgba(124,58,237,0.15);
}
.form-input::placeholder { color: var(--text-3); }

.form-textarea {
  resize: vertical;
  min-height: 90px;
  line-height: 1.5;
}

.form-color {
  padding: 4px 6px;
  height: 40px;
  cursor: pointer;
  border-radius: var(--radius-sm);
}

.form-select { appearance: none; cursor: pointer; }

.char-count {
  font-size: 0.75rem;
  color: var(--text-3);
  text-align: right;
  margin-top: -10px;
}

/* Toggle Switch */
.toggle-switch { position: relative; display: inline-block; width: 44px; height: 24px; flex-shrink: 0; }
.toggle-switch input { opacity: 0; width: 0; height: 0; }
.toggle-slider {
  position: absolute;
  inset: 0;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 100px;
  transition: var(--transition);
  cursor: pointer;
}
.toggle-slider::before {
  content: '';
  position: absolute;
  width: 18px; height: 18px;
  left: 2px; bottom: 2px;
  background: var(--text-3);
  border-radius: 50%;
  transition: var(--transition);
}
.toggle-switch input:checked + .toggle-slider { background: var(--primary); border-color: var(--primary); }
.toggle-switch input:checked + .toggle-slider::before { transform: translateX(20px); background: #fff; }

/* Platform-specific field groups */
.hidden { display: none !important; }

.form-actions {
  display: flex;
  gap: 10px;
  margin-top: 24px;
}
.btn-generate { flex: 1; justify-content: center; }

/* ============================================================
   PREVIEW PANEL
   ============================================================ */
.preview-panel {
  display: flex;
  gap: 20px;
  align-items: flex-start;
}
.preview-wrapper { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; }

/* Phone frame */
.phone-frame {
  width: 320px;
  min-height: 520px;
  margin: 0 auto 20px;
  border-radius: 40px;
  border: 10px solid #1c1c2e;
  background: var(--tiktok-bg);
  position: relative;
  overflow: hidden;
  box-shadow: 0 30px 80px rgba(0,0,0,0.6), inset 0 0 0 1px rgba(255,255,255,0.05);
  transition: background var(--transition);
}
.phone-frame[data-platform="facebook"]  { background: var(--facebook-bg); border-color: #ddd; }
.phone-frame[data-platform="instagram"] { background: var(--instagram-bg); border-color: #ddd; }
.phone-frame[data-platform="whatsapp"]  { background: var(--whatsapp-bg); border-color: #1c1c2e; }

.phone-notch {
  position: absolute;
  top: 0; left: 50%;
  transform: translateX(-50%);
  width: 88px; height: 22px;
  background: #1c1c2e;
  border-radius: 0 0 16px 16px;
  z-index: 10;
}

.phone-status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 26px 16px 8px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-1);
  position: relative;
  z-index: 5;
}
.phone-frame[data-platform="facebook"]  .phone-status,
.phone-frame[data-platform="instagram"] .phone-status { color: #111; }
.phone-frame[data-platform="whatsapp"]  .phone-status { color: #111; }

.status-time { letter-spacing: 0.05em; }
.status-icons { display: flex; align-items: center; gap: 4px; }

.phone-screen {
  padding: 8px 12px 20px;
  min-height: 380px;
  overflow-y: auto;
}

.preview-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 320px;
  gap: 12px;
  color: rgba(255,255,255,0.25);
  text-align: center;
  font-size: 0.85rem;
}
.placeholder-icon { font-size: 2.5rem; }
.phone-frame[data-platform="facebook"] .preview-placeholder,
.phone-frame[data-platform="instagram"] .preview-placeholder,
.phone-frame[data-platform="whatsapp"] .preview-placeholder {
  color: rgba(0,0,0,0.25);
}

.preview-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 12px;
  width: 100%;
  max-width: 400px;
}
.preview-tip {
  font-size: 0.78rem;
  color: var(--text-3);
  text-align: center;
}

/* ============================================================
   TIKTOK COMMENT PREVIEW
   ============================================================ */
.tt-wrapper { padding: 0; }
.tt-comment {
  display: flex;
  gap: 10px;
  padding: 8px 0;
}
.tt-avatar {
  width: 38px; height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}
.tt-body { flex: 1; min-width: 0; }
.tt-header {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
  margin-bottom: 3px;
}
.tt-username {
  font-size: 13px;
  font-weight: 400;
  color: rgba(255,255,255,0.9);
  font-family: system-ui, sans-serif;
}
/* Badge verificado — ahora es SVG inline, no necesita clase CSS */
.tt-time {
  font-size: 11px;
  color: rgba(255,255,255,0.4);
}
.tt-text {
  font-size: 14px;
  color: rgba(255,255,255,0.92);
  line-height: 1.5;
  word-break: break-word;
  margin-bottom: 6px;
  font-family: system-ui, sans-serif;
}
.tt-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}
.tt-reply {
  font-size: 12px;
  color: rgba(255,255,255,0.5);
  font-weight: 500;
}
.tt-replies {
  font-size: 12px;
  color: rgba(255,255,255,0.45);
}
.tt-see-replies {
  display: flex;
  align-items: center;
  gap: 6px;
  padding-left: 48px;
  margin-top: 4px;
  font-size: 13px;
  font-weight: 500;
  color: rgba(255,255,255,0.55);
  font-family: system-ui, sans-serif;
  cursor: pointer;
}
.tt-see-replies-dash {
  color: rgba(255,255,255,0.25);
  letter-spacing: -2px;
  margin-right: 2px;
}
.tt-heart-btn {
  margin-left: auto;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
  align-self: flex-end;
  padding-bottom: 2px;
}
.tt-heart-count { font-size: 12px; color: rgba(255,255,255,0.5); }
.tt-divider { display: none; }

/* ============================================================
   FACEBOOK COMMENT PREVIEW
   ============================================================ */
.fb-wrapper {
  background: #fff;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}
.fb-comment { display: flex; gap: 10px; align-items: flex-start; }
.fb-avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}
.fb-right { flex: 1; min-width: 0; }
.fb-name-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 3px;
  overflow: visible;
}
.fb-username {
  font-size: 15px;
  font-weight: 700;
  color: #050505;
  line-height: 1.3;
}
.fb-time-sep {
  font-size: 13px;
  color: #65676B;
  line-height: 1;
}
.fb-time {
  font-size: 13px;
  font-weight: 400;
  color: #65676B;
}
.fb-text {
  font-size: 15px;
  color: #050505;
  line-height: 1.45;
  word-break: break-word;
  margin-bottom: 6px;
}
.fb-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.fb-reply-btn {
  font-size: 13px;
  font-weight: 600;
  color: #65676B;
  cursor: pointer;
}
.fb-react-badge {
  display: flex;
  align-items: center;
  gap: 4px;
}
.fb-react-emoji {
  font-size: 16px;
  line-height: 1;
}
.fb-react-count {
  font-size: 14px;
  font-weight: 400;
  color: #050505;
}
.fb-like-btn {
  margin-left: auto;
  display: flex;
  align-items: center;
  cursor: pointer;
}
.fb-see-replies {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
  font-size: 13px;
  font-weight: 500;
  color: #65676B;
  cursor: pointer;
}

/* ============================================================
   INSTAGRAM COMMENT PREVIEW
   ============================================================ */
.ig-wrapper {
  background: #fff;
  padding: 0;
  font-family: -apple-system, 'Helvetica Neue', Arial, sans-serif;
}
.ig-comment {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 8px 0;
}
.ig-avatar {
  width: 32px; height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}
.ig-story-ring {
  padding: 2px;
  background: linear-gradient(135deg, #feda75, #fa7e1e, #d62976, #962fbf, #4f5bd5);
  border-radius: 50%;
  flex-shrink: 0;
}
.ig-story-ring .ig-avatar {
  border: 2px solid #fff;
}
.ig-body { flex: 1; min-width: 0; }
.ig-user-row {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-bottom: 2px;
  overflow: visible;
  line-height: 1.2;
}
.ig-username {
  font-size: 13.5px;
  font-weight: 600;
  color: #262626;
}
.ig-time { font-size: 12px; color: #8E8E8E; }
.ig-text {
  font-size: 14px;
  color: #262626;
  line-height: 1.45;
  word-break: break-word;
  margin-bottom: 6px;
}
.ig-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}
.ig-reply-btn {
  font-size: 12px;
  font-weight: 600;
  color: #8E8E8E;
  cursor: pointer;
}
.ig-heart-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 2px;
  flex-shrink: 0;
  padding-top: 6px;
  min-width: 24px;
}
.ig-heart {
  display: flex;
  align-items: center;
  cursor: pointer;
}
.ig-like-count {
  font-size: 11px;
  color: #262626;
  font-weight: 400;
}
.ig-see-replies {
  font-size: 12px;
  font-weight: 600;
  color: #8E8E8E;
  padding-left: 46px;
  margin-top: 2px;
  margin-bottom: 6px;
}
.ig-see-replies::before { content: '── '; }

/* ============================================================
   WHATSAPP MESSAGE PREVIEW
   ============================================================ */
.wa-wrapper {
  padding: 10px 8px;
  display: flex;
  flex-direction: column;
}
.wa-wrapper.dark { background: #0D1117; }

/* Contenedor del bubble + avatar */
.wa-bubble-container {
  display: flex;
  align-items: flex-end;
  gap: 6px;
}
.wa-bubble-container.sent-side {
  flex-direction: row-reverse; /* bubble a la derecha */
}
.wa-bubble-container.received-side {
  flex-direction: row; /* avatar izq, bubble derecha */
}

/* Avatar del remitente (mensajes recibidos en grupo) */
.wa-recv-avatar {
  width: 28px; height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
  overflow: hidden;
}

.wa-message {
  max-width: 78%;
  min-width: 80px;
  border-radius: 8px;
  padding: 6px 9px 8px;
  position: relative;
  font-family: -apple-system, 'Helvetica Neue', Arial, sans-serif;
  box-shadow: 0 1px 0.5px rgba(0,0,0,0.13);
}

/* Enviado — colita arriba-derecha */
.wa-message.sent {
  background: #DCF8C6;
  border-top-right-radius: 2px;
}
.wa-message.sent::after {
  content: '';
  position: absolute;
  right: -8px;
  top: 0;
  width: 0; height: 0;
  border-left: 8px solid #DCF8C6;
  border-bottom: 8px solid transparent;
}

/* Recibido — colita abajo-izquierda (donde está el avatar) */
.wa-message.received {
  background: #FFFFFF;
  border-bottom-left-radius: 2px;
}
.wa-message.received::after {
  content: '';
  position: absolute;
  left: -8px;
  bottom: 0;
  width: 0; height: 0;
  border-right: 8px solid #FFFFFF;
  border-top: 8px solid transparent;
}

/* Nombre del remitente dentro del bubble */
.wa-sender-name {
  font-size: 13px;
  font-weight: 600;
  color: #00A884;
  margin-bottom: 1px;
  display: block;
}

.wa-text {
  font-size: 14.5px;
  color: #111B21;
  line-height: 1.5;
  word-break: break-word;
}
.wa-dark .wa-text { color: #E9EDEF; }

.wa-meta {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  margin-top: 3px;
}
.wa-time {
  font-size: 11px;
  color: rgba(0,0,0,0.45);
}
.wa-dark .wa-time { color: rgba(255,255,255,0.4); }
.wa-tick-svg {
  display: inline-flex;
  align-items: center;
}

/* Selector de tipo de mensaje WhatsApp */
.wa-msg-type {
  display: flex;
  gap: 4px;
  background: var(--bg-input);
  padding: 4px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}
.wa-type-opt {
  flex: 1;
  cursor: pointer;
}
.wa-type-opt input[type="radio"] { display: none; }
.wa-type-label {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 7px 6px;
  border-radius: 5px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-2);
  transition: all var(--transition);
  min-height: 32px;
}
.wa-type-opt input:checked + .wa-type-label {
  background: linear-gradient(135deg, #128C7E, #25D366);
  color: #fff;
  box-shadow: 0 2px 8px rgba(18,140,126,0.35);
}

/* ============================================================
   HOW-TO SECTION
   ============================================================ */
.howto-section {
  padding: 60px 0;
  background: linear-gradient(180deg, transparent, rgba(124,58,237,0.05));
}
.section-title {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--text-1);
  margin-bottom: 40px;
  text-align: center;
  letter-spacing: -0.02em;
}
.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.step-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  text-align: center;
  transition: border-color var(--transition), transform var(--transition);
}
.step-card:hover { border-color: rgba(124,58,237,0.4); transform: translateY(-3px); }
.step-number {
  width: 48px; height: 48px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
  font-size: 1.3rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  box-shadow: 0 4px 16px rgba(124,58,237,0.3);
}
.step-card h3 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--text-1);
}
.step-card p { font-size: 0.875rem; color: var(--text-2); line-height: 1.6; }

/* ============================================================
   HISTORY
   ============================================================ */
.history-section { padding: 40px 0 60px; }
.history-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}
.history-header .section-title { text-align: left; margin-bottom: 0; }

.history-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
}
.history-empty {
  grid-column: 1/-1;
  text-align: center;
  padding: 48px 20px;
  color: var(--text-3);
  font-size: 0.9rem;
  background: var(--bg-card);
  border: 1px dashed var(--border);
  border-radius: var(--radius-lg);
  line-height: 1.6;
}

.history-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  transition: border-color var(--transition), transform var(--transition);
  cursor: pointer;
}
.history-card:hover { border-color: rgba(124,58,237,0.4); transform: translateY(-2px); }
.history-platform-badge {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 100px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 10px;
}
.badge-tiktok    { background: rgba(0,0,0,0.6); color: #fff; border: 1px solid #444; }
.badge-facebook  { background: rgba(24,119,242,0.15); color: #4A9EF5; border: 1px solid rgba(24,119,242,0.2); }
.badge-instagram { background: rgba(228,64,95,0.15); color: #F45B78; border: 1px solid rgba(228,64,95,0.2); }
.badge-whatsapp  { background: rgba(37,211,102,0.12); color: #25D366; border: 1px solid rgba(37,211,102,0.2); }
.badge-youtube   { background: rgba(255,0,0,0.12);   color: #FF4444; border: 1px solid rgba(255,0,0,0.2); }
.badge-twitter   { background: rgba(0,0,0,0.6); color: #fff; border: 1px solid #333; }
.badge-threads   { background: rgba(255,255,255,0.08); color: #aaa; border: 1px solid #444; }
.badge-linkedin  { background: rgba(10,102,194,0.15); color: #4A9EF5; border: 1px solid rgba(10,102,194,0.2); }
.badge-reddit    { background: rgba(255,69,0,0.12); color: #FF6534; border: 1px solid rgba(255,69,0,0.2); }

.history-username {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-1);
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.history-text {
  font-size: 0.8rem;
  color: var(--text-2);
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  line-height: 1.4;
  margin-bottom: 10px;
}
.history-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.history-date { font-size: 0.72rem; color: var(--text-3); }
.history-actions { display: flex; align-items: center; gap: 2px; }
.history-delete, .history-dl {
  font-size: 0.75rem;
  color: var(--text-3);
  padding: 4px 7px;
  border-radius: 6px;
  transition: all var(--transition);
  line-height: 1;
}
.history-delete:hover { background: rgba(239,68,68,0.15); color: #F87171; }
.history-dl:hover:not(:disabled) { background: rgba(124,58,237,0.15); color: var(--primary-light); }
.history-dl:disabled { opacity: 0.4; cursor: not-allowed; }

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  border-top: 1px solid var(--border);
  padding: 32px 0;
  text-align: center;
}
.footer-inner { display: flex; flex-direction: column; align-items: center; gap: 12px; }
.footer-brand { display: flex; align-items: center; gap: 10px; }
.footer-copy { font-size: 0.85rem; color: var(--text-2); }
.footer-disclaimer {
  font-size: 0.75rem;
  color: var(--text-3);
  max-width: 560px;
  line-height: 1.6;
}

/* ============================================================
   TOAST
   ============================================================ */
.toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%) translateY(80px);
  background: #1E1E35;
  color: var(--text-1);
  padding: 12px 24px;
  border-radius: 100px;
  font-size: 0.875rem;
  font-weight: 500;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
  z-index: 9999;
  opacity: 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
  pointer-events: none;
  white-space: nowrap;
}
.toast.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}
.toast.success { border-color: rgba(52,211,153,0.4); background: rgba(16,47,35,0.95); color: #34D399; }
.toast.error   { border-color: rgba(248,113,113,0.4); background: rgba(47,16,16,0.95); color: #F87171; }

/* ============================================================
   RESPONSIVE
   ============================================================ */

/* ── Tablet ancho ──────────────────────────────────────── */
@media (max-width: 1100px) {
  .editor-grid { grid-template-columns: 360px 1fr; }
  .ad-sidebar { display: none; }
}

/* ── Tablet / iPad ─────────────────────────────────────── */
@media (max-width: 900px) {
  .editor-grid { grid-template-columns: 1fr; gap: 16px; }
  .preview-panel { order: -1; }
  .form-panel    { order:  1; }
  .steps-grid    { grid-template-columns: 1fr; }
  .nav-links     { display: none; }
  .preview-wrapper { width: 100%; align-items: center; }
}

/* ── Móvil ─────────────────────────────────────────────── */
@media (max-width: 600px) {
  /* Ocultar solo lo que no aporta en móvil */
  .ad-container    { display: none; }
  #clearHistoryBtn { display: none; }

  /* ── Historial compacto ── */
  .history-section { padding: 20px 0 32px; }
  .history-header { margin-bottom: 14px; }
  .history-header .section-title { font-size: 1.1rem; }
  .history-grid { grid-template-columns: 1fr; gap: 10px; }
  .history-card { padding: 12px; }
  .history-empty { padding: 28px 16px; font-size: 0.82rem; }

  /* ── Hero compacto ── */
  .hero { padding: 20px 0 16px; }
  .hero-badge { font-size: 0.7rem; padding: 4px 10px; margin-bottom: 10px; }
  .hero-title { font-size: 1.55rem; line-height: 1.2; margin-bottom: 8px; }
  .hero-subtitle { font-size: 0.82rem; line-height: 1.45; margin-bottom: 12px; }
  .hero-platforms { gap: 6px; margin-bottom: 14px; flex-wrap: wrap; justify-content: center; }
  .platform-badge { font-size: 0.7rem; padding: 4px 10px; }
  .btn-hero { display: none; }

  /* ── How-to compacto ── */
  .howto-section { padding: 20px 0; }
  .howto-section .section-title { font-size: 1.1rem; margin-bottom: 14px; }
  .steps-grid { grid-template-columns: 1fr; gap: 10px; }
  .step-card { padding: 12px 14px; display: flex; align-items: flex-start; gap: 12px; text-align: left; }
  .step-number { flex-shrink: 0; width: 28px; height: 28px; font-size: 0.8rem; line-height: 28px; margin: 0; box-shadow: none; }
  .step-card h3 { font-size: 0.85rem; margin-bottom: 2px; }
  .step-card p  { font-size: 0.78rem; line-height: 1.4; }

  /* ── Nav compacto ── */
  .nav { height: 52px; }
  .nav-links { display: none; }
  .logo img { width: 30px; height: 30px; }
  .logo-text { font-size: 1.05rem; }

  /* ── Main ── */
  .main { padding-top: 0; }
  .panel-title { font-size: 0.9rem; margin-bottom: 10px; }
  .preview-tip { font-size: 0.72rem; line-height: 1.4; margin-top: 8px; }

  /* ── Tabs ── */
  .platform-tabs {
    gap: 3px;
    padding: 4px;
    margin: 10px 0 10px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    border-radius: var(--radius);
  }
  .platform-tabs::-webkit-scrollbar { display: none; }
  .tab-btn { flex: none; padding: 8px 11px; font-size: 0.75rem; gap: 4px; white-space: nowrap; }
  .tab-icon { width: 15px; height: 15px; }

  /* ── Editor grid ── */
  .editor-grid { gap: 10px; margin-bottom: 24px; }

  /* ── Cards ── */
  .card { padding: 14px; border-radius: var(--radius); }
  .form-row { grid-template-columns: 1fr; }
  .form-label { font-size: 0.74rem; }
  .form-input { font-size: 0.85rem; padding: 9px 12px; }
  .form-textarea { min-height: 70px; }

  /* ── Preview ── */
  .preview-card-outer { max-width: 100%; border-radius: var(--radius); }
  .preview-actions { flex-direction: row; gap: 8px; margin-bottom: 0; }
  .btn-download { flex: 1; padding: 12px 14px; font-size: 0.88rem; }
  .btn-share    { flex: 1; padding: 12px 14px; font-size: 0.88rem; }
  .btn-copy     { padding: 12px 14px; font-size: 0.85rem; }

  /* ── Form actions ── */
  .form-actions { margin-top: 14px; gap: 8px; }
  .btn-generate { flex: 1; justify-content: center; }
  #saveHistoryBtn { padding: 10px 14px; font-size: 0.82rem; }

  /* ── WhatsApp ── */
  .wa-type-label { padding: 6px 4px; min-height: 28px; }

  /* ── Avatar ── */
  .avatar-thumb { width: 46px; height: 46px; }
  .avatar-thumb-text { font-size: 18px; }
}

/* ── Móvil pequeño (<420px) ────────────────────────────── */
@media (max-width: 420px) {
  .container { padding: 0 10px; }
  .hero-title { font-size: 1.35rem; }

  /* Solo íconos en tabs */
  .tab-btn { padding: 8px 9px; font-size: 0; gap: 0; }
  .tab-btn .tab-icon { width: 16px; height: 16px; }

  .card { padding: 12px; }
  .step-card { padding: 10px 12px; }
}

/* ============================================================
   AVATAR UPLOAD WIDGET
   ============================================================ */
.avatar-upload-row {
  display: flex;
  align-items: center;
  gap: 14px;
}

.avatar-thumb {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 2px solid var(--border);
  overflow: hidden;
  transition: border-color var(--transition), transform var(--transition);
  cursor: pointer;
}
.avatar-thumb:hover { border-color: var(--primary-light); transform: scale(1.05); }

.avatar-thumb-text {
  font-size: 22px;
  font-weight: 700;
  color: #fff;
  line-height: 1;
  user-select: none;
  pointer-events: none;
}

.avatar-upload-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.avatar-file-label {
  cursor: pointer;
  user-select: none;
}

/* ============================================================
   PREVIEW CARD (sin marco de teléfono)
   ============================================================ */
.preview-card-outer {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 8px 48px rgba(0,0,0,0.45);
  background: #121212;
  transition: background 0.25s ease, box-shadow 0.25s ease;
  width: 100%;
  max-width: 400px;
  margin: 0 auto 20px;
  display: inline-block;
}

.preview-card-outer[data-platform="facebook"]  { background: #fff; box-shadow: 0 8px 48px rgba(0,0,0,0.18); }
.preview-card-outer[data-platform="instagram"] { background: #FFFFFF; box-shadow: 0 8px 48px rgba(0,0,0,0.15); }
.preview-card-outer[data-platform="whatsapp"]  { background: #E5DDD5; box-shadow: 0 8px 48px rgba(0,0,0,0.2); }
.preview-card-outer[data-platform="youtube"]   { background: #FFFFFF; box-shadow: 0 8px 48px rgba(0,0,0,0.12); }
.preview-card-outer[data-platform="twitter"]   { background: #000000; box-shadow: 0 8px 48px rgba(0,0,0,0.55); }
.preview-card-outer[data-platform="threads"]   { background: #FFFFFF; box-shadow: 0 8px 48px rgba(0,0,0,0.15); }
.preview-card-outer[data-platform="linkedin"]  { background: #F3F2EF; box-shadow: 0 8px 48px rgba(0,0,0,0.18); }
.preview-card-outer[data-platform="reddit"]    { background: #1A1A1B; box-shadow: 0 8px 48px rgba(0,0,0,0.55); }

.preview-card {
  padding: 10px 12px;
}

/* Override the old phone-frame placeholder for the new card */
.preview-card .preview-placeholder {
  min-height: 100px;
  padding: 24px 16px;
}
.preview-card-outer[data-platform="tiktok"]   .preview-placeholder { color: rgba(255,255,255,0.3); }
.preview-card-outer[data-platform="twitter"]  .preview-placeholder { color: rgba(255,255,255,0.3); }
.preview-card-outer[data-platform="reddit"]   .preview-placeholder { color: rgba(255,255,255,0.3); }
.preview-card-outer[data-platform="threads"]  .preview-placeholder { color: rgba(0,0,0,0.28); }
.preview-card-outer[data-platform="facebook"]  .preview-placeholder,
.preview-card-outer[data-platform="instagram"] .preview-placeholder,
.preview-card-outer[data-platform="whatsapp"]  .preview-placeholder,
.preview-card-outer[data-platform="linkedin"]  .preview-placeholder { color: rgba(0,0,0,0.28); }

/* Smooth entrance for generated comments */
.preview-card > * {
  animation: fadeIn 0.18s ease;
}
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ============================================================
   TIKTOK MODE TABS (Comentario / Responder)
   ============================================================ */
.tt-mode-tabs {
  display: flex;
  gap: 6px;
  margin-bottom: 14px;
  background: var(--bg-input);
  padding: 4px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

.tt-mode-btn {
  flex: 1;
  padding: 7px 10px;
  border-radius: 6px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-2);
  transition: all var(--transition);
  text-align: center;
  white-space: nowrap;
}
.tt-mode-btn:hover  { color: var(--text-1); background: rgba(255,255,255,0.06); }
.tt-mode-btn.active {
  background: linear-gradient(135deg, #010101, #69C9D0);
  color: #fff;
  box-shadow: 0 2px 10px rgba(105,201,208,0.3);
}

.tt-reply-info {
  background: rgba(105,201,208,0.08);
  border: 1px solid rgba(105,201,208,0.2);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  font-size: 0.78rem;
  color: var(--text-2);
  margin-bottom: 14px;
  line-height: 1.5;
}
.tt-reply-info strong { color: var(--text-1); }

.form-hint {
  font-size: 0.73rem;
  color: var(--text-3);
  margin-top: -8px;
  margin-bottom: 10px;
  line-height: 1.4;
}

/* ============================================================
   TIKTOK REPLY STICKER — vista previa
   ============================================================ */
.tt-reply-scene {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 18px 16px 30px; /* extra bottom para que la punta no se corte */
}

.tt-reply-bubble {
  display: inline-flex;
  flex-direction: row;
  align-items: flex-start;
  gap: 10px;
  background: #fff;
  border-radius: 20px;
  padding: 10px 14px 12px 10px;
  max-width: 290px;
  position: relative;
  box-shadow: 0 2px 16px rgba(0,0,0,0.3);
}

/* Speech bubble tail — punta abajo-izquierda */
.tt-reply-bubble::after {
  content: '';
  position: absolute;
  bottom: -9px;
  left: 16px;
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 10px 10px 0 0;
  border-color: #fff transparent transparent transparent;
}

/* Avatar inside the bubble */
.tt-reply-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  flex-shrink: 0;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.tt-reply-avatar-default { background: transparent; }
.tt-reply-avatar-default svg { display: block; }

/* Text column inside bubble */
.tt-reply-text-col {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
  padding-top: 2px;
}

.tt-reply-header {
  font-size: 11px;
  color: rgba(0,0,0,0.45);
  font-family: -apple-system, system-ui, sans-serif;
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.tt-reply-header strong {
  font-weight: 700;
  color: rgba(0,0,0,0.68);
}

.tt-reply-original {
  font-size: 13px;
  color: rgba(0,0,0,0.85);
  font-family: -apple-system, system-ui, sans-serif;
  font-weight: 500;
  line-height: 1.4;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.tt-bubble-user-row {
  display: flex;
  align-items: center;
  gap: 5px;
}

.tt-bubble-username {
  font-size: 12px;
  font-weight: 700;
  color: rgba(0,0,0,0.68);
  font-family: -apple-system, system-ui, sans-serif;
  line-height: 1.2;
}

.tt-bubble-comment {
  font-size: 18px;
  font-weight: 800;
  color: #000;
  font-family: -apple-system, system-ui, sans-serif;
  line-height: 1.3;
  word-break: break-word;
  letter-spacing: -0.01em;
}

.tt-bubble-time {
  font-size: 11px;
  color: rgba(0,0,0,0.38);
  font-family: -apple-system, system-ui, sans-serif;
  margin-top: 2px;
}

.tt-reply-caption {
  font-size: 22px;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.25;
  font-family: -apple-system, system-ui, sans-serif;
  text-shadow: 0 1px 6px rgba(0,0,0,0.55);
  padding: 6px 0 2px;
  letter-spacing: -0.02em;
  word-break: break-word;
}

/* ============================================================
   YOUTUBE COMMENT PREVIEW
   ============================================================ */
.yt-wrapper {
  background: #fff;
  padding: 0;
  font-family: 'Roboto', -apple-system, Arial, sans-serif;
}

.yt-pinned {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 500;
  color: #606060;
  margin-bottom: 10px;
}

.yt-comment {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.yt-avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.yt-body { flex: 1; min-width: 0; }

.yt-header {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 4px;
  overflow: visible;
}

.yt-username {
  font-size: 13px;
  font-weight: 500;
  color: #0F0F0F;
}
.yt-dot {
  font-size: 12px;
  color: #606060;
  line-height: 1;
}
.yt-time {
  font-size: 12px;
  color: #606060;
}
.yt-more-btn {
  margin-left: auto;
  font-size: 18px;
  color: #606060;
  flex-shrink: 0;
  line-height: 1;
  letter-spacing: 1px;
}

.yt-text {
  font-size: 14px;
  color: #0F0F0F;
  line-height: 1.5;
  word-break: break-word;
  margin-bottom: 6px;
}

.yt-actions {
  display: flex;
  align-items: center;
  gap: 0;
}

.yt-like-group {
  display: flex;
  align-items: center;
  gap: 0;
  margin-right: 4px;
}

.yt-action-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px; height: 36px;
  border-radius: 50%;
  border: none;
  background: none;
  color: #606060;
  cursor: pointer;
  padding: 0;
}

.yt-like-count {
  font-size: 13px;
  color: #0F0F0F;
  margin: 0 8px 0 2px;
  font-weight: 400;
}

.yt-creator-heart {
  margin-left: 4px;
  width: 20px; height: 20px;
  background: #FF0000;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  color: #fff;
  font-style: normal;
}

.yt-see-replies {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 14px;
  font-weight: 700;
  color: #0F0F0F;
  padding: 4px 0 0 52px;
  margin-top: 2px;
  cursor: pointer;
  position: relative;
}

.yt-see-replies::before {
  content: '';
  position: absolute;
  left: 20px;
  top: -6px;
  width: 14px;
  height: 24px;
  border-left: 1.5px solid #C9C9C9;
  border-bottom: 1.5px solid #C9C9C9;
  border-bottom-left-radius: 6px;
}

/* ============================================================
   EMOJI PICKER
   ============================================================ */
.form-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}
.form-label-row .form-label { margin-bottom: 0; }

.emoji-trigger { font-size: 0.8rem; }

.emoji-container { position: relative; }

.emoji-panel {
  display: none;
  position: absolute;
  bottom: calc(100% + 6px);
  left: 0;
  z-index: 500;
  width: 280px;
  max-height: 270px;
  overflow: hidden;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 10px;
}
.emoji-panel.open { display: block; }

.emoji-tabs {
  display: flex;
  gap: 3px;
  margin-bottom: 8px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
  overflow-x: auto;
  scrollbar-width: none;
}
.emoji-tabs::-webkit-scrollbar { display: none; }

.emoji-tab {
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--text-2);
  white-space: nowrap;
  cursor: pointer;
  transition: all var(--transition);
  border: none;
  background: none;
}
.emoji-tab:hover, .emoji-tab.active {
  background: rgba(124,58,237,0.2);
  color: var(--text-1);
}

.emoji-grid {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 1px;
  overflow-y: auto;
  max-height: 180px;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}
.emoji-grid::-webkit-scrollbar { width: 4px; }
.emoji-grid::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }

.emoji-btn {
  padding: 5px 3px;
  border-radius: 5px;
  font-size: 1.15rem;
  line-height: 1;
  text-align: center;
  cursor: pointer;
  background: none;
  border: none;
  transition: background var(--transition), transform 0.1s ease;
}
.emoji-btn:hover {
  background: rgba(255,255,255,0.1);
  transform: scale(1.25);
}

/* ============================================================
   PWA INSTALL BANNER
   ============================================================ */
.pwa-banner {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  background: #1A1A30;
  border-top: 1px solid rgba(124,58,237,0.3);
  border-radius: 20px 20px 0 0;
  padding: 16px 18px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  z-index: 9998;
  box-shadow: 0 -8px 32px rgba(0,0,0,0.5);
  transform: translateY(110%);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.pwa-banner.show { transform: translateY(0); }

.pwa-banner-icon img { border-radius: 10px; flex-shrink: 0; }

.pwa-banner-body { flex: 1; min-width: 0; }
.pwa-banner-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-1);
  margin-bottom: 3px;
}
.pwa-banner-sub {
  font-size: 0.8rem;
  color: var(--text-2);
  line-height: 1.4;
}
.pwa-banner-sub strong { color: var(--text-1); }

.pwa-install-btn {
  margin-top: 6px;
  padding: 7px 16px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
  border-radius: 100px;
  font-size: 0.82rem;
  font-weight: 700;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.pwa-banner-close {
  font-size: 14px;
  color: var(--text-3);
  padding: 6px;
  flex-shrink: 0;
  border-radius: 50%;
  transition: background var(--transition);
}
.pwa-banner-close:hover { background: rgba(255,255,255,0.08); color: var(--text-1); }

.ios-hint     { display: none; }
.android-hint { display: none; }

/* ============================================================
   DOWNLOAD CAPTURE ANIMATION
   ============================================================ */
@keyframes captureFlash {
  0%   { box-shadow: 0 8px 48px rgba(0,0,0,0.45); }
  20%  { box-shadow: 0 0 0 3px rgba(124,58,237,0.9), 0 8px 48px rgba(0,0,0,0.45); }
  55%  { box-shadow: 0 0 0 7px rgba(255,255,255,0.22), 0 0 40px rgba(124,58,237,0.45); }
  100% { box-shadow: 0 8px 48px rgba(0,0,0,0.45); }
}
.preview-card-outer.capturing {
  animation: captureFlash 0.72s ease forwards;
}

/* ============================================================
   VERIFIED BADGE — overflow fix para html2canvas
   ============================================================ */
.tt-header   { overflow: visible; }
.fb-username { overflow: visible; }

/* ============================================================
   TWITTER / X
   ============================================================ */
.tw-wrapper {
  background: #000;
  padding: 16px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  display: flex;
  gap: 12px;
}
.tw-left { flex-shrink: 0; }
.tw-avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  font-size: 16px; font-weight: 700; color: #fff;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.tw-body { flex: 1; min-width: 0; }
.tw-user-row {
  display: flex; align-items: center; gap: 4px;
  flex-wrap: wrap; margin-bottom: 2px; overflow: visible;
}
.tw-name { color: #fff; font-weight: 700; font-size: 0.95rem; }
.tw-handle { color: #71767B; font-size: 0.85rem; }
.tw-sep { color: #71767B; font-size: 0.85rem; }
.tw-time { color: #71767B; font-size: 0.85rem; }
.tw-more { color: #71767B; margin-left: auto; font-size: 1.2rem; line-height: 1; }
.tw-reply-to { color: #71767B; font-size: 0.85rem; margin-bottom: 4px; }
.tw-reply-handle { color: #1D9BF0; }
.tw-text {
  color: #E7E9EA; font-size: 0.97rem;
  line-height: 1.5; margin: 4px 0 10px;
  word-break: break-word;
}
.tw-actions {
  display: flex; gap: 18px; margin-top: 2px;
}
.tw-action {
  display: inline-flex; align-items: center; gap: 6px;
  color: #71767B; font-size: 0.82rem; cursor: pointer;
  transition: color 0.15s;
}
.tw-act-reply:hover  { color: #1D9BF0; }
.tw-act-rt:hover     { color: #00BA7C; }
.tw-act-like:hover   { color: #F91880; }
.tw-act-views:hover  { color: #1D9BF0; }

/* ============================================================
   THREADS
   ============================================================ */
.th-wrapper {
  background: #fff;
  padding: 14px 16px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}
.th-comment { display: flex; gap: 10px; align-items: flex-start; }
.th-left { flex-shrink: 0; }
.th-avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  font-size: 14px; font-weight: 700; color: #fff;
  display: flex; align-items: center; justify-content: center;
}
.th-body { flex: 1; min-width: 0; }
.th-user-row {
  display: flex; align-items: center; gap: 4px;
  margin-bottom: 4px; overflow: visible;
}
.th-username { font-weight: 700; font-size: 0.9rem; color: #000; }
.th-time { color: #999; font-size: 0.8rem; margin-left: 4px; }
.th-more { color: #999; margin-left: auto; font-size: 1rem; cursor: pointer; }
.th-text {
  color: #000; font-size: 0.9rem;
  line-height: 1.4; margin-bottom: 10px;
  word-break: break-word;
}
.th-actions { display: flex; gap: 14px; margin-bottom: 6px; }
.th-action { color: #666; cursor: pointer; display: inline-flex; align-items: center; }
.th-action:hover { color: #000; }
.th-like-count { color: #999; font-size: 0.8rem; margin-top: 2px; }
.th-replies-count { color: #999; font-size: 0.8rem; margin-top: 1px; }

/* ============================================================
   LINKEDIN
   ============================================================ */
.li-wrapper {
  background: #fff;
  padding: 14px 16px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
}
.li-comment { display: flex; gap: 10px; }
.li-avatar {
  width: 38px; height: 38px;
  border-radius: 50%;
  font-size: 15px; font-weight: 700; color: #fff;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.li-right { flex: 1; min-width: 0; }
.li-bubble {
  background: #F3F2EF;
  border-radius: 0 12px 12px 12px;
  padding: 10px 14px;
}
.li-name-row {
  display: flex; align-items: center; gap: 5px;
  margin-bottom: 1px; overflow: visible;
}
.li-name { font-weight: 700; font-size: 0.9rem; color: rgba(0,0,0,0.9); }
.li-degree {
  background: rgba(0,0,0,0.08); color: rgba(0,0,0,0.5);
  border-radius: 3px; font-size: 0.7rem; font-weight: 600;
  padding: 1px 5px;
}
.li-title { color: rgba(0,0,0,0.55); font-size: 0.78rem; margin-bottom: 5px; }
.li-text {
  color: rgba(0,0,0,0.9); font-size: 0.9rem;
  line-height: 1.45; word-break: break-word;
}
.li-footer {
  display: flex; align-items: center; gap: 8px;
  margin-top: 6px; font-size: 0.8rem;
}
.li-time { color: rgba(0,0,0,0.5); }
.li-react-btn { color: rgba(0,0,0,0.6); font-weight: 600; cursor: pointer; }
.li-react-btn:hover { color: rgba(0,0,0,0.9); }
.li-sep { color: rgba(0,0,0,0.3); }
.li-reply-btn { color: rgba(0,0,0,0.6); font-weight: 600; cursor: pointer; }
.li-reply-btn:hover { color: rgba(0,0,0,0.9); }
.li-reactions {
  display: flex; align-items: center; gap: 4px;
  margin-top: 5px; font-size: 0.78rem;
}
.li-react-count { color: rgba(0,0,0,0.55); }

/* ============================================================
   REDDIT (dark mode)
   ============================================================ */
.rd-wrapper {
  background: #1A1A1B;
  padding: 12px 16px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}
.rd-header {
  display: flex; align-items: center; gap: 6px;
  margin-bottom: 10px; font-size: 0.78rem;
}
.rd-sub { color: #D7DADC; font-weight: 700; }
.rd-sub-sep { color: #818384; }
.rd-user { color: #818384; }
.rd-time { color: #818384; }
.rd-comment {
  display: flex; gap: 10px; align-items: flex-start;
}
.rd-vote {
  display: flex; flex-direction: column;
  align-items: center; gap: 4px;
  flex-shrink: 0;
}
.rd-vote-up, .rd-vote-down {
  width: 24px; height: 24px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 2px; cursor: pointer; color: #818384;
  transition: color 0.15s;
}
.rd-vote-up:hover   { color: #FF4500; }
.rd-vote-down:hover { color: #7193FF; }
.rd-vote-count {
  font-size: 0.78rem; font-weight: 700;
  color: #D7DADC; line-height: 1;
}
.rd-body { flex: 1; min-width: 0; }
.rd-user-row {
  display: flex; align-items: center; gap: 6px;
  margin-bottom: 6px; font-size: 0.8rem;
}
.rd-username { color: #D7DADC; font-weight: 700; }
.rd-op-badge {
  background: #FF4500; color: #fff;
  font-size: 0.65rem; font-weight: 700;
  padding: 1px 5px; border-radius: 2px;
}
.rd-timestamp { color: #818384; }
.rd-text {
  color: #D7DADC; font-size: 0.9rem;
  line-height: 1.55; word-break: break-word;
  margin-bottom: 10px;
}
.rd-awards {
  display: flex; align-items: center; gap: 5px;
  margin-bottom: 8px; flex-wrap: wrap;
}
.rd-award {
  display: inline-flex; align-items: center; gap: 3px;
  font-size: 0.75rem; color: #818384;
}
.rd-award-icon {
  width: 16px; height: 16px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 10px; font-weight: 700;
}
.rd-award-gold   { background: #FFD700; color: #000; }
.rd-award-silver { background: #C0C0C0; color: #000; }
.rd-award-bronze { background: #CD7F32; color: #fff; }
.rd-actions {
  display: flex; align-items: center; gap: 4px;
}
.rd-action {
  display: inline-flex; align-items: center; gap: 5px;
  color: #818384; font-size: 0.78rem; font-weight: 700;
  padding: 5px 8px; border-radius: 2px;
  cursor: pointer; transition: background 0.15s, color 0.15s;
}
.rd-action:hover { background: rgba(255,255,255,0.06); color: #D7DADC; }
.ig-user-row { overflow: visible; }

/* ============================================================
   DARK MODE — YouTube
   ============================================================ */
.yt-dark { background: #0F0F0F !important; }
.yt-dark .yt-pinned { color: #AAAAAA; }
.yt-dark .yt-pinned svg { fill: #AAAAAA; }
.yt-dark .yt-username { color: #F1F1F1; }
.yt-dark .yt-dot, .yt-dark .yt-time { color: #AAAAAA; }
.yt-dark .yt-more-btn { color: #AAAAAA; }
.yt-dark .yt-text { color: #F1F1F1; }
.yt-dark .yt-action-btn { color: #AAAAAA; }
.yt-dark .yt-action-btn svg { stroke: #AAAAAA; }
.yt-dark .yt-like-count { color: #F1F1F1; }
.yt-dark .yt-see-replies { color: #3EA6FF; }
.yt-dark .yt-see-replies::before { border-color: #3EA6FF; }
.yt-dark .yt-see-replies svg { stroke: #3EA6FF; }

/* ============================================================
   DARK MODE — Instagram
   ============================================================ */
.ig-dark { background: #000000 !important; }
.ig-dark .ig-username { color: #FAFAFA; }
.ig-dark .ig-time { color: #A8A8A8; }
.ig-dark .ig-text { color: #FAFAFA; }
.ig-dark .ig-reply-btn { color: #A8A8A8; }
.ig-dark .ig-heart svg { stroke: #FAFAFA; }
.ig-dark .ig-like-count { color: #FAFAFA; }
.ig-dark .ig-see-replies { color: #A8A8A8; }

/* ============================================================
   DARK MODE — LinkedIn
   ============================================================ */
.li-dark { background: #1B1B1B !important; }
.li-dark .li-bubble { background: #2A2A2A; }
.li-dark .li-name { color: rgba(255,255,255,0.9); }
.li-dark .li-title { color: rgba(255,255,255,0.5); }
.li-dark .li-text { color: rgba(255,255,255,0.88); }
.li-dark .li-time { color: rgba(255,255,255,0.45); }
.li-dark .li-react-btn { color: rgba(255,255,255,0.6); }
.li-dark .li-reply-btn { color: rgba(255,255,255,0.6); }
.li-dark .li-sep { color: rgba(255,255,255,0.25); }
.li-dark .li-react-count { color: rgba(255,255,255,0.5); }

/* ============================================================
   ATTACHED IMAGE (Reddit / Twitter)
   ============================================================ */
.comment-attached-img {
  margin-top: 8px;
  border-radius: 12px;
  overflow: hidden;
  width: 100%;
}
.comment-attached-img img {
  width: 100%;
  max-height: 260px;
  object-fit: cover;
  display: block;
}

/* ============================================================
   NESTED REPLY
   ============================================================ */
.nested-reply {
  padding-left: 52px;
  position: relative;
  margin-top: 0;
}
.nested-reply::before {
  content: '';
  position: absolute;
  left: 20px;
  top: 0;
  width: 16px;
  height: 22px;
  border-left: 1.5px solid rgba(255,255,255,0.12);
  border-bottom: 1.5px solid rgba(255,255,255,0.12);
  border-bottom-left-radius: 6px;
}
.nested-reply.light-reply::before {
  border-color: rgba(0,0,0,0.12);
}
.nested-reply .tt-wrapper,
.nested-reply .fb-wrapper,
.nested-reply .ig-wrapper,
.nested-reply .yt-wrapper,
.nested-reply .tw-wrapper,
.nested-reply .th-wrapper,
.nested-reply .li-wrapper,
.nested-reply .rd-wrapper {
  background: transparent !important;
  padding: 6px 0 0;
}

/* ============================================================
   STACKED COMMENTS
   ============================================================ */
.stack-divider {
  height: 1px;
  background: rgba(255,255,255,0.07);
  margin: 6px 0;
}
.preview-card-outer[data-platform="facebook"]  .stack-divider,
.preview-card-outer[data-platform="instagram"] .stack-divider,
.preview-card-outer[data-platform="whatsapp"]  .stack-divider,
.preview-card-outer[data-platform="youtube"]   .stack-divider,
.preview-card-outer[data-platform="threads"]   .stack-divider,
.preview-card-outer[data-platform="linkedin"]  .stack-divider {
  background: rgba(0,0,0,0.07);
}

/* ============================================================
   EXTRA SLOT UI
   ============================================================ */
.extra-slot {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px;
  margin-top: 10px;
  background: rgba(255,255,255,0.02);
}
.slot-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.slot-label {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-2);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.slot-remove {
  font-size: 0.75rem;
  color: var(--text-3);
  padding: 2px 8px;
  border-radius: 4px;
  transition: all var(--transition);
}
.slot-remove:hover { color: #F45B78; background: rgba(244,91,120,0.1); }

.stack-add-btn {
  width: 100%;
  margin-top: 10px;
  padding: 8px;
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  color: var(--text-3);
  font-size: 0.82rem;
  font-weight: 600;
  transition: all var(--transition);
  background: none;
  cursor: pointer;
}
.stack-add-btn:hover:not(:disabled) {
  border-color: var(--primary);
  color: var(--primary);
  background: rgba(124,58,237,0.05);
}
.stack-add-btn:disabled { opacity: 0.35; cursor: default; }

/* ============================================================
   REPLY SECTION
   ============================================================ */
.reply-section {
  border-top: 1px solid var(--border);
  padding-top: 14px;
  margin-top: 14px;
}
.reply-toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.reply-toggle-label {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-2);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.reply-fields { margin-top: 12px; }

/* ============================================================
   PANEL PROPIETARIO
   ============================================================ */
.owner-panel {
  position: fixed;
  top: 68px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--surface-2, #1a1a2e);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 16px;
  padding: 24px 24px 20px;
  width: 260px;
  z-index: 900;
  box-shadow: 0 16px 48px rgba(0,0,0,0.55);
  text-align: center;
  animation: slideDown 0.18s ease;
}
.owner-panel.hidden { display: none; }

@keyframes slideDown {
  from { opacity: 0; transform: translateX(-50%) translateY(-10px); }
  to   { opacity: 1; transform: translateX(-50%) translateY(0); }
}

.owner-panel-close {
  position: absolute;
  top: 10px; right: 12px;
  background: none; border: none;
  color: var(--text-2); font-size: 0.85rem;
  cursor: pointer; padding: 4px 6px; border-radius: 6px;
  transition: background 0.15s;
}
.owner-panel-close:hover { background: rgba(255,255,255,0.08); }

.owner-panel-icon  { font-size: 1.8rem; margin-bottom: 6px; }
.owner-panel-title { font-size: 0.9rem; font-weight: 700; color: var(--text-1); margin-bottom: 14px; }

.owner-form { display: flex; flex-direction: column; gap: 10px; }
.owner-pin-input { text-align: center; letter-spacing: 0.15em; font-size: 1rem; }

.owner-success {
  padding: 10px;
  background: rgba(34,197,94,0.12);
  border: 1px solid rgba(34,197,94,0.3);
  border-radius: 8px;
  color: #22c55e;
  font-size: 0.85rem;
  font-weight: 500;
}
.owner-success.hidden { display: none; }

/* ============================================================
   USAGE BADGE
   ============================================================ */
.usage-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  justify-content: center;
  margin-top: 10px;
  padding: 7px 14px;
  border-radius: 20px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  font-size: 0.8rem;
  color: var(--text-2);
  transition: background 0.2s, border-color 0.2s, color 0.2s;
}
.usage-badge.usage-warning {
  background: rgba(234,179,8,0.1);
  border-color: rgba(234,179,8,0.35);
  color: #eab308;
}
.usage-badge.usage-empty {
  background: rgba(239,68,68,0.1);
  border-color: rgba(239,68,68,0.35);
  color: #ef4444;
}
.usage-badge.usage-ok {
  background: rgba(34,197,94,0.1);
  border-color: rgba(34,197,94,0.35);
  color: #22c55e;
}
.usage-badge.usage-owner {
  background: rgba(234,179,8,0.12);
  border-color: rgba(234,179,8,0.5);
  color: #eab308;
  font-weight: 600;
}
.usage-icon  { font-size: 0.9rem; }
.usage-label { font-weight: 500; }
.usage-logout {
  margin-left: 8px;
  background: none;
  border: 1px solid currentColor;
  border-radius: 6px;
  color: inherit;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 2px 7px;
  cursor: pointer;
  opacity: 0.7;
  transition: opacity 0.15s;
  line-height: 1.4;
}
.usage-logout:hover { opacity: 1; }

/* ============================================================
   MODAL DE REGISTRO
   ============================================================ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.75);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
  animation: fadeIn 0.18s ease;
}
.modal-overlay.hidden { display: none; }

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.modal-box {
  background: var(--surface-2, #1a1a2e);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 20px;
  padding: 36px 32px 28px;
  max-width: 420px;
  width: 100%;
  position: relative;
  animation: slideUp 0.22s ease;
  text-align: center;
}

@keyframes slideUp {
  from { transform: translateY(20px); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 16px;
  background: none;
  border: none;
  color: var(--text-2);
  font-size: 1rem;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
  line-height: 1;
  transition: background 0.15s;
}
.modal-close:hover { background: rgba(255,255,255,0.1); }

.modal-icon {
  font-size: 2.6rem;
  margin-bottom: 12px;
}
.modal-title {
  font-size: 1.35rem;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--text-1, #fff);
}
.modal-desc {
  font-size: 0.92rem;
  color: var(--text-2);
  line-height: 1.55;
  margin-bottom: 22px;
}

.modal-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.modal-form .form-input {
  text-align: center;
  font-size: 0.95rem;
}
.btn-full {
  width: 100%;
  justify-content: center;
  padding: 13px;
  font-size: 0.95rem;
  border-radius: 12px;
}

.modal-fine {
  margin-top: 14px;
  font-size: 0.75rem;
  color: var(--text-3, rgba(255,255,255,0.35));
}

.register-success {
  margin-top: 18px;
  padding: 14px;
  background: rgba(34,197,94,0.12);
  border: 1px solid rgba(34,197,94,0.3);
  border-radius: 10px;
  color: #22c55e;
  font-size: 0.88rem;
  font-weight: 500;
}
.register-success.hidden { display: none; }
