/* ══════════════════════════════════════════════════════
   dark-form.css
   Formulário mobile do modelo Dark.
   Visual app-like, segue identidade temtudinho.
   Accent laranja (#d4420a) referente ao modelo Dark.
══════════════════════════════════════════════════════ */

:root {
  --ink: #0d0f14;
  --paper: #f0f3f8;
  --accent: #d4420a;
  --accent2: #a83008;
  --muted: #707a8a;
  --border: rgba(240, 243, 248, 0.1);
  --surface: rgba(240, 243, 248, 0.06);
  --input-bg: rgba(240, 243, 248, 0.06);
  --input-border: rgba(240, 243, 248, 0.14);
  --text: rgba(240, 243, 248, 0.88);
  --text-muted: rgba(240, 243, 248, 0.4);
  --success: rgba(34, 197, 94, 0.9);
  --danger: rgba(239, 68, 68, 0.85);
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: "DM Sans", sans-serif;
  background: var(--ink);
  background-image:
    linear-gradient(rgba(240, 243, 248, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(240, 243, 248, 0.025) 1px, transparent 1px);
  background-size: 60px 60px;
  color: var(--text);
  min-height: 100dvh;
  overflow-x: hidden;
  padding-bottom: calc(80px + env(safe-area-inset-bottom, 0px));
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.03'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
  opacity: 0.4;
}

/* ── TOP NAV ──────────────────────────────────────────────── */
.df-nav {
  position: sticky;
  top: 0;
  z-index: 200;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.25rem;
  background: rgba(13, 15, 20, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}

.df-nav-logo {
  font-family: "Playfair Display", serif;
  font-weight: 900;
  font-size: 1rem;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -0.02em;
}
.df-nav-logo span {
  color: var(--accent);
}

.df-nav-label {
  font-family: "DM Mono", monospace;
  font-size: 0.58rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.df-save-indicator {
  font-family: "DM Mono", monospace;
  font-size: 0.6rem;
  letter-spacing: 0.08em;
  color: var(--success);
  opacity: 0;
  transition: opacity 0.3s;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}
.df-save-indicator.show {
  opacity: 1;
}
.df-save-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--success);
}

/* ── HERO ─────────────────────────────────────────────────── */
.df-hero {
  padding: 1.75rem 1.25rem 0.5rem;
}
.df-hero-eyebrow {
  font-family: "DM Mono", monospace;
  font-size: 0.58rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.5rem;
  display: block;
}
.df-hero-title {
  font-family: "Playfair Display", serif;
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: var(--paper);
  margin-bottom: 0.4rem;
}
.df-hero-title em {
  font-style: italic;
  color: var(--accent);
}
.df-hero-sub {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.55;
}

/* ── PROGRESS BAR ────────────────────────────────────────── */
.df-progress-wrap {
  padding: 1rem 1.25rem 0;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.df-progress-bar {
  flex: 1;
  height: 3px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
}
.df-progress-fill {
  height: 100%;
  background: var(--accent);
  border-radius: 2px;
  transition: width 0.4s ease;
  width: 0%;
}
.df-progress-label {
  font-family: "DM Mono", monospace;
  font-size: 0.58rem;
  color: var(--text-muted);
  white-space: nowrap;
}

/* ── SEÇÕES ──────────────────────────────────────────────── */
.df-sections {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.df-section {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
}

.df-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.1rem;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  gap: 0.75rem;
}

.df-section-header-left {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex: 1;
  min-width: 0;
}

.df-section-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(212, 66, 10, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--accent);
}
.df-section-icon svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.df-section-meta {
  flex: 1;
  min-width: 0;
}

.df-section-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--paper);
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.df-section-status {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-top: 2px;
}
.df-section-status.done {
  color: var(--success);
}

.df-section-chevron {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  color: var(--text-muted);
  transition: transform 0.25s ease;
}
.df-section-chevron svg {
  width: 100%;
  height: 100%;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
}
.df-section.open .df-section-chevron {
  transform: rotate(180deg);
}

