:root {
    --foreground: #0f172a;
  }
  
  * {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Inter", system-ui, -apple-system, sans-serif;
  }
  
  body {
    background-color: #f8fafc;
    color: #1e293b;
    line-height: 1.5;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    padding-top: 70px;
  }
  
  
  header {
    background: white;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
  }
  
  nav {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }
  
  .logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    font-size: 1.2rem;
    color: #2563eb;
  }
  
  .logo a {
    color: #2563eb;
    text-decoration: none;
  }
  
  .logo-icon {
    width: 24px;
    height: 24px;
    background: #2563eb;
    border-radius: 6px;
  }
  
  .nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
  }
  
  .nav-links a {
    text-decoration: none;
    color: #64748b;
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s;
  }
  
  .nav-links a:hover {
    color: #2563eb;
  }
  
  .back-btn {
    background: #2563eb;
    color: white !important;
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    transition: background-color 0.2s;
  }
  
  .back-btn:hover {
    background: #1d4ed8;
  }
  
  .menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #0f172a;
    cursor: pointer;
  }
  
  
  main {
    flex: 1;
    padding: 2rem;
  }
  
  .container {
    display: grid;
    grid-template-columns: 1fr;
    align-items: start;
    gap: 2rem;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 1rem;
  }
  
  @media (min-width: 1024px) {
    .container {
      grid-template-columns: 1fr 1fr;
      align-items: start;
      padding: 0 2rem;
    }
  }
  
