.currency-input-wrapper {
  position: relative;
  margin-bottom: 0.5rem;
  display: flex;
  flex-direction: column;

  input {
    width: 100%;
    padding: 12px 40px 12px 14px; /* Espaço extra à direita para o ícone */
    border: 2px solid var(--divider, #e0e0e0);
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    color: var(--text-primary, #333);
    background-color: var(--surface, #ffffff);
    transition: all 0.2s ease;
    box-sizing: border-box;

    &:focus {
      outline: none;
      border-color: var(--primary, #007bff);
      box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
    }

    &:hover:not(:disabled):not(:readonly) {
      border-color: var(--primary-light, #66b3ff);
    }

    &::placeholder {
      color: transparent;
    }

    // Estados especiais
    &:disabled {
      background-color: var(--surface-disabled, #f5f5f5);
      color: var(--text-disabled, #999);
      cursor: not-allowed;
      border-color: var(--divider, #e0e0e0);
    }
  }

  label {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    background-color: var(--surface, #ffffff);
    color: var(--text-secondary, #666);
    font-size: 16px;
    font-weight: 500;
    transition: all 0.2s ease;
    pointer-events: none;
    padding: 0 4px;
    white-space: nowrap;
    z-index: 2;

    &.active {
      top: 0;
      font-size: 12px;
      font-weight: 600;
      color: var(--primary, #007bff);
    }
  }

  // Ícone de moeda
  .currency-icon {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary, #666);
    font-size: 14px;
    pointer-events: none;
    z-index: 2;

    i {
      opacity: 0.7;
    }
  }

  // Estados de foco
  &.focused {
    input {
      border-color: var(--primary, #007bff);
      box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
    }

    label {
      color: var(--primary, #007bff);
    }

    .currency-icon i {
      opacity: 1;
      color: var(--primary, #007bff);
    }
  }

  // Estados para readonly
  &.readonly {
    input {
      background-color: var(--surface-disabled, #f8f9fa) !important;
      color: var(--text-secondary, #666) !important;
      cursor: not-allowed !important;
      border-color: var(--divider, #e0e0e0) !important;

      &:focus {
        box-shadow: none !important;
        border-color: var(--divider, #e0e0e0) !important;
      }
    }

    label {
      color: var(--text-secondary, #666) !important;

      &.active {
        color: var(--text-secondary, #666) !important;
      }
    }

    &::after {
      content: '\f023'; /* FontAwesome lock icon */
      font-family: 'Font Awesome 5 Free';
      font-weight: 900;
      position: absolute;
      right: 12px;
      top: 50%;
      transform: translateY(-50%);
      color: var(--text-secondary, #666);
      font-size: 12px;
      opacity: 0.7;
      pointer-events: none;
      z-index: 3;
    }

    .currency-icon {
      display: none;
    }
  }

  // Informações de valor
  .value-info {
    margin-top: 4px;
    font-size: 12px;
    color: var(--text-secondary, #666);
    text-align: right;

    .text-muted {
      opacity: 0.8;
    }
  }

  // Indicador de campo obrigatório
  .required-indicator {
    color: var(--danger, #dc3545);
    margin-left: 4px;
    font-weight: 700;
    font-size: 14px;
  }

  // Responsividade
  @media (max-width: 768px) {
    input {
      font-size: 16px; // Evita zoom no iOS
      padding: 14px 40px 14px 16px;
    }

    label {
      left: 16px;
      
      &.active {
        font-size: 11px;
      }
    }

    .currency-icon {
      right: 14px;
    }
  }

  // Animações suaves
  input, label, .currency-icon {
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  }

  // Estados de validação (para integração futura)
  &.error {
    input {
      border-color: var(--danger, #dc3545);
      
      &:focus {
        box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.1);
      }
    }

    label.active {
      color: var(--danger, #dc3545);
    }
  }

  &.success {
    input {
      border-color: var(--success, #28a745);
      
      &:focus {
        box-shadow: 0 0 0 3px rgba(40, 167, 69, 0.1);
      }
    }

    label.active {
      color: var(--success, #28a745);
    }
  }
} 