.df-section-body {
  display: none;
  padding: 0 1.1rem 1.1rem;
  flex-direction: column;
  gap: 1rem;
}
.df-section.open .df-section-body {
  display: flex;
}

/* ── CAMPOS ──────────────────────────────────────────────── */
.df-field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.df-label {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  text-transform: uppercase;
}
.df-label .req {
  color: var(--accent);
  margin-left: 2px;
}

.df-input,
.df-textarea,
.df-select {
  width: 100%;
  background: var(--input-bg);
  border: 1px solid var(--input-border);
  border-radius: 10px;
  color: var(--text);
  font-family: "DM Sans", sans-serif;
  font-size: 0.95rem;
  padding: 0.75rem 1rem;
  outline: none;
  transition:
    border-color 0.2s,
    background 0.2s;
  -webkit-appearance: none;
  appearance: none;
}
.df-input:focus,
.df-textarea:focus,
.df-select:focus {
  border-color: var(--accent);
  background: rgba(212, 66, 10, 0.06);
}

.df-textarea {
  resize: none;
  line-height: 1.6;
  min-height: 100px;
}

.df-select {
  background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1L6 7L11 1' stroke='%238b96a8' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  padding-right: 2.5rem;
  cursor: pointer;
}

.df-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

.df-hint {
  font-size: 0.68rem;
  color: var(--text-muted);
  line-height: 1.5;
  padding-left: 0.25rem;
}

/* ── FOTO ────────────────────────────────────────────────── */
.df-photo-row {
  display: flex;
  align-items: center;
  gap: 1rem;
}
.df-photo-preview {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--input-bg);
  border: 2px solid var(--input-border);
  overflow: hidden;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.df-photo-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: none;
}
.df-photo-preview svg {
  width: 28px;
  height: 28px;
  fill: currentColor;
}
.df-photo-info {
  flex: 1;
}
.df-photo-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  font-family: "DM Sans", sans-serif;
  font-size: 0.8rem;
  padding: 0.5rem 0.85rem;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  margin-bottom: 0.35rem;
}
.df-photo-hint {
  font-size: 0.68rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* ── SKILL ROWS (barras) ─────────────────────────────────── */
.df-skill-item {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  background: rgba(240, 243, 248, 0.03);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.75rem;
  position: relative;
}
.df-skill-top {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.df-skill-input {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--text);
  font-family: "DM Sans", sans-serif;
  font-size: 0.9rem;
  outline: none;
  padding: 0;
}
.df-skill-remove {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
  -webkit-tap-highlight-color: transparent;
}
.df-skill-remove:active {
  color: var(--danger);
}

.df-skill-level-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.df-skill-slider {
  flex: 1;
  -webkit-appearance: none;
  appearance: none;
  height: 4px;
  border-radius: 2px;
  background: var(--border);
  outline: none;
  cursor: pointer;
}
.df-skill-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--accent);
  cursor: pointer;
  border: 2px solid var(--ink);
}
.df-skill-slider::-moz-range-thumb {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--accent);
  cursor: pointer;
  border: 2px solid var(--ink);
}
.df-skill-pct {
  font-family: "DM Mono", monospace;
  font-size: 0.65rem;
  color: var(--text-muted);
  width: 32px;
  text-align: right;
  flex-shrink: 0;
}

/* ── BADGES (hard skills / software) ────────────────────── */
.df-tags-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0.5rem;
  background: var(--input-bg);
  border: 1px solid var(--input-border);
  border-radius: 10px;
  min-height: 48px;
  cursor: text;
}
.df-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  background: rgba(212, 66, 10, 0.15);
  border: 1px solid rgba(212, 66, 10, 0.3);
  border-radius: 6px;
  padding: 0.25rem 0.5rem;
  font-size: 0.78rem;
  color: var(--paper);
}
.df-tag-remove {
  background: transparent;
  border: none;
  color: rgba(240, 243, 248, 0.5);
  cursor: pointer;
  font-size: 0.85rem;
  line-height: 1;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}