.form-container,
.preview-container {
    flex: 1;
    background: white;
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
    transition: box-shadow 0.3s ease;
    width: 100%;
  }

  /* Mantém o preview visível próximo ao topo, inclusive em telas menores */
  .preview-container {
    position: sticky;
    top: 88px; /* header (70px) + espaçamento */
    min-height: 420px;
  }
  
  .form-container:hover,
  .preview-container:hover {
    box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  }
  
  @media (min-width: 1024px) {
    .preview-container { top: 2rem; min-height: 500px; }
  }

  /* Em telas grandes, o preview ao lado; em telas pequenas, vamos movê-lo para cima via DOM */
  @media (max-width: 1023px) {
    .preview-container { width: 100%; }
    .form-container { width: 100%; }
  }
  
  /* Form Elements */
  h2 {
    color: #0f172a;
    margin-bottom: 1.5rem;
    text-align: center;
    font-size: 1.5rem;
    font-weight: 600;
    letter-spacing: -0.025em;
  }
  
  .form-group {
    margin-bottom: 1.25rem;
  }
  
  label {
    display: block;
    margin-bottom: 0.5rem;
    color: #334155;
    font-weight: 500;
    font-size: 0.875rem;
  }
  .hint { display:block; color:#64748b; font-size: .8rem; margin-top:.25rem; }
  
  input,
  select,
  textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #e2e8f0;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    transition: all 0.2s ease;
    background-color: #fff;
  }
  
  input:hover,
  select:hover,
  textarea:hover {
    border-color: #cbd5e1;
  }
  
  input:focus,
  select:focus,
  textarea:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
  }
  
  textarea {
    min-height: 120px;
    resize: vertical;
  }
  

  .buttons-container {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1rem; 
    width: 100%;
    margin: 2rem 0; 
  }
  
  @media (min-width: 640px) {
    .buttons-container {
      flex-direction: row;
      justify-content: center;
      gap: 2rem; 
    }
  
    .btn,
    .btn-secondary,
    .btn-primary,
    .btn-clear,
    .remover-curso,
    .remover-experiencia,
    .adicionar-experiencia {
      margin: 0; 
    }
  }
  
  .btn,
  .btn-secondary,
  .btn-primary,
  .btn-clear,
  .remover-curso,
  .remover-experiencia,
  .adicionar-experiencia {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 0.5rem;
    cursor: pointer;
    font-weight: 500;
    font-size: 0.875rem;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: auto;
    max-width: none;
    margin: 0.25rem 0.25rem; 
  }
  
  .btn,
  .btn-primary {
    background-color: #3b82f6;
    color: white;
  }
  
  .btn:hover,
  .btn-primary:hover {
    background-color: #2563eb;
    transform: translateY(-1px);
  }
  
  .btn-secondary,
  .btn-clear {
    background-color: #64748b;
    color: white;
  }
  
  .btn-secondary:hover,
  .btn-clear:hover {
    background-color: #475569;
    transform: translateY(-1px);
  }
  
  .btn-download {
    background-color: #22c55e;
    color: white;
    width: 100%;
    margin-top: 1rem;
  }
  
  .btn-download:hover {
    background-color: #16a34a;
  }
  
  
  .experiencia-item,
  .curso-item {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding: 1.5rem;
    border: 1px solid #e2e8f0;
    border-radius: 0.75rem;
    background-color: #f8fafc;
  }
  
  .experiencia-actions,
  .curso-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
  }

  .btn-icon {
    appearance: none;
    border: 1px solid #e2e8f0;
    background: #fff;
    color: #0f172a;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all .2s ease;
    box-shadow: 0 1px 2px rgba(0,0,0,0.04);
  }

  .btn-icon:hover {
    background: #f8fafc;
    transform: translateY(-1px);
  }

  .btn-icon i { pointer-events: none; }
  
  @media (min-width: 640px) {
    .experiencia-actions,
    .curso-actions {
      flex-direction: row;
    }
  }
  
  .remover-experiencia,
  .remover-curso {
    background-color: #ef4444;
    color: white;
  }
  
  .remover-experiencia:hover,
  .remover-curso:hover {
    background-color: #dc2626;
  }
  
  .adicionar-experiencia {
    background-color: #64748b;
    color: white;
  }
  
  .adicionar-experiencia:hover {
    background-color: #475569;
  }
  
  /* Footer */
  footer {
    background: var(--foreground);
    color: white;
    padding: 4rem 0 2rem;
    width: 100%;
    min-height: 300px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
  }
  
  .footer-content {
    max-width: 1200px;
    width: 95%;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
    padding: 0 1rem;
  }
  
  @media (min-width: 768px) {
    .footer-content {
      flex-direction: row;
      justify-content: space-between;
      padding: 0 2rem;
    }
  }
  
  .footer-links {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }
  
  @media (min-width: 768px) {
    .footer-links {
      flex-direction: row;
      gap: 2rem;
      text-align: left;
    }
  }
  
  .footer-links a {
    color: white;
    text-decoration: none;
    opacity: 0.8;
    transition: opacity 0.2s;
  }
  
  .footer-links a:hover {
    opacity: 1;
  }
  
  .footer-divider {
    width: 90%;
    max-width: 1200px;
    margin: 2rem auto;
    border: none;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
  }
  
  .footer-bottom {
    text-align: center;
    width: 95%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
    color: rgba(255, 255, 255, 0.8);
  }
  
  
  @media (max-width: 1024px) {
    .menu-toggle {
      display: block;
    }
  
    .nav-links {
      display: none;
      position: absolute;
      top: 100%;
      left: 0;
      right: 0;
      background: white;
      padding: 1rem;
      flex-direction: column;
      box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    }
  
    .nav-links.active {
      display: flex;
    }
  }
  
  
  @media print {
    body {
      padding: 0;
      margin: 0;
      background: none;
      color: black;
      font-size: 12pt;
      line-height: 1.5;
    }
  
    .form-container,
    header,
    footer,
    .actions,
    .btn,
    .btn-secondary,
    .btn-primary,
    .btn-download {
      display: none !important;
    }
  
    .container {
      display: block;
      padding: 0;
      margin: 0;
      width: 100%;
      max-width: none;
    }
  
    .preview-container {
      box-shadow: none;
      padding: 20mm;
      border: none;
      background: none;
      width: 100%;
    }
  
    #curriculo {
      font-size: 11pt;
      line-height: 1.4;
    }
  
    #curriculo h1 {
      font-size: 18pt;
      margin-bottom: 15pt;
      color: black;
    }
  
    #curriculo .section {
      margin-bottom: 12pt;
      padding-bottom: 8pt;
      border-bottom: 1pt solid #000;
      break-inside: avoid;
    }
  
    #curriculo .section-title {
      font-size: 14pt;
      font-weight: bold;
      margin-bottom: 8pt;
      color: black;
    }
  
    h1,
    h2,
    h3,
    .section-title {
      break-after: avoid;
    }
  
    @page {
      margin: 0;
      size: A4;
    }
  
    a {
      text-decoration: none;
      color: black;
    }
  
    a[href^="http"]:after {
      content: " (" attr(href) ")";
      font-size: 10pt;
      font-style: italic;
    }
  
    * {
      -webkit-print-color-adjust: exact;
      print-color-adjust: exact;
      color-adjust: exact;
      color: black !important;
      background-color: transparent !important;
    }
  }

  /* Estilos dos modelos de currículo */
  #curriculo .cv {
    color: #0f172a;
  }

  #curriculo .cv .header {
    text-align: center;
    margin-bottom: 20px;
  }

  #curriculo .cv h1 {
    text-transform: uppercase;
    margin-bottom: 10px;
    font-size: 1.5rem;
  }

  #curriculo .cv .contacts {
    margin-bottom: 15px;
    font-size: 0.95rem;
  }

  #curriculo .cv .keywords {
    background-color: #f5f5f5;
    padding: 10px;
    margin-bottom: 20px;
    text-align: center;
  }

  #curriculo .cv .section {
    margin-bottom: 20px;
  }

  #curriculo .cv .section-title {
    font-weight: 700;
    margin-bottom: 10px;
  }

  #curriculo .cv ul {
    margin-left: 20px;
  }

  /* Variantes */
  #curriculo .cv--classico .section-title {
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 4px;
  }

  #curriculo .cv--moderno .header {
    border-bottom: 3px solid #2563eb;
    padding-bottom: 10px;
  }

  #curriculo .cv--moderno .section-title {
    color: #2563eb;
    letter-spacing: 0.02em;
  }
  
  
