/* ── SECTION LABEL ── */
.section-label {
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--text3);
  text-transform: uppercase;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.filter-section { margin-bottom: 28px; }
.cards-grid { display: flex; flex-wrap: wrap; gap: 8px; }

/* ── FILTER CARDS ── */
.filter-card {
  padding: 8px 16px;
  border-radius: var(--r-pill);
  font-size: 14.5px;
  font-weight: 400;
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all 0.18s;
  background: var(--surface);
  color: var(--text2);
  user-select: none;
  backdrop-filter: blur(8px);
}
.filter-card:hover { border-color: var(--border2); color: var(--white); background: var(--surface2); }
.filter-card.selected {
  background: var(--tiffany-bg);
  border-color: var(--tiffany);
  color: var(--tiffany2);
}

/* ── PLATFORM TAGS ── */
.platform-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.platform-tag {
  padding: 8px 16px;
  border-radius: var(--r-pill);
  font-size: 13.5px;
  font-weight: 400;
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all 0.15s;
  background: var(--surface);
  color: var(--text2);
  user-select: none;
}
.platform-tag:hover { border-color: var(--border2); color: var(--white); }
.platform-tag.selected { background: var(--tiffany-bg); border-color: var(--tiffany); color: var(--tiffany2); }
.platform-tag[data-p="Instagram"].selected { background: rgba(225,48,108,0.15); border-color: #E1306C; color: #f080a0; }
.platform-tag[data-p="TikTok"].selected { background: rgba(100,100,100,0.2); border-color: #aaa; color: #ddd; }
.platform-tag[data-p="YouTube"].selected { background: rgba(255,0,0,0.15); border-color: #FF0000; color: #ff6060; }
.platform-tag[data-p="Pinterest"].selected { background: rgba(230,0,35,0.15); border-color: #E60023; color: #ff5060; }
.platform-tag[data-p="Twitter/X"].selected { background: rgba(100,100,100,0.2); border-color: #888; color: #ccc; }
.platform-tag[data-p="Threads"].selected { background: rgba(100,100,100,0.2); border-color: #888; color: #ccc; }

/* ── INPUTS ── */
.field-input, .field-textarea {
  width: 100%;
  padding: 12px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  font-family: inherit;
  font-size: 14px;
  color: var(--text);
  outline: none;
  transition: border-color 0.18s, box-shadow 0.18s;
  backdrop-filter: blur(8px);
}
.field-input:focus, .field-textarea:focus {
  border-color: var(--tiffany);
  box-shadow: 0 0 0 3px var(--tiffany-bg);
}
.field-textarea { resize: none; line-height: 1.65; }
.field-input::placeholder, .field-textarea::placeholder { color: var(--text4); }

.field-select {
  width: 100%; padding: 11px 13px;
  border: 1px solid var(--border); border-radius: var(--r);
  font-family: inherit; font-size: 13.5px; color: var(--text);
  background: var(--surface); outline: none; cursor: pointer; appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='rgba(255,255,255,0.4)' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center;
}
.field-select option { background: #2a1040; }

.field-wrap { position: relative; margin-bottom: 8px; }
.field-wrap .field-input { padding-right: 46px; }
.field-toggle { position: absolute; right: 13px; top: 50%; transform: translateY(-50%); background: none; border: none; cursor: pointer; color: var(--text3); font-size: 16px; transition: color 0.15s; }
.field-toggle:hover { color: var(--text2); }

/* ── BUTTONS ── */
.btn {
  padding: 12px 22px;
  font-size: 13.5px;
  font-weight: 600;
  font-family: inherit;
  border: none;
  border-radius: var(--r-pill);
  cursor: pointer;
  transition: all 0.2s;
  letter-spacing: 0.02em;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.btn-primary {
  background: var(--tiffany);
  color: #1a0a2e;
  box-shadow: 0 4px 20px rgba(105,197,215,0.3);
}
.btn-primary:hover:not(:disabled) { transform: translateY(-1px); box-shadow: 0 6px 28px rgba(105,197,215,0.4); }
.btn-primary:disabled { opacity: 0.4; cursor: not-allowed; transform: none; }
.btn-ghost {
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text2);
  backdrop-filter: blur(8px);
}
.btn-ghost:hover { border-color: var(--border2); color: var(--white); background: var(--surface2); }
.btn-full { width: 100%; justify-content: center; }
.btn-sm { padding: 8px 16px; font-size: 12px; }

/* ── OUTPUT SURFACE ── */
.output-surface {
  background: rgba(180, 120, 160, 0.12);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: var(--r-lg);
  backdrop-filter: blur(12px);
  overflow: hidden;
}
.output-surface-header {
  padding: 16px 22px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.output-surface-title {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--tiffany);
}
.output-surface-body { padding: 22px; }

/* ── EMPTY STATE ── */
.empty-state {
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 10px; color: var(--text4);
  padding: 56px 20px;
}
.empty-icon { font-size: 37px; opacity: 0.3; }
.empty-title { font-size: 15px; font-weight: 500; color: var(--text3); }
.empty-sub { font-size: 12.5px; color: var(--text4); }

/* ── LOADING RING ── */
.loading-ring {
  width: 36px; height: 36px;
  border: 2.5px solid rgba(255,255,255,0.1);
  border-top-color: var(--tiffany);
  border-radius: 50%;
  animation: spin 0.75s linear infinite;
}

/* ── UPLOAD SLOT ── */
.upload-slot {
  display: flex; align-items: center; gap: 12px;
  padding: 13px 16px;
  border-radius: var(--r);
  cursor: pointer;
  transition: all 0.18s;
  background: var(--surface3);
  position: relative; overflow: hidden;
}
.upload-slot:hover { border-color: var(--tiffany-bd); background: var(--tiffany-bg); }
.upload-slot.filled { border-style: solid; border-color: var(--tiffany-bd); background: var(--tiffany-bg); }
.upload-slot input { display: none; }
.slot-thumb { width: 48px; height: 48px; border-radius: 9px; object-fit: cover; display: none; flex-shrink: 0; }
.slot-thumb.visible { display: block; }
.slot-icon { width: 48px; height: 48px; border-radius: 9px; background: var(--surface2); display: flex; align-items: center; justify-content: center; font-size: 23px; flex-shrink: 0; }
.slot-icon.hidden { display: none; }
.slot-tag { font-size: 11.5px; font-family: monospace; font-weight: 600; color: var(--tiffany); margin-bottom: 3px; }
.slot-name { font-size: 12px; color: var(--text3); }
.slot-remove { position: absolute; right: 10px; top: 10px; width: 22px; height: 22px; background: rgba(0,0,0,0.3); border: none; border-radius: 50%; cursor: pointer; font-size: 11px; color: var(--text2); display: none; align-items: center; justify-content: center; transition: background 0.15s; }
.upload-slot.filled .slot-remove { display: flex; }
.slot-remove:hover { background: rgba(232,122,122,0.4); color: var(--danger); }

/* Add slot button */
.btn-add-slot { width: 100%; padding: 9px; border: 1.5px dashed var(--border); border-radius: var(--r); background: none; font-size: 13px; color: var(--text3); cursor: pointer; font-family: inherit; transition: all 0.18s; margin-top: 8px; }
.btn-add-slot:hover { border-color: var(--tiffany-bd); color: var(--tiffany); background: var(--tiffany-bg); }

/* ── LOC UPLOAD ── */
.loc-upload {
  border: 1.5px dashed var(--border);
  border-radius: var(--r);
  padding: 13px 16px;
  cursor: pointer;
  transition: all 0.18s;
  background: var(--surface3);
  display: flex; align-items: center; gap: 11px;
}
.loc-upload:hover { border-color: var(--tiffany-bd); background: var(--tiffany-bg); }
.loc-upload.filled { border-style: solid; border-color: var(--tiffany-bd); background: var(--tiffany-bg); }
.loc-upload input { display: none; }
.loc-thumb { width: 46px; height: 46px; border-radius: 8px; object-fit: cover; display: none; flex-shrink: 0; }
.loc-thumb.visible { display: block; }
.loc-icon { font-size: 23px; flex-shrink: 0; }
.loc-info { flex: 1; }
.loc-tag { font-size: 11.5px; font-weight: 600; color: var(--tiffany); margin-bottom: 2px; font-family: monospace; }
.loc-name { font-size: 12px; color: var(--text3); }

/* ── INFO BOX ── */
.info-box {
  padding: 13px 16px;
  background: var(--tiffany-bg);
  border: 1px solid var(--tiffany-bd);
  border-radius: var(--r);
  font-size: 13px;
  color: var(--text2);
  line-height: 1.65;
  margin-bottom: 10px;
}
.info-box-label { font-size: 10px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--tiffany); margin-bottom: 5px; }
.info-box-text { font-size: 13.5px; color: var(--white); font-style: italic; line-height: 1.7; }

/* ── VALIDATION MSG ── */
.validation-msg {
  display: none;
  padding: 11px 14px;
  background: rgba(232,122,122,0.12);
  border: 1px solid rgba(232,122,122,0.3);
  border-radius: 9px;
  font-size: 13px;
  color: var(--danger);
  margin-bottom: 14px;
}

/* ── DIVIDER ── */
.divider { height: 1px; background: var(--border); margin: 32px 0; }

/* ── FALA MODE ── */
.fala-mode { display: flex; gap: 8px; margin-bottom: 16px; }
.fala-btn {
  flex: 1;
  padding: 11px;
  border-radius: var(--r-pill);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text3);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.18s;
}
.fala-btn.active { background: var(--tiffany-bg); border-color: var(--tiffany); color: var(--tiffany2); }

/* ── ACTION ROW ── */
.action-row {
  display: flex;
  gap: 10px;
  margin-top: 20px;
  flex-wrap: wrap;
}
.action-row-right { justify-content: flex-end; }

/* ── SCENE CARD ── */
.scene-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
  animation: fadeUp 0.3s ease both;
}
.scene-header {
  padding: 13px 20px;
  background: rgba(105,197,215,0.08);
  border-bottom: 1px solid var(--border);
  display: flex; gap: 8px; flex-wrap: wrap; align-items: center;
}
.scene-chip {
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 11.5px;
  font-weight: 600;
  background: rgba(255,255,255,0.1);
  color: var(--text2);
}
.scene-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0; }
.scene-block { padding: 18px 20px; border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.scene-block:nth-child(2) { border-right: none; }
.scene-block:nth-child(3) { border-right: none; border-bottom: none; }
.scene-block:nth-child(4) { border-bottom: none; }
.scene-block-full { padding: 18px 20px; border-top: 1px solid var(--border); }
.block-label { font-size: 10.5px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--tiffany); margin-bottom: 8px; }
.block-text { font-size: 14px; line-height: 1.75; color: var(--text2); }
.block-fala { font-size: 16px; font-style: italic; color: var(--white); line-height: 1.65; font-family: 'Cormorant Garamond', serif; font-weight: 400; }
.block-legenda { font-size: 13.5px; color: var(--text2); padding: 12px 16px; background: var(--surface2); border-radius: 9px; border-left: 3px solid var(--tiffany); line-height: 1.65; }

.scene-social {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
  animation: fadeUp 0.3s ease 0.1s both;
  margin-top: 12px;
}
.scene-social-header {
  padding: 12px 20px;
  background: var(--tiffany-bg);
  border-bottom: 1px solid var(--tiffany-bd);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--tiffany);
}

/* ── PROMPT CARD ── */
.prompt-card {
  background: rgba(20,10,35,0.6);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
  animation: fadeUp 0.3s ease both;
}
.prompt-card-header {
  padding: 14px 20px;
  background: rgba(255,255,255,0.04);
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between;
}
.prompt-card-title { font-size: 11px; font-weight: 700; letter-spacing: 0.1em; color: var(--tiffany); }
.prompt-text {
  padding: 20px;
  font-family: 'Courier New', monospace;
  font-size: 12.5px;
  line-height: 2.0;
  color: rgba(200,220,235,0.85);
  white-space: pre-wrap;
  word-break: break-word;
}

/* ── MOTION SECTIONS ── */
.motion-section {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
  animation: fadeUp 0.3s ease both;
  margin-bottom: 12px;
}
.motion-section-header {
  padding: 11px 18px;
  background: rgba(105,197,215,0.07);
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between;
}
.motion-section-title { font-size: 11px; font-weight: 700; letter-spacing: 0.09em; text-transform: uppercase; color: var(--tiffany); }
.motion-section-body { padding: 16px 18px; font-size: 14px; line-height: 1.8; color: var(--text2); }
.motion-prompt-card {
  background: rgba(20,10,35,0.6);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
  margin-bottom: 12px;
  animation: fadeUp 0.3s ease both;
}
.motion-prompt-header { padding: 14px 20px; background: rgba(255,255,255,0.04); border-bottom: 1px solid var(--border); display: flex; align-items: center; justify-content: space-between; }
.motion-prompt-title { font-size: 11px; font-weight: 700; letter-spacing: 0.1em; color: var(--tiffany); }
.motion-prompt-text { padding: 20px; font-family: 'Courier New', monospace; font-size: 12.5px; line-height: 1.9; color: rgba(200,220,235,0.85); white-space: pre-wrap; word-break: break-word; }

/* ── IMG REFS ── */
.img-refs-bar { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.img-ref-chip { display: flex; align-items: center; gap: 9px; padding: 8px 14px; background: var(--surface); border: 1px solid var(--border); border-radius: 10px; }
.img-ref-thumb { width: 36px; height: 36px; border-radius: 7px; object-fit: cover; }
.img-ref-tag { font-size: 11.5px; font-family: monospace; font-weight: 600; color: var(--tiffany); }

/* ── PERSPECTIVE SYSTEM ── */
.perspective-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-top: 8px;
  width: 100%;
}
.perspective-btn {
  position: relative;
  padding: 8px 10px;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 8px;
  background: rgba(255,255,255,0.04);
  color: var(--text2);
  font-size: 13px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  transition: all 0.18s;
  user-select: none;
}
.perspective-btn:hover {
  background: rgba(255,255,255,0.09);
  border-color: rgba(255,255,255,0.25);
  color: var(--white);
}
.perspective-btn.active {
  background: rgba(99,220,200,0.12);
  border-color: var(--tiffany);
  color: var(--tiffany);
}
.perspective-info-icon {
  font-size: 11px;
  opacity: 0.4;
  cursor: pointer;
  flex-shrink: 0;
  transition: opacity 0.15s;
  line-height: 1;
}
.perspective-info-icon:hover { opacity: 1; }
.perspective-popup {
  background: rgba(16,16,24,0.97);
  color: #e0e0e0;
  padding: 9px 13px;
  border-radius: 8px;
  font-size: 12px;
  max-width: 260px;
  line-height: 1.5;
  border: 1px solid rgba(255,255,255,0.1);
  box-shadow: 0 6px 24px rgba(0,0,0,0.5);
  pointer-events: none;
}