.df-tag-input {
  flex: 1;
  min-width: 100px;
  background: transparent;
  border: none;
  color: var(--text);
  font-family: "DM Sans", sans-serif;
  font-size: 0.88rem;
  outline: none;
  padding: 0.15rem 0.25rem;
}

/* ── DOTS DE IDIOMA ──────────────────────────────────────── */
.df-lang-dots {
  display: flex;
  gap: 6px;
  margin-top: 0.35rem;
}
.df-lang-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 1.5px solid var(--accent);
  background: transparent;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background 0.15s;
  flex-shrink: 0;
}
.df-lang-dot.filled {
  background: var(--accent);
}

/* ── BLOCOS DINÂMICOS ────────────────────────────────────── */
.df-block {
  background: rgba(240, 243, 248, 0.03);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  position: relative;
}

.df-block-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.df-block-title {
  font-family: "DM Mono", monospace;
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.df-block-remove {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 0.75rem;
  cursor: pointer;
  padding: 0.25rem 0.5rem;
  border-radius: 6px;
  -webkit-tap-highlight-color: transparent;
  display: flex;
  align-items: center;
  gap: 0.3rem;
}
.df-block-remove:active {
  color: var(--danger);
}

/* Bullets de experiência */
.df-bullets {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.df-bullet-item {
  display: flex;
  gap: 0.5rem;
  align-items: flex-start;
}
.df-bullet-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  margin-top: 0.6rem;
  flex-shrink: 0;
}
.df-bullet-input {
  flex: 1;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border);
  color: var(--text);
  font-family: "DM Sans", sans-serif;
  font-size: 0.88rem;
  outline: none;
  padding: 0.25rem 0;
  line-height: 1.5;
  resize: none;
  min-height: 36px;
}
.df-bullet-input:focus {
  border-bottom-color: var(--accent);
}

.df-bullet-remove {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 0.9rem;
  padding: 0.25rem;
  flex-shrink: 0;
  margin-top: 0.2rem;
  -webkit-tap-highlight-color: transparent;
}
.df-bullet-remove:active {
  color: var(--danger);
}

/* ── BOTÃO ADICIONAR ─────────────────────────────────────── */
.df-add-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  width: 100%;
  padding: 0.65rem;
  background: transparent;
  border: 1px dashed rgba(212, 66, 10, 0.35);
  border-radius: 10px;
  color: var(--accent);
  font-family: "DM Sans", sans-serif;
  font-size: 0.82rem;
  font-weight: 500;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition:
    background 0.15s,
    border-color 0.15s;
}
.df-add-btn:active {
  background: rgba(212, 66, 10, 0.08);
  border-color: var(--accent);
}

/* ── BOTTOM ACTION BAR ───────────────────────────────────── */
.df-bottom-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 300;
  background: rgba(13, 15, 20, 0.97);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid var(--border);
  padding: 0.85rem 1.25rem;
  padding-bottom: calc(0.85rem + env(safe-area-inset-bottom, 0px));
  display: flex;
  gap: 0.75rem;
}

.df-btn-secondary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.75rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--text);
  font-family: "DM Sans", sans-serif;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
  flex-shrink: 0;
}

.df-btn-primary {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.25rem;
  background: var(--accent);
  border: none;
  border-radius: 12px;
  color: #fff;
  font-family: "DM Sans", sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background 0.15s;
}
.df-btn-primary:active {
  background: var(--accent2);
}

.df-btn-primary svg,
.df-btn-secondary svg {
  width: 15px;
  height: 15px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  flex-shrink: 0;
}

/* ── TOAST ───────────────────────────────────────────────── */
.df-toast {
  position: fixed;
  bottom: calc(80px + env(safe-area-inset-bottom, 0px) + 0.75rem);
  left: 50%;
  transform: translateX(-50%) translateY(8px);
  background: rgba(13, 15, 20, 0.97);
  color: var(--paper);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: 10px;
  padding: 0.7rem 1.1rem;
  font-size: 0.82rem;
  white-space: nowrap;
  z-index: 400;
  opacity: 0;
  transition:
    opacity 0.25s,
    transform 0.25s;
  pointer-events: none;
}
.df-toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
