:root {
    --primary-color: #4a6fa5;
    --secondary-color: #6b8cae;
    --background-color: #f5f7fa;
    --text-color: #333;
    --light-gray: #e0e0e0;
    --white: #fff;
    --success-color: #4caf50;
    --error-color: #f44336;
    --footer-bg: #2c3e50;
    --footer-text: #ecf0f1;
  }
  
  * {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
  }
  
  body {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
  }
  
  /* Animaciones */
  @keyframes fadeInDown {
    to { transform: translateY(0); opacity: 1; }
  }
  
  @keyframes fadeInUp {
    to { transform: scale(1); opacity: 1; }
  }
  
  @keyframes fadeInUpButton {
    to { transform: translateY(0); opacity: 1; }
  }
  
  @keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
    20%, 40%, 60%, 80% { transform: translateX(5px); }
  }
  
  /* Componentes reutilizables */
  .flex-center {
    display: flex;
    justify-content: center;
    align-items: center;
  }
  
  .card {
    background: var(--white);
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  }
  
  /* Estructura principal */
  .banner {
    text-align: center;
    padding: 1.5rem 0;
    background-color: var(--primary-color);
    color: var(--white);
    transform: translateY(-20px);
    opacity: 0;
    animation: fadeInDown 0.6s forwards;
  }
  
  .banner h1 {
    font-size: 2.2rem;
    font-weight: 300;
    margin-bottom: 0.5rem;
  }
  
  .subtitle {
    font-size: 0.9rem;
    opacity: 0.8;
  }
  
  .container {
    width: 100%;
    flex: 1;
    padding: 1rem;
  }
  
  /* Formulario */
  form {
    width: 100%;
    max-width: 400px;
    padding: 2rem;
    margin: 2rem 0;
    transform: scale(0.95);
    opacity: 0;
    animation: fadeInUp 0.5s 0.3s forwards;
  }
  
  h2 {
    margin-bottom: 1.5rem;
    color: var(--primary-color);
    text-align: center;
    font-weight: 500;
  }
  
  label {
    display: block;
    margin-top: 1rem;
    font-weight: 500;
    color: var(--text-color);
    font-size: 0.95rem;
  }
  
  input, textarea {
    width: 100%;
    padding: 0.8rem;
    margin-top: 0.5rem;
    border: 1px solid var(--light-gray);
    border-radius: 6px;
    font-size: 1rem;
    transition: all 0.3s ease;
  }
  
  textarea {
    resize: vertical;
    min-height: 80px;
    font-family: inherit;
  }
  
  input:focus, textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(74, 111, 165, 0.2);
  }
  
  button {
    width: 100%;
    padding: 0.8rem;
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    margin-top: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    transform: translateY(5px);
    opacity: 0;
    animation: fadeInUpButton 0.5s 0.6s forwards;
  }
  
  button:hover {
    background-color: var(--secondary-color);
    transform: translateY(-2px);
  }
  
  button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
  }
  
  #msg {
    margin-top: 1rem;
    text-align: center;
    font-size: 0.9rem;
    min-height: 1.5rem;
    transition: all 0.3s ease;
  }
  
  /* Footer */
  .footer {
    background-color: var(--footer-bg);
    color: var(--footer-text);
    padding: 1.5rem 0;
    text-align: center;
    margin-top: auto;
    transform: translateY(20px);
    opacity: 0;
    animation: fadeInUp 0.6s 0.4s forwards;
  }
  
  .footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
  }
  
  .footer-links {
    margin-top: 0.8rem;
  }
  
  .footer-links a {
    color: var(--footer-text);
    text-decoration: none;
    margin: 0 0.5rem;
    font-size: 0.9rem;
    opacity: 0.8;
    transition: opacity 0.3s;
  }
  
  .footer-links a:hover {
    opacity: 1;
    text-decoration: underline;
  }
  
  /* Clases utilitarias */
  .shake {
    animation: shake 0.5s;
  }
  
  .flex-center {
    display: flex;
    justify-content: center;
    align-items: center;
  }
  
  /* Responsive */
  @media (max-width: 480px) {
    .banner h1 {
      font-size: 1.8rem;
    }
    
    form {
      padding: 1.5rem;
    }
    
    input, button {
      padding: 0.7rem;
    }
    
    .footer-links {
      display: flex;
      flex-direction: column;
      gap: 0.5rem;
    }
    
    .footer-links a {
      margin: 0;
    }
  }

  .container {
    width: 100%;
    flex: 1;
    padding: 1rem;
    display: flex;
    justify-content: center;
    align-items: center;
  }

  #msg {
    margin-top: 1em;
    font-weight: bold;
  }
  
  /* Estilo para el botón de volver */
  .back-button {
    position: absolute;
    top: 1rem;
    left: 1rem;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
  }
  
  .back-button:hover {
    background: rgba(255, 255, 255, 0.3);
  }
  
  .back-button svg {
    width: 16px;
    height: 16px;
    fill: currentColor;
  }
  
  @media (max-width: 480px) {
    .back-button {
      top: 0.5rem;
      left: 0.5rem;
      padding: 0.4rem 0.8rem;
      font-size: 0.9rem;
    }
  